---
title: "Get jail statistics"
method: GET
path: "/jail/{ctid}/stats/{step}"
tags: ["Jail"]
---

# Get jail statistics

`GET /jail/{ctid}/stats/{step}`

Retrieve statistics for a jail by CTID and GFS retention step

## Path parameters

- `ctid` integer, required
- `step` 'minutely' | 'hourly' | 'daily' | 'weekly' | 'monthly' | 'yearly', required

## Response `200`

Success

- GithubComAlchemillahqSylveInternalAPIResponseArrayGithubComAlchemillahqSylveInternalDbModelsJailJailStats
  - `data` GithubComAlchemillahqSylveInternalDbModelsJailJailStats[]
    - `cpuUsage` number
    - `createdAt` string
    - `id` integer
    - `jid` integer
    - `memoryUsage` number
  - `error` string
  - `message` string
  - `status` string

## Other responses

- `400` — Bad Request
- `401` — Unauthorized
- `404` — Jail Not Found
- `500` — Internal Server Error

---

[API](https://skmtc.net/alchemillahq/apis/sylve-api.md) · [All operations](https://skmtc.net/alchemillahq/apis/sylve-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/alchemillahq/sylve-api/revisions/7a7bea85004e/schema)
