Skip to main content

Cancel Payment Transaction

The merchant can cancel an already initiated transaction using this function.

Resource Informations

NameValue
Requires authentication?Yes
Rate limited?No

Request

Request headers

NameValue
AuthorizationBearer token
Content-Typeapplication/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 NameTypeDescription
versionIntegerInner parameter for communication with SCP.
userIdStringUnique ID of the user that is involved in the payment process.
merchantServiceUUIDStringUnique UUID of the Service which is also the clientid from mID. Provided by mID.
merchantCallbackStringCallback URL to notify the Merchant about the status of the transaction. This URL also contains the OrderID generated by the Merchant for correspondence.
transactionTimeoutIntegerLifecycle of the transaction in seconds.
merchantIdStringID of the Merchant/Distributor.
paymentTransactionIdStringThe unique ID of the payment transaction to be cancelled.
cancellationMessageStringReason 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 NameTypeDescription
transactionIdStringUnique ID corresponding to the transaction.
transactionStatusStringStatus of the transaction.
transactionMessageStringBriefing on the transaction status.

Sample Response

{
"transactionId": "string",
"cancelStatus": "string",
"transactionMessage": "string"
}