tenancy

POST /v1/orgs

Create an organization.

جميع نقاط نهاية tenancy

المصادقة

أرسل مفتاح واجهة برمجة التطبيقات (API) كرمز حامل (bearer token). لا يحدد نقطة النهاية هذه إذنًا محددًا في المواصفات، لذا امنح مفتاحك الحد الأدنى الذي محتاجه وتحقق من الاستجابة بدلاً من الافتراض.

لا يقبل هذا الطرف أي معرف للمؤسسة. يحدد مفتاحك بالفعل المؤسسة التي ينتمي إليها، وتكون الاستجابة محصورة في نطاقها.

جربه الآن

استبدل أي شيء بين أقواس زاوية بقيمك الخاصة، والعنصر النائب للمفتاح بمفتاح من لوحة تحكمك.

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

هل سجلت الدخول؟ تقوم وحدة تحكم واجهة برمجة التطبيقات في لوحة التحكم الخاصة بك بربط معرف مؤسستك الحقيقي ومفتاحك الخاص، وتنفذ الطلب مقابل واجهة برمجة التطبيقات المباشرة لتتمكن من رؤية الاستجابة الفعلية. افتح هذه النهاية الطرفية في وحدة تحكم API

التفاصيل

Creates a child organization under the caller's org (reseller creating a client, etc.). Send an `Idempotency-Key` so retries never create duplicates (docs/09 §2).

المعلمات

الاسمالنوعمطلوبما هو هذا
Idempotency-Key (header)stringلاClient-generated key that makes an unsafe request replay-safe: the server stores the first response and returns it verbatim for repeats.

جسم الطلب

الاسمالنوعمطلوبما هو هذا
typeOrgTypeنعمOrganization type in the tenancy tree.
parent_org_idUuid | nullلاDefaults to the caller's org when omitted.
namestringنعم
default_currencyCurrencyCodeلا

الاستجابة

الاسمالنوعمطلوبما هو هذا
idUuidنعمUUIDv7 identifier — sortable by creation time (docs/02 §8).
typeOrgTypeنعمOrganization type in the tenancy tree.
parent_org_idUuid | nullلاParent in the tenancy tree; null for a top-level org.
namestringنعم
brand_idobjectلاWhite-label brand applied to this org's surfaces.
default_currencyCurrencyCodeنعمISO 4217 currency code (money is minor units + this code — CLAUDE.md §2.8).
statusstring<active, suspended, closed>نعم
created_atstringنعم

الأخطاء التي يمكن أن تُرجعها نقطة النهاية هذه

401 · 403 · 409 · 422 · 429