Investec Developer Community Wiki
  • 🏠Home
    • Investec Developer community wiki
  • ⚒️Get Started
    • Get started overview
    • Investec Developer Docs
    • Self-enrollment guide
    • API quick start guide
      • 🔑How to create your API keys
      • 👤How to authenticate against the Investec API
      • 🏦How to get your account, balance, and transaction data
      • 💸How to make transfers and payments
    • Programmable card quick start guide
      • 🙌How to activate your programmable card
      • 🚀How to add low-code snippets to your card on Investec Online
      • 🖥️How to add code to your card and run a simulation using the online IDE
      • 💳How to use the programmable card API
    • Sample apps
  • ⚒️Get Building
    • Get building overview
    • Community GitHub
    • Community libraries & tools
    • Build tutorials & guides
      • 💳Card | Slack Integration
      • 🚗Card | How to create a DIY petrol card
      • 🎯API | No-code Budget Expense App
    • Build challenges & hackathons
      • 🎯[Closed] Q1 2025 Bounty Challenge | Path to Financial Health
      • 🎁[CLOSED] Q4 2024 Bounty Challenge | Festive API Wrappers
      • 🚂[CLOSED] Q3 2024 Bounty Challenge | Everyday Solutions
      • ☄️[CLOSED] Q2 2024 Bounty Challenge | Card Code Snippets
      • 💰[CLOSED] Bounties Playground | banking.make.dev
      • 👩‍💻👩💻 [CLOSED] Mindjoy | Kid at Heart Build Challenge
      • ⚡[CLOSED] EskomSePush Build Challenge
        • EskomSePush Build Challenge Submissions
      • 💳[CLOSED] 2022 Hackathon | low-code/no-code
        • 2022 Hackathon | low-code/no-code | Submissions
      • 💰[CLOSED] Spreadsheet Banking | Bounties
        • 👩‍💻👩💻 Spreadsheet Banking | Basic Functions
      • 🏔️[CLOSED] Q1 2023 Bounty Challenge
      • 💳[CLOSED] Q2 2023 Bounty Challenge
        • 🗺️Checklist for Bounty Hunters 🏆
        • 🚀Bounty Challenge #2: Code Snippet Showdown 🚀
      • 🍕[CLOSED] Q1 2024 Bounty Challenge | The Tutorial Quest
    • Open-source projects
  • 🙌Community
    • Get involved
    • Community champions
    • Community events
    • Community manifesto
    • Blog posts
    • Community integration pros
    • Investec Developer's QRious Puzzle Challenge
  • 💬Feedback and Support
    • Get support
    • Community FAQs
    • Feature requests
    • Submit product issues
Powered by GitBook
On this page
  • Using Postman
  • 1. Get your accounts and account ID with Postman
  • 2. Get your account balance with Postman
  • 3. Get your transaction data with Postman
  • cuRL code snippets
  • 🏦 Private Banking
  • 🧰 CIB

Was this helpful?

  1. Get Started
  2. API quick start guide

How to get your account, balance, and transaction data

PreviousHow to authenticate against the Investec APINextHow to make transfers and payments

Last updated 3 months ago

Was this helpful?

The Account information API allows you access to your account and transaction data. It can be used to retrieve things like account details and balances.

Using Postman

