Usage Analytics
Usage Analytics
https://app.contentstack.com/analytics/v2/usage?from={YYYY-MM-DD}&to={YYYY-MM-DD}&orgUid={organization_uid}The Usage Analytics request gives a quick usage overview of your bandwidth and API utilization over a particular period of time.
Here’s how your response body would look like when you pass the jobId in the Retrieve Data endpoint.
{
"data": [
{
"total_api_bandwidth": 0,
"total_api_count": 0,
"total_cdn_bandwidth": 0,
"total_cdn_count": 0,
"date": "2024-03-02"
},
{
"total_api_bandwidth": 0,
"total_api_count": 0,
"total_cdn_bandwidth": 10110,
"total_cdn_count": 4,
"date": "2024-02-12"
},
{
"total_api_bandwidth": 0,
"total_api_count": 0,
"total_cdn_bandwidth": 0,
"total_cdn_count": 0,
"date": "2024-02-22"
},
{
"total_api_bandwidth": 0,
"total_api_count": 0,
"total_cdn_bandwidth": 0,
"total_cdn_count": 0,
"date": "2024-03-25"
},
{
"total_api_bandwidth": 94685,
"total_api_count": 26,
"total_cdn_bandwidth": 0,
"total_cdn_count": 0,
"date": "2024-03-04"
},
{
"total_api_bandwidth": 0,
"total_api_count": 0,
"total_cdn_bandwidth": 0,
"total_cdn_count": 0,
"date": "2024-02-28"
}
],
"meta": {
"orgUid": "blt**************87",
"includeCount": "true",
"from": "2024-01-31",
"duration": "day",
"to": "2024-03-31",
"services": "[\"cdn\",\"cma\"]"
},
"uid": "0f****46-5ee9-4f38-9146-1f********8"
}
The response body provides detailed insights into your organization's API and CDN usage over a specified period. Here’s a breakdown of the key elements:
- total_api_bandwidth: The total bandwidth consumed by API requests on the specified date.
- total_api_count: The number of API requests executed on the specified date.
- total_cdn_bandwidth: The total bandwidth consumed by CDN requests on the specified date.
- total_cdn_count: The number of CDN requests made on the specified date.
- date: The specific date for the reported statistics.
This data helps monitor and analyze the usage patterns of API and CDN resources, aiding in efficient resource management and planning.
- The apiKey parameter cannot be combined with the automations, launch, or cs-assets services. Doing so returns a 400 error.
- The projectUid and environmentUid parameters are only applicable to the ["launch"] service. Combining either one with cs-assets returns a 400 error.
- space_uid and subService can only be used when services is set to ["cs-assets"] on its own.
- When services is cs-assets, you must pass duration. Without it the response returns an empty data array rather than an error.
Here’s how your response body would look like with services set to cs-assets.
{
"data": [
{
"date": "2026-03-01",
"asset_api_usage": 0,
"asset_bandwidth_usage": 0
},
{
"date": "2026-05-01",
"asset_api_usage": 2783,
"asset_bandwidth_usage": 19438120
}
],
"meta": {
"orgUid": "blt**************cc",
"from": "2026-03-31",
"to": "2026-05-25",
"services": "[\"cs-assets\"]",
"duration": "month"
},
"uid": "a1****69-2fd7-4912-a213-4f********d4"
}Field reference:
- asset_api_usage: The number of Assets API requests made in the period.
- asset_bandwidth_usage: The bandwidth consumed by Assets requests in the period.
- date: The start of the period the row covers.
{
"jobId": "job_7******a-c**f-4**9-9**0-c**********6",
"paginated": false
}