---
title: "Get metrics for a specific priority"
method: GET
path: "/priorities/{id}/metrics"
tags: ["Analytics"]
---

# Get metrics for a specific priority

`GET /priorities/{id}/metrics`

Retrieves aggregated time-series metrics (visitors, queue size, status) for a specific priority over a given time range.

## Path parameters

- `id` string, uuid, required

## Query parameters

- `from` string, required
- `to` string

## Response `200`

Successful response with analytics data.

- PriorityMetricsResponse
  - `meta` MetricsMeta, required
    - `interval` string, required — The actual time bucket interval used.
    - `from` string, date-time, required — The effective start time of the data.
    - `to` string, date-time, required — The effective end time of the data.
  - `data` MetricsBucket[], required — Ordered list of time buckets.
    - `timestamp` string, date-time, required — The start time of this bucket.
    - `metrics` object, required
      - `visitors` object, required
        - `currentVisitors` integer, required — Number of current visitors on the site during this interval.
        - `waitingVisitors` integer, required — Number of visitors waiting in the priority during this interval.
        - `maxConcurrentVisitors` integer, required — Maximum concurrent visitors allowed (from configuration).
        - `admissionRatePerMinute` integer, required — Admission rate per minute (from configuration).
        - `newVisitorsRatePerMinute` integer, required — Actual rate of new visitors entering the site per minute during this interval.
        - `waitingRatePerMinute` integer, required — Actual rate of visitors entering the waiting queue per minute during this interval.
        - `admittedRatePerMinute` integer, required — Actual rate of visitors admitted from the queue per minute during this interval (distinct from the configured admissionRatePerMinute).
    - `state` object, required
      - `status` 'off' | 'inPreAdmission' | 'inProgress', required — The operational status of the queue at the end of this interval.
      - `mode` 'alwaysOn' | 'scheduled', required — The configuration mode at the end of this interval.

## Other responses

- `401` — Unauthorized - missing or invalid API key.
- `403` — Forbidden. The provided API key is valid, but the user does not have sufficient permissions to perform this operation.
- `404` — Resource not found.
- `422` — Unprocessable entity - invalid or missing from/to parameters.

---

[API](https://skmtc.net/datadome/apis/protection-api.md) · [All operations](https://skmtc.net/datadome/apis/protection-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/datadome/protection-api/revisions/2576052958eb/schema)
