Cancel Payment Transaction
The merchant can cancel an already initiated transaction using this function.
Resource Informations
Name | Value |
---|---|
Requires authentication? | Yes |
Rate limited? | No |
Request
Request headers
Name | Value |
---|---|
Authorization | Bearer token |
Content-Type | application/json |
HTTP request URL for SSMS
POST https://{tenantId}.{hostname}/digitanium/v3/mpower/payment/transaction/void
HTTP request URL for SHIFT
POST https://{hostname}/auth/realms/{tenantId}/mpower/v1/payment/transaction/cancel
note
API requests must be made over https. Calls made over plain http will fail.
Request body
Field Name | Type | Description |
---|---|---|
version | Integer | Inner parameter for communication with SCP. |
userId | String | Unique ID of the user that is involved in the payment process. |
merchantServiceUUID | String | Unique UUID of the Service which is also the clientid from mID. Provided by mID. |
merchantCallback | String | Callback URL to notify the Merchant about the status of the transaction. This URL also contains the OrderID generated by the Merchant for correspondence. |
transactionTimeout | Integer | Lifecycle of the transaction in seconds. |
merchantId | String | ID of the Merchant/Distributor. |
paymentTransactionId | String | The unique ID of the payment transaction to be cancelled. |
cancellationMessage | String | Reason for cancellation. |
Sample Request
{
"version": 1,
"userId": "<User-ID>",
"merchantServiceUUID": "<merchantServiceUUID>",
"merchantCallback": "<Callback-URL>",
"transactionTimeout": 60,
"merchantId": "<merchantId>",
"paymentTransactionId": "<Payment-TransactionID>",
"cancellationMessage": "<Cancellation-Message>"
}
Response
Field Name | Type | Description |
---|---|---|
transactionId | String | Unique ID corresponding to the transaction. |
transactionStatus | String | Status of the transaction. |
transactionMessage | String | Briefing on the transaction status. |
Sample Response
{
"transactionId": "string",
"cancelStatus": "string",
"transactionMessage": "string"
}