Click to Dial

After creating a Service User within the Chronicall UI, you will be given an authentication key.
Anytime a request is made to the API, an authentication key must be present.

Add the following header to your API request:

 Authorization : Bearer {authentication_key}

By having the authorization key present, you will be able to access everything that the Service User is set up in Chronicall to have access to.

Note: For this feature, you must be updated to version 4.2.3 or newer.

Use Cases

Programmatically make a call (Click to Dial) for an agent. When this endpoint is used, it will dial the desired agent's extension. Then, once connected with the agent, it will connect the call to the desired "numberToDial".

Click to Dial

POST /rest/api/v1/agents/{AgentId}/click-to-dial

Will Click to Dial the number for the agent.

Arguments


AgentId


The AgentId of the desired agent.




externalPrefix




The dial out external prefix, e.g., 9.




numberToDial




The number the agent should dial. This can be an extension or an external number. It should be formatted as the agent would dial it.

{
  "externalPrefix" : "9",
  "numberToDial" : "8017132800"
}

Response

204 status code for success.

Status Code

Failure


400 Bad Request


Malformed JSON request body.




401 Unauthorized




The authorization header wasn’t valid.




403 Forbidden




The authenticated user doesn’t have Chronicall access to view data one or more of the requested agents or groups.