Cancel or refund a transaction from the terminal transaction list, and receive a receipt on the PED or on the POS.
You can only use this cancel or refund method for transactions that:
- have been completed on the PED that is receiving the cancel or refund request.
- are still within the PED storage – this is currently limited to 100 tenders.
Class
Name | Description |
---|---|
MerchantPed | Extends
|
Method
Name | Description |
---|---|
| Refund a completed transaction from the terminal transaction list. The transaction must have been completed on the PED that is receiving the cancel or refund request, and must be still within the PED storage (this is currently limited to 100 tenders.) |
Create Request Object
Name | Description |
---|---|
| Refund request request object passed with the CancelOrRefund method. |
Parameters
Name | Type | Required | Description |
---|---|---|---|
merchantAccount |
String | The merchantAccount that is canceling the transaction and refunding the money (if applicable). |
|
tenderReference |
String | Tender reference provided by the library if there is no connection to the PSP. Use the Tender reference to identify the transaction to be cancelled. | |
handleReceipt |
Boolean | Specifies that the POS handles and prints receipts. If omitted, it is required that the PED prints the receipt. If there is no printer unit, the transaction will fail. | |
additionalData |
AdditionalData | Contains key/value pairs that can be used by the merchant to return specific additional data, in particular in the final transaction result. |
Callback
Name | Description |
---|---|
| Returns the result of the request. |
Parameters
Name | Type | Description |
---|---|---|
| result | Object that contains the result of the cancel or refund request (whether it was completed). |
Getters
Name | Type | Description |
---|---|---|
getTenderReference |
String | Returns tender reference for the transaction. |
getAdyenResult |
AdyenResult | Retrieves the transaction result details |
getReceiptSet |
Receipts.ReceiptSet | Returns a list of receipt information. |
Result Parameters
Name | Type | Description |
---|---|---|
| String | Result code generated by the LIBRARY. As this request is not processed on the PSP, check |
pedResult | string | Result code generated by the PED.
As this request is not processed on the PSP, check
|
pspResult | long | Result code generated by the PSP. |
errorMessage | String | Information that clarifies the error code. |