X-Metering-Tags header. Pass a tag key — such as team, feature, or tenant_id — and get back a ranked breakdown of spend and request counts per tag value for the chosen period. Use this to run internal chargebacks, understand which product features are driving costs, or monitor per-tenant consumption.
Endpoint
Query Parameters
The tag key to group results by. This must match a key you’ve been setting in the
X-Metering-Tags request header on your proxied calls.Common values: team, feature, tenant_idThe time period to aggregate spend over. Must be one of:
| Value | Description |
|---|---|
week | Last 7 days |
month | Current calendar month (default) |
quarter | Current calendar quarter |
Response Fields
The tag key that was used to group the results. Mirrors the
key query parameter. Example: "team"The aggregation period that was used. Mirrors the
period query parameter. Example: "month"An array of spend groups, one per distinct tag value, sorted by
spend descending.Tag-based analytics require you to set tags on your proxy requests using the
X-Metering-Tags header. Requests made without tags will not appear in any by-tag breakdown.