General

Transactions

General Transactions API documentation

Introduction

The transactions API call is used to get all the transactions in a given time frame.

Get Transactions

This API will retrieve a list of transactions.

Path
GET /transactions

Query Parameters:

ParameterExample
start_dateyyyy-mm-dd
end_dateyyyy-mm-dd
Please note this API will only pull data through for a given agent set in the API Key settings

Response:

{
    "status": true,
    "total": 30862,
    "records": [
        {
            "transaction_number": "c2e8dfd5-5cb8-46f7-dede-8c96df15df1f",
            "amount": "150.00",
            "status": "Paid",
            "transaction_date": "2023-11-04T00:00:00.000Z",
            "id_number": "8812345678901",
            "company_name": "",
            "response_reason": "",
            "reference_number": "B457",
            "member_number": "MEM450045",
            "workflow_reference": "1234-1234"
        },
        ...
    ]
}

Fields:

NameExampleDescription
transaction_numberc2e8dfd5-5cb8-46f7-dede-8c96df15df1fSystem generated transaction number
amount150.00Transaction Amount
statusPaidPlease see list below of statuses
transaction_date2023-11-04T00:00:00.000ZDate the transaction occurred
id_number8812345678901ID number of person associated to the transaction
company_nameInc CorpCompany name associated to the transaction
response_reasonTransaction DisputedDescription of reason transaction was declined
reference_numberB457Reference number of transaction assigned, can be statement reference too
member_numberMEM450045Customer or member number assigned to person or company
workflow_reference1234-1234Referenced passed through from contact centre

Transactions Statuses:

  • Pending
  • Generated
  • Unpaid
  • Updated/Pending
  • Transmission Accepted
  • Transmission Rejected
  • Account Type Corrected
  • Redirected
  • Paid
  • Sent
  • Undelivered
  • Reversed
  • Transmission Accepted (with warnings)
  • Unpaid (Permanent Failure)

All lookup values can be found under: Lookups API

Error Response:

{
    "status": false,
    "error": "Not authorized to make this API call. Requesting Read on General."
}

When you get this API response ensure that under the API keys section your API Key has the correct permissions: API Keys


Copyright © 2024 SwitchTransact