Refund a Payment

Initiates a refund for a specified payment using its unique ID. By default, the full amount will be refunded, but you can specify a smaller amount for a partial refund. This flexibility allows merchants to handle various refund scenarios, such as partial returns or adjustments.

Path parameters

paymentIdstringRequired
ID of the payment to refund.

Request

This endpoint expects an object.
amountintegerOptional
Specify the amount to refund in minor units. Defaults to the remaining balance if not provided.
orderIdstringOptional
Optionally provide a specific order ID for the refund. Defaults to the original order ID if not specified.
reasonstringOptional

Optionally include a reason for the refund for record-keeping purposes.

Response

Payment refunded successfully.
idstring or null
The unique payment ID.
datedatetime or nullDefaults to 1970-01-01T00:00:00.000Z
The date and time at which the payment was created.
dateUpdateddatetime or nullDefaults to 1970-01-01T00:00:00.000Z
The date and time of the last payment update.
statusenum or null
The current status of the payment.
orderIdstring or null
Your reference for the payment.
currencyCodestring or null

The 3-letter currency code in ISO 4217 format.

amountinteger or null
The amount you charged the customer, in minor units.
transactionslist of objects or null
processorobject or null
metadatamap from strings to any or null
Additional data to be used throughout the payment lifecycle.

Errors