Network-wide URL protection settings url-guard-settings
Platform-wide default switch and thresholds for network-wide URL protection; admin only. Per-site switch and thresholds live in the site security settings.
Pick an endpoint to see its example call on the right.
Authentication
Send the X-API-Key header (create a key on the API Keys page; the key is shown only once at creation). An Authorization: Bearer token obtained by logging in also works.
X-API-Key
Authentication failures return 401; forbidden returns 403 (code such as insufficient_scope).
Conventions
Paging uses page (from 1) and page_size; sort with sort=field or sort=-field.
Times are RFC 3339 (UTC); amounts are in cents.
Writes return 200/201/204 on success; duplicates of a unique key return 409.
/api/v2/url-guard-settingsGet network-wide URL protection settings
Authentication: Admin only
/api/v2/url-guard-settingsUpdate network-wide URL protection settings
Authentication: Admin only
Request body application/json
| Field | Type | Description |
|---|---|---|
actionRequired | string | Action on the URL once triggered - challenge, block or per-IP rate limit. |
baseline_ratio | integer | Triggering also requires this many times the usual level (usual = the URL's average QPS over the past hour, excluding the last minute). The panel accepts 0 and up, default 5; 0 = ignore the multiple (legacy configs lack the field and keep the old rule). Applies to new triggers only - renewing an active rule looks at QPS alone. Omit on update to keep the stored value. |
enabledRequired | boolean | Global default switch, used by sites that do not set their own. |
expected_updated_at | string | Optimistic lock - the updated_at as the caller read it (use 1970-01-01T00:00:00Z when the read value is null). If it differs from the stored one, 409 stale_version is returned and nothing is saved; omit to skip the check. |
gate | string | WAF enhanced (waf_enhanced) gate - full (active), readonly (expired but within the read-only buffer, License.readonly_days, 7 days by default; still effective, settings read-only), basic (not purchased or fallen back, nothing is pushed); ignored on update. |
gate_expired_at | string | Administrator responses with gate_reason=expired only - when the platform WAF Enhanced license expired; not present in tenant responses. |
gate_owner | WafGateOwner | The owner of the site, in administrator responses only; tenant responses carry no one else's information. |
gate_packages | string[] | Administrator responses only - names of the owner's unexpired packages (at most 20); not present in tenant responses. |
gate_reason | WafGateReason | Why WAF Enhanced (waf_enhanced) is not in effect; absent when gate is full or readonly. package = the platform is licensed but the owner has no unexpired package that includes WAF Enhanced; license = the platform has not enabled it (never licensed, revoked by the provider, or the license was disabled); expired = the platform license has expired and its read-only buffer period (License.readonly_days, default 7 days) has passed, so it fell back to basic. |
hold_sRequired | integer | Seconds the rule is held; it is renewed while still over the threshold and lapses once traffic drops. |
kind | string | Challenge type for action=challenge (default js); must be empty for other actions. |
max_per_siteRequired | integer | Max rules in effect at the same time per site. |
qpsRequired | integer | Trigger only when the network-wide total QPS of a URL is at least this (and at least baseline_ratio times its usual level). |
rate | integer | Max requests per IP per 10 seconds for action=limit; must be 0 for other actions. |
updated_at | string | Version in the response (null if never changed); ignored on update - use expected_updated_at for the optimistic lock. |
Network-wide URL protection settings object
| Field | Type | Description |
|---|---|---|
action | string | Action on the URL once triggered - challenge, block or per-IP rate limit. |
baseline_ratio | integer | Triggering also requires this many times the usual level (usual = the URL's average QPS over the past hour, excluding the last minute). The panel accepts 0 and up, default 5; 0 = ignore the multiple (legacy configs lack the field and keep the old rule). Applies to new triggers only - renewing an active rule looks at QPS alone. Omit on update to keep the stored value. |
enabled | boolean | Global default switch, used by sites that do not set their own. |
expected_updated_at | string | Optimistic lock - the updated_at as the caller read it (use 1970-01-01T00:00:00Z when the read value is null). If it differs from the stored one, 409 stale_version is returned and nothing is saved; omit to skip the check. |
gate | string | WAF enhanced (waf_enhanced) gate - full (active), readonly (expired but within the read-only buffer, License.readonly_days, 7 days by default; still effective, settings read-only), basic (not purchased or fallen back, nothing is pushed); ignored on update. |
gate_expired_at | string | Administrator responses with gate_reason=expired only - when the platform WAF Enhanced license expired; not present in tenant responses. |
gate_owner | WafGateOwner | The owner of the site, in administrator responses only; tenant responses carry no one else's information. |
gate_packages | string[] | Administrator responses only - names of the owner's unexpired packages (at most 20); not present in tenant responses. |
gate_reason | WafGateReason | Why WAF Enhanced (waf_enhanced) is not in effect; absent when gate is full or readonly. package = the platform is licensed but the owner has no unexpired package that includes WAF Enhanced; license = the platform has not enabled it (never licensed, revoked by the provider, or the license was disabled); expired = the platform license has expired and its read-only buffer period (License.readonly_days, default 7 days) has passed, so it fell back to basic. |
hold_s | integer | Seconds the rule is held; it is renewed while still over the threshold and lapses once traffic drops. |
kind | string | Challenge type for action=challenge (default js); must be empty for other actions. |
max_per_site | integer | Max rules in effect at the same time per site. |
qps | integer | Trigger only when the network-wide total QPS of a URL is at least this (and at least baseline_ratio times its usual level). |
rate | integer | Max requests per IP per 10 seconds for action=limit; must be 0 for other actions. |
updated_at | string | Version in the response (null if never changed); ignored on update - use expected_updated_at for the optimistic lock. |
Responses and errors
Success returns the resource JSON directly (HTTP 2xx); failures return application/problem+json (code, detail, plus errors on validation failures); lists carry items + total.
{
"id": 1,
"name": "example"
}{
"items": [
{
"id": 1
}
],
"page": 1,
"page_size": 20,
"total": 1
}{
"code": "validation_failed",
"detail": "Invalid request parameters",
"errors": [
{
"code": "required",
"field": "/name",
"message": "name is required"
}
],
"request_id": "0123456789abcdef",
"status": 422,
"title": "Unprocessable Entity",
"type": "about:blank"
}