Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Info

Should your application intend to utilise the scheduling API, please refer to the Scheduling API guide here for steps to initiate a scheduled debit.

Steps to implement - Process a transaction using saved card details

API workflow

API

Sample

POST Process a transaction using saved card details

  • Minimum API property requirements

    • ProcessType

    • Reference

    • Amount

Example Request

Code Block
{{url}}/businesses/{{business-id}}/payers/{{payer-reference}}/transactions/card
Code Block
{
    "ProcessType": "COMPLETE",
    "Reference": "Transaction-001",
    "Amount": 100.75,
    "Description": "This is a test transaction",
    "Audit": {
      "Username": "Example-User",
      "UserIP": "1.2.3.4"
    }
}

Example Response for successful transaction

Code Block
{
  "transactionId": "71403",
  "reference": "Transaction-001",
  "statusCode": "S",
  "subStatusCode": null,
  "statusDescription": null,
  "processedAmount": 100.75,
  "cardType": "Visa",
  "redirectId": null,
  "redirectUrl": null,
  "cardAuthorizationReference": null
}

Example Response for failed/rejected transaction

Code Block
{
    "transactionId": "71403",
    "reference": "Transaction-001",
    "statusCode": "F",
    "subStatusCode": "R6",
    "statusDescription": "Transaction Declined",
    "processedAmount": 100.51,
    "cardType": "Visa",
    "redirectId": null,
    "redirectUrl": null,
    "cardAuthorizationReference": null

...

What to do if the payment is failed / rejected?

...

This concludes the API workflow of implementing the Process a transaction using saved card (charge stored card) to your application. Please refer to our other methods available for accepting payments.

...