post https://enbduat-acquiring-apigw.creditpluspinelabs.com/checkout/apis/v2/transactions/cancel
Cancel (Void) transaction API is used to cancel (void) the transaction with PG. Usually, this API can get the transaction cancelled (voided) when transaction is still in non-terminal state i.e. PROCESSING, AUTHORIZED, CAPTURED, PROCESSING. It supports cancellation of AUTH, PURCHASE, CAPTURE and REFUND transactions. Based on the transactionUtr provided in the request, checkout will identify which transaction needs to be cancelled.
HTTP Status and Response Status Matrix
HTTP Status | Response Status | Response Message |
---|---|---|
200 | CANCELLED | Successfully cancelled (voided). |
200 | ALREADY_CANCELLED | Provided transaction is already cancelled(voided) |
400 | VALIDATION_ERROR | In case of VALIDATION_ERROR, field specific validation details will be returned. |
400 | REJECTED | No transaction found to initiate cancel(void). Please provide valid transactionUtr. |
400 | ERROR_FROM_PG | This will be populated by processor |
400 | REJECTED | Cancel (Void) transaction not allowed as the original transaction is already processed |
404 | ERROR_FROM_PG | This will be populated by processor |
404 | TRANSACTION_NOT_FOUND | This will be populated by processor |
500 | ERROR_FROM_PG | This will be populated by processor |
500 | ERROR_FROM_PG | Error in gateway response |
500 | INTERNAL_PROCESSING _ERROR | Something went wrong at our end, try again after some time |
502 | ERROR_CONNECTING_PG | Gateway connectivity unavailable |
503 | ERROR_CONNECTING_PG | Gateway connectivity unavailable |
503 | SERVICE_UNAVAILABLE | We see a downtime at our end. Please try again sometime! |