Get a report
get
/AgentWeb/api/analyticsmanager/serviceUsageMetrics/metricData/{metricsName}
This method returns a report for the requested metric in JSON or CSV format.
Request
Path Parameters
-
metricsName(required): string
The name of metric for which you want to generate the report.Default Value:
NamedUsers
Allowed Values:[ "NamedUsers", "ChatConnectedUsers", "ChatNamedUsers", "NonContactCenterNamedUsers", "ConnectedUsers", "CoBrowseNamedUsers", "VideoChatNamedUsers", "KnowledgeNamedUsers", "CustomObjectsDisplayCount", "EmailsSentCount", "Tier1Sessions", "Tier2Sessions", "Tier3Sessions", "KnowledgeConnectedUsers" ]
Query Parameters
-
endDate:
The end date to filter the report, and is only needed for session reports. Default value: Current date. This is needed only for session reports. Format: YYYY-MM-DDTHH:MM:SS, example: 2024-05-20T00:00:00.
-
format:
The format of the report: JSON (Default) or CSV.
-
interfaceName: string
The name of the interface to filter the data, and is only needed for session reports. Default value: ~any~.
-
startDate(required):
The start date to filter the report. Start date should fall within 1 year of today's date. Format: YYYY-MM-DDTHH:MM:SS, example: 2024-01-20T00:00:00.
Header Parameters
-
USERSESSION(required): string
The authentication token for the header.
Response
Supported Media Types
- text/plain
200 Response
Status of report data fetch
Examples
Use GET with the following syntax to retrieve data for a metric:
https://mysite.example.com/AgentWeb/api/analyticsmanager/serviceUsageMetrics/metricData/{metricsName}
where {metricsName}
can be one of the following:
- NamedUsers: The count of named users.
- ChatConnectedUsers: The count of connected users with chat permission.
- ChatNamedUsers: The count of named users with chat permission.
- NonContactCenterNamedUsers: The count of non contact center named users.
- ConnectedUsers: The count of connected users.
- CoBrowseNamedUsers: The count of co-browse named users.
- VideoChatNamedUsers: The count of video chat named users.
- KnowledgeNamedUsers: The count of knowledge named users.
- CustomObjectsDisplayCount: The count of deployed custom objects.
- EmailsSentCount: The count of sent outreach or feedback emails.
- Tier1Sessions: The details of Tier 1 sessions usage.
- Tier2Sessions: The details of Tier 2 sessions usage.
- Tier3Sessions: The details of Tier 3 sessions usage.
- KnowledgeConnectedUsers: The count of knowledge connected users.
The following example shows how to generate a report containing a list of named users with a start date of August 20, 2024.
cURL Command Example
curl -X GET "https://mysite.example.com/AgentWeb/api/analyticsmanager/serviceUsageMetrics/metricData/NamedUsers?startDate=2024-08-20T00%3A00%3A00&format=JSON" -H "USERSESSION: feihg98GnT7i" -H "Content-Type: application/json"
Response Body Example
[{"metricPeriod":"08/20/2024 11:00 PM","metricCount":"4096"},
{"metricPeriod":"08/21/2024 11:02 PM","metricCount":"4096"},
{"metricPeriod":"08/22/2024 11:02 PM","metricCount":"4096"},
{"metricPeriod":"08/23/2024 11:02 PM","metricCount":"4096"},
{"metricPeriod":"08/24/2024 11:02 PM","metricCount":"4096"},
{"metricPeriod":"08/25/2024 11:01 PM","metricCount":"4096"},
{"metricPeriod":"08/26/2024 11:01 PM","metricCount":"4096"}]