hosting

POST /v1/site-groups

Create a site group.

Alle hosting Endpunkte

Authentifizierung

Senden Sie einen API-Schlüssel als Bearer-Token. Dieser Endpunkt gibt in der Spezifikation keine spezifische Berechtigung an. Versehen Sie Ihren Schlüssel daher mit den minimal erforderlichen Rechten und prüfen Sie die Antwort, anstatt Annahmen zu treffen.

Dieser Endpunkt erfordert keine Organisations-ID. Ihr Schlüssel identifiziert bereits die zugehörige Organisation, und die Antwort ist entsprechend eingeschränkt.

Ausprobieren

Ersetzen Sie alles in spitzen Klammern durch Ihre eigenen Werte und den Platzhalter für den Schlüssel durch einen Schlüssel aus Ihrem Dashboard.

curl -X POST https://api.zinndigital.com/v1/site-groups \
  -H "Authorization: Bearer zdk_live_…" \
  -H "Content-Type: application/json" \
  -d '{ "name": <string> }'

Angemeldet? Die API-Konsole in Ihrem Dashboard trägt automatisch Ihre echte Organisations-ID sowie Ihren eigenen Schlüssel ein und führt die Anfrage gegen die Live-API aus, sodass Sie die tatsächliche Antwort sehen können. Öffnen Sie diesen Endpunkt in der API-Konsole

Details

Gated on `sites.groups.manage` in addition to `sites.view`. Refused with 422 when the organisation's plan does not sell `site_groups`, when the name is blank or already taken (case-insensitively, per organisation), or when the organisation already holds the maximum number of groups.

Anfragekörper

NameTypErforderlichWas es ist
namestringJa
colourstring<slate, blue, green, amber, red, purple, teal, pink>Nein
notesstringNein

Antwort

NameTypErforderlichWas es ist
idstringJa
namestringJaUnique per organisation, case-insensitively. Two groups called `Casino` and `CASINO` are a support ticket rather than a feature — nobody can tell them apart in a filter and half…
colourstring<slate, blue, green, amber, red, purple, teal, pink>JaA chip colour from a closed set, never a free hex value. The dashboard draws these through the design system's contrast-checked tone tokens; a customer-supplied colour would ren…
notesstringJaThe operator's own note. Never published, never shown to anyone else.
site_countintegerJa
created_atstringJa
updated_atstringJa

Fehler, die dieser Endpunkt zurückgeben kann

401 · 403 · 422