security

POST /v1/ip-allow

Allow an address or range.

Tutti gli endpoint security

Autenticazione

Invia una chiave API come bearer token. Questo endpoint non specifica un permesso specifico nella specifica, quindi assegna alla tua chiave i permessi minimi necessari e verifica la risposta invece di fare supposizioni.

L'ID della tua organizzazione va qui

Questo endpoint accetta org_id come parametro di query. Omettilo e la chiamata coprirà l'intero sottoalbero del tuo tenant; invialo per limitare la chiamata a una singola organizzazione.

L'identificativo della tua organizzazione si trova nella schermata delle chiavi API nella tua dashboard, accanto alla chiave stessa. È lo stesso identificativo in ogni chiamata che effettui.

Provalo

Sostituisci qualsiasi elemento tra parentesi angolari con i tuoi valori e il segnaposto key con una chiave dalla tua dashboard.

curl -X POST https://api.zinndigital.com/v1/ip-allow \
  -H "Authorization: Bearer zdk_live_…" \
  -H "Content-Type: application/json" \
  -d '{ "cidr": <string>, "label": <string> }'

Hai effettuato l'accesso? La console API nella tua dashboard inserisce il tuo ID organizzazione reale e la tua chiave personale, ed esegue la richiesta sull'API live in modo da poter vedere la risposta effettiva. Apri questo endpoint nella console API

Dettagli

Adds one entry. A bare address is normalised to a host network (`203.0.113.7` becomes `203.0.113.7/32`) so the list holds one shape and you cannot add the same fact twice in two spellings. `0.0.0.0/0` and `::/0` are refused, and so is any prefix broader than /8 (IPv4) or /32 (IPv6): an entry that admits the whole internet is the same as having no allow-list, while reading on screen as though something is protected.

Parametri

NomeTipoObbligatorioChe cos'è
org_id (query)stringNoThe organization to act on. Omitted (or empty) means your own. A reseller managing a client org must name it - defaulting silently would edit the reseller's own list while the s…

Corpo della richiesta

NomeTipoObbligatorioChe cos'è
cidrstringAn address or a CIDR range. `0.0.0.0/0` and `::/0` are refused, as is anything broader than /8 (IPv4) or /32 (IPv6). Both families are checked - rejecting only the IPv4 literal…
labelstring
expires_atstringNo
enabledbooleanNo

Risposta

NomeTipoObbligatorioChe cos'è
idstring
scopestring<staff_infra, staff_site, customer_site>
cidrstringCanonical CIDR. A bare address is stored as a host network (`/32`, or `/128` for IPv6) so one column answers both "is this a range" and "does it contain X".
labelstringRequired. An unlabelled range is one nobody dares remove, which is how a list grows until it stops being a control.
expires_atstringNonull = permanent. An expired entry is NOT deleted - it stays visible and greyed so an operator can see what lapsed and re-add it.
enabledboolean
expiredbooleanComputed server-side. Two surfaces deriving "is this still in force?" from a raw timestamp is two implementations of one decision, and they disagree on the boundary second.
in_forcebooleanenabled AND not expired - the only field that decides anything.
created_bystringAudit ref of whoever added it (`user:<id>` / `apikey:<id>`).
created_atstring