FILTER BY TAG

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
id
response field.

Endpoints

Production:
POST
https://api.cybersource.com
/pts/v2/payments/
{id}
/refunds
Test:
POST
https://apitest.cybersource.com
/pts/v2/payments/
{id}
/refunds
The
{id}
is the request ID contained in the original transaction request.

Required Fields for Refunding a Payment

clientReferenceInformation.code
orderInformation.amountDetails.currency
Set to
EUR
.
orderInformation.amountDetails.totalAmount
paymentInformation.paymentType.method.name
Set to
SODEXO
.
paymentInformation.paymentType.name
Set to
Voucher
.
processingInformation.actionList
Set to
AP_REFUND
.

Example: Refunding a Payment

Request
{ "clientReferenceInformation": { "code": "refnum-1234" }, "paymentInformation": { "paymentType": { "method": { "name": "SODEXO" }, "name": "Voucher" } }, "processingInformation": { "actionList": "AP_REFUND" }, "orderInformation": { "amountDetails": { "totalAmount": "5.00", "currency": "EUR" } } }
Response to a Successful Request
{ "_links": { "self": { "method": "GET", "href": "/pts/v2/refunds/7546712826736457204806" }, "status": { "method": "POST", "href": "/pts/v2/refresh-payment-status/7546712826736457204806" } }, "clientReferenceInformation": { "code": "refnum-1234" }, "errorInformation": { "reason": "PAYMENT_REFUSED", "message": "Payment Service Error" }, "id": "7546712826736457204806", "processorInformation": { "responseCode": "30200" }, "status": "FAILED" }

Response Statuses for Refunding a Payment

Cybersource
responds to your refund request with one of these statuses in the
status
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 Transaction Status.