hosting

POST /v1/site-groups

Create a site group.

All hosting endpoints

Authentication

Send an API key as a bearer token. This endpoint does not state a specific permission in the specification, so give your key the least it needs and check the response rather than assuming.

This endpoint takes no organisation id. Your key already identifies the organisation it belongs to, and the response is scoped to it.

Try it

Replace anything in angle brackets with your own values, and the key placeholder with a key from your dashboard.

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

Signed in? The API console in your dashboard fills in your real organisation id and your own key, and runs the request against the live API so you can see the actual response. Open this endpoint in the API console

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.

Request body

NameTypeRequiredWhat it is
namestringYes
colourstring<slate, blue, green, amber, red, purple, teal, pink>No
notesstringNo

Response

NameTypeRequiredWhat it is
idstringYes
namestringYesUnique 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>YesA 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…
notesstringYesThe operator's own note. Never published, never shown to anyone else.
site_countintegerYes
created_atstringYes
updated_atstringYes

Errors this endpoint can return

401 · 403 · 422