Void Invoice
You can cancel an already created invoice by void it immediately using this endpoint. It will be failed if status invoice is
PAID
or COMPLETED
Request :
Endpoint :
/v1/invoices/:id/void
HTTP Method :
POST
Header :
Authorization: Basic ENCODED_KEY
ENCODED_KEY
value is result of Base64Encode("apiKey"+":"+"secretKey"
)Response :
Sample Success Response :
HTTP Status Code :
200
{
"data": {
"referenceId": "INV-220119035-35NDVS"
},
"meta": {
"message": "Successfully void invoice!",
"statusCode": 200
}
}
Sample Failed Response :
HTTP Status Code :
400ON
{
"meta": {
"message": "Invoice has been paid",
"errors": [
"Invoice has been paid"
],
"statusCode": 400,
"errorCode": "INVOICE_ALREADY_PAID"
}
}
Last modified 4mo ago