Accounts

Retrieve balances for multiple accounts and all active usage sources.

Returns active grant totals, corrected usage totals, and balances for every active metric and granted currency across up to 100 accounts. The PostgreSQL and ClickHouse aggregates run in parallel.

get/v2/accounts/balances

Query parameters

account_idsstring required

Comma-separated LedgerUp account identifiers. Between 1 and 100 unique ids.

Response

Balances for the requested accounts and all active metrics and granted currencies.

Example response

{
  "data": [
    {
      "account_id": "account_0194f4e3a2b77c6aa91c4f6b4db2a980",
      "metric_id": "metric_0194f4e3a2b77c6aa91c4f6b4db2a980",
      "currency": "usd",
      "grant_total": "1000",
      "usage_total": "275.5",
      "balance": "724.5"
    }
  ]
}

Changes

No recorded changes to this endpoint across all 1 revision of this API.