Links
🌏

Sync Online Banking Accounts

Generate a GathrLink iFrame in order to allow a Customer to login to their internet banking profile and retrieve transactional data and PDF bank statements.
get
{{baseUrl}}/bank-accounts/:bank_account_id/sync?redirect_url={{redirectUrl}}
Sync Online Banking Accounts

Webhook Requirements | result_url

As this is a specific post query, we need to make sure we are sending customer/clients to a safe destination, as such, there is validation done on the Redirect and Result URL.
The Filed under validation must have a valid A or AAAA record when querying the dns_get_record PHP function.
A a simple guideline:
  • Must be RFC compliant
  • Must include the hostname
  • Be careful with special characters that might mess with the structure of the post request

Webhook Response

The following is the payload that gets sent to the url that is provided in the result_url parameter in the POST Sync Online Banking Accounts request.
The webhook gets triggered once transaction and statement(s) has successfully been collected. Once you receive the relevant successful payloads, you can query the relevant/transactions, /statements, /accounts and /transaction-reports endpoints to retrieve the affordability data you require.

Online Login – Transaction Success

```postman_json
{
"data": {
"bank": "standard-bank",
"session": "tG4536",
"success": true,
"code": "transactions-success",
"tenant": "{{tenantid}}",
"message": "Success”,
"bank_account_id": "{{bankaccountid}}
}
}
```
Once you receive the transaction successful payload, you can query /transactions and /transaction-reports endpoints to retrieve the transactional data you require.

Online Login – Statement Success

```postman_json
{
"data": {
"bank": "standard-bank",
"session": "tG4536",
"success": true,
"code": "statement-success",
"tenant": "{{tenantid}}",
"message": "Success”,
"bank_account_id": "{{bankaccountid}}
}
}
```
Once you receive the statement successful payload, you can query /statements and /accounts endpoints to retrieve the statement and account data you require.

Online Login – Transaction Failure

```postman_json
{
"data": {
"bank": "standard-bank",
"session": "tG4536",
"success": false,
"code": "transactions-failed",
"tenant": "{{tenantid}}",
"message": "We were unable to process the transactions in this account. Please make sure the correct accounts are selected, or try another method”,
"bank_account_id": "{{bankaccountid}}
}
}
```
Transaction Failure Codes
  • LOGIN_FAILED = "login-failed"
  • OTP_FAILED = "otp-failed"
  • LOGIN_UNATHORISED = "login-unauthorised"
  • USER_ACCOUNT_FAILED = "user-accounts-failed"
  • ACCOUNT_SELECTION_FAILED = "accounts-failed"
  • STATEMENT_FAILED = "statement-failed"
  • TRANSACTION_FAILED = "transactions-failed"

Online Login – Statement Failure

```postman_json
{
"data": {
"bank": "standard-bank",
"session": "tG4536",
"success": false,
"code": "statement-failure",
"tenant": "{{tenantid}}",
"message": "Failed”,
"bank_account_id": "{{bankaccountid}}
}
}
```

Online Login – Session Expired

```postman_json
{
"data": {
"bank": "standard-bank",
"session": "tG4536",
"success": false,
"code": "session-expired",
"tenant": "{{tenantid}}",
"message": "Session expired after 30 minutes”
“bank_account_id”: “115f6237-6b92-4b37-a044-77734d6efafd”
}
}
```
Last modified 4mo ago