SpareSpare Docs
GuidesAPI Reference

Accounts & Balances

List accounts and read current and historical balances.

v1 and v2

These endpoints exist in v1 (/api/v1.0/…) and v2 (/api/v2.0/…). v2 is for long-lived consent; v1 is the standard flow. Both are shown below, pick the version that matches your consent type.

v1

GET
/api/v1.0/ais/Account/Get
Authorization
Query

Account id

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

curl -X GET "https://example.com/api/v1.0/ais/Account/Get?id=497f6eca-6276-4993-bfeb-53cbbbba6f08"
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": {    "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",    "externalId": "string",    "currency": {      "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",      "englishName": "string",      "arabicName": "string",      "iso4117Code": "str",      "iso4117Number": "stri"    },    "servicer": {      "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",      "address": {        "addressType": "string",        "department": "string",        "subDepartment": "string",        "addressLine": "string",        "streetName": "string",        "buildingNumber": "string",        "postalCode": "string",        "townName": "string",        "countrySubDivision": "string",        "country": "string",        "shortAddress": "string",        "unitNumber": 0,        "secondaryNumber": "string",        "district": "string",        "city": "string"      },      "scheme": "string",      "identification": "string"    },    "accounts": [      {        "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",        "scheme": "string",        "identification": "string",        "name": "string"      }    ],    "status": "string",    "statusUpdatedDateTime": "2019-08-24T14:15:22Z",    "type": "string",    "subType": "string",    "description": "string",    "openingDate": "2019-08-24T14:15:22Z",    "maturityDate": "2019-08-24T14:15:22Z"  }}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
Empty
GET
/api/v1.0/ais/Account/List
Authorization
Query

Consent id

Page number

Number of items per page maximum allow is 200 per page

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

curl -X GET "https://example.com/api/v1.0/ais/Account/List?consentId=497f6eca-6276-4993-bfeb-53cbbbba6f08"
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": [    {      "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",      "externalId": "string",      "currency": {        "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",        "englishName": "string",        "arabicName": "string",        "iso4117Code": "str",        "iso4117Number": "stri"      },      "servicer": {        "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",        "address": {          "addressType": "string",          "department": "string",          "subDepartment": "string",          "addressLine": "string",          "streetName": "string",          "buildingNumber": "string",          "postalCode": "string",          "townName": "string",          "countrySubDivision": "string",          "country": "string",          "shortAddress": "string",          "unitNumber": 0,          "secondaryNumber": "string",          "district": "string",          "city": "string"        },        "scheme": "string",        "identification": "string"      },      "accounts": [        {          "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",          "scheme": "string",          "identification": "string",          "name": "string"        }      ],      "status": "string",      "statusUpdatedDateTime": "2019-08-24T14:15:22Z",      "type": "string",      "subType": "string",      "description": "string",      "openingDate": "2019-08-24T14:15:22Z",      "maturityDate": "2019-08-24T14:15:22Z"    }  ],  "meta": {    "currentPageNumber": 0,    "pageSize": 0,    "totalNumberOfPages": 0,    "totalItems": 0  }}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
Empty
GET
/api/v1.0/ais/Balance/Get
Authorization
Query

Account id

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

curl -X GET "https://example.com/api/v1.0/ais/Balance/Get?accountId=497f6eca-6276-4993-bfeb-53cbbbba6f08"
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": {    "accountId": "3d07c219-0a88-45be-9cfc-91e9d095a1e9",    "externalAccountId": "string",    "balances": [      {        "creditDebitIndicator": "string",        "dateTime": "string",        "creditLine": [          {            "included": true,            "type": "string",            "amount": {              "amount": 0.1,              "currency": "string",              "localExchange": {                "sourceCurrency": "string",                "targetCurrency": "string",                "rate": 0.1,                "date": "2019-08-24",                "value": 0.1              }            }          }        ],        "type": "string",        "amount": {          "amount": 0.1,          "currency": "string",          "localExchange": {            "sourceCurrency": "string",            "targetCurrency": "string",            "rate": 0.1,            "date": "2019-08-24",            "value": 0.1          }        }      }    ]  }}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
Empty
GET
/api/v1.0/ais/Balance/History
Authorization
Query

Account id

From booking date time

To booking date time

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

curl -X GET "https://example.com/api/v1.0/ais/Balance/History?accountId=497f6eca-6276-4993-bfeb-53cbbbba6f08"
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": {    "accountId": "3d07c219-0a88-45be-9cfc-91e9d095a1e9",    "history": [      {        "date": "string",        "balances": [          {            "type": "string",            "amount": {              "amount": 0.1,              "currency": "string",              "localExchange": {                "sourceCurrency": "string",                "targetCurrency": "string",                "rate": 0.1,                "date": "2019-08-24",                "value": 0.1              }            }          }        ]      }    ]  }}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
Empty
GET
/api/v2.0/ais/Account/Get
Authorization
Query

Account id

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

curl -X GET "https://example.com/api/v2.0/ais/Account/Get?id=497f6eca-6276-4993-bfeb-53cbbbba6f08"
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": {    "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",    "externalId": "string",    "currency": {      "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",      "englishName": "string",      "arabicName": "string",      "iso4117Code": "str",      "iso4117Number": "stri"    },    "servicer": {      "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",      "address": {        "addressType": "string",        "department": "string",        "subDepartment": "string",        "addressLine": "string",        "streetName": "string",        "buildingNumber": "string",        "postalCode": "string",        "townName": "string",        "countrySubDivision": "string",        "country": "string",        "shortAddress": "string",        "unitNumber": 0,        "secondaryNumber": "string",        "district": "string",        "city": "string"      },      "scheme": "string",      "identification": "string"    },    "accounts": [      {        "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",        "scheme": "string",        "identification": "string",        "name": "string"      }    ],    "status": "string",    "statusUpdatedDateTime": "2019-08-24T14:15:22Z",    "type": "string",    "subType": "string",    "description": "string",    "openingDate": "2019-08-24T14:15:22Z",    "maturityDate": "2019-08-24T14:15:22Z"  }}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
Empty
GET
/api/v2.0/ais/Account/List
Authorization
Query

Consent id

Page number

Number of items per page maximum allow is 200 per page

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

curl -X GET "https://example.com/api/v2.0/ais/Account/List?consentId=497f6eca-6276-4993-bfeb-53cbbbba6f08"
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": [    {      "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",      "externalId": "string",      "currency": {        "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",        "englishName": "string",        "arabicName": "string",        "iso4117Code": "str",        "iso4117Number": "stri"      },      "servicer": {        "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",        "address": {          "addressType": "string",          "department": "string",          "subDepartment": "string",          "addressLine": "string",          "streetName": "string",          "buildingNumber": "string",          "postalCode": "string",          "townName": "string",          "countrySubDivision": "string",          "country": "string",          "shortAddress": "string",          "unitNumber": 0,          "secondaryNumber": "string",          "district": "string",          "city": "string"        },        "scheme": "string",        "identification": "string"      },      "accounts": [        {          "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",          "scheme": "string",          "identification": "string",          "name": "string"        }      ],      "status": "string",      "statusUpdatedDateTime": "2019-08-24T14:15:22Z",      "type": "string",      "subType": "string",      "description": "string",      "openingDate": "2019-08-24T14:15:22Z",      "maturityDate": "2019-08-24T14:15:22Z"    }  ],  "meta": {    "currentPageNumber": 0,    "pageSize": 0,    "totalNumberOfPages": 0,    "totalItems": 0  }}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
Empty
GET
/api/v2.0/ais/Balance/Get
Authorization
Query

Account id

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

curl -X GET "https://example.com/api/v2.0/ais/Balance/Get?accountId=497f6eca-6276-4993-bfeb-53cbbbba6f08"
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": {    "accountId": "3d07c219-0a88-45be-9cfc-91e9d095a1e9",    "externalAccountId": "string",    "balances": [      {        "creditDebitIndicator": "string",        "dateTime": "string",        "creditLine": [          {            "included": true,            "type": "string",            "amount": {              "amount": 0.1,              "currency": "string",              "localExchange": {                "sourceCurrency": "string",                "targetCurrency": "string",                "rate": 0.1,                "date": "2019-08-24",                "value": 0.1              }            }          }        ],        "type": "string",        "amount": {          "amount": 0.1,          "currency": "string",          "localExchange": {            "sourceCurrency": "string",            "targetCurrency": "string",            "rate": 0.1,            "date": "2019-08-24",            "value": 0.1          }        }      }    ]  }}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
{  "error": "INVALID_DATA",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "data": null}
Empty