Cancel or Refund

Return the funds to the shopper when you are not sure whether the payment has been captured. 


If you want to return the funds to your shopper, but are not certain whether the payment has been captured or not, use the Cancel or Refund functionality. 

This will either: 

  • cancel the payment – in case it has not yet been captured. 
  • refund the payment – in case it has already been captured.

Do not use Cancel or Refund for payments that involve (multiple) partial captures.

Cancel or refund a payment

To issue a cancel or refund, make a request to the /cancelOrRefund endpoint. You need to specify: 

  • merchantAccount: The name of your merchant account that is used to process the payment.
  • originalReference: The original pspReference of the payment that you want to cancel or refund. This reference is returned in the response to your payment request, and in the AUTHORISATION notification.
{
    "merchantAccount" : "YourMerchantAccount",
    "originalReference" : "9313547924770610",
    "reference" : "YourModificationReference"
}

You will receive a /cancelOrRefund  response containing: 

  • pspReference: The PSP reference associated with this /cancelOrRefund  request.

{
    "pspReference" : "8863534564726784",
    "response" : "[cancelOrRefund-received]"
}

Notifications

To know whether your request to cancel or refund the payment was successful, you need to receive CANCEL_OR_REFUND notifications. 

CANCEL_OR_REFUND notifications are not included in the Standard notifications. If you want to receive these notifications, contact our Support Team.

If you have enabled CANCEL_OR_REFUND notifications, we will send you a notification once  we have processed your request to cancel or refund the payment. This notification contains:

  • eventCodeCANCEL_OR_REFUND.
  • pspReference: Same as the pspReference in the /cancelOrRefund response.
  • success: Indicates whether the request to cancel or refund the payment was successful.
    • true: your request was successful. The  modification.action field in the  additionalData object contains information about whether the request produced a cancel or a refund. 
    • false: your request failed. The notification includes a reason field with a short description of the problem. Review the reason, fix the issue if possible, and resubmit the refund request.
 {
   "live":"false",
   "notificationItems":[
      {
         "NotificationRequestItem":{
            "additionalData":{
               "modification.action":"refund"
            },
            "amount":{
               "currency":"EUR",
               "value":100
            },
            "eventCode":"CANCEL_OR_REFUND",
            "eventDate":"2018-09-20T14:29:09+02:00",
            "merchantAccountCode":"YourMerchantAccount",
            "originalReference":"9313547924770610",
            "paymentMethod":"visa",
            "pspReference":"8863534564726784",
            "reason":"",
            "success":"true"
         }
      }
   ]
}

For more information about the fields in the CANCEL_OR_REFUND notification, refer to Notifications API.  

See also