Autenticação
Envie uma chave de API como um token bearer. Este endpoint não especifica uma permissão específica na documentação, portanto, conceda à sua chave o mínimo necessário e verifique a resposta em vez de assumir.
Onde vai o ID da sua organização
Este endpoint aceita org_id como parâmetro de consulta. Omita-o e a chamada abrangerá toda a sua subárvore de locatários; envie-o para restringir a chamada a uma única organização.
O ID da sua organização está na tela de chaves de API no seu painel, ao lado da própria chave. É o mesmo ID em todas as chamadas que você fizer.
Experimente
Substitua qualquer item entre colchetes por seus próprios valores e o espaço reservado para a chave por uma chave do seu painel.
curl -X GET https://api.zinndigital.com/v1/sites \
-H "Authorization: Bearer zdk_live_…"Conectado? O console da API no seu painel preenche o ID da sua organização real e a sua própria chave, e executa a requisição contra a API de produção para que você possa ver a resposta real. Abra este endpoint no console da API
Detalhes
Lists the sites the principal can view across its tenancy subtree. Cursor-paginated. RLS guarantees no site outside the principal's subtree is ever returned (CLAUDE.md §2.3). Sites with status `deleted` are **not** listed by default — they are a terminal state with their own endpoint, `GET /v1/sites/deleted`, which also reports how long each one stays recoverable. Pass `status=deleted` explicitly to list them here. Every other status, including `deleting`, is listed as normal.
Parâmetros
| Nome | Tipo | Obrigatório | O que é |
|---|---|---|---|
X-Zinn-Org (header) | string | Não | **Which organisation this call acts for.** Send a client organisation's id and every org-scoped endpoint answers for that client alone; omit it and the answer covers everything… |
cursor (query) | string | Não | Opaque cursor from a previous page's `page.next_cursor`. |
limit (query) | integer | Não | Maximum items to return (page size). |
org_id (query) | Uuid | Não | Restrict to one organization in scope (default — the whole subtree). |
status (query) | SiteStatus | Não | Filter by site lifecycle status. Omitted, every status except `deleted` is returned; pass `deleted` to list deleted sites here rather than at `GET /v1/sites/deleted`. |
product_line (query) | string | Não | Filter by product line code (e.g. `footprint_free`, `mainstream`). |
group (query) | string | Não | Restrict to the sites in one site group (#2729). A group id belonging to another tenant matches nothing and returns an empty page rather than a 404 — the queryset is already nar… |
search (query) | string | Não | Case-insensitive substring match on the site's primary domain or its name. Applied in the database across the whole collection in scope — not to the page already fetched — so a… |
ordering (query) | string<domain, -domain, name, -name, status, -status, line, -line, stack, -stack, region, -region, plan, -plan, created, -created, authority, -authority, indexed, -indexed> | Não | Sort key, optionally `-`-prefixed for descending. Defaults to `-created` (newest first). Sorting is applied across the whole collection and the cursor carries the sort position,… |
Resposta
| Nome | Tipo | Obrigatório | O que é |
|---|---|---|---|
data | Site[] | Sim | — |
page | PageMeta | Sim | — |
Erros que este endpoint pode retornar
401 · 403 · 422 · 429