---
title: "Daily quantiles over a window for a metric in a scope"
method: POST
path: "/v1/analytics.getTrend"
tags: ["analytics"]
---

# Daily quantiles over a window for a metric in a scope

`POST /v1/analytics.getTrend`

## Request body

- AnalyticsGetTrendRequestBody
  - `$schema` string, uri — A URL to the JSON Schema for this object.
  - `domain` string, required — Analytics domain ID.
  - `metric` string, required — Metric ID within the domain.
  - `scope` string, required — Scope ID within the domain.
  - `scope_value` string — Country name/code or region name. Required for non-global scopes.
  - `window` '7d' | '30d' | '90d', required — Lookback window.

## Response `200`

OK

- AnalyticsTrend
  - `$schema` string, uri — A URL to the JSON Schema for this object.
  - `points` AnalyticsTrendPoint[], nullable, required
    - `count` integer, required
    - `date` string, required
    - `p50` number, double, required
    - `p90` number, double, required
    - `p99` number, double, required

## Other responses

- `400` — Bad Request
- `422` — Unprocessable Entity
- `500` — Internal Server Error

---

[API](https://skmtc.net/steamsets/apis/steamsets-api.md) · [All operations](https://skmtc.net/steamsets/apis/steamsets-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/steamsets/steamsets-api/versions/593d89718daa/schema)
