Skip to content
Developerhome

Available accounts

  Less than to read

Connector APIBanking Service -> Provider

This endpoint allows Banking Service to retrieve a list of accounts available for linking using the multi-account linking flow.

The /availableaccounts endpoint enables you to use the multi-account link flow to link additional accounts to an existing BankConnection. This means customers do not need to repeat the single account flow multiple times.

:

Note: All accounts that are under the same authorisation should be returned within the GET /availableaccounts request.


GET/availableaccounts

Request

The following query parameters are sent within the GET availableaccounts request:

Query Parameter Description
externalId This externalId is the identifier you give when first providing Banking Service with the users accounts through the patch authorisations call on the onboarding flow.

Response

Using the externalId provided in the query parameters you should then return an array of available accounts under the same authorisation.

Example of response:

[
    {
        "accountType": "string",
        "accountName": "string",
        "externalId": "string",
        "bankIdentifier": "e9316993-a44f-49a7-b891-2374c77ce5a4",
        "accountIdentifier": "4de7d7a7-b222-4024-96b5-95b20d350b77",
        "branchIdentifier": "string"
    },
    {
        "accountType": "string",
        "accountName": "string",
        "externalId": "string",
        "bankIdentifier": "a4676993-a44f-49a7-b891-2374c77ce5a4",
        "accountIdentifier": "7vh6d3a2-b222-4024-96b5-95b20d350b77",
        "branchIdentifier": "string"
    }
]

Description of the fields:

  • accountType: (string) is the type of account; ‘business’, ‘savings’, ‘loan’, ‘creditCard’, ‘corporate’ or ‘personal’.
  • accountName: (string) The bank account name that is to be displayed to the customer. Can use account name qnd masked account number to help customers identify.
  • externalId: (string) The provider’s own unique identifier for the bank account.
  • bankIdentifier: (string) The real-world bank identifier for the specific bank. Banking Service recommends this to be an identifier that represents the customer’s credentials.
  • accountIdentifier: (string) The real-world account number for the bank account. Usually this isn’t the account number but a unique identifier held by the provider.
  • branchIdentifier: (string) The real-world branch identifier for the bank account. If you do not wish to use please populate with the string ‘n/a’.

Securing this endpoint

Within this request you will be passed a Sage ID token under the authorisation header which can be verified using the following endpoint:

  • Sandbox https://id-shadow.sage.com/.well-known/jwks.json
  • Production https://id.sage.com/.well-known/jwks.json

The following is an example of the request headers which would be sent along with this request:

  headers: {
    accept: 'application/json',
    Authorization: 'Bearer **Sage ID Token**',
    'content-type': 'application/json; charset=utf-8',
  }

Was this helpful?