hosting

POST /v1/sites/{siteId}/cdn/purge

Purge a site's CDN cache.

Toate punctele finale hosting

Autentificare

Trimiteți o cheie API ca token de tip bearer. Cheia trebuie să aibă permisiunea sites.cache.purge; o cheie care nu o are va fi respinsă cu 403, nu 404.

Acest endpoint nu necesită un ID de organizație. Cheia ta identifică deja organizația căreia îi aparține, iar răspunsul este limitat la aceasta.

Încearcă

Înlocuiți tot ce se află între paranteze unghiulare cu propriile valori și substituentul cheie cu o cheie din tabloul de bord.

curl -X POST https://api.zinndigital.com/v1/sites/{siteId}/cdn/purge \
  -H "Authorization: Bearer zdk_live_…"

Autentificat? Consola API din panoul de control îți completează ID-ul real al organizației și propria cheie și rulează cererea în API-ul live, astfel încât să poți vedea răspunsul efectiv. Deschideți acest punct final în consola API

Detalii

Purges the whole zone for this site. The engine verifies the site owns the domain before purging, because on a pooled CDN account a zone resolves by name alone and an unchecked purge could clear a different tenant's cache — so the hostname is read off the site row and **the request body must be empty**. A body carrying a `domain`, `zone` or `urls` key is a `422`, not a silently ignored field. A site that is not served through our CDN is a `404`, answered before any vendor call. `Idempotency-Key` is accepted and requires no de-duplication here: purging a zone twice has the same effect as purging it once. Requires `sites.cache.purge`.

Parametri

NumeTipObligatoriuCe este
siteId (path)UuidDaSite ID (UUIDv7).
Idempotency-Key (header)stringNuClient-generated key that makes an unsafe request replay-safe: the server stores the first response and returns it verbatim for repeats.

Răspuns

NumeTipObligatoriuCe este
purgedbooleanDa

Erori pe care le poate returna acest punct final

401 · 403 · 404 · 422 · 429 · 503