CorebanqCorebanq Developer Docs
Accountsv2

List accounts (unified fiat and crypto) - V2

Retrieves a unified list of both traditional bank accounts and cryptocurrency accounts with comprehensive search, filtering, sorting, and pagination capabilities. This is the V2 implementation of the unified accounts API - recommended over V3. Supports advanced search operators for precise filtering, field-specific searches, and multiple response formats including stacked grouping. **Access Control:** - **Regular users**: Can only access accounts linked to their customers - **Administrator users**: Can access all accounts across all customers (with PermReadAll permission) - **Metadata**: Each account includes metadata with icon_url for currency representation

GET/v2/accounts

Query Parameters

search?string

General search query for filtering accounts by address, currency code, account identifier, IBAN, or description

search.id?string

Search by account ID (exact match)

search.id.in?string

Search by multiple account IDs (comma-separated UUIDs)

search.customer_id?string

Search by customer ID (exact match)

search.customer_id.in?string

Search by multiple customer IDs (comma-separated UUIDs)

search.currency?string

Search by currency code (exact match, e.g. EUR, USD, BTC)

search.currency.in?string

Search by multiple currency codes (comma-separated)

search.currency_id?string

Search by currency ID (exact match)

search.currency_id.in?string

Search by multiple currency IDs (comma-separated UUIDs)

search.project_id?integer

Search by CRP project ID (exact match, only for crypto accounts)

search.project_id.in?string

Search by multiple project IDs (comma-separated integers, only for crypto accounts)

search.iban?string

Search by IBAN (exact match, only for fiat accounts)

search.iban.like?string

Search by IBAN pattern (partial match, only for fiat accounts)

search.main_wallet_address?string

Search by wallet address (exact match, only for crypto accounts)

search.main_wallet_address.like?string

Search by wallet address pattern (partial match, only for crypto accounts)

search.balance?number

Search by exact balance amount

search.balance.gt?number

Search by balance greater than specified amount

search.balance.gte?number

Search by balance greater than or equal to specified amount

search.balance.lt?number

Search by balance less than specified amount

search.balance.lte?number

Search by balance less than or equal to specified amount

search.is_crypto?boolean

Filter by account type: true for cryptocurrency accounts, false for traditional bank accounts

search.active?boolean

Filter by account status (true for active, false for inactive)

search.can_be_converted_to_fiat?boolean

Filter by accounts that can be converted to fiat currency (only applies to crypto accounts)

search.status?string

Filter by account status

search.created_at.gt?string

Search by accounts created after specified date (ISO 8601 format)

search.created_at.gte?string

Search by accounts created from specified date (ISO 8601 format)

search.created_at.lt?string

Search by accounts created before specified date (ISO 8601 format)

search.created_at.lte?string

Search by accounts created until specified date (ISO 8601 format)

search.modified_at.gt?string

Search by accounts modified after specified date (ISO 8601 format)

search.modified_at.gte?string

Search by accounts modified from specified date (ISO 8601 format)

search.modified_at.lt?string

Search by accounts modified before specified date (ISO 8601 format)

search.modified_at.lte?string

Search by accounts modified until specified date (ISO 8601 format)

sort?string

Sort fields with optional - prefix for descending order, comma-separated. Available fields: id, customer_id, currency, balance, is_crypto, active, status, created_at, modified_at

limit?integer

Maximum number of accounts to return. Can be -1 (special case: returns empty data but shows total count) or any positive integer >= 1

offset?integer

Number of accounts to skip for pagination

search.balance_posted?string

Search by posted balance in minor units (e.g., 10000 for 100.00)

search.balance_available?string

Search by available balance in minor units

search.subledger_code?string

Search by subledger code (exact match)

stack?string

Field to stack by with optional format (e.g., created_at[DD-MM-YYYY]). Available fields: currency, is_crypto, status, created_at

distinct?string

Field to get distinct records by (e.g., 'customer_id' to get one account per customer)

Response Body

application/json

curl -X GET "https://example.com/v2/accounts"
{
  "data": [
    {
      "id": "123e4567-e89b-12d3-a456-426614174000",
      "active": true,
      "customer_id": "987fcdeb-51d2-11ec-9d64-0242ac120002",
      "currency": "EUR",
      "currency_id": "550e8400-e29b-11d4-a716-446655440000",
      "balance": 1250.75,
      "subledger": {
        "id": "550e8400-e29b-11d4-a716-446655440000",
        "code": "490-123e4567",
        "balance_posted": 125075,
        "balance_pending": 125075,
        "balance_available": 100000,
        "balance_posted_fmt": "1250.75",
        "balance_available_fmt": "1000.00"
      },
      "is_crypto": false,
      "iban": "DE89370400440532013000",
      "country_code": "DE",
      "country": "Germany",
      "country_id": "276",
      "check_digits": "89",
      "bban": "370400440532013000",
      "bank": "Deutsche Bank",
      "bic": "DEUTDEFF",
      "description": "Main EUR account",
      "metadata": {
        "icon_url": "/icons/eur.svg"
      },
      "status": "active",
      "created_at": "2023-01-15T10:30:00Z",
      "modified_at": "2023-08-28T14:22:00Z"
    },
    {
      "id": "456e7890-e89b-12d3-a456-426614174001",
      "active": true,
      "customer_id": "987fcdeb-51d2-11ec-9d64-0242ac120002",
      "currency": "BTC",
      "currency_id": "550e8400-e29b-11d4-a716-446655440001",
      "balance": 0.054321,
      "is_crypto": true,
      "project_id": 1,
      "crp_account_id": 12345,
      "main_wallet_address": "bc1qxy2kgdygjrsqtzq2n0yrf2493p83kkfjhx0wlh",
      "main_wallet_address_tag": null,
      "can_be_converted_to_fiat": true,
      "last_balance_sync": "2023-08-28T14:20:00Z",
      "description": "Bitcoin wallet",
      "metadata": {
        "icon_url": "/icons/btc.svg",
        "is_crypto": true
      },
      "status": "active",
      "created_at": "2023-02-20T09:15:00Z",
      "modified_at": "2023-08-28T14:20:00Z",
      "networks": [
        {
          "network_id": "c66c3e55-b12e-42a5-8229-d5dfc618a497",
          "network_name": "Bitcoin",
          "network_code": "BTC",
          "asset_id": "6add50d8-a5c9-4c69-8035-06dc0580ca9b",
          "crp_account_id": 135,
          "main_wallet_address": "tb1qecx8j4kh7mfvh28hru0ckea8hzegd0984s0hdh",
          "balance": 0,
          "can_be_converted_to_fiat": true,
          "last_balance_sync": "2023-08-28T14:20:00Z",
          "active": true,
          "created_at": "2023-02-20T09:15:00Z"
        }
      ]
    }
  ],
  "total": 15,
  "total_unfiltered": 20,
  "has_more": true
}
Empty
Empty
Empty
Empty