# stats.get

Source: https://docs.lightair.app/developers/remote-api/stats.get

> Gives performance numbers: frame rate, render time, dropped frames by cause, CPU, memory and free disk space.

JSON-RPC 2.0 method of Lightair's Remote API (ws://localhost:4455/rpc). Group: App and state. Script plugins need the `project.read` permission.

Dropped frames are counted by cause:

- `lagged_frames`: the renderer was late.
- `output_skipped_frames`: frames of the primary canvas an encoder was too slow for.
- `output_dropped_network`: frames the connections dropped, summed over every destination.
- `record_dropped_frames` and `record_total_frames`: the recording's own.

`cpu_percent` is worked out between two calls, so the first call answers `null`.

## Parameters

None.

## Result

| Name | Type | Required | Description |
|---|---|---|---|
| `fps` | `number` | no | Frames drawn per second. |
| `frame_time_ms` | `number` | no | Average time to draw a frame. |
| `total_frames` | `number` | no | Frames drawn. |
| `lagged_frames` | `number` | no | Frames the renderer was late for. |
| `lagged_last_second` | `number` | no | Late frames in the last second. |
| `output_skipped_frames` | `number` | no | Frames of the primary canvas an encoder was too slow for. |
| `output_total_frames` | `number` | no | Frames drawn, to compare the skipped ones with. |
| `output_dropped_network` | `number` | no | Frames the connections dropped, over every destination. |
| `record_dropped_frames` | `number` | no | Frames the recording dropped. |
| `record_total_frames` | `number` | no | Frames the recording got. |
| `cpu_percent` | `number | null` | no | Lightair's CPU use since the last call. |
| `cpu_seconds` | `number` | no | Lightair's CPU time so far. |
| `memory_mb` | `number` | no | Memory in use. |
| `disk_free_mb` | `number | null` | no | Free space where recordings are saved. |

## From an AI agent

The MCP server's `get_stats` reaches this method.

## Related

- [state.get](https://docs.lightair.app/developers/remote-api/state.get.md)
- [issues.list](https://docs.lightair.app/developers/remote-api/issues.list.md)
- [output.list](https://docs.lightair.app/developers/remote-api/output.list.md)
