agency-invoicing
GET /v1/agency-invoicing/clients/{clientId}
One client, with their whole invoice history.
المصادقة
أرسل مفتاح واجهة برمجة التطبيقات (API key) كرمز حامل (bearer token). يجب أن يحمل المفتاح إذن agency.invoicing.view؛ والمفتاح الذي لا يملكه يُرفض بالرمز 403 وليس 404.
حيث يتم إدخال معرف مؤسستك
تأخذ نقطة النهاية هذه org_id كمعلمة استعلام. اتركه فارغاً ليغطي الاستدعاء شجرة مستأجريك بالكامل، أو أرسله لتضييق نطاق الاستدعاء ليشمل منظمة واحدة.
معرف مؤسستك موجود على شاشة مفاتيح واجهة برمجة التطبيقات (API) في لوحة تحكمك، بجوار المفتاح نفسه. وهو نفس المعرف في كل طلب تجريه.
جربه الآن
استبدل أي شيء بين أقواس زاوية بقيمك الخاصة، والعنصر النائب للمفتاح بمفتاح من لوحة تحكمك.
curl -X GET https://api.zinndigital.com/v1/agency-invoicing/clients/{clientId} \
-H "Authorization: Bearer zdk_live_…"هل سجلت الدخول؟ تقوم وحدة تحكم واجهة برمجة التطبيقات في لوحة التحكم الخاصة بك بربط معرف مؤسستك الحقيقي ومفتاحك الخاص، وتنفذ الطلب مقابل واجهة برمجة التطبيقات المباشرة لتتمكن من رؤية الاستجابة الفعلية. افتح هذه النهاية الطرفية في وحدة تحكم API
التفاصيل
⭐ Every invoice you have raised against them, what they still owe and what they have been billed in total — the "all client history" screen in one request rather than a filtered list. Requires `agency.invoicing.view`.
المعلمات
| الاسم | النوع | مطلوب | ما هو هذا |
|---|---|---|---|
clientId (path) | Uuid | نعم | — |
org_id (query) | Uuid | لا | Which of your organizations is invoicing. Required only when you belong to more than one — otherwise it is inferred from your DIRECT membership, never from the subtree-expanded… |
الاستجابة
| الاسم | النوع | مطلوب | ما هو هذا |
|---|---|---|---|
id | Uuid | نعم | UUIDv7 identifier — sortable by creation time (docs/02 §8). |
name | string | نعم | — |
contact_name | string | لا | — |
email | string | لا | — |
phone | string | لا | — |
address | string | لا | — |
tax_number_label | string | لا | — |
tax_number | string | لا | — |
currency | string | نعم | — |
locale | string | لا | Which language this client's invoices and payment page render in. An agency in Berlin invoicing a French client sends a French invoice. |
notes | string | لا | — |
archived | boolean | لا | — |
created_at | string | لا | — |
invoices | AgencyInvoice[] | لا | — |
outstanding_minor | integer | لا | What this client still owes, in minor units. |
invoiced_total_minor | integer | لا | Everything ever billed to them, void invoices excluded. |
الأخطاء التي يمكن أن تُرجعها نقطة النهاية هذه
401 · 403 · 404 · 429