v1

latestOpenAPI 3.0.3MIT-LICENSE2026-07-2469127278.1 KB
Orders

Refund Order

Creates a refund for an order. This operation is used to refund a previously paid order (fully or partially, depending on the request body). The API will validate the order and its related charges before processing the refund. If the refund cannot be created due to business rules or state, an error response is returned.

post/orders/{id}/refunds

Path parameters

idstring required

Identifier of the resource

Headers

Accept-Language'es' | 'en'

Use for knowing which language to use

X-Child-Company-Idstring

In the case of a holding company, the company id of the child company to which will process the request.

Request body

amountinteger required

Amount to refund. If not provided, the API refunds the refundable amount of the selected charge.

charge_idstring nullable

Charge ID to refund. If not provided, the API selects a refundable charge from the order.

reason'requested_by_client' | 'cannot_be_fulfilled' | 'duplicated_transaction' | 'suspected_fraud' | 'other' required

Refund reason. If not provided, the API uses a default reason.

expires_atinteger nullable

Expiration timestamp for cash refunds (must be within the allowed range configured by the API).

Example request

{
  "amount": 500,
  "charge_id": "6976b2e3c4418f00012943c5",
  "reason": "suspected_fraud",
  "expires_at": 1553273553
}

Response

successful operation