hosting
GET /v1/sites/{siteId}/cdn/statistics
Edge hits, bytes and country breakdown for a site.
Authentication
Send an API key as a bearer token. The key must carry the sites.view permission; a key without it is refused with 403, not 404.
This endpoint takes no organisation id. Your key already identifies the organisation it belongs to, and the response is scoped to it.
Try it
Replace anything in angle brackets with your own values, and the key placeholder with a key from your dashboard.
curl -X GET https://api.zinndigital.com/v1/sites/{siteId}/cdn/statistics \
-H "Authorization: Bearer zdk_live_…"Signed in? The API console in your dashboard fills in your real organisation id and your own key, and runs the request against the live API so you can see the actual response. Open this endpoint in the API console
Details
Points are returned in the vendor's own buckets and in time order, not re-aggregated: re-bucketing would invent numbers the CDN did not measure. Requires `sites.view`.
Parameters
| Name | Type | Required | What it is |
|---|---|---|---|
siteId (path) | Uuid | Yes | Site ID (UUIDv7). |
window (query) | string<Last24Hours, Last30Days, Last12Months> | No | Which bucket of hits and bytes to return. |
period (query) | string<Last1Hour, Last24Hours, Last7Days> | No | Which window the country breakdown covers. ⛔ **A different vocabulary from `window`** — the two vendor endpoints underneath do not share one, and `Last30Days` is a valid `window… |
Response
| Name | Type | Required | What it is |
|---|---|---|---|
window | string | Yes | — |
windows | string[] | Yes | — |
hits | SiteCdnPoint[] | Yes | — |
bytes | SiteCdnPoint[] | Yes | — |
period | string | Yes | The window the country breakdown covers, or empty when the requested `period` is not one this vendor endpoint accepts. |
periods | string[] | Yes | — |
countries | SiteCdnCountry[] | Yes | — |
Errors this endpoint can return
401 · 403 · 404 · 422 · 429 · 503