Real Time

Real Time
- Real Time Manage
GET livechat/realTime/Agents
GET livechat/realTime/Queue
GET livechat/realTime/Today
GET livechat/realTime/RightNow
Endpoint
Get agents' status

GET livechat/realTime/Agents

Parameters:

Name Type In Required Description
departmentId guid path no Id of the department.
includeStatusDistribution bool path no Whether include status distribution or not.
utcOffset int path no Time offset for search
startTime datetime path no Start time for search
endTime datetime path no End time for search
Response:

Name Type Description
intradayChats string Intraday chats number of the agent.
currentStatusId guid Current status Id of the agent.
maxConcurrentChats int Max concurrent chats of the agent.
intradayLinearChatTime string Intraday linear chat time of the agent.
agentId guid Id of the agent.
onGoingChats int The ongoing chats number of the agent.
statusDistribution string Dictionary of status with status id.
displayName string Display name of the agent.
Example

Sample Request:

curl https://api15.comm100.io/v4/livechat/realTime/Agents \
-X 'GET' \
-H 'Authorization: Bearer {access_token}' \

Response:

 HTTP/1.1 200 OK

{"total":32,"pageCount":7,"list":[{"agentId":"51f36e1a-d521-43bf-a0a8-20cbade284e4","displayName":"srita2 chen","currentStatusId":"00000000-0000-0000-0000-000000000000","onGoingChats":1,"maxConcurrentChats":0,"intradayChats":0,"intradayLinearChatTime":"06:53:57.0500000","statusDistribution":{}},{"agentId":"841d966b-744b-405e-86d1-7e8c573ebc60","displayName":"srita chen 10001","currentStatusId":"00000000-0000-0000-0000-000000000000","onGoingChats":1,"maxConcurrentChats":0,"intradayChats":0,"intradayLinearChatTime":"00:20:38.2649999","statusDistribution":{}},{"agentId":"74ed2bc3-a41f-4dc8-9ae0-f562ebea5943","displayName":" frank 10001","currentStatusId":"00000000-0000-0000-0000-000000000002","onGoingChats":0,"maxConcurrentChats":0,"intradayChats":0,"intradayLinearChatTime":"00:00:00","statusDistribution":{}},{"agentId":"7bf10c1d-2973-4848-b08f-cd5195e6b337","displayName":"1 1","currentStatusId":"00000000-0000-0000-0000-000000000002","onGoingChats":0,"maxConcurrentChats":0,"intradayChats":0,"intradayLinearChatTime":"00:00:00","statusDistribution":{}},{"agentId":"ed22fff9-5000-4430-8a32-efb530c9f049","displayName":"1000 1","currentStatusId":"00000000-0000-0000-0000-000000000002","onGoingChats":0,"maxConcurrentChats":0,"intradayChats":0,"intradayLinearChatTime":"00:00:00","statusDistribution":{}}],"pageIndex":1,"pageSize":5}
Get chat queue status

GET livechat/realTime/Queue

Parameters:

No Parameters
Response:

Name Type Description
routeToAgent agent Reference to Agent.
avgWaitTimeinLast30Mins int Average wait time in last 30 minutes.
routeToDepartmentId guid Id of the route to department.
visitors visitor[] Reference of visitor.
routeToAgentId guid Id of the route to agent.
avgWaitTimeinLast60Mins int Average wait time in last 60 minutes.
routeToDepartment department Reference to Department.
switchedtoMessagesinLast30Mins int Switched to messages in last 30 minutes.
currentQueueLength int Length of current queue.
maxConcurrentChats int Max concurrent chats of the site.
abandonedChatsinLast30Mins int Abandoned chats in last 30 minutes.
ongoingChats int The ongoing chats number of the agent.
Example

Sample Request:

curl https://api15.comm100.io/v4/livechat/realTime/Queue \
-X 'GET' \
-H 'Authorization: Bearer {access_token}' \

Response:

 HTTP/1.1 200 OK

