Links

Get Agent Total Service Time

Gives the total service time sorted by agent.
HTTP Method
URL
Requires Auth
GET
/api/v1/livechat/analytics/agents/total-service-time
yes
  • Permission required: view-livechat-manager
  • Service time means how long time the agent is online and available. It does not mean how long time the agent was busy serving chats.

Query Parameters

This endpoint supports the optional offset and count parameters from the Paginationquery parameters. The other required parameters are as follows:
Key
Example Value
Description
start*
2020-09-09T00:11:22.345Z
The start date.
end*
2020-09-10T23:59:22.345Z
The end date.

Example Call

curl --location --request GET 'http://localhost:3000/api/v1/livechat/analytics/agents/total-service-time?start=2020-02-12T00:11:22.345Z&end=2020-02-18T23:59:22.345Z' \
--header 'X-Auth-Token: myauth-token' \
--header 'X-User-Id: myuser-name'

Example Response

{
"agents": [
{
"chats": 3,
"_id": "rbAXPnMktTFbNpwtJ",
"username": "kim.baeko",
"serviceTimeDuration": 331
},
{
"chats": 4,
"_id": "CkCPNcvsvCDfmWLqC",
"username": "han.jun",
"serviceTimeDuration": 823
},
{
"chats": 4,
"_id": "CkCPNcvsvCDfmWLqC",
"username": "doe.john",
"serviceTimeDuration": 333
}
],
"count": 3,
"offset": 0,
"total": 3,
"success": true
}
Last modified 3mo ago
Rocket.Chat versions receive support for six months after release.