---
title: "Your metered usage over a rolling window"
method: GET
path: "/v1/usage"
---

# Your metered usage over a rolling window

`GET /v1/usage`

## Request

- Base URL: `https://api.reqbeat.com`
- URL: `https://api.reqbeat.com/v1/usage`
- Auth: one of:
  - API key in header `X-API-Key`
  - HTTP bearer

Metered usage for the caller's customer over a rolling window --
`window` is hours (default 24). Aggregates across every key the
customer holds, not just the one presented on this call.

`keys[]` splits those same totals per key, so a customer holding one
key per environment (or per client) can attribute its spend. It lists
the keys with at least one metered event in the window, ascending by
`key_id`; each of the five totals sums across `keys[]` to the
customer-level number printed beside it.

## Query parameters

- `window` integer: Rolling look-back window in HOURS for the returned usage totals.

## Response `200`

Successful Response

- UsageResponse
  - `calls` integer, required
  - `changes` integer, required
  - `watches` integer, required
  - `forced_fresh` integer, required
  - `by_meter_class` object, required
  - `keys` KeyUsageBreakdown[], required
    - `key_id` integer, required
    - `calls` integer, required
    - `changes` integer, required
    - `watches` integer, required
    - `forced_fresh` integer, required
    - `by_meter_class` object, required

## Other responses

- `401`: No API key was sent.
- `403`: A key was sent, but it is unknown or revoked.
- `422`: Validation Error

---

[API](https://skmtc.dev/reqbeat/apis/reqbeat-api.md) · [All operations](https://skmtc.dev/reqbeat/apis/reqbeat-api/llms.txt) · [OpenAPI document](https://skmtc.dev/reqbeat/apis/reqbeat-api/revisions/4758e5957e8c?raw)
