> ## Documentation Index
> Fetch the complete documentation index at: https://docs.squasher.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Infrastructure API

> Check the health of your Squasher Collectors and list the hosts that send standard OpenTelemetry host metrics.

The infrastructure API reads what your collectors and hosts report. Use it to see if every Squasher
Collector still sends data, and which hosts send CPU, memory, and filesystem metrics. To install a
collector, see [Host and Docker metrics](https://docs.squasher.ai/integrations/infrastructure-monitoring.md).

## Operations

| Operation | Method and path | Purpose |
| - | - | - |
| `infrastructure.collectors.overview` | `GET /v1/projects/{project_id}/infrastructure/overview` | Count active, degraded, and offline collectors. |
| `infrastructure.collectors.list` | `GET /v1/projects/{project_id}/infrastructure/collectors` | List the collectors and their pipeline counters. |
| `infrastructure.hosts.list` | `GET /v1/projects/{project_id}/infrastructure/hosts` | List the hosts that send host metrics. |

The key needs read access to the project.

## Collector status

Squasher finds a collector from its OpenTelemetry self-metrics of the last 24 hours. Its `status`
is one of:

| Status | Meaning |
| - | - |
| `active` | The collector sent data in the last 5 minutes, and nothing failed. |
| `degraded` | In the last 15 minutes, the collector failed to export or refused points. |
| `offline` | The collector sent no data in the last 5 minutes. |

`throttled` is `true` when ingest answered `429` (the project rate limit) to the collector in the
last 15 minutes. See [Ingest rate limit](https://docs.squasher.ai/integrations/infrastructure-monitoring.md#ingest-rate-limit).

## Collector overview

```text theme={null}
GET https://api.squasher.ai/v1/projects/{project_id}/infrastructure/overview
```

```json theme={null}
{
  "active": 3,
  "degraded": 1,
  "offline": 0,
  "throttled": 0,
  "total": 4,
  "lookback_hours": 24,
  "generated_at": "2026-11-25T12:00:00.000Z"
}
```

## List collectors

```text theme={null}
GET https://api.squasher.ai/v1/projects/{project_id}/infrastructure/collectors?limit=50
```

`limit` is from 1 to 100, and the default is 50. The response has `collectors`, the same
`overview`, and `truncated` (`true` when there are more collectors than `limit`). Degraded
collectors come first, then offline ones.

Each collector has `collector_id`, `status`, `throttled`, `last_seen`, `version`, `host_name`,
`host_id`, `environment`, `monitored_service`, `target`, `config_digest`, and
`config_schema_version`. `pipeline` holds the point counters of the receiver (accepted and
refused) and of the exporter (sent, failed, dropped, and throttled). `resource_usage` holds
`cpu_seconds_total`, `memory_rss_bytes`, and `uptime_seconds`. A counter is `null` when the
collector version does not report it.

## List hosts

```text theme={null}
GET https://api.squasher.ai/v1/projects/{project_id}/infrastructure/hosts?from=2026-11-25T11:00:00Z&to=2026-11-25T12:00:00Z
```

| Parameter | Meaning |
| - | - |
| `from` | Start of the window (ISO 8601). Default: one hour before `to`. |
| `to` | End of the window (ISO 8601). Default: now. The window is at most 24 hours. |
| `limit` | From 1 to 100. Default: 50. |

A host is found from the standard OpenTelemetry `system.*` metrics, grouped by `host.name`. They
can come from the Squasher Collector or from the OpenTelemetry Collector `hostmetrics` receiver
(`collector` is `squasher_collector` or `opentelemetry_collector`). A host is `offline` when it
sent no point in the last 5 minutes of the window, else `active`.

Each host has `name` (`host.name`, else `host.id`, else `service.name`), `status`, `last_seen`,
`os_type`, `host_arch`, `environment`, `service_name`, `service_names`, and `metrics` (the newest
point of each host metric). `cpu_utilization`, `memory_utilization`, and
`filesystem_utilization` (the fullest filesystem) are fractions from 0 to 1 over the last 5
minutes of the window, or `null` when the host does not send that metric. The response also has
`from`, `to`, `total`, `truncated`, and `generated_at`.

## CLI and MCP

Use `squasher infra collectors overview`, `squasher infra collectors list`, and
`squasher infra hosts list`. In MCP Code Mode, call `search("infrastructure")`.

Related: [Metrics API](https://docs.squasher.ai/api-reference/metrics.md), [Host and Docker metrics](https://docs.squasher.ai/integrations/infrastructure-monitoring.md).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.