Skip to main content
POST
Record an invoice payment

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Headers

Idempotency-Key
string
required

Required; reuse it only to retry the same request

Path Parameters

invoice_id
string<MeteroidId>
required

Invoice ID

Example:

"inv_7n42DGM5Tflk9n8mt7Fhc7"

Body

application/json
amount
integer<int64>
required

The positive amount received, in minor units of the invoice currency (e.g. cents).

Required range: x >= 1
Example:

1250

paid_at
string<date-time> | null

When the payment was received, at most a day ahead. Defaults to the current time.

reference
string | null

Reference for the external payment, such as a bank transfer ID.

Response

Recorded payment

amount
integer<int64>
required
Required range: x >= 0
amount_refunded
integer<int64>
required

On a PAYMENT: how much was voluntarily given back (the sum of its settled REFUND children). The invoice stays paid — the Refund credit note is what reduces it.

amount_reversed
integer<int64>
required

On a PAYMENT: how much was involuntarily clawed back (chargeback, bank recall, lost dispute). This is what the invoice nets out, reopening it.

currency
string
required
id
string<MeteroidId>
required
Example:

"pay_7n42DGM5Tflk9n8mt7Fhc7"

payment_type
enum<string>
required
Available options:
PAYMENT,
REFUND
status
enum<string>
required
Available options:
READY,
PENDING,
SETTLED,
CANCELLED,
FAILED,
REFUNDED
amount_disputed
integer<int64>

On a PAYMENT: the part of amount_reversed lost to disputes or chargebacks. The invoice stays paid; only the rest of amount_reversed (a failed collection) reopens it.

amount_reversed_excess
integer<int64>

On a PAYMENT: what the provider withdrew above what the payment still held (refunded before). Never applied to the invoice or credit: contest it with the provider.

credit_note_id
string<MeteroidId> | null

Set on a REFUND drawn against a finalized Refund credit note.

Example:

"crn_7n42DGM5Tflk9n8mt7Fhc7"

error
string | null
parent_transaction_id
string<MeteroidId> | null

Set on a REFUND: the settled payment the money is given back from.

Example:

"pay_7n42DGM5Tflk9n8mt7Fhc7"

payment_method_id
string<MeteroidId> | null
Example:

"pm_7n42DGM5Tflk9n8mt7Fhc7"

payment_method_info
object | null
processed_at
string<date-time> | null
provider_transaction_id
string | null
refund_mode
enum<string> | null

How a voluntary refund was issued: through the provider, or recorded after a wire or cash movement made outside Meteroid.

Available options:
ONLINE,
OFFLINE
reversal_kind
enum<string> | null

Why a payment was involuntarily clawed back.

Available options:
REFUND,
CHARGEBACK,
DEBTOR_RECALL,
INSUFFICIENT_FUNDS,
MANDATE_INVALID,
RETURNED,
DISPUTE,
OTHER
reversal_reason
string | null

The provider's raw cause, or what the operator typed when reversing by hand.