Bulk mark invoices paid

POST/api/v1/invoices/bulk-payments

Mark a selection of invoices paid in one call, recording the payment date you supply and optionally matching one or more bank transactions to each invoice.

Operation ID: bulk_mark_invoices_paid·View as markdown·OpenAPI slice

Authentication

Bearer token authentication. Pass your DayZero API token in the Authorization header and the target business UUID in x-business-id.

Request body

invoicesarray · BulkInvoicePaymentRowrequiredBulkInvoicePaymentRow

Invoices to settle (1-500 rows).

3 fields
invoice_idstringrequired

UUID of the invoice to settle.

paid_onstring · date-time

Payment date for this invoice (YYYY-MM-DD or full ISO 8601). Overrides the batch-level paid_on. When transactions are linked and no date is given anywhere, the transaction's own date is recorded.

transactionsarray · BulkInvoicePaymentAllocation

Bank transactions to match to this invoice. One or many — a customer who paid an invoice in two deposits gets two entries. Leave empty to mark the invoice paid without linking a transaction.

paid_onstring · date-time

Payment date applied to every row that does not carry its own (YYYY-MM-DD or full ISO 8601). This is the date recorded as the invoice's 'Paid on' — not the date the request was made.

Responses

201Successful Response

successboolean
messagestring
codestring
dataBulkMarkInvoicesPaidResponse

400Bad Request - Invalid input

errorstringrequired

Error category: validation_error, unauthorized, forbidden, not_found, conflict, rate_limited, server_error, or service_unavailable.

messagestringrequired

Human-readable explanation, safe to show to end users.

codestringrequired

Stable machine-readable code in CATEGORY_NNN form (e.g. NOT_FOUND_006, AUTH_010, GEN_002).

request_idstring

Correlation id for support requests. Echoes the x-request-id request header when one was supplied.

errorsobject

Field-level validation messages keyed by field name. Present on 400/422 validation failures only.

401Unauthorized - Missing/invalid token or no access to this business

errorstringrequired

Error category: validation_error, unauthorized, forbidden, not_found, conflict, rate_limited, server_error, or service_unavailable.

messagestringrequired

Human-readable explanation, safe to show to end users.

codestringrequired

Stable machine-readable code in CATEGORY_NNN form (e.g. NOT_FOUND_006, AUTH_010, GEN_002).

request_idstring

Correlation id for support requests. Echoes the x-request-id request header when one was supplied.

errorsobject

Field-level validation messages keyed by field name. Present on 400/422 validation failures only.

403Forbidden - Insufficient permissions

errorstringrequired

Error category: validation_error, unauthorized, forbidden, not_found, conflict, rate_limited, server_error, or service_unavailable.

messagestringrequired

Human-readable explanation, safe to show to end users.

codestringrequired

Stable machine-readable code in CATEGORY_NNN form (e.g. NOT_FOUND_006, AUTH_010, GEN_002).

request_idstring

Correlation id for support requests. Echoes the x-request-id request header when one was supplied.

errorsobject

Field-level validation messages keyed by field name. Present on 400/422 validation failures only.

422Validation Error

errorstringrequired

Error category: validation_error, unauthorized, forbidden, not_found, conflict, rate_limited, server_error, or service_unavailable.

messagestringrequired

Human-readable explanation, safe to show to end users.

codestringrequired

Stable machine-readable code in CATEGORY_NNN form (e.g. NOT_FOUND_006, AUTH_010, GEN_002).

request_idstring

Correlation id for support requests. Echoes the x-request-id request header when one was supplied.

errorsobject

Field-level validation messages keyed by field name. Present on 400/422 validation failures only.