v1
latestOpenAPI 3.1.02026-07-228956435.8 KBCharges
Cancel a charge
Cancels a charge. Only charges with status pending can be canceled. Once the collection starts, the charge can no longer be canceled.
post/charges/{id}/cancel
Path parameters
idstring required
The id of the charge to cancel. Only pending charges can be canceled.
Response
The canceled charge, with status canceled.
Example response
{
"id": "ch_o9YDuRzUez2GqV4x",
"amount": 5000,
"created_at": "2021-05-17T17:04:10.284Z",
"currency": "CLP",
"failure_code": "insufficient_funds",
"metadata": {
"order_id": "9182"
},
"mode": "live",
"recipient_account": {
"holder_id": "111111111",
"institution_id": "cl_banco_estado",
"number": "987654321",
"type": "checking_account"
},
"status": "succeeded",
"subscription_id": "sub_nMNejK7BT8oGbvO4"
}