# Accounts

## GET Accounts

<mark style="color:green;">`POST`</mark> `https://api.finqware.com/v1/accounts/get`

Get account data.

#### Request Body

| Name                                               | Type   | Description                                                      |
| -------------------------------------------------- | ------ | ---------------------------------------------------------------- |
| client\_id<mark style="color:red;">\*</mark>       | string | An identifier for your tenant app.                               |
| client\_secret<mark style="color:red;">\*</mark>   | string | A tenant app secret.                                             |
| credentials\_id<mark style="color:red;">\*</mark>  | string | A pointer to a consent record created via an onboarding session. |
| access\_token<mark style="color:red;">\*</mark>    | string | An authorization key for this particular consent record.         |
| tenant\_user\_id<mark style="color:red;">\*</mark> | string | A unique identifier for your end-user.                           |

{% tabs %}
{% tab title="200: OK A list of bank accounts and related info." %}

```javascript
[
    {
        "data": {
            "account_schemes": [
                {
                    "identification": "CZ6355...254079",
                    "scheme_name": "IBAN"
                },
                {
                    "identification": "BRDEROBUXXX",
                    "scheme_name": "BICFI"
                }
            ],
            "balances": [
                {
                    // always a positive decimal number.
                    // for overdraft/negative balances check the credit_debit_indicator.
                    "balance_amount": "123.34",

                    "balance_currency": "RON",

                    // check the balances docs page for all supported types
                    "balance_type": "Expected",

                    "credit_limit_included": false,

                    // credit   -> positive or zero amount
                    // debit    -> negative amount (overdraft)
                    "credit_debit_indicator": "credit"
                }
            ],
            "account_sub_type": "Account sub-type",
            "account_type": "Personal current account",
            "currency": "RON",
            "name": "",
            "nickname": ""
        },
        "id": "f3dc1a92-...-b715a988553d",
        "servicer_id": "e5c11467-...-52a6492054d8",
        "servicer_name": "XYZ Bank",
        "timestamp": "2021-02-01T13:14:52Z"
    }
]
```

{% endtab %}

{% tab title="400: Bad Request " %}

```javascript
// check the errors docs page for details
{
  "id": "uuid",
  "type": "invalid_request",
  "http": 400,
  "code": "invalid_client_id",
  "message": "error message"
}
```

{% endtab %}
{% endtabs %}
