POST
/businesses/{bid}/documents/{id}/credit-noteCorrect with a credit note
POST /businesses/{bid}/documents/{id}/credit-note
Requires the documents scope.
The only way to undo an issued 305 or 320: issues a linked חשבונית מס זיכוי (330) mirroring the original amounts. For a receipt (400) it issues a negative receipt. Nothing is ever deleted (הוראה 23).
Path parameters
| Name | Type | Description | |
|---|---|---|---|
bid | string | required | Business id, from POST /businesses. |
id | string | required | Document id. |
Body (optional)
| Field | Type | Description | |
|---|---|---|---|
reason | string | Printed on the credit note as its note. |
Response
201: { "ok": true, … }
| Field | Type | Description | |
|---|---|---|---|
ok | boolean | required | |
document | Document | required | A draft is freely mutable. An issued document is immutable forever, blocked at the database engine, not merely in application code. |
Errors: 400, 401, 403, 404, 409, 429. Every failure answers { "error": …, "reason": … }. Branch on reason.