hosting
GET /v1/sites/{siteId}/cdn/analytics
Read edge traffic for a site's CDN zone.
Автентифікація
Надішліть ключ API як маркер носія (bearer token). Ключ повинен мати дозвіл sites.view; ключ без нього відхиляється з кодом 403, а не 404.
Цей кінцевий пункт не потребує ідентифікатора організації. Ваш ключ уже ідентифікує організацію, якій він належить, і відповідь обмежується її межами.
Спробувати
Замініть усе в кутових дужках власними значеннями, а заповнювач ключа — ключем із вашої панелі керування.
curl -X GET https://api.zinndigital.com/v1/sites/{siteId}/cdn/analytics \
-H "Authorization: Bearer zdk_live_…"Увійшли в систему? Консоль API у вашій панелі керування автоматично підставляє ваш реальний ідентифікатор організації та ваш власний ключ, а також виконує запит до робочого API, щоб ви могли побачити справжню відповідь. Відкрийте цю кінцеву точку в консолі API
Деталі
Daily requests, bytes, threats and unique visitors as counted **at the CDN edge**. This is not the same measurement as `/v1/sites/{siteId}/cdn/statistics`, and the two will not agree. That endpoint reports the hosting platform's own edge cache for a site on a managed hosting plan; this one reports the Cloudflare zone's. A site may have one, the other, both or neither, and they are counted at different edges — collapsing them into one number would invent a figure that is true of neither. Requires `sites.view`.
Параметри
| Назва | Тип | Обов'язкове | Що це таке |
|---|---|---|---|
siteId (path) | Uuid | Так | Site ID (UUIDv7). |
days (query) | integer | Ні | How many days to report, clamped to 1–30. Clamped rather than trusted: this is reachable from a screen a customer can refresh, against a provider API whose request budget is sha… |
Відповідь
| Назва | Тип | Обов'язкове | Що це таке |
|---|---|---|---|
site_id | Uuid | Так | UUIDv7 identifier — sortable by creation time (docs/02 §8). |
supported | boolean | Так | — |
days | CdnTrafficDay[] | Так | Most recent first. |
total_requests | integer | Так | — |
total_threats | integer | Так | — |
Помилки, які може повертати ця кінцева точка
401 · 403 · 404 · 429 · 503