If you want to split the refund amount between the balance accounts in your platform the exact same way as you defined in the original payment request, you do not need to include the split instructions in your reversal request.
Requirements
In addition to the general requirements for in-person payments with an Adyen for Platforms integration, take into account the following information.
| Requirement | Description |
|---|---|
| Integration type | A Terminal API integration with payment terminals or with a Mobile solution. |
| Webhooks | Listen to the following webhook events: |
Make a refund without split instructions
-
From the POIData.POITransactionID object in the Terminal API payment response, get the
TransactionIDandTimeStampof the original payment. You need to specify this information in your reversal request. -
Make a Terminal API reversal request specifying:
-
The standard
SaleToPOIRequest.MessageHeaderobject, withMessageClassset to Service andMessageCategoryset to Reversal.Parameter Required Description ProtocolVersion
3.0 MessageClass
Service MessageCategory
Reversal MessageType
Request ServiceID
Your unique ID for this request, consisting of 1-10 alphanumeric characters. Must be unique within the last 48 hours for the terminal ( POIID) being used.SaleID
Your unique ID for the POS system component to send this request from. POIID
The unique ID of the terminal to send this request to. Format: [device model]-[serial number]. -
The ReversalRequest object with:
Parameter Required Description OriginalPOITransaction.POITransactionID
An object with: TransactionID: The transaction identifier of the original payment in the formattenderReference.pspReference. For example, BV0q001765198054002.CWBC43ZX2VTFWR82TimeStamp: The date and time of the original payment request in UTC format.
ReversalReason
Set to MerchantCancel.
The following Terminal API request example splits a full refund of a USD 188.00 payment according to the original payment split:
The payment terminal shows a waiting screen until you receive a response.
-
-
When you receive the ReversalResponse, note the following:
Parameter Description Response.ResultSuccess means we received your request. The refund itself will be processed asynchronously. POIData.POITransactionID.TransactionIDThe PSP reference for this refund request. PaymentReceiptThe generated receipt data. This includes REFUND REQUESTED. Response.AdditionalResponseThis includes: posOriginalAmountValue: The amount (in minor units) of the original payment.posAuthAmountValue: The refund amount (in minor units) that we will try to get authorized.pspReference: The PSP reference for this refund request.
If your request failed, the ReversalResponse.Response contains:
Result: FailureAdditionalResponse: This includes amessageexplaining why the request failed. For example:- Original pspReference required for this operation: Messages like this tell you how to fix the request so you can try again.
- Transaction is already voided: This message tells you that we already received a full reversal request for the original transaction.
-
Wait for the CANCEL_OR_REFUND webhook event to learn the outcome of the refund request. Refunds are always processed asynchronously.
Track fund movements
To track the status of the fund transfers initiated by a refund, listen to the following webhooks:
- Transfer webhooks: Adyen sends a balancePlatform.transfer.created webhook to inform your server that funds will be deducted from balance accounts, and balancePlatform.transfer.updated webhooks after every status change.
- Transaction webhooks: Adyen sends a balancePlatform.transaction.created webhook to inform your server that funds have been deducted from a balance account.
Webhook examples
In the example below, you can see the webhooks you receive when you send a refund request. We send webhooks for each balance account involved in the refund, and each split of the refunded amount.
The following tabs show the webhooks you receive when:
- The refund amount is deducted from your user's balance account.
- The commission amount is deducted from your liable balance account.
- The transaction fees are deducted from the specified balance account.