latestOpenAPI 3.0.3raw.githubusercontent.com2026-08-013764062.2 MB

b2c3116e633e

Metrics

Query impact metrics time series data

Enterprise feature

Queries an impact metric source for time series data based on the provided metric name, time range, and aggregation mode.

get/api/admin/impact-metrics

Query parameters

metricNamestring required
Example:http_requests_total

The Prometheus metric name to query.

range'hour' | 'day' | 'week' | 'month' | 'threeMonths' | 'sixMonths' required
Example:day

The time range for the query.

aggregationMode'rps' | 'count' | 'avg' | 'sum' | 'p50' | 'p95' | 'p99' required
Example:rps

The aggregation mode for the query.

labelsstring
Example:{"endpoint":["/api/admin"]}

A JSON-encoded object mapping label names to arrays of label values to filter by.

mode'display' | 'edit'
Example:display

Query mode. edit (default) also returns the available labels for the metric (used by filter UIs). display skips label discovery and returns time-series data only (cheaper; use for dashboard rendering).

source'internal' | 'external' required
Example:external

Whether the metric comes from the internal Unleash impact metrics or an external source.

Response

impactMetricsDataSchema

startstring required

The start of the queried time range as a Unix epoch timestamp in seconds.

endstring required

The end of the queried time range as a Unix epoch timestamp in seconds.

stepstring required

The step interval between data points.

labelsobject required

Available label values for the queried metric, keyed by label name.

Example response

{
  "start": "1712745600",
  "end": "1712832000",
  "step": "15m"
}