On This Page
Refund a Payment
This section describes how to refund a payment. You can refund a settled payment for the
full amount or a partial amount by sending a refund request. Multiple partial refund
requests are also supported, and the total amount of all of the refund requests must be
less than the settled amount.
Requesting a refund requires the sale request ID from the sale response. The sale request
ID is in the
requestID
response field.Endpoints
Set the
apRefundService_run
field to
true
, and send the request to one of these
endpoints:Production:
https://ics2ws.ic3.com/commerce/1.x/transactionProcessor
Test:
https://ics2wstest.ic3.com/commerce/1.x/transactionProcessor
Required Fields for Refunding a Payment
- Set toMOP.
- Set to the request ID included in the sale response.
- Set totrue.
- Set toDKK.
Example: Refunding a Payment
Request
<requestMessage xmlns="urn:schemas-cybersource-com:transaction-data-1.211"> <merchantID>nrphotography</merchantID> <merchantReferenceCode>MobilePay-Refund</merchantReferenceCode> <purchaseTotals> <currency>DKK</currency> <grandTotalAmount>43.00</grandTotalAmount> </purchaseTotals> <apPaymentType>MOP</apPaymentType> <apRefundService run="true"> <refundRequestID>7520730687846156704605</refundRequestID> </apRefundService> </requestMessage>
Response to a Successful Request
<replyMessage xmlns="urn:schemas-cybersource-com:transaction-data-1.211"> <merchantReferenceCode>MobilePay-Refund</merchantReferenceCode> <requestID>7520733601546193504601</requestID> <decision>ACCEPT</decision> <reasonCode>100</reasonCode> <requestToken>AxjnrwSTl7MlJA1JColZANgZYjWmjCHRr1pUGynvzPgZOxoDYZiiNDJpJl6MYZYX6Tl7Mayg6hXZtdAA7jiI</requestToken> <purchaseTotals> <currency>DKK</currency> </purchaseTotals> <apRefundReply> <reasonCode>100</reasonCode> <transactionID>384920815203</transactionID> <status>REFUNDED</status> <processorResponse>00006</processorResponse> <amount>43.00</amount> <dateTime>2025-07-09T15:02:44Z</dateTime> <reconciliationID>XFZ40CQWVJAY</reconciliationID> <returnRef>CFXPACDEZAZS</returnRef> <paymentStatus>refunded</paymentStatus> <responseCode>00006</responseCode> </apRefundReply> </replyMessage>
Response Statuses for Refunding a Payment
Cybersource
responds to your refund request with one of these
statuses in the
field:- FAILED: The refund request failed.
- REFUNDED: The refund request is accepted but is not completed. Send a check status request to verify that the status is refunded. For more information, see Check a Status.