billing

GET /v1/billing/profile

Get the organization's billing profile.

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

المصادقة

أرسل مفتاح واجهة برمجة التطبيقات (API key) كرمز حامل (bearer token). يجب أن يحمل المفتاح إذن billing.view؛ والمفتاح الذي لا يملكه يُرفض بالرمز 403 وليس 404.

حيث يتم إدخال معرف مؤسستك

تأخذ نقطة النهاية هذه org_id كمعلمة استعلام. اتركه فارغاً ليغطي الاستدعاء شجرة مستأجريك بالكامل، أو أرسله لتضييق نطاق الاستدعاء ليشمل منظمة واحدة.

معرف مؤسستك موجود على شاشة مفاتيح واجهة برمجة التطبيقات (API) في لوحة تحكمك، بجوار المفتاح نفسه. وهو نفس المعرف في كل طلب تجريه.

جربه الآن

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

curl -X GET https://api.zinndigital.com/v1/billing/profile \
  -H "Authorization: Bearer zdk_live_…"

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

التفاصيل

Returns the customer's one "Bill to" block — what renders on the next invoice (docs/34 §2.5). An organization that has never saved one gets a **200 with an empty profile** (every field blank, `updated_at` null), not a 404, so the form always has a shape to render. Requires `billing.view`.

المعلمات

الاسمالنوعمطلوبما هو هذا
org_id (query)UuidلاThe organization whose profile to read; defaults to the caller's own.

الاستجابة

الاسمالنوعمطلوبما هو هذا
org_idstringنعم
legal_namestringنعم
company_namestringنعم
billing_addressBillingAddressنعمA billing address. Everything is optional **except** `country`, which tax determination needs (docs/34 §2.2). `country` is an ISO 3166-1 alpha-2 code, uppercased by the server.
vat_numberstringنعم
vat_statusstring<unvalidated, pending, valid, invalid>نعمState of the validate-not-trust check on `vat_number` (docs/34 §2.3). Read-only; a change to `vat_number` resets it to `unvalidated`.
tax_idLabelValueلاA free-label secondary tax id (US EIN, AU ABN, …). Null when unset.
custom_invoice_fieldsLabelValue[]نعمUp to five customer-defined `{label, value}` lines, rendered verbatim.
billing_emailstringنعمWhere invoices are delivered; blank means the account email.
invoice_localestringنعمPreferred invoice language; blank means the account language.
updated_atstringلاWhen the profile was last saved. Null if it has never been saved.

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

401 · 403 · 422 · 429