Get agents
Use this method to get a list of agents with pagination and filtering options. Using a filter is optional. The result can be filtered by one or many optional filters described in parameters. More info
Authorizations:
Scopes:
query Parameters
agentIds | Array of strings Optional filter. List of agents Id to match result. |
queueIds | Array of strings Optional filter. List of queues Id to match result. |
displayName | string Optional. Agent display name. This is case insensitive and will search for substring anywhere within string, 255 characters max. |
status | string Enum: "ACTIVE" "BUSY" "INVISIBLE" "AWAY" Optional. Indicates a status set by the agent reflecting their availability preferences. |
availability | string Enum: "ACTIVE" "BUSY" "INVISIBLE" "AWAY" Optional. Indicates the agent status set by the system reflecting the actual availability. |
role | string Enum: "AGENT" "SUPERVISOR" Optional. Agent role. |
enabled | boolean Optional. Agent enable/disable toggle. |
createdAfter | string <date-time> Optional. Filter results created after specific date and time. Format: yyyy-MM-dd'T'HH:mm:ss.SSSZ |
createdBefore | string <date-time> Optional. Filter results created before specific date and time. Format: yyyy-MM-dd'T'HH:mm:ss.SSSZ |
updatedAfter | string <date-time> Optional. Filter results updated after specific date and time. Format: yyyy-MM-dd'T'HH:mm:ss.SSSZ |
updatedBefore | string <date-time> Optional. Filter results updated before specific date and time. Format: yyyy-MM-dd'T'HH:mm:ss.SSSZ |
limit | integer <int64> <= 999 Default: 10 Size of the result page. |
page | integer <int64> Default: 0 Number of the current page. |
orderBy | string This parameter is used to order your results. If an order is not given, the default order id:asc will be applied. Possible ordering fields are properties. Ordering direction can be specified with modifiers asc for the ascending ordering or desc for the descending one. |
Responses
OK
Bad request
Unauthorized
Forbidden
Internal Server Error
Request samples
- cURL
- Java
- C#
- Go
- Python
- PHP
- JavaScript
- NodeJs
- Ruby
curl -L -g 'https://{baseUrl}/ccaas/1/agents' \ -H 'Authorization: {authorization}' \ -H 'Accept: application/json'
Response samples
- 200
- 400
- 401
- 403
- 500
{- "agents": [
- {
- "id": "9030551F327704A0F262995A1A4B4596",
- "displayName": "Malcolm Young",
- "status": "INVISIBLE",
- "availability": "AWAY",
- "role": "AGENT",
- "enabled": true,
- "createdAt": "2019-05-10T07:45:23.777+0000",
- "updatedAt": "2019-05-10T09:53:58.463+0000"
}, - {
- "id": "97457D13B1FC79AF3C1A1096AE7E77AB",
- "displayName": "Angus Young",
- "status": "ACTIVE",
- "availability": "BUSY",
- "role": "SUPERVISOR",
- "enabled": true,
- "createdAt": "2019-05-10T07:45:23.777+0000",
- "updatedAt": "2019-05-10T09:53:58.463+0000"
}, - {
- "id": "E83E787CF2613450157ADA3476171E3F",
- "displayName": "Bon Scott",
- "status": "INVISIBLE",
- "availability": "BUSY",
- "role": "AGENT",
- "enabled": true,
- "createdAt": "2019-05-10T07:45:23.777+0000",
- "updatedAt": "2019-05-10T09:53:58.463+0000"
}, - {
- "id": "F66D67327326FCCB027BEAA916B94542",
- "displayName": "Phil Rudd",
- "status": "ACTIVE",
- "availability": "ACTIVE",
- "role": "AGENT",
- "enabled": true,
- "createdAt": "2019-05-10T07:45:23.777+0000",
- "updatedAt": "2019-05-10T09:53:58.463+0000"
}, - {
- "id": "F66D67327326FCCB027BEAA916B94542",
- "displayName": "Brian Johnson",
- "status": "ACTIVE",
- "availability": "BUSY",
- "role": "AGENT",
- "enabled": true,
- "createdAt": "2019-05-10T07:45:23.777+0000",
- "updatedAt": "2019-05-10T09:53:58.463+0000"
}, - {
- "id": "7E77AB97457D13B1FC79AF3C1A1096AE7E77AB",
- "displayName": "Neil Young",
- "status": "ACTIVE",
- "availability": "ACTIVE",
- "role": "AGENT",
- "enabled": false,
- "createdAt": "2019-03-10T07:45:44.744+0000",
- "updatedAt": "2019-03-10T09:33:58.374+0000"
}
], - "pagination": {
- "totalItems": 6,
- "page": 0,
- "limit": 10,
- "orderBy": "id:ASC"
}
}
Need assistance
Encountering issues
What's new? Check out
Unsure about a term? See