Tabba.
IntegrationerSådan virker TabbaFeatures

© 2026 Tabba. Alle rettigheder forbeholdes.

Udviklere
Udviklere
Udviklere
Overview
Credit an issued invoice POST

Andre spor

AI clientsREST API
Credit notes

Credit an issued invoice

The accounting platform books and sends the credit note inside the request, and the answer is the booked credit note, 201. A full credit takes the whole invoice back and is refused once anything was credited (INVOICE_ALREADY_CREDITED); a partial credit names lines of the invoice, each by no more than is left on it (VALIDATION_FAILED with AMOUNT_EXCEEDS_BILLED under the line). Amounts are before VAT. **Sending it again is safe**: the same external_id is the same credit note, whatever its body says the second time. Booked, it is answered as it stands, 200, and nothing is booked twice; not booked, that attempt is taken up again under its own date and lines. **A credit note that booked and could not be delivered is a success** whose send_error says why. An attempt the platform gave no definite answer to holds every other credit on the invoice back (CREDIT_ATTEMPT_UNRESOLVED, 409) until the request that made it is sent again. Metered against the platform_write bucket as well as default.

POST
/credit-notes

Authorization

bearerAuth
AuthorizationBearer <token>

An API key minted by an admin under Settings → Developers. It is bound to one company and has a scope: read, or read_write. A request without one, or with one that is not ours, is answered 401 and metered by its client address (x-rate-limits).

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X POST "https://example.com/credit-notes" \  -H "Content-Type: application/json" \  -d '{    "external_id": "string",    "invoice": "string",    "kind": "full",    "credit_date": "string"  }'
{  "object": "credit_note",  "id": "string",  "external_id": "string",  "invoice_id": "string",  "customer_id": "string",  "currency": "string",  "kind": "full",  "origin": "manual",  "credit_date": "string",  "issued_at": "string",  "platform_ref": "string",  "platform_number": -9007199254740991,  "send_error": {    "reason": "string",    "platform_reason": "string"  },  "total_amount": 0,  "created_at": "string",  "updated_at": "string",  "lines": [    {      "id": "string",      "invoice_line_id": "string",      "amount": 0,      "position": -9007199254740991    }  ]}

Read the configuration of the company the key is bound to GET

The base currency every figure is stated in, and the two accounts the month-end accrual moves. Both accounts are null until an admin has confirmed them.

Delete a customer DELETE

Refused with `DELETE_BLOCKED_BY_REFERENCES` (409) while an invoice, a recurring series or a credit note of the company names the customer: the platform is then not asked. Refused with `DELETE_BLOCKED_BY_BOOKINGS` (409) when the accounting platform holds bookings against the customer. Either way nothing is deleted.

external_id*string

Your own key. A create under one that is taken is the same credit note: nothing is booked twice.

Length1 <= length <= 255
invoice*string

The issued invoice to credit: its id, or ext:<external_id>.

Length1 <= length <= 255
kind*string

Value in

  • "full"
  • "partial"
credit_date*string

YYYY-MM-DD: the date the credit is booked on.

lines?array<>

For a partial credit: at least one line, each once. Not read for a full credit.

Itemsitems <= 200