v1

latestOpenAPI 3.1.0AGPL-3.0-only2026-07-1773264353.7 KB
Usage

Get subscription usage

Retrieve aggregated usage data for a subscription's usage-based components. If start_date/end_date are omitted, defaults to the current billing period.

get/api/v1/usage/subscription/{subscription_id}

Path parameters

subscription_idstring MeteroidId required
Example:sub_7n42DGM5Tflk9n8mt7Fhc7

Subscription ID

Query parameters

start_datestring date
end_datestring date
metric_idstring MeteroidId
Example:bm_7n42DGM5Tflk9n8mt7Fhc7

Response

Subscription usage data

period_endstring date required
period_startstring date required

Example response

{
  "usage": [
    {
      "metric_id": "bm_7n42DGM5Tflk9n8mt7Fhc7"
    }
  ]
}