Auto Distribution
- 09 Oct 2024
- 5 Minutes to read
- Print
- DarkLight
Auto Distribution
- Updated on 09 Oct 2024
- 5 Minutes to read
- Print
- DarkLight
Article summary
Did you find this summary helpful?
Thank you for your feedback
Auto Distribution
You need the Manage Settings permission to manage Auto Distrubution
Auto Distribution
- Auto Distribution ManageGET livechat/autoDistributionConfig
- Get the Auto Distribution ConfigurationsPOST livechat/autoDistributionConfig:disable
- Disable the Auto DistributionPOST livechat/autoDistributionConfig:enable
- Enable the Auto DistributionPUT livechat/autoDistributionConfig
- Update the Auto Distribution Configuration
Auto Distribution JSON Format
Auto Distribution is represented as simple flat JSON objects with the following keys:
Name | Type | Description |
---|---|---|
isEnabled | bool | Whether auto distribution is enabled or not. |
autoDistributionMethod | string | Allowed values are "loadBalancing", "roundRobin", "capabilityWeighted". |
isLastChattedAgentPreferredForAutoDistribution | bool | Whether the last-chatted agent is preferred or not. |
ifLimitMaxConcurrentChatsForAllAgents | bool | Whether to set the same maximum number of chats for all agents. |
maxConcurrentChatsForAllAgents | integer | Maximum number of chats for all agents. |
ifAgentCanManuallyAcceptChatsAfterReachingMaxChatsLimit | bool | Whether to allow agent to manually accept chat after reaching max chats limit in agent console. |
ifNotAutoDistributeChatsToAgentsWhenHavingAudioVideoChat | bool | Whether to allocate chats to agents who are having audio or video chats. |
agentAutoDistributionConfigs | agentAutoDistributionConfigs[] | Reference to Agent Auto Distribution. |
departmentAutoDistributionConfigs | departmentAutoDistributionConfigs[] | Reference to Department Auto Distribution. |
Agent Auto Distribution JSON Format:
Name | Type | Description |
---|---|---|
ifAutoAcceptChat | bool | When it is false, the agent will not accept chat automatically. Default: true. |
maxConcurrentChats | integer | Maximum chat number. |
agentId | guid | Id of the agent. |
agent | agent[] | Reference to Agent. |
Department Auto Distribution JSON Format:
Name | Type | Description |
---|---|---|
departmentId | guid | Id of the department. |
autoDistributionMethod | string | Allowed values are "loadBalancing", "roundRobin", "capabilityWeighted". |
isLastChattedAgentPreferred | bool | Whether the last chatted agent is preferred or not. |
backupDepartmentId | guid | Id of the backup department. This field is deprecated, use "backupDepartments" instead. |
department | department[] | Reference to department. |
backupDepartments | backupDepartments[] | Reference to Backup Department Auto Distribution. |
Backup Department Auto Distribution JSON Format:
Name | Type | Description |
---|---|---|
departmentId | guid | Id of the department. |
backupDepartmentId | guid | Id of the backup department. |
order | integer | Order of the backup department. |
id | guid | Id of the backup department auto distribution. |
Get the Auto Distribution Configurations
GET livechat/autoDistributionConfig
Parameters:
No Parameters
Response:
Example
Sample Request:
curl https://api11.comm100.io/v4/livechat/autoDistributionConfig \
-X 'GET' \
-H 'Authorization: Bearer {access_token}' \
Response:
HTTP/1.1 200 OK
{
"isEnabled": true,
"autoDistributionMethod": "capabilityWeighted",
"isLastChattedAgentPreferredForAutoDistribution": true,
"ifLimitMaxConcurrentChatsForAllAgents": true,
"maxConcurrentChatsForAllAgents": 1,
"ifAgentCanManuallyAcceptChatsAfterReachingMaxChatsLimit": true,
"ifNotAutoDistributeChatsToAgentsWhenHavingAudioVideoChat": true,
"agentAutoDistributionConfigs": [
{
"agentId": "2d950b8f-d8f7-4fd8-986f-befe4abb9cd4",
"maxConcurrentChats": 999,
"ifAutoAcceptChat": true,
"agent": {
"avatar": "https://api11.comm100.io/Global/agents/2d950b8f-d8f7-4fd8-986f-befe4abb9cd4/avatar?SiteId=10100000&version=e27fddde04b7a554e657a6be21e7b755",
"id": "2d950b8f-d8f7-4fd8-986f-befe4abb9cd4",
"email": "oden@beta.com",
"displayName": "Oden",
"firstName": "Oden",
"lastName": "Beta",
"isAdmin": true,
"isActive": true,
"phone": "",
"title": "11",
"bio": "",
"timeZone": "Arabic Standard Time",
"datetimeFormat": "DD/MM/YYYY HH:mm:ss",
"systemAvatarId": "2b68a098-f138-eb11-ac9f-18c04d023ea9",
"ifCustomizeAvatar": false,
"customizeAvatar": null,
"createdTime": "2021-01-30T03:03:51.78Z",
"isLocked": false,
"lockedTime": "2021-01-30T03:03:51.9466667Z",
"isDeleted": false,
"language": "en",
"superAgentId": "00000000-0000-0000-0000-000000000000",
"externalId": "",
"permissionIds": [
1024
],
"departmentIds": [
"0d1b1d6e-5784-4f2d-9b9c-21bd8358f04c"
],
"roleIds": [
"b8cc04bc-a562-eb11-aac4-0219204b659b"
],
"shiftIds": [],
"chatbotSmartTriggerActionIds": [],
"triggerIds": [
"d84427d9-6ea6-440f-8d31-3d55d98f7aff"
],
"segmentIds": [],
"skillIds": []
}
}
],
"departmentAutoDistributionConfigs": [
{
"departmentId": "40dcf4ea-10fe-4c71-917b-50a71393085a",
"backupDepartmentId": "00000000-0000-0000-0000-000000000000",
"autoDistributionMethod": "loadBalancing",
"isLastChattedAgentPreferred": true,
"department": {
"id": "40dcf4ea-10fe-4c71-917b-50a71393085a",
"name": "depart",
"description": "ment",
"isAvailableInLiveChat": true,
"isAvailableInTicketingAndMessaging": true,
"offlineMessageMailTo": "toAllAgents",
"offlineMessageEmailAddresses": "",
"isDeleted": false,
"agentIds": [
"6a076e05-50f9-424b-b356-cacbc7f99065"
],
"chatbotSmartTriggerActionIds": [],
"shiftIds": [],
"segmentIds": []
},
"backupDepartments": [
{
"departmentId": "40dcf4ea-10fe-4c71-917b-50a71393085a",
"backupDepartmentId": "007ac439-b73c-461b-9bde-da2dbb4437af",
"order": 1,
"id": "a6c52b55-4261-4ca5-8f30-1f770538e599"
},
{
"departmentId": "40dcf4ea-10fe-4c71-917b-50a71393085a",
"backupDepartmentId": "f1ff3fff-33ab-46dd-a9f3-7ca415df9b25",
"order": 2,
"id": "04dbb0a6-ffc1-4e28-bbf9-c57dca28bbd2"
}
]
}
]
}
Disable the Auto Distribution
POST livechat/autoDistributionConfig:disable
Parameters:
No Parameters
Response:
Example
Sample Request:
curl https://api11.comm100.io/v4/livechat/autoDistributionConfig:disable \
-X 'POST' \
-H 'Authorization: Bearer {access_token}' \
Response:
HTTP/1.1 200 OK
{
"isEnabled": false,
"autoDistributionMethod": "loadBalancing",
"isLastChattedAgentPreferredForAutoDistribution": true,
"ifLimitMaxConcurrentChatsForAllAgents": true,
"maxConcurrentChatsForAllAgents": 3,
"ifAgentCanManuallyAcceptChatsAfterReachingMaxChatsLimit": true,
"ifNotAutoDistributeChatsToAgentsWhenHavingAudioVideoChat": true,
"agentAutoDistributionConfigs": [
{
"ifAutoAcceptChat": true,
"maxConcurrentChats": 3,
"agentId": "35DC397E-509F-4D34-A1DE-843CE5B26D93",
"agent": {
"id": "c2c165b7-d5ce-40e5-a492-f586f514a062",
"email": "andy@comm100.com",
"displayName": "Andy Liao",
"firstName": "Andy",
"lastName": "Liao",
"isAdmin": true,
"isActive": true,
"phone": "13712345678",
"title": "Manager",
"bio": "Hello, I am Andy",
"timeZone": "Pacific Standard Time",
"datetimeFormat": "YYYY/MM/DD HH:mm:ss",
"createdTime": "2020-12-25T06:01:00.913Z",
"isLocked": true,
"lockedTime": "2020-12-25T06:01:00.93Z",
"ifCustomizeAvatar": true,
"customizeAvatar": "https://dash11.comm100.io/Global/agents/c1ad60f8-e2e1-47d2-ad50-8b5de24d2b06/customizeAvatar?SiteId=10000&version=6e7b513d20baaf89b84e81e56d365111",
"systemAvatarId": "1383d4fd-3114-eb11-80fc-00155d081d0b",
"avatar": "https://api11.comm100.io/v4/Global/agents/c2c165b7-d5ce-40e5-a492-f586f514a062/avatar",
"permissionIds": [
"45A2EF45-7D46-EB11-8100-00155D081D0B"
],
"departmentIds": [
"b6ff11d8-0be7-4e99-b8c7-5a7ab501c69b"
],
"roleIds": [
"e0bf1302-d145-eb11-8100-00155d081d0b"
]
}
}
],
"departmentAutoDistributionConfigs": [
{
"departmentId": "C36A27EC-EC1E-4A86-8B15-3367FE680AD3",
"autoDistributionMethod": "0",
"isLastChattedAgentPreferred": true,
"backupDepartmentId": "DE314FF0-E864-4929-81E7-7E575F752037",
"backupDepartments": [
{
"departmentId": "C36A27EC-EC1E-4A86-8B15-3367FE680AD3",
"backupDepartmentId": "DE314FF0-E864-4929-81E7-7E575F752037",
"order": 1,
"id": "a6c52b55-4261-4ca5-8f30-1f770538e599"
}
]
}
]
}
Enable the Auto Distribution
POST livechat/autoDistributionConfig:enable
Parameters:
No Parameters
Response:
Example
Sample Request:
curl https://api11.comm100.io/v4/livechat/autoDistributionConfig:enable \
-X 'POST' \
-H 'Authorization: Bearer {access_token}' \
Response:
HTTP/1.1 200 OK
{
"isEnabled": true,
"autoDistributionMethod": "loadBalancing",
"isLastChattedAgentPreferredForAutoDistribution": true,
"ifLimitMaxConcurrentChatsForAllAgents": true,
"maxConcurrentChatsForAllAgents": 3,
"ifAgentCanManuallyAcceptChatsAfterReachingMaxChatsLimit": true,
"ifNotAutoDistributeChatsToAgentsWhenHavingAudioVideoChat": true,
"agentAutoDistributionConfigs": [
{
"ifAutoAcceptChat": true,
"maxConcurrentChats": 3,
"agentId": "35DC397E-509F-4D34-A1DE-843CE5B26D93",
"agent": {
"id": "c2c165b7-d5ce-40e5-a492-f586f514a062",
"email": "andy@comm100.com",
"displayName": "Andy Liao",
"firstName": "Andy",
"lastName": "Liao",
"isAdmin": true,
"isActive": true,
"phone": "13712345678",
"title": "Manager",
"bio": "Hello, I am Andy",
"timeZone": "Pacific Standard Time",
"datetimeFormat": "YYYY/MM/DD HH:mm:ss",
"createdTime": "2020-12-25T06:01:00.913Z",
"isLocked": true,
"lockedTime": "2020-12-25T06:01:00.93Z",
"ifCustomizeAvatar": true,
"customizeAvatar": "https://dash11.comm100.io/Global/agents/c1ad60f8-e2e1-47d2-ad50-8b5de24d2b06/customizeAvatar?SiteId=10000&version=6e7b513d20baaf89b84e81e56d365111",
"systemAvatarId": "1383d4fd-3114-eb11-80fc-00155d081d0b",
"avatar": "https://api11.comm100.io/v4/Global/agents/c2c165b7-d5ce-40e5-a492-f586f514a062/avatar",
"permissionIds": [
"45A2EF45-7D46-EB11-8100-00155D081D0B"
],
"departmentIds": [
"b6ff11d8-0be7-4e99-b8c7-5a7ab501c69b"
],
"roleIds": [
"e0bf1302-d145-eb11-8100-00155d081d0b"
]
}
}
],
"departmentAutoDistributionConfigs": [
{
"departmentId": "C36A27EC-EC1E-4A86-8B15-3367FE680AD3",
"autoDistributionMethod": "0",
"isLastChattedAgentPreferred": true,
"backupDepartmentId": "DE314FF0-E864-4929-81E7-7E575F752037",
"backupDepartments": [
{
"departmentId": "C36A27EC-EC1E-4A86-8B15-3367FE680AD3",
"backupDepartmentId": "DE314FF0-E864-4929-81E7-7E575F752037",
"order": 1,
"id": "a6c52b55-4261-4ca5-8f30-1f770538e599"
}
]
}
]
}
Update the Auto Distribution Configurations
PUT livechat/autoDistributionConfig
Parameters:
Name | Type | in | Required | Description |
---|---|---|---|---|
isEnabled | bool | body | no | Whether auto distribution is enabled or not. |
autoDistributionMethod | string | body | no | Allowed values are "loadBalancing", "roundRobin", "capabilityWeighted". |
isLastChattedAgentPreferredForAutoDistribution | bool | body | no | Whether the last-chatted agent is preferred or not. |
ifLimitMaxConcurrentChatsForAllAgents | bool | body | no | Whether to set the same maximum number of chats for all agents. |
maxConcurrentChatsForAllAgents | integer | body | no | Maximum number of chats for all agents. |
ifAgentCanManuallyAcceptChatsAfterReachingMaxChatsLimit | bool | body | no | Whether to allow agent to manually accept chat after reaching max chats limit in agent console. |
ifNotAutoDistributeChatsToAgentsWhenHavingAudioVideoChat | bool | body | no | Whether to allocate chats to agents who are having audio or video chats. |
agentAutoDistributionConfigs | agentAutoDistributionConfigs[] | body | no | Reference to Agent Auto Distribution. |
departmentAutoDistributionConfigs | departmentAutoDistributionConfigs[] | body | no | Reference to Department Auto Distribution. |
Response:
Example
Sample Request:
curl https://api11.comm100.io/v4/livechat/autoDistributionConfig \
-X 'PUT' \
-H 'Authorization: Bearer {access_token}' \
-H 'Content-Type: application/json' \
-D '{"isEnabled": true,"autoDistributionMethod": "loadBalancing","isLastChattedAgentPreferredForAutoDistribution": true,"ifLimitMaxConcurrentChatsForAllAgents": true,"maxConcurrentChatsForAllAgents": 3,"ifAgentCanManuallyAcceptChatsAfterReachingMaxChatsLimit": true,"ifNotAutoDistributeChatsToAgentsWhenHavingAudioVideoChat": true,"agentAutoDistributionConfigs": [{"agentId": "2d950b8f-d8f7-4fd8-986f-befe4abb9cd4","maxConcurrentChats": 999,"ifAutoAcceptChat": true,"agent": {"avatar": "https://api11.comm100.io/Global/agents/2d950b8f-d8f7-4fd8-986f-befe4abb9cd4/avatar?SiteId=10100000&version=e27fddde04b7a554e657a6be21e7b755","id": "2d950b8f-d8f7-4fd8-986f-befe4abb9cd4","email": "oden@beta.com","displayName": "Oden","firstName": "Oden","lastName": "Beta","isAdmin": true,"isActive": true,"phone": "","title": "11","bio": "","timeZone": "ArabicStandardTime","datetimeFormat": "DD/MM/YYYYHH:mm:ss","systemAvatarId": "2b68a098-f138-eb11-ac9f-18c04d023ea9","ifCustomizeAvatar": false,"customizeAvatar": null,"createdTime": "2021-01-30T03:03:51.78Z","isLocked": false,"lockedTime": "2021-01-30T03:03:51.9466667Z","isDeleted": false,"language": "en","superAgentId": "00000000-0000-0000-0000-000000000000","externalId": "","permissionIds": [1024],"departmentIds": ["0d1b1d6e-5784-4f2d-9b9c-21bd8358f04c"],"roleIds": ["b8cc04bc-a562-eb11-aac4-0219204b659b"],"shiftIds": [],"chatbotSmartTriggerActionIds": [],"triggerIds": ["d84427d9-6ea6-440f-8d31-3d55d98f7aff"],"segmentIds": [],"skillIds": []}}],"departmentAutoDistributionConfigs": [{"departmentId": "40dcf4ea-10fe-4c71-917b-50a71393085a","backupDepartments": [{"backupDepartmentId": "007ac439-b73c-461b-9bde-da2dbb4437af","order": 1},{"backupDepartmentId": "f1ff3fff-33ab-46dd-a9f3-7ca415df9b25","order": 2}],"autoDistributionMethod": "loadBalancing","isLastChattedAgentPreferred": true,"department": {"id": "40dcf4ea-10fe-4c71-917b-50a71393085a","name": "depart","description": "ment","isAvailableInLiveChat": true,"isAvailableInTicketingAndMessaging": true,"offlineMessageMailTo": "toAllAgents","offlineMessageEmailAddresses": "","isDeleted": false,"agentIds": ["6a076e05-50f9-424b-b356-cacbc7f99065"],"chatbotSmartTriggerActionIds": [],"shiftIds": [],"segmentIds": []}}]}'
Response:
HTTP/1.1 200 OK
{
"isEnabled": true,
"autoDistributionMethod": "loadBalancing",
"isLastChattedAgentPreferredForAutoDistribution": true,
"ifLimitMaxConcurrentChatsForAllAgents": true,
"maxConcurrentChatsForAllAgents": 3,
"ifAgentCanManuallyAcceptChatsAfterReachingMaxChatsLimit": true,
"ifNotAutoDistributeChatsToAgentsWhenHavingAudioVideoChat": true,
"agentAutoDistributionConfigs": [
{
"agentId": "2d950b8f-d8f7-4fd8-986f-befe4abb9cd4",
"maxConcurrentChats": 999,
"ifAutoAcceptChat": true,
"agent": {
"avatar": "https://api11.comm100.io/Global/agents/2d950b8f-d8f7-4fd8-986f-befe4abb9cd4/avatar?SiteId=10100000&version=e27fddde04b7a554e657a6be21e7b755",
"id": "2d950b8f-d8f7-4fd8-986f-befe4abb9cd4",
"email": "oden@beta.com",
"displayName": "Oden",
"firstName": "Oden",
"lastName": "Beta",
"isAdmin": true,
"isActive": true,
"phone": "",
"title": "11",
"bio": "",
"timeZone": "Arabic Standard Time",
"datetimeFormat": "DD/MM/YYYY HH:mm:ss",
"systemAvatarId": "2b68a098-f138-eb11-ac9f-18c04d023ea9",
"ifCustomizeAvatar": false,
"customizeAvatar": null,
"createdTime": "2021-01-30T03:03:51.78Z",
"isLocked": false,
"lockedTime": "2021-01-30T03:03:51.9466667Z",
"isDeleted": false,
"language": "en",
"superAgentId": "00000000-0000-0000-0000-000000000000",
"externalId": "",
"permissionIds": [
1024
],
"departmentIds": [
"0d1b1d6e-5784-4f2d-9b9c-21bd8358f04c"
],
"roleIds": [
"b8cc04bc-a562-eb11-aac4-0219204b659b"
],
"shiftIds": [],
"chatbotSmartTriggerActionIds": [],
"triggerIds": [
"d84427d9-6ea6-440f-8d31-3d55d98f7aff"
],
"segmentIds": [],
"skillIds": []
}
}
],
"departmentAutoDistributionConfigs": [
{
"departmentId": "40dcf4ea-10fe-4c71-917b-50a71393085a",
"backupDepartmentId": "00000000-0000-0000-0000-000000000000",
"autoDistributionMethod": "loadBalancing",
"isLastChattedAgentPreferred": true,
"department": {
"id": "40dcf4ea-10fe-4c71-917b-50a71393085a",
"name": "depart",
"description": "ment",
"isAvailableInLiveChat": true,
"isAvailableInTicketingAndMessaging": true,
"offlineMessageMailTo": "toAllAgents",
"offlineMessageEmailAddresses": "",
"isDeleted": false,
"agentIds": [
"6a076e05-50f9-424b-b356-cacbc7f99065"
],
"chatbotSmartTriggerActionIds": [],
"shiftIds": [],
"segmentIds": []
},
"backupDepartments": [
{
"departmentId": "40dcf4ea-10fe-4c71-917b-50a71393085a",
"backupDepartmentId": "007ac439-b73c-461b-9bde-da2dbb4437af",
"order": 1,
"id": "a6c52b55-4261-4ca5-8f30-1f770538e599"
},
{
"departmentId": "40dcf4ea-10fe-4c71-917b-50a71393085a",
"backupDepartmentId": "f1ff3fff-33ab-46dd-a9f3-7ca415df9b25",
"order": 2,
"id": "04dbb0a6-ffc1-4e28-bbf9-c57dca28bbd2"
}
]
}
]
}
Was this article helpful?