If you’re new to APIs and want to get familiar with using the endpoints, we recommend you create a Postman account (it's free) and use the Postman collections provided to test things out.

It includes collections for the 🏦 Private Banking, 🧰 Corporate Investment Banking (CIB) and 💳Programmable card APIs.

1. Get your accounts and account ID with Postman

Follow these steps for 🏦 Private Banking and 🧰 CIB, using the appropriate Postman collection and API endpoints as above.

  1. Navigate to the Accounts folder and the GET Accounts query

  2. Hit Send to make a call to the account information API endpoint (no additional parameters need to be set).

🏦 https://openapi.investec.com/za/pb/v1/accounts
🧰 https://openapi.investec.com/za/bb/v1/accounts

The Accounts query will returns accountID as well as account balance for 🧰 CIB.

The JSON response will include all of your accounts and each account has a unique ID (accountID) that you will use when transacting against it.

Example response for 🏦 Private Banking
{
  "data": {
    "accounts": [
      {
        
        "accountNumber": "11223344556677",
        "accountName": "Jane Smith",
        "referenceName": "Jane Smith",
        "productName": "Private Bank Account",
        "kycCompliant": true,
        "profileId": "9876543210"
      },
    ]
  },
  "links": {
    "self": "https://openapi.investec.com/za/pb/v1/accounts"
  },
  "meta": {
    "totalPages": 1
  }
}
Example response for 🧰 CIB
{
    "data": {
        "accounts": [
            {
                "AccountHolderAddress": {
                    "AddressLine1": "",
                    "AddressLine2": "",
                    "City": "",
                    "Country": "",
                    "CountryCode": ""
                },
                "RoutingBIC": "",
                "BankAccountProductType": "",
                "CreditLastCycleToNextBusinessDate": "0001-01-01T00:00:00",
                "CustomerAccountType": "",
                "DebitLastCycleToNextBusinessDate": "0001-01-01T00:00:00",
                "DueDateOfPayment": "2023-05-14T22:00:01Z",
                "MinimumAmountLimit": 0,
                "NumberOfCardHolders": 0,
                "CreditLimit": 1,
                "DebitAccountBankName": "",
                "PendingTransactions": 0,
                "Banks": {
                    "Name": "Investec South Africa",
                    "ChipsUID": "",
                    "Branch": [
                        {
                            "Number": ""
                        }
                    ],
                    "PostalAddress": {
                        "AddressLine1": "",
                        "AddressLine2": "",
                        "City": "",
                        "Country": null
                    }
                },
                "Currencies": {
                    "CurrencyCode": "ZAR"
                },
                "InterestDistribution": "",
                "NoticesBalance": 0,
                "AccountOpenDate": "2021-07-01T22:00:01Z",
                "CumulativeNoticesAmount": 0,
                "InstantAvailableNoticeBalance": 0,
                "MinimimAmountLimit": 0,
                "loggedOnUser": {
                    "UserFirstName": "John",
                    "UserLastName": "Doe",
                    "UserCompany": "John Doe (Pty) Ltd"
                },
                "NoticeInterestNominated": 0,
                "NoticeInterestBank": "",
                "noticeInterestAccountName": "",
                "NoticeInterestAccount": "",
                "PreviousStatementPeriod": "2023-01-01T22:00:01Z",
                "DebitAccountNumber": "",
                "DealReference": "",
                "AutomaticPaymentOrder": "0",
                "BackOfficeCustomerCode": "JDCARD",
                "AccountId": "10111",
                "AccountName": "10011111111 Credit Card",
                "AccountFullName": "",
                "AccountType": "Credit Card",
                "AccountTypeId": "1",
                "AccountNumber": "10011111111",
                "AlternativeAccNo": "",
                "ElectronicAccountNumber": "",
                "Balances": {
                    "CapitalBalance": 100,
                    "AvailableBalance": 100,
                    "PrincipalAmount": 0,
                    "ValueDate": "2023-01-01T22:00:01Z",
                    "ClosingBalance": 200,
                    "PendingCardBalance": 0
                },
                "BackOfficeType": "",
                "Products": {
                    "StartDate": "0001-01-01T00:00:00",
                    "EndDate": "0001-01-01T00:00:00",
                    "OverdraftLimit": 0,
                    "MaxTransferLimit": 0
                },
                "Description": "Credit Card",
                "OwnerType": "1",
                "Interests": {
                    "Amount": 0,
                    "Rate": 0,
                    "RateMaturity": 0,
                    "RateCredit": 0,
                    "RateDebit": 10,
                    "AccruedCreditInterest": 0,
                    "AccruedDebitInterest": 0
                },
                "ActiveFlag": "Y",
                "NickName": "Credit Card",
                "CreatedDate": "2021-07-01T22:00:01Z",
                "ModifiedDate": "0001-01-01T00:00:00",
                "MaturityAmount": 0,
                "StatementFrequency": "",
                "StatementNumber": "",
                "StatementDay": "0",
                "StatementMonth": "",
                "EmailAddress": "",
                "Category": "Borrow",
                "LinkedAccount": "",
                "AccountFormat": "4"
            }
        ]
    },
    "links": {
        "self": null
    },
    "meta": {
        "totalPages": 1
    }
}

2. Get your account balance with Postman

Follow these steps for 🏦 Private Banking using the appropriate Postman collection and API endpoints as above. The account balance for 🧰 CIB is included in the Get Accounts request.

  1. Retrieve the accountID from your previous call to get accounts.

  2. Head over to the "Variables" table to insert your accountID. You can also set it under the Params tab on the query page.

  3. Navigate to the Accounts folder and the GET Account Balance query .

  4. Hit Send to make a call to the API endpoint.

🏦  https://openapi.investec.com/za/pb/v1/accounts/:accountId/balance
Example response for 🏦 Private Banking
{
    "data": {
        "accountId": "3353431574710163189587446",
        "currentBalance": 33607.16,
        "availableBalance": 33607.16,
        "currency": "ZAR"
    },
    "links": {
        "self": "https://openapisandbox.investec.com/za/pb/v1/accounts/3353431574710163189587446/balance"
    },
    "meta": {
        "totalPages": 1
    }
}

3. Get your transaction data with Postman

Follow these steps for 🏦 Private Banking and 🧰 CIB, using the appropriate Postman collection and API endpoints as above.

  1. Ensure you have added your accountID to the "Variables" table

  2. Navigate to the GET Account transactions query and set the dates for which you would like to view the transactions by selecting fromDate and toDate in the Query params table and adding the dates.

  3. Hit Send to make a call to the API endpoint.

🏦  https://openapi.investec.com/za/pb/v1/accounts/:accountId/transactions?fromDate=2023-03-10&toDate=2023-03-10
🧰  https://openapi.investec.com/za/bb/v1/accounts/:accountId/transactions?fromDate=2023-01-01&toDate=2023-01-31
Example response for 🏦 Private Bank
{
    "data": {
        "transactions": [
            {
                "accountId": "3353431574710163189587446",
                "type": "DEBIT",
                "transactionType": "CardPurchases",
                "status": "POSTED",
                "description": "KURUMAN FRESH PRODUCE H KURUMAN ZA",
                "cardNumber": "402261xxxxxx0011",
                "postedOrder": 11049,
                "postingDate": "2023-04-13",
                "valueDate": "2023-04-30",
                "actionDate": "2023-04-12",
                "transactionDate": "2023-04-11",
                "amount": 53.6,
                "runningBalance": 34679.66
            },
            {
                "accountId": "3353431574710163189587446",
                "type": "DEBIT",
                "transactionType": "CardPurchases",
                "status": "POSTED",
                "description": "YOCO   *ARUKAH HEALTH KURUMAN ZA",
                "cardNumber": "402261xxxxxx0018",
                "postedOrder": 11050,
                "postingDate": "2023-04-13",
                "valueDate": "2023-04-30",
                "actionDate": "2023-04-12",
                "transactionDate": "2023-04-12",
                "amount": 374,
                "runningBalance": 34305.66
            },
           
        ]
    },
    "links": {
        "self": "https://openapisandbox.investec.com/za/pb/v1/accounts/3353431574710163189587446/transactions"
    },
    "meta": {
        "totalPages": 1
    }
}
Example response for 🧰 CIB
{
    "data": {
        "transactions": [
            {
                "AccountName": "ZAR 1900539687921 SmartRate Plus Notice 32",
                "TransactionCode": "9",
                "TransactionStatus": "approved",
                "InvestmentDate": "0001-01-01T00:00:00",
                "InvestmentDateUtc": "0001-01-01T00:00:00",
                "InvestmentDateSa": "0001-01-01T01:52:00+01:52",
                "InvestmentName": null,
                "InvestmentStatus": null,
                "RemainingTerm": null,
                "InvestmentAmount": null,
                "StatementId": "52292",
                "InstantAccessBalance": null,
                "BranchCode": null,
                "AccountNumber": null,
                "DistributionAccount": null,
                "AccountType": null,
                "PostDate": "0001-01-01T00:00:00",
                "PostDateUtc": "0001-01-01T00:00:00",
                "PostDateSa": "0001-01-01T01:52:00+01:52",
                "Interest": null,
                "AccruedInterest": null,
                "MaturityDate": "0001-01-01T00:00:00",
                "MaturityDateUtc": "0001-01-01T00:00:00",
                "MaturityDateSa": "0001-01-01T01:52:00+01:52",
                "BankName": null,
                "CustomerReferenceId": "",
                "BackOfficeReferenceId": "",
                "CardNumber": "92974054603",
                "TransactionId": "202304110000000000009",
                "Reference": "DVfZ WT tmKkeb",
                "Beneficiaries": {
                    "LinkList": null,
                    "Entities": {
                        "EntityName": "aQaZUGJXQuCqxwJX JoYk ftvSWKWybWXPS OZVmxIq"
                    }
                },
                "Description": "X bssSCS",
                "Accounts": {
                    "AccountId": 91974,
                    "AccountNumber": "1900539687921"
                },
                "Currencies": {
                    "CurrencyCode": "ZAR"
                },
                "CaptureDate": "2023-07-19T18:25:33.83Z",
                "CaptureDateUtc": "2023-07-19T18:25:33.83Z",
                "CaptureDateSa": "2023-07-19T20:25:33.83+02:00",
                "ValueDate": "2023-07-19T18:25:33.83Z",
                "ValueDateUtc": "2023-07-19T18:25:33.83Z",
                "ValueDateSa": "2023-07-19T20:25:33.83+02:00",
                "CardHolderName": "mj TgW VOGbTQo",
                "AutoForwardProcessingDate": false,
                "Amount": -130000000,
                "Reference_1": "99162191",
                "Reference_2": "",
                "Reference_3": "MAECrNWJfonnjpifiJDlhUBtixrq kMHnf",
                "Reference_4": null,
                "Reference_5": null,
                "Reference_8": "665",
                "Reference_9": "gUDASgs t pwqHBeowNZBJwJkEGIMdEErHJXocDrXTfbeIRRjF srDkOAdOxUvfWnsCFhSZLKkxJ TyMlYXsoCDyP USlHaNRRMwItGdxJrP",
                "Reference_10": "",
                "RunningBalance": 19290794.77
            },
            {
                "AccountName": "ZAR 1900539687921 SmartRate Plus Notice 32",
                "TransactionCode": "10",
                "TransactionStatus": "approved",
                "InvestmentDate": "0001-01-01T00:00:00",
                "InvestmentDateUtc": "0001-01-01T00:00:00",
                "InvestmentDateSa": "0001-01-01T01:52:00+01:52",
                "InvestmentName": null,
                "InvestmentStatus": null,
                "RemainingTerm": null,
                "InvestmentAmount": null,
                "StatementId": "52311",
                "InstantAccessBalance": null,
                "BranchCode": null,
                "AccountNumber": null,
                "DistributionAccount": null,
                "AccountType": null,
                "PostDate": "0001-01-01T00:00:00",
                "PostDateUtc": "0001-01-01T00:00:00",
                "PostDateSa": "0001-01-01T01:52:00+01:52",
                "Interest": null,
                "AccruedInterest": null,
                "MaturityDate": "0001-01-01T00:00:00",
                "MaturityDateUtc": "0001-01-01T00:00:00",
                "MaturityDateSa": "0001-01-01T01:52:00+01:52",
                "BankName": null,
                "CustomerReferenceId": "",
                "BackOfficeReferenceId": "",
                "CardNumber": "",
                "TransactionId": "202304300000000000010",
                "Reference": "",
                "Beneficiaries": {
                    "LinkList": null,
                    "Entities": {
                        "EntityName": "hdPZPMq "
                    }
                },
                "Description": "VpXcXPsq",
                "Accounts": {
                    "AccountId": 91974,
                    "AccountNumber": "1900539687921"
                },
                "Currencies": {
                    "CurrencyCode": "ZAR"
                },
                "CaptureDate": "2023-08-07T18:25:33.83Z",
                "CaptureDateUtc": "2023-08-07T18:25:33.83Z",
                "CaptureDateSa": "2023-08-07T20:25:33.83+02:00",
                "ValueDate": "2023-08-07T18:25:33.83Z",
                "ValueDateUtc": "2023-08-07T18:25:33.83Z",
                "ValueDateSa": "2023-08-07T20:25:33.83+02:00",
                "CardHolderName": "",
                "AutoForwardProcessingDate": false,
                "Amount": 1313801.71,
                "Reference_1": "",
                "Reference_2": "",
                "Reference_3": "",
                "Reference_4": null,
                "Reference_5": null,
                "Reference_8": "797",
                "Reference_9": "vPqivetP",
                "Reference_10": "",
                "RunningBalance": 20604596.48
            },
            {
                "AccountName": "ZAR 1900539687921 SmartRate Plus Notice 32",
                "TransactionCode": "11",
                "TransactionStatus": "approved",
                "InvestmentDate": "0001-01-01T00:00:00",
                "InvestmentDateUtc": "0001-01-01T00:00:00",
                "InvestmentDateSa": "0001-01-01T01:52:00+01:52",
                "InvestmentName": null,
                "InvestmentStatus": null,
                "RemainingTerm": null,
                "InvestmentAmount": null,
                "StatementId": "52342",
                "InstantAccessBalance": null,
                "BranchCode": null,
                "AccountNumber": null,
                "DistributionAccount": null,
                "AccountType": null,
                "PostDate": "0001-01-01T00:00:00",
                "PostDateUtc": "0001-01-01T00:00:00",
                "PostDateSa": "0001-01-01T01:52:00+01:52",
                "Interest": null,
                "AccruedInterest": null,
                "MaturityDate": "0001-01-01T00:00:00",
                "MaturityDateUtc": "0001-01-01T00:00:00",
                "MaturityDateSa": "0001-01-01T01:52:00+01:52",
                "BankName": null,
                "CustomerReferenceId": "",
                "BackOfficeReferenceId": "",
                "CardNumber": "",
                "TransactionId": "202305310000000000011",
                "Reference": "",
                "Beneficiaries": {
                    "LinkList": null,
                    "Entities": {
                        "EntityName": "pZwWKoPA"
                    }
                },
                "Description": " tqwoyld",
                "Accounts": {
                    "AccountId": 91974,
                    "AccountNumber": "1900539687921"
                },
                "Currencies": {
                    "CurrencyCode": "ZAR"
                },
                "CaptureDate": "2023-09-07T18:25:33.83Z",
                "CaptureDateUtc": "2023-09-07T18:25:33.83Z",
                "CaptureDateSa": "2023-09-07T20:25:33.83+02:00",
                "ValueDate": "2023-09-08T18:25:33.83Z",
                "ValueDateUtc": "2023-09-08T18:25:33.83Z",
                "ValueDateSa": "2023-09-08T20:25:33.83+02:00",
                "CardHolderName": "",
                "AutoForwardProcessingDate": false,
                "Amount": 1076307.1,
                "Reference_1": "",
                "Reference_2": "",
                "Reference_3": "",
                "Reference_4": null,
                "Reference_5": null,
                "Reference_8": "",
                "Reference_9": " HT icGG",
                "Reference_10": "",
                "RunningBalance": 21680903.58
            },
            {
                "AccountName": "ZAR 1900539687921 SmartRate Plus Notice 32",
                "TransactionCode": "12",
                "TransactionStatus": "approved",
                "InvestmentDate": "0001-01-01T00:00:00",
                "InvestmentDateUtc": "0001-01-01T00:00:00",
                "InvestmentDateSa": "0001-01-01T01:52:00+01:52",
                "InvestmentName": null,
                "InvestmentStatus": null,
                "RemainingTerm": null,
                "InvestmentAmount": null,
                "StatementId": "52372",
                "InstantAccessBalance": null,
                "BranchCode": null,
                "AccountNumber": null,
                "DistributionAccount": null,
                "AccountType": null,
                "PostDate": "0001-01-01T00:00:00",
                "PostDateUtc": "0001-01-01T00:00:00",
                "PostDateSa": "0001-01-01T01:52:00+01:52",
                "Interest": null,
                "AccruedInterest": null,
                "MaturityDate": "0001-01-01T00:00:00",
                "MaturityDateUtc": "0001-01-01T00:00:00",
                "MaturityDateSa": "0001-01-01T01:52:00+01:52",
                "BankName": null,
                "CustomerReferenceId": "",
                "BackOfficeReferenceId": "",
                "CardNumber": "",
                "TransactionId": "202306300000000000012",
                "Reference": "",
                "Beneficiaries": {
                    "LinkList": null,
                    "Entities": {
                        "EntityName": "lAxjcVbg"
                    }
                },
                "Description": "gLeRJPbl",
                "Accounts": {
                    "AccountId": 91974,
                    "AccountNumber": "1900539687921"
                },
                "Currencies": {
                    "CurrencyCode": "ZAR"
                },
                "CaptureDate": "2023-10-07T18:25:33.83Z",
                "CaptureDateUtc": "2023-10-07T18:25:33.83Z",
                "CaptureDateSa": "2023-10-07T20:25:33.83+02:00",
                "ValueDate": "2023-10-08T18:25:33.83Z",
                "ValueDateUtc": "2023-10-08T18:25:33.83Z",
                "ValueDateSa": "2023-10-08T20:25:33.83+02:00",
                "CardHolderName": "",
                "AutoForwardProcessingDate": false,
                "Amount": 1103322.74,
                "Reference_1": "",
                "Reference_2": "",
                "Reference_3": "",
                "Reference_4": null,
                "Reference_5": null,
                "Reference_8": "",
                "Reference_9": "rIYXgXSU",
                "Reference_10": "",
                "RunningBalance": 22784226.32
            }
        ]
    },
    "links": {
        "self": "https://openapisandbox.investec.com/za/bb/v1/accounts/91974/transactions"
    },
    "meta": {
        "TotalCount": 4,
        "TotalPages": 1,
        "CurrentPage": 1,
        "CurrentPageSize": 100,
        "ResultCount": 4
    }
}

Pro Tips:

  • You may have noticed, the endpoint accepts a pagination parameter for when you need to iterate through a longer transaction history.

  • Filtering can be done using the postingdate

    • postingdate is the date at which the transaction affects your balance

    • transactiondate is the date on which the transaction took place (day the card was physically swiped)

cuRL code snippets

🏦 Private Banking

Get accounts and accountID

curl --location 'https://openapi.investec.com/za/pb/v1/accounts' \
--header 'Accept: application/json'

Get account balance

curl --location 'https://openapi.investec.com/za/pb/v1/accounts//balance' \
--header 'Accept: application/json'

Get transaction data

curl --location 'https://openapi.investec.com/za/pb/v1/accounts//transactions' \
--header 'Accept: application/json'

🧰 CIB

Get accounts, accountID and account balance

curl --location 'https://openapi.investec.com/za/bb/v1/accounts' \
--header 'Accept: application/json' \
--header 'Authorization: [[Authorization-masked-secret]]'

Get transaction data

curl --location 'https://openapi.investec.com/za/bb/v1/accounts/<<account id>>/transactions?fromDate=2023-01-01&toDate=2023-01-31' \
--header 'Accept: application/json' \
--header 'Authorization: [[Authorization-masked-secret]]'

Ensure have and pasted in your bearer token into the "Variables" tables.

fromDate and toDate can be any formatted date [Example of formatted date: 1999-09-09]].

⚒️
🏦
Investec Programmable Banking Postman Collection
authenticated
ISO 8601