Correct a received payment
curl --request PATCH \ --url https://example.com/api/v1/payments/example \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "amount": 1, "method": "BANK_TRANSFER", "notes": "example", "paidAt": "example" }'Corrects the date, method, notes or amount of a received payment, and audits each change. An amount change moves the invoice’s amountPaid by the difference and its status with it. A Stripe payment keeps its amount and method, and a payment backing an overage release keeps its amount, method and date; both are refused with 422. The payment can be raised at most to what the invoice still owes plus the payment’s own amount, so the invoice’s payments never pass its total; a higher amount is refused with 409 and the message names both numbers. Requires the payments.manage permission.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Resource identifier (CUID2).
Resource identifier (CUID2).
Request Body
Section titled “Request Body”object
Corrected amount. Moves the invoice’s amountPaid by the difference: a PAID invoice it no longer covers reopens with the balance due, an open one it now covers becomes PAID. At most what the invoice still owes plus this payment’s own amount, else 409. Refused for a Stripe payment.
Corrected method. Refused for a Stripe payment.
When the payment was received (ISO 8601), not in the future. The invoice’s paidAt follows the payment that covers it.
Responses
Section titled “Responses”The corrected payment.
object
A payment recorded against an invoice.
object
Payment amount as a decimal number.
Cumulative amount refunded through Stripe. Zero until a refund is recorded.
Latest Stripe dispute status on this payment, or null if never disputed.
Payment method: STRIPE, BANK_TRANSFER, CHECK, CASH or OTHER.
Payment status: PENDING, PROCESSING, SUCCEEDED, FAILED, REFUNDED or VOIDED.
Example generated
{ "data": { "amount": 1, "amountRefunded": 1, "createdAt": "2026-04-15T12:00:00Z", "disputeStatus": "example", "disputedAt": "2026-04-15T12:00:00Z", "id": "example", "invoiceId": "example", "method": "example", "notes": "example", "paidAt": "2026-04-15T12:00:00Z", "status": "example" }}Validation error. Parse failures include field paths and expectations.
Validation error with safe field paths and expected values; submitted values are never returned.
object
object
Stable machine-readable error code.
object
Human-readable error message.
HTTP status code, mirrored in the body.
Example
{ "error": { "code": "UNAUTHORIZED" }}Unauthorized.
Standard error envelope.
object
object
Stable machine-readable error code.
Human-readable error message.
HTTP status code, mirrored in the body.
Example
{ "error": { "code": "UNAUTHORIZED" }}Forbidden.
Standard error envelope.
object
object
Stable machine-readable error code.
Human-readable error message.
HTTP status code, mirrored in the body.
Example
{ "error": { "code": "UNAUTHORIZED" }}Not found.
Standard error envelope.
object
object
Stable machine-readable error code.
Human-readable error message.
HTTP status code, mirrored in the body.
Example
{ "error": { "code": "UNAUTHORIZED" }}Conflict.
Standard error envelope.
object
object
Stable machine-readable error code.
Human-readable error message.
HTTP status code, mirrored in the body.
Example
{ "error": { "code": "UNAUTHORIZED" }}Invalid input.
Standard error envelope.
object
object
Stable machine-readable error code.
Human-readable error message.
HTTP status code, mirrored in the body.
Example
{ "error": { "code": "UNAUTHORIZED" }}Rate limit exceeded. Wait for Retry-After before retrying.
Standard error envelope.
object
object
Stable machine-readable error code.
Human-readable error message.
HTTP status code, mirrored in the body.
Example
{ "error": { "code": "UNAUTHORIZED" }}Headers
Section titled “Headers”Maximum requests in the current quota window.
Quota policy in requests and window seconds, for example 60;w=60.
Requests left in this quota window (zero when blocked).
Seconds until the current quota window resets, when available from the rate-limit store.
Seconds until another request may be attempted.
Chelsea is operated by Arepa Labs LLC