3. Cancel
You can use this service to send a sync cancel command to your terminals.
POST
{{Base Address}}/api/payment/sync/cancel
You just need to send a request to the address provided above. You can use the 'Base Address' as needed for both the Test environment and the Live environment.
The header information that must be sent to the service is as follows:
apikeyprivate
string
Yes
The Private Key obtained from the merchant panel.
apiclientprivate
string
Yes
The Private Client obtained from the merchant panel.
The body information that must be sent to the service is as follows:
{
"PaymentRequestId": "7cc7c8e8-9d92-41b6-9378-e9ecef5a7812"
}
PaymentRequestId
Guid
Yes
It is the identity information returned from Paywall at the moment of the sale order.
The response returned from the service:
Result
object
It returns the details of the service.
ErrorCode
int
Error code. If the transaction is successful, it returns a value of '0'.
Succeeded
bool
It returns a true or false value. If the transaction is successful, it returns a value of 'true'.
Failed
bool
It returns a true or false value. If the transaction fails, it returns a value of 'true'.
Message
string
If the transaction is incorrect, this is the error message specified, and it provides language support based on the locale parameter.
ClientMessage
string
It returns the fixed values of Paywall error codes. You can perform mapping.
{
"result": {
"paymentRequestId": "72ec8714-d116-4306-8881-38a43c485da9",
"paymentRequestActivityId": "3a7deace-d437-4d3f-8ef8-1cba82f18e8f",
"paymentRequestActivityTypeId": 2,
"paymentStatus": 4
},
"failed": false,
"message": null,
"clientMessage": null,
"succeeded": true
}
PaymentRequestId
Guid
It is the identity information of the Async payment in Paywall. It must be stored.
PaymentRequestActivityId
Guid
It is the identity information of the last transaction of the Async payment.
PaymentRequestActivityTypeId
int
It is the transaction type of the last Async payment.
Bkz: Payment Type
PaymentStatus
int
It is the last status of the Async payment. Bkz: Payment Status
Last updated