---
title: "Queue the subscription_state snapshot for this environment."
method: POST
path: "/api/v1/admin/metrics/subscription-state/run"
tags: ["Metrics Admin"]
---

# Queue the subscription_state snapshot for this environment.

`POST /api/v1/admin/metrics/subscription-state/run`

## Request

- Base URL: `https://api.avatarfactory.io` (the document declares no server; this is the origin it was published from)
- URL: `https://api.avatarfactory.io/api/v1/admin/metrics/subscription-state/run`
- Auth: one of:
  - API key in cookie `session`
  - HTTP bearer

## Request body

- SubscriptionStateRunRequest: Body of `POST /api/v1/admin/metrics/subscription-state/run`; empty means yesterday (UTC).
  - `as_of_date` string, date, nullable

## Response `202`

Accepted

- SubscriptionStateRunResponse
  - `as_of_date` string, date, required
  - `env` string, required
  - `queued` boolean, required

## Other responses

- `400`: Bad Request
- `401`: Unauthorized
- `403`: Forbidden
- `422`: Unprocessable Entity

---

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