Consumption

Base URL: $CONSUMER_API

List immutable consumption for an explicitly linked account

Logs

GET /consumption

Pages the computed consumption records of one account linked to the caller, such as usage per billing cycle. account_id is required (400 without it) and the caller needs read access to that account, otherwise 403. Pagination uses limit and after.

Parameters

tenant_idstring · query · required

Tenant (utility workspace) that owns the account; when omitted it is worked out from the caller's account memberships.

account_idstring · query · required

Required identifier of the linked account whose consumption is listed.

limitinteger · query · optional

Maximum resources to return (default 20, maximum 100).

afterstring · query · optional

Opaque cursor returned by the previous page.

meter_idstring · query · optional

Returns only consumption measured by this meter of the account.

cycle_idstring · query · optional

Returns only consumption for this billing cycle.

Returns

200 Account consumption after membership authorization

curl -X GET "$CONSUMER_API/consumption" \
  -H "Authorization: Bearer sk_test_..."
Response 200

Account consumption after membership authorization