Cancel a POS transaction before settlement.
Use the following request to void a transaction before settlement.
{
"merchant": "MERCHANT-1",
"site": "SITE-1",
"merchantTransactionId": "POS_002",
"merchantTransactionDate": "2025-01-27T08:51:02.826Z",
"amounts": {
"transaction": 24.99,
"currencyCode": "GBP",
"gratuity": 0
},
"operation": "Void",
"statusCallbackUrl": "http://192.168.204.43:5000/statuspacket"
}| Parameter | Description |
|---|---|
merchantstring (≤ 20 characters) required | Your unique merchant identifier, as assigned by PXP. |
sitestring (≤ 20 characters) required | Your unique site identifier, as assigned by PXP. |
merchantTransactionIdstring (≤ 50 characters) required | The unique identifier for this transaction, as chosen by you. |
merchantTransactionDatedate-time required | The date and time when the initial transaction happened, in ISO 8601 format. |
amountsobject required | Details about the transaction amount. |
amounts.transactionstring required | The value of the transaction. For Void operations, this should match the original transaction value. |
amounts.currencyCodestring required | The currency code associated with the transaction, in ISO 4217 format. |
amounts.gratuitynumber | The optional gratuity amount. |
operationstring required | The type of modification that you want to make. Set this to Void. Possible values:
|
statusCallbackUrlstring | The webhook URL that PXP should sent status updates to, if the Return status packets feature is enabled for the device. This overrides the webhook URL configured in the Unity Portal. |
If your request is successful, you'll receive a 200 response containing a new systemTransactionId and an updated state. You'll also receive a Transaction (Card Cancelled) webhook notification.
{
"state": "Cancelled",
"stateData": {},
"approvalCode": "260643",
"merchantTransactionId": "POS_002",
"systemTransactionId": "c1651dba-da35-44f1-bf12-a169d46ced0b",
"merchantTransactionDate": "2025-04-11T08:37:02.826445+01:00",
"fundingData": {
"maskedPrimaryAccountNumber": "222360******0011",
"expiryMonth": "12",
"expiryYear": "2049",
"cardScheme": "MasterCard",
"gatewayTokenId": "db2d6ff1-d67e-44d2-9e56-4bcdacad753f",
"providerResponse": {
"provider": "PXP Financial",
"code": "00",
"message": "",
"merchantId": "",
"terminalId": "",
"paymentAccountReference": "",
"schemeTransactionId": "",
"merchantAdvice": {
"code": "",
"message": ""
},
"settlementDate": "2025-04-11T12:03:37.519413+01:00"
}
}
}