agency-invoicing
POST /v1/agency-invoicing/invoices/{invoiceId}/void
Void an invoice.
Uthibitishaji
Tuma ufunguo wa API kama tokeni ya kubeba. Ufunguo lazima uwe na ruhusa ya agency.invoicing.manage; ufunguo usio nayo unakataliwa kwa 403, si 404.
Mahali ambapo kitambulisho cha shirika lako huwekwa
Kigezo hiki kinachukua org_id kama kigezo cha utafutaji. Iache wazi na simu itashughulikia tawi lako lote la wapangaji; itume ili kupunguza simu iwe ya shirika moja tu.
Kitambulisho cha shirika lako kipo kwenye skrini ya funguo za API katika dashibodi yako, kando ya ufunguo wenyewe. Ni kitambulisho kile kile katika kila ombi unalofanya.
Jaribu
Badilisha chochote kilicho ndani ya mabano ya pembe na maadili yako mwenyewe, na kishikiliaji cha ufunguo na ufunguo kutoka kwa dashibodi yako.
curl -X POST https://api.zinndigital.com/v1/agency-invoicing/invoices/{invoiceId}/void \
-H "Authorization: Bearer zdk_live_…" \
-H "Content-Type: application/json" \
-d '{ }'Umeingia kwenye akaunti? Dashibodi yako ya kiweko cha API inajaza kitambulisho chako halisi cha shirika na ufunguo wako mwenyewe, na kuendesha ombi dhidi ya API ya moja kwa moja ili uweze kuona jibu halisi. Fungua sehemu hii ya mwisho (endpoint) kwenye konsole ya API
Maelezo
⛔ The number is KEPT — a voided invoice is a document that says VOID on it, not an absence, and deleting the number would leave the gap the sequence exists to prevent. ⛔ Refused when payments have been recorded: that is a refund, which is a different act. Requires `agency.invoicing.manage`.
Vigezo
| Jina | Aina | Inayohitajika | Kilicho hiki |
|---|---|---|---|
invoiceId (path) | Uuid | Ndiyo | — |
org_id (query) | Uuid | Hapana | 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… |
Mwili wa ombi
| Jina | Aina | Inayohitajika | Kilicho hiki |
|---|---|---|---|
reason | string | Hapana | — |
Majibu
| Jina | Aina | Inayohitajika | Kilicho hiki |
|---|---|---|---|
id | Uuid | Ndiyo | UUIDv7 identifier — sortable by creation time (docs/02 §8). |
number | string | Hapana | The agency's own number. ⛔ Empty until issue: a number allocated to something that may never be sent leaves a hole in a sequence. |
status | string<draft, sent, partially_paid, paid, void> | Ndiyo | — |
is_overdue | boolean | Hapana | ⭐ DERIVED from the due date and the status, never stored — so there is no sweep to maintain a flag and nothing to go stale. A draft is never overdue however old it is: nobody ha… |
client_id | Uuid | Hapana | UUIDv7 identifier — sortable by creation time (docs/02 §8). |
client_name | string | Hapana | — |
currency | string | Ndiyo | — |
issue_date | string | Ndiyo | — |
due_date | string | Hapana | — |
reference | string | Hapana | — |
notes | string | Hapana | — |
footer | string | Hapana | — |
subtotal_minor | integer | Hapana | — |
discount_minor | integer | Hapana | — |
tax_minor | integer | Hapana | — |
total_minor | integer | Ndiyo | — |
amount_paid_minor | integer | Hapana | — |
amount_due_minor | integer | Hapana | — |
tax_breakdown | AgencyInvoiceTaxGroup[] | Hapana | — |
source | string | Hapana | Where the invoice came from — `time_tracking` when it was generated from tracked hours, empty when an agency typed it. |
sent_at | string | Hapana | — |
last_sent_to | string | Hapana | — |
paid_at | string | Hapana | — |
void_reason | string | Hapana | — |
created_at | string | Hapana | — |
lines | AgencyInvoiceLine[] | Hapana | — |
payments | AgencyInvoicePayment[] | Hapana | — |
portal_url | string | Hapana | The payment link to send to the client. ⛔ Returned on a SINGLE-invoice read only, never in a list: a list is the thing that gets logged, cached and pasted into a support ticket,… |
Hitilafu ambazo mwisho huu unaweza kurudisha
401 · 403 · 404 · 409 · 429