tenancy

PATCH /v1/orgs/{orgId}

Rename an organization.

Tất cả các điểm cuối tenancy

Xác thực

Gửi khóa API dưới dạng mã thông báo bearer. Khóa này phải có quyền org.update; khóa không có quyền này sẽ bị từ chối với mã lỗi 403, không phải 404.

Nơi điền id tổ chức của bạn

Endpoint này nhận mã tổ chức của bạn trực tiếp trong URL dưới dạng orgId. Hãy thay thế nó vào đường dẫn — không có header hoặc query parameter nào có thể thay thế được.

Mã tổ chức của bạn nằm ở màn hình khóa API trong bảng điều khiển, ngay bên cạnh khóa đó. Đây là cùng một mã trong mọi lệnh gọi mà bạn thực hiện.

Dùng thử

Thay thế bất kỳ nội dung nào trong ngoعل (angle brackets) bằng giá trị của riêng bạn và trình giữ chỗ key bằng một key từ trang tổng quan của bạn.

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

Đã đăng nhập? Bảng điều khiển API trong trang quản lý của bạn sẽ tự điền ID tổ chức thực tế và khóa của riêng bạn, sau đó chạy yêu cầu đối với API trực tiếp để bạn có thể xem phản hồi thực tế. Mở điểm cuối này trong bảng điều khiển API

Chi tiết

⛔ 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.

Tham số

TênLoạiBắt buộcNội dung này là gì
orgId (path)UuidOrganization ID (UUIDv7).
orgId (path)Uuid

Nội dung yêu cầu

TênLoạiBắt buộcNội dung này là gì
namestringThe organization's display name. The only editable field.

Phản hồi

TênLoạiBắt buộcNội dung này là gì
idUuidUUIDv7 identifier — sortable by creation time (docs/02 §8).
typeOrgTypeOrganization type in the tenancy tree.
parent_org_idUuid | nullKhôngParent in the tenancy tree; null for a top-level org.
namestring
brand_idobjectKhôngWhite-label brand applied to this org's surfaces.
default_currencyCurrencyCodeISO 4217 currency code (money is minor units + this code — CLAUDE.md §2.8).
statusstring<active, suspended, closed>
created_atstring

Các lỗi điểm cuối này có thể trả về

401 · 403 · 404 · 422 · 429