Important: To enable this feature contact your Live Assist for Microsoft Dynamics 365 Account Manager. This feature is available with solution version 3.4.0.1 or greater.
This article describes how to collect statistical data about your Agent activity. The data is available from your CRM instance; you retrieve the data with the Microsoft Web API or XRM API.
The Agent Activity Reporting API provides two entities containing reporting metrics:
- Agent Status Change
- Agent Chat Participation
See also:
- Developer Guide for Dynamics 365 for Customer Engagement apps
- Query Data using the Web API
- Chat Queue Statistics API
- Visitor Contextual Information API.
Enabling Agent Activity Statistics
Your organization does not collect Agent Activity Statistics by default. Enable it by contacting your Account Manager
Agent Status Change
When an agent's status changes, Live Assist creates a Agent Status Changes record.
Note: Live Assist only monitors agent activity in the LAD365 CRM Widget, not on the Engagement Portal.
Entity Properties
Entity Name | cxlvhlp_agentstatuschange | ||
---|---|---|---|
Entity Set Path | https://<CRM URL>/api/data/v9.0/cxlvhlp_agentstatuschanges |
Name | Mandatory | Type | Details | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
cxlvhlp_agentid |
Yes | User Lookup | A GUID referencing a User Entity For Example: e821a67a-3c34-e911-a99c-0022480081c3 |
||||||||||
cxlvhlp_status |
Yes | Option Set |
An option set of values with enumerations:
|
||||||||||
cxlvhlp_timestamp |
Yes | Date and Time | A timestamp: 2019-01-02T00:37:22Z |
Agent Status Examples:
This query, returns the Agent's status record before the timestamp you provide:
cxlvhlp_agentstatuschanges?$filter=_cxlvhlp_agentid_value eq AGENT_ID and cxlvhlp_timestamp lt WINDOW_START&$orderby=cxlvhlp_timestamp&$top=1
This query returns all of the status change events within the start and end times you specify:
cxlvhlp_agentstatuschanges?$filter=_cxlvhlp_agentid_value eq AGENT_ID and Microsoft.Dynamics.CRM.Between(PropertyName=”cxlvhlp_timestamp”,PropertyValues=[WINDOW_START,WINDOW_END])&$orderby=cxlvhlp_timestamp asc
Agent Chat Participation
When an agent joins a chat, Live Assist creates Agent Chat Participation record. Later, when the agent is no longer participating on the chat because it ends or after a transfer, Live Assist updates the record.
Entity Properties
Entity Name | cxlvhlp_agentchatparticipation | ||
---|---|---|---|
Entity Set Path | https://<CRM URL>/api/data/v9.0/cxlvhlp_agentchatparticipations |
Name | Mandatory | Type | Details |
---|---|---|---|
cxlvhlp_agentid |
Yes | User Lookup | A GUID referencing a User Entity. For example: e821a67a-3c34-e911-a99c-0022480081c3 |
cxlvhlp_starttime |
Yes | Date and Time | A timestamp. For example: 2019-01-02T00:37:22Z |
cxlvhlp_endtime |
No | Date and Time | A timestamp: For example: 2019-01-02T00:37:22Z |
cxlvhlp_chatsessionid |
Yes | Single Line of Text | A Session ID string: For example: 161266174294967497 |
Agent Chat Participation Examples:
This query, returns all of an Agent's participation events for the time window you provide, including any on going chats:
cxlvhlp_agentchatparticipations?$filter=_cxlvhlp_agentid_value eq AGENT_ID and cxlvhlp_starttime lt WINDOW_END and ((cxlvhlp_endtime gt WINDOW_START) or (cxlvhlp_endtime eq null))
This query returns the number of active chats an Agent has at the time you provide:
cxlvhlp_agentchatparticipations/$count?$filter=_cxlvhlp_agentid_value eq AGENT_ID and cxlvhlp_starttime lt TIME_STAMP and ((cxlvhlp_endtime gt TIME_STAMP ) or (cxlvhlp_endtime eq null))