Deferred Cancel

When deferring a card payment a shadow is placed on the card holder's bank account. If you do not wish to take any money you should cancel the deferred transaction which allocates the amount reserved back to the card holder's available balance. Normally after 7 days, this is done automatically by the Payment Gateway.

Method Purpose
POST Cancel a Deferred card transaction

POST

Action: Create a request to Cancel a Deferred card transaction.
Method: POST
URL: https://pay.smarterpay.com/SmarterPayCardPaymentService/api/transaction/{ID}

{ID} denotes ID of the card record.


Request Parameters

Property Mandatory Description
payment_type True Always set to 'DeferredCancel'.
platform True Always set to 'SmarterPayCloud'.
internal_payment_description False A long description of the transaction for internal use only. Not seen by the customer.
gateway_payment_description False A long description of the transaction that will be forwarded to the Payment Gateway. Depending on the Payment Gateway, this may or may not be seen by the customer.
custom_reference False Custom reference set on record.
isAsnyc False Set to true if you do not wish to wait for the result of the transaction. You will receive 202 Accepted if this is set to true. You can view the result of the transaction via the SmarterPay Cloud Portal or via a Webhook.
metadata False Any additional data attached to the transaction. Recommendation to use key/value pairs or simple JSON structures. This will be sent out in any active Webhooks so can be used to tie information back to source records in another platform.

Request Sample

{
   "payment_type":"DeferredCancel",
   "platform":"SmarterPayCloud",
   "amount":100,
   "currency_code":"GBP",   
   "internal_payment_description":"Cancel for something",  
   "gateway_payment_description":"Cancel for something sent to the gateway",
   "custom_reference":"MYREFERENCE0001" ,
   "isAsnyc": false,
   "related_payment_id":"P01YZ96J1D7WDK8NEWD"
}

Response Parameters

Property Description
card_id The ID of the card that the deferred cancel took place under.
payment_id The unique ID of the deferred cancel transaction.
platform The platform that the transaction took place on. Always 'SmarterPayCloud'.
payment_type The type of transaction. In this case 'DeferredCancel'.
payment_gateway Confirmation of the Payment Gateway that the transaction took place on.
status Normalised result of the transaction. See the possible values here.
status_details Normalised result details of the transaction. See the possible values here.
status_code Normalised result code of the transaction. See the possible values here.
gateway_status The result of the transaction as sent by the Payment Gateway. See Payment Gateway documentation for possible values.
gateway_status_details Additional result details provided by the Payment Gateway. Not all Payment Gateways supply this. See Payment Gateway documentation for possible values.
gateway_status_code Additional result code provided by the Payment Gateway. Not all Payment Gateways supply this. See Payment Gateway documentation for possible values.

Response Sample

{
    "card_id": "CD01OQW39P4G97J56NXL",
    "payment_id": "P01QW39P4ODOY3P56NX",
    "platform": "SmarterPayCloud",
    "payment_type": "DeferredCancel",
    "payment_gateway": "OpayoPi",
    "status": "successful",
    "status_details": "",
    "status_code": "",
    "gateway_status": "Ok",
    "gateway_status_details": "The Authorisation was Successful.",
    "gateway_status_code": "0000"
}