[{ "routeToDepartmentId": "3fa85f64-5717-4562-b3fc-2c963f66afa6", "routeToDepartment": { "id": "3fa85f64-5717-4562-b3fc-2c963f66afa6", "siteId": 0, "name": "string", "description": "string", "isAvailableInLiveChat": true, "isAvailableInTicketingAndMessaging": true, "isDeleted": true }, "routeToAgentId": "3fa85f64-5717-4562-b3fc-2c963f66afa6", "routeToAgent": { "id": "3fa85f64-5717-4562-b3fc-2c963f66afa6", "displayName": "string", "email": "string", "isAdmin": true, "siteId": 0, "firstName": "string", "lastName": "string", "isActive": true, "phone": "string", "title": "string", "bio": "string", "apiKey": "string", "createdTime": "2021-05-17T07:17:22.908Z", "isLocked": true, "lockedTime": "2021-05-17T07:17:22.908Z", "isDeleted": true, "systemAvatarId": "3fa85f64-5717-4562-b3fc-2c963f66afa6", "ifCustomizeAvatar": true, "customizeAvatar": "string", "avatar": "string", "departmentIds": [ "3fa85f64-5717-4562-b3fc-2c963f66afa6" ] }, "ongoingChats": 0, "maxConcurrentChats": 0, "currentQueueLength": 0, "avgWaitTimeinLast30Mins": 0, "avgWaitTimeinLast60Mins": 0, "abandonedChatsinLast30Mins": 0, "switchedtoMessagesinLast30Mins": 0, "visitors": [ { "visitorId": "3fa85f64-5717-4562-b3fc-2c963f66afa6", "contactIdentityId": "3fa85f64-5717-4562-b3fc-2c963f66afa6", "waitTime": 0 } ] }]
Get today's status

GET livechat/realTime/Today

Parameters:

Name Type In Required Description
utcOffset int path no Time offset for search
endTime datetime path no End time for search.
startTime datetime path no Start time for search
Response:

Name Type Description
avgWaitingTime double AvgWaiting time number of today.
totalChats int Total chats number of today.
chatRequests int Chat requests number of today.
abandondedChats int Abandonded chats number of today.
switchedToMessageChats int Switched to message chats number of today.
uniqueChatRate double Unique chat rate number of today.
avgScore double Avg score number of today.
serviceAccessibilityRate double Service accessibility rate number of today.
acceptedInvitations int Accepted invitations number of today.
departmentTransferredChats int Department transferred chats number of today.
missedChats int Missed chats number of today.
chatAcceptanceRate double Chat acceptance rate number of today.
totalTransferredChats int Total transferred chats number of today.
agentAvgResponseTime double Agent avg response time number of today.
chats int Chats number of today.
avgChatTime double Avg chat time number of today.
agentUtilization double Agent utilization number of today.
Example

Sample Request:

curl https://api15.comm100.io/v4/livechat/realTime/Today \
-X 'GET' \
-H 'Authorization: Bearer {access_token}' \

Response:

 HTTP/1.1 200 OK

{"chatRequests":0,"totalChats":0,"chats":0,"chatAcceptanceRate":0.0,"abandondedChats":0,"switchedToMessageChats":0,"missedChats":0,"avgWaitingTime":0.0,"avgChatTime":0.0,"agentAvgResponseTime":0.0,"acceptedInvitations":0,"serviceAccessibilityRate":0.0,"departmentTransferredChats":0,"totalTransferredChats":0,"uniqueChatRate":0.0,"agentUtilization":1.0,"avgScore":0.0}
Get current status

GET livechat/realTime/RightNow

Parameters:

Name Type In Required Description
utcOffset int path no Time offset for search
startTime datetime path no Start time for search
endTime datetime path no End time for search
Response:

Name Type Description
loggedInAgents int Logged in agents number of right now.
agentsInChat int Agents in chat number of right now.
chatUtilization int Chat utilization number of right now.
visitorOnSite int Visitor on site number of right now.
ongoingChats int Ongoing chats number of right now.
ongoingChatsWithAgent int Ongoing chats with agent number of right now.
currentQueueLength int Current queue length number of right now.
ongoingChatsWithBot int Ongoing chats with bot number of right now.
Example

Sample Request:

curl https://api15.comm100.io/v4/livechat/realTime/RightNow \
-X 'GET' \
-H 'Authorization: Bearer {access_token}' \

Response:

 HTTP/1.1 200 OK

{"agentsInChat":0,"ongoingChats":1,"ongoingChatsWithAgent":1,"ongoingChatsWithBot":0,"currentQueueLength":0,"visitorOnSite":1,"loggedInAgents":2,"chatUtilization":0.0}