SpareSpare Docs
GuidesAPI Reference

Bank Accounts

Register and manage creditor bank accounts for payment settlement.

GET
/payment/bank-account
Authorization
Header

Regulatory jurisdiction the request routes to (e.g. `UAE`, `KSA`, `MAIN`). Match it to the market you're integrating.

Query

1-based page number for paginated results. Defaults to the first page.

Number of items to return per page. Defaults to the API's page size.

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X GET "https://example.com/payment/bank-account" \  -H "x-tenant: KSA"
{  "data": [    {      "accountHolderName": "string",      "accountIdentification": "string",      "bankName": "string",      "createdAt": "2019-08-24T14:15:22Z",      "id": "string",      "isDefault": true,      "name": "string",      "scheme": "string"    }  ],  "error": "string",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  },  "meta": {    "currentPageNumber": 0,    "pageSize": 0,    "totalNumberOfPages": 0  }}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "not_found",  "details": {},  "message": "string"}
POST
/payment/bank-account
Authorization
Header

Regulatory jurisdiction the request routes to (e.g. `UAE`, `KSA`, `MAIN`). Match it to the market you're integrating.

Body
*object
object
object
object

Request Body

application/json

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X POST "https://example.com/payment/bank-account" \  -H "x-tenant: KSA" \  -H "Content-Type: application/json" \  -d '{    "accountDetails": {      "identificationNumber": "string"    },    "accountHolderDetails": {      "name": "string"    }  }'
{  "data": {    "accountHolderName": "string",    "accountIdentification": "string",    "bankName": "string",    "createdAt": "2019-08-24T14:15:22Z",    "id": "string",    "isDefault": true,    "name": "string",    "scheme": "string"  },  "error": "string",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  }}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "not_found",  "details": {},  "message": "string"}
GET
/payment/bank-account/default
Authorization
Header

Regulatory jurisdiction the request routes to (e.g. `UAE`, `KSA`, `MAIN`). Match it to the market you're integrating.

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X GET "https://example.com/payment/bank-account/default" \  -H "x-tenant: KSA"
{  "data": {    "accountHolderName": "string",    "accountIdentification": "string",    "bankName": "string",    "createdAt": "2019-08-24T14:15:22Z",    "id": "string",    "isDefault": true,    "name": "string",    "scheme": "string"  },  "error": "string",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  }}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "not_found",  "details": {},  "message": "string"}
PUT
/payment/bank-account/default
Authorization
Header

Regulatory jurisdiction the request routes to (e.g. `UAE`, `KSA`, `MAIN`). Match it to the market you're integrating.

Query

Resource identifier to filter by.

When true, return only the default bank account.

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X PUT "https://example.com/payment/bank-account/default" \  -H "x-tenant: KSA"
{  "data": {    "id": "string",    "identification": "string",    "name": "string",    "schemeName": "string"  },  "error": "string",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  }}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "not_found",  "details": {},  "message": "string"}
GET
/payment/bank-account/{bankAccountId}
Authorization
Path

UUID of the bank account (from the bank accounts list).

Header

Regulatory jurisdiction the request routes to (e.g. `UAE`, `KSA`, `MAIN`). Match it to the market you're integrating.

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X GET "https://example.com/payment/bank-account/string" \  -H "x-tenant: KSA"
{  "data": {    "accountHolderName": "string",    "accountIdentification": "string",    "bankName": "string",    "createdAt": "2019-08-24T14:15:22Z",    "id": "string",    "isDefault": true,    "name": "string",    "scheme": "string"  },  "error": "string",  "errorDescription": {    "property1": [      "string"    ],    "property2": [      "string"    ]  }}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "not_found",  "details": {},  "message": "string"}
DELETE
/payment/bank-account/{bankAccountId}
Authorization
Path

UUID of the bank account (from the bank accounts list).

Header

Regulatory jurisdiction the request routes to (e.g. `UAE`, `KSA`, `MAIN`). Match it to the market you're integrating.

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X DELETE "https://example.com/payment/bank-account/string" \  -H "x-tenant: KSA"
Empty
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "string",  "details": {},  "message": "string"}
{  "code": "not_found",  "details": {},  "message": "string"}