2. Sale/Rollback

You can use this service to send a sync sale rollback command to your terminals.

POST {{Base Address}}/api/payment/sync/sale/rollback

You only need to send a request to the address provided above. You can use the 'Base Address' as desired for both the test environment and the production environment.

Important: To use the Sync Sale Rollback service, you must include the 'apikeyprivate' and 'apiclientprivate' parameters in the 'Header' section of your request.

PhysicalAPI Address

The header information that needs to be sent to the service is as follows:

Parameter
Type
Compulsory
Description

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 needs to be sent to the service is as follows:

{
    "PaymentRequestId": "7cc7c8e8-9d92-41b6-9378-e9ecef5a7812"
}
Parameter
Type
Compulsory
Description
PaymentRequestId

Guid

Yes

The identification information returned by Paywall at the time of the sales order.

Response returned from the service:

Parameter
Type
Description

Result

object

Returns the information in the details of the service.

ErrorCode

int

Error code. Returns the value '0' if the transaction is successful.

Succeeded

bool

Returns a true or false value. Returns 'true' if the transaction is successful.

Failed

bool

Returns a true or false value. Returns 'true' if the transaction is unsuccessful.

Message

string

If the transaction is erroneous, this is the message related to the error. It provides language support based on the locale parameter.

ClientMessage

string

Returns the fixed values of the 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
}
Parameter
Type
Description
PaymentRequestId

Guid

The identity information of the Async payment in Paywall. It should be stored.

PaymentRequestActivityId

Guid

It is the identity information of the last transaction of the Async payment.

PaymentRequestActivityTypeId

int

The transaction type of the last Async payment.

Bkz: Payment Type

PaymentStatus

int

The last status of the Async payment. Bkz: Payment Status

Last updated