Skip to content

Retrieves a zone-kpis resource.​

GET
/api/zones/{zoneId}/traffic-chart

Retrieves a zone-kpis resource.

Authorizations​

ApiToken

Long-lived API token created via POST /api/api-tokens (returned once in plaintext). A token created with readOnly may only perform safe requests (GET, HEAD, OPTIONS); write requests are rejected on every endpoint.

Type
API Key (header: X-API-TOKEN)
or
JWT

JWT access token obtained via POST /api/auth/login. Send as: Authorization: Bearer .

Type
HTTP (bearer)

Parameters​

Path Parameters

zoneId*

Zone identifier

Type
string
Required

Query Parameters

metric*

The traffic metric to chart. Use "top" for a ranked breakdown (see dimension/limit).

Type
string
Required
Valid values
"access""status-codes""image-cache""html-cache""content-type""cache-purges""blocked""top"
dimension

metric=top: which column to rank. Ignored for other metrics.

Type
string
Valid values
"host""country""status""uri"
limit

metric=top: number of rows to return (default 8, max 100).

Type
integer
Minimum
1
Maximum
100
Default
8
range

Preset time range. Ignored when from/to are provided.

Type
string
Valid values
"5 minutes""15 minutes""1 hour""6 hours""1 day""3 days""7 days""30 days"
Default
"1 hour"
from

Custom range start (Unix timestamp in seconds).

Type
integer
to

Custom range end (Unix timestamp in seconds).

Type
integer
points

Number of data points (buckets). Auto-calculated when omitted.

Type
integer
Minimum
1
Maximum
100
host

Only count requests for this host (host[like]=… for substring, host[neq]=… to exclude).

Type
string
status_code

Only count requests with this HTTP status code (also status_code[neq]/[nin]/[gte]/[lt]/…; [nin] takes a comma-separated list).

Type
integer
client_ip

Only count requests from this client IP address (client_ip[like]=… for substring, client_ip[nin]=… to exclude a comma-separated list).

Type
string
cache_status

Only count requests with this cache status, e.g. HIT, MISS or BYPASS (cache_status[nin]=… to exclude a comma-separated list).

Type
string
method

Only count requests with this HTTP method, e.g. GET, POST or HEAD (method[nin]=… to exclude a comma-separated list).

Type
string
geo_country

Only count requests from this client country, as a two-letter ISO code, e.g. DE (geo_country[nin]=… to exclude a comma-separated list).

Type
string
user_agent

Only count requests with this User-Agent (user_agent[like]=… for a case-sensitive substring, e.g. user_agent[like]=bot).

Type
string
waf_rule_action

Only count requests with this WAF rule verdict: block, challenge, throttle, skip, log or shadow.

Type
string
q

Free-text filter: case-insensitive substring match over host, URI, client IP and request id.

Type
string

Responses​

zone-kpis resource

JSON
{
  
"@context": "string",
  
"@id": "string",
  
"@type": "string",
  
"metric": "string",
  
"series": {
  
  
"additionalProperties": [
  
  
  
[
  
  
  
]
  
  
]
  
},
  
"range": "string",
  
"from": "string",
  
"to": "string",
  
"items": [
  
  
{
  
  
  
"additionalProperties": 0
  
  
}
  
],
  
"dimension": "string"
}

Playground​

Authorization
Variables
Key
Value

Samples​

Powered by VitePress OpenAPI