Payments
Reverse a payment
Returns funds back to the customer by automatically performing the appropriate payment action depending on the payment's status.
For more information, see <a href="https://www.checkout.com/docs/payments/manage-payments/reverse-a-payment">Reverse a payment</a>.
post/payments/{id}/reversals
Request
- Base URLhttps://{prefix}.api.sandbox.checkout.com
- Auth
- OAuth 2Client credentialsToken URLstringScopesgateway, gateway:payment-voids, gateway:payment-refunds, gateway:payment-cancellations
- or API key in header Authorization
- TypeScriptA function with typed inputs. Its response is checked against the schema.
Path parameters
idstring required
The unique identifier for the payment.
Headers
Cko-Idempotency-Keystring
An optional idempotency key for safely retrying payment requests
Request body
Example request
{
"reference": "ORD-5023-4E89",
"metadata": {
"coupon_code": "NY2018",
"partner_id": 123989
}
}Response
Payment is already reversed
Example response
{
"action_id": "act_y3oqhf46pyzuxjbcn2giaqnb44"
}Changes
No recorded changes to this operation across all 1 revision of this API.