Skip to navigation

List account balances

Lists the organisation’s account balances — the latest reading per account and asset, as the venue last stated it; accountId narrows to one account’s. A DISCOVERED account’s balances are served while it is being classified. Rows are ordered by accountId then assetId; a view other than latest is 400. A member deployed without the surface answers 503 BALANCES_UNAVAILABLE.

Authentication

AuthorizationBearer

Bearer authentication of the form Bearer <token>, where token is your auth token.

Headers

X-Request-IdstringOptional

Your own id for the request: 8 to 128 of [A-Za-z0-9._-]. It becomes the request’s id and is echoed on the response. A value off that grammar is replaced with a fresh id, never refused.

Query parameters

accountIdintegerOptional>=1

Only one account’s balances — the accountId its rows carry and GET /accounts serves. An account outside your organisation, or one this member does not hold, yields an empty collection, like an account with no reading; 0, a negative or a non-integer refuses 400.

limitintegerOptional>=1

Page size, 1-100; larger values are clamped. Without it the whole collection is served as one page.

cursorstringOptional<=2048 characters

nextCursor or prevCursor from a previous page, sent with the same filters. One that does not decode, or that came from another query, is refused 400 INVALID_CURSOR: drop it and fetch the first page.

includeenumOptional

total adds the exact number of rows matching the filters.

Allowed values:

Response

A page of the readings inside the principal’s org, account then asset ascending — all of them unless limit is sent; the position it was read at rides the body and the headers.

globalSequencestringformat: "^[0-9]+$"

The position as a decimal string — the last change this member had applied, orders, balance readings and algo instances included.

itemslist of objects
asOfSeqTsNsstring or nullOptionalformat: "^[0-9]+$"

The sequencer timestamp (epoch-ns) the data is complete through; also sent as X-Immix-As-Of-Seq-Ts. Null when unknown.

nextCursorstring or nullOptional

Pass as cursor for the next page. Null on the last page.

prevCursorstring or nullOptional

Pass as cursor for the previous page. Null on the first page.

totalinteger or nullOptional

Exact count matching the filter. Null unless include=total.

unscaledbooleanOptionalDeprecated

Never present since 0.3.1: a balance states its own scale, so no item is ever served raw. Kept, deprecated, so a client generated from 0.3.0 still compiles.

Errors

400
List Account Balances Request Bad Request Error
401
List Account Balances Request Unauthorized Error
403
List Account Balances Request Forbidden Error
503
List Account Balances Request Service Unavailable Error