---
title: "Get Gateway Stats"
method: GET
path: "/api/gateway/stats"
tags: ["Gateway"]
---

# Get Gateway Stats

`GET /api/gateway/stats`

Get Context-Gateway install statistics.

**Requires admin authentication**

Returns aggregated stats:
- Total installs (all time)
- Installs by time period (day, week, month)
- Breakdown by OS
- Breakdown by version
- Top 10 countries

## Response `200`

Successful Response

- GatewayInstallStatsResponse
  - `success` boolean
  - `message` string, nullable
  - `period` string, required — Time period (last_hour, last_day, last_week, etc.)
  - `period_start` string, required — Start of period (ISO)
  - `period_end` string, required — End of period (ISO)
  - `total_installs` integer, required — Total number of installs in period
  - `by_version` object — Installs by version
  - `top_countries` object — Top countries

## Other responses

- `401` — Unauthorized - requires API key
- `403` — Forbidden - admin access required
- `500` — Internal Server Error

---

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