Welcome to the Accounts section of our API documentation and reference guide. This portion provides an exhaustive toolset for performing various operation and management tasks around accounts. You can retrieve a list of all accounts using GET /account, and open new accounts using either POST /account/business/{id} for business customers, or POST /account/individual/{id} for individual customers, with the customer's ID filled in as required.
Endpoints
The Accounts has the following endpoints:
- GET/account: Get list of all accounts
- POST/account/business/{id}: Open a new account for a business customer
- POST/account/individual/{id}: Open a new account for an individual customer
- GET/account/{accountNumber}: Retrieve a specific account by its account number
- GET/account/{accountNumber}/balance: Retrieve balance details for an account
- PATCH/account/{accountNumber}/status: Update status of an account (Admin use only)
Parameters
Here's a table of Account's parameters, their default values, and their definitions based on the provided details:
Parameter | Default Value | Definition |
---|---|---|
accountNumber | (required) accountNumber | This is a required field that represents the account number in question. Typically, it's a unique identifier used by banks to denote a specific account. It usually should be provided in the path of the request. |
request.status | "ACTIVE" | This field signifies the current status of the account. In this instance, the status of the account is "ACTIVE". Generally, this field is included in the request body and should be provided as a JSON object. |
id | (required) id | This is a required field that denotes a unique identifier for the request or operation, typically used to track or manage the request operation. |
Status Codes
HTTP Status Code | Reason | Example Reasons | Response Model |
---|---|---|---|
201 | Created | The request was successful and a resource was created. | { "status": "Created" } |
401 | Unauthorized | The request requires user authentication. | { "error": "Unauthorized" } |
403 | Forbidden | The server understood the request, but it refuses to authorize it. | { "error": "Forbidden" } |
404 | Not Found | The server can not find the requested resource. | { "error": "Not Found" } |