# Overview

> Nanite gives each of your agents its own Linux machine, driven over a plain HTTP API.

Nanite runs sandboxes: small Linux machines, one per agent, that are ready in under a second and go to sleep when nothing uses them. You create them, run commands in them and move files in and out over HTTP, from any language.

## What a sandbox is

- Debian 13 on arm64, running as root, with curl, git and jq installed.
- 2 vCPU, 2 GiB of memory and a 20 GiB disk.
- A disk that stays. Packages you install and files you write are still there after the sandbox sleeps.
- Outbound internet access, with [secrets](https://nanite.run/docs/environment-and-secrets.md) that the sandbox never sees.

## Base URL

Every endpoint lives under one base URL and takes an API key in the `Authorization` header.

```text
https://api.nanite.run/v1/sandboxes
```

Requests and responses are JSON unless a page says otherwise. Every response carries a `Nanite-Request-Id` header. Include it when you write to support.

## How a sandbox lives

A sandbox is `running` while something uses it. After 30 seconds with no request, no command running, no CPU work and no network use, it stops and becomes `warm`. A warm sandbox may later go `cold`. Any request that needs the machine wakes it again, so you rarely have to think about it. See [Sandboxes](https://nanite.run/docs/sandboxes.md#lifecycle).

You pay for CPU and memory only while a sandbox runs, and for the disk it keeps while it sleeps. See [Billing](https://nanite.run/docs/billing.md).

## The API at a glance

| Endpoint                                                    | What it does                                   |
| ----------------------------------------------------------- | ---------------------------------------------- |
| [`/v1/sandboxes`](https://nanite.run/docs/sandboxes.md)                          | Create, list, get, update and delete sandboxes |
| [`/v1/sandboxes/{name}/exec`](https://nanite.run/docs/exec.md)                   | Run commands, over HTTP or a WebSocket         |
| [`/v1/sandboxes/{name}/fs`](https://nanite.run/docs/filesystem.md)               | Read, write, list and watch files              |
| [`/v1/sandboxes/{name}/checkpoint`](https://nanite.run/docs/checkpoints.md)      | Save the disk and roll back to it              |
| [`/v1/sandboxes/{name}/env`](https://nanite.run/docs/environment-and-secrets.md) | Environment variables and secrets              |
| [`/v1/sandboxes/{name}/proxy`](https://nanite.run/docs/ports-and-proxy.md)       | Reach a port inside the sandbox                |

Start with the [Quickstart](https://nanite.run/docs/quickstart.md).
