Bugfix: Get correct endpoint
Merge pull request #135 from guidow/send_tasks_to_agents

Bugfix: Get correct endpoint