Skip to main content
GET
Get all monthly usage for an account.

Authorizations

x-api-key
string
header
required

LedgerUp API Key.

Path Parameters

account_id
string
required

LedgerUp account identifier.

Pattern: ^account_[0-9a-f]{32}$
Example:

"account_0194f4e3a2b77c6aa91c4f6b4db2a980"

Query Parameters

aggregation
enum<string>
default:sum

Aggregation applied to corrected usage events. latest returns the quantity from the event with the latest occurred_at; ties use accepted_at then event ID. count returns the number of events.

Available options:
sum,
min,
max,
avg,
latest,
count
Example:

"sum"

currency
string

Aggregate only events for this currency. Normalized to lowercase.

Pattern: ^[A-Za-z]{3}$
Example:

"usd"

Response

Account usage grouped by UTC calendar month and metric.

aggregation
enum<string>
default:sum
required

Aggregation applied to corrected usage events. latest returns the quantity from the event with the latest occurred_at; ties use accepted_at then event ID. count returns the number of events.

Available options:
sum,
min,
max,
avg,
latest,
count
Example:

"sum"

data
object[]
required