tenancy

PATCH /v1/orgs/{orgId}

Rename an organization.

Todos os endpoints de tenancy

Autenticação

Envie uma chave de API como um token de portador. A chave deve ter a permissão org.update; uma chave sem ela é recusada com 403, e não 404.

Onde vai o ID da sua organização

Este endpoint aceita o ID da sua organização diretamente na URL, como orgId. Substitua-o no caminho — não há cabeçalho ou parâmetro de consulta que sirva como alternativa.

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 PATCH https://api.zinndigital.com/v1/orgs/{orgId} \
  -H "Authorization: Bearer zdk_live_…" \
  -H "Content-Type: application/json" \
  -d '{ "name": <string> }'

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

⛔ Deliberately narrow: only `name`. `type`, `parent_org_id` and `default_currency` are **not** editable here — re-parenting moves a whole billing relationship and is `tenancy.offboarding`'s job. ⭐ The currency is not un-changeable, it simply is not a patchable field: it has its own route, `POST /v1/orgs/{orgId}/billing-currency` (`changeOrganizationBillingCurrency`), because re-denominating converts the wallet and re-prices live subscriptions rather than writing one column. This description read "a currency change would leave stored prices and issued invoices denominated in something the org no longer claims (#501)" until 2026-08-31, which was true of a patch and was read as *"it cannot be done"*. Requires `org.update` **on that org**; an org you cannot reach answers 404 rather than 403, the same as the GET, so this is never an existence oracle.

Parâmetros

NomeTipoObrigatórioO que é
orgId (path)UuidSimOrganization ID (UUIDv7).
orgId (path)UuidSim

Corpo da requisição

NomeTipoObrigatórioO que é
namestringSimThe organization's display name. The only editable field.

Resposta

NomeTipoObrigatórioO que é
idUuidSimUUIDv7 identifier — sortable by creation time (docs/02 §8).
typeOrgTypeSimOrganization type in the tenancy tree.
parent_org_idUuid | nullNãoParent in the tenancy tree; null for a top-level org.
namestringSim
brand_idobjectNãoWhite-label brand applied to this org's surfaces.
default_currencyCurrencyCodeSimISO 4217 currency code (money is minor units + this code — CLAUDE.md §2.8).
statusstring<active, suspended, closed>Sim
created_atstringSim

Erros que este endpoint pode retornar

401 · 403 · 404 · 422 · 429