Skip to content

Turn off the CDN for a zone

DELETE /api/v2/cdn/zones/{id}

Turns off CDN proxying for the zone. The domain, its DNS zone and the saved CDN settings are kept. To turn proxying back on, send proxied: true to PATCH /api/v2/cdn/zones/{id}. The domain must be active. Otherwise the call returns 404 cdn_zone_not_found.

Authentication: An API key with the scopes write:cdn and write:domains. About keys and scopes

Request

Path parameters

idstringrequired
The CDN zone ID. From GET /api/v2/cdn/zones.

Example

DELETE /api/v2/cdn/zones/{id}
curl -X DELETE "https://cloud.hostup.se/api/v2/cdn/zones/cdn_01hxa3b4c5d6e7f8g9h0j1k2m3" \
-H "Authorization: Bearer $HOSTUP_API_KEY"

Responses

204 CDN proxying is off. No response body.

Errors

Errors are Problem Details with a stable code. Branch on the code, not on the text.

400Invalid request. The response body is an RFC 7807 Problem Details document.
401Unauthorized. Authentication is required.
403Forbidden. The caller lacks a required scope or does not own the resource.
404Not found. The resource does not exist or is not owned by the caller; code is cdn_zone_not_found.
409Conflict. code is account_suspended, or a route-specific blocker with its own recovery fields.
429Rate limited. Retry after the limit resets. 429 responses include Retry-After seconds plus X-RateLimit-* headers.
500Internal error. Retry later or contact support if the issue persists.
502Upstream failure. A dependent provider request failed; the Problem Details code is upstream_failed. Retry later or contact support if the issue persists.