---
title: "Get server statistics"
method: GET
path: "/servers/{id}/stats"
tags: ["Server Info"]
---

# Get server statistics

`GET /servers/{id}/stats`

## Request

- Base URL: `https://api.cloudpepper.io`
- URL: `https://api.cloudpepper.io/servers/{id}/stats`
- Auth: HTTP bearer

Retrieves detailed statistics about the server's performance and resource usage. This endpoint provides comprehensive data about system resources including CPU, memory, disk usage, and database connections. The data comes from the server's Prometheus monitoring system and can be used for performance analysis, capacity planning, and troubleshooting.

**Key Information Provided:**
- CPU usage and model information
- Memory usage metrics
- Disk space utilization
- Database connections and performance metrics

**NOTE:** This endpoint requires the server to have the Prometheus capability enabled. If the capability is not enabled, the endpoint will return a 403 error.

## Response `200`

Statistics retrieved successfully

- object
  - `cpu` object: CPU usage information
  - `disk` object: Disk usage information
  - `mem` object: Memory usage information
  - `db_backends` object: Number of active database connections
  - `db_maxconns` object: Maximum allowed database connections

## Other responses

- `404`: Server not found

---

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