Change the state of an agent.
This API enables you to control the agent states (applicable for offline agents only) within the account directly through your CRM system.
To use this API with the help of a token, follow these steps:
- Generate the Token: Use the 'Generate Token' API to obtain an authentication token.
- Enter the Token ID: Navigate to the right section of this page, under the 'AUTHORIZATION' tab. Here, input the generated token ID.
- With the token entered, pass the below header and body parameters:
APIs Domain NameFor domestic ccaas - enter the domain: in1-ccaas-api.ozonetel.com
For international ccaas - enter the domain: api.ccaas.ozonetel.com
For Partners - enter the respective URL
Header parameters
| Parameter | Description |
|---|---|
| Content-Type | application/json |
Body Params
| Parameter | Description |
|---|---|
| userName* | Your CloudAgent account username |
| phoneName | Phone name of the agent configured in the CloudAgent account. |
| state* | Mention the agent state change - 'Ready', 'Pause' |
| agentId* | The unique ID assigned to an agent |
| pauseReason | The reason provided if the state is 'Pause' |
Note
- Parameters with ‘*’ are considered to be mandatory parameters.
- This API is applicable only in case of offline agents
Possible responses
Invalid apiKey | "status": "error" |
Empty apiKey | "status": "error" |
Invalid userName | "status": "error" |
Empty userName | "status": "error" |
Invalid state | "status": "error" |
Passing Invalid pauseReason Value. When the user passes State as Pause. | "status":"error", |
Changing the agent to 'Pause' / 'Ready" state when he is not logged in. | "status":"error", |
Changing the agent to Pause state when he is in ACW state. | "status":"error", |
Changing the agent to Pause state when he is in BUSY state. | "status":"error", |
Success response | "status": "success" |
