# HTTP API reference

The supported compatibility endpoints at api.runtabs.dev.

Canonical: https://docs.runtabs.dev/api-reference/
Reviewed: 2026-11-28

## Base URL and headers

Use `https://api.runtabs.dev` with `X-API-Key: <workspace-key>`. Mutation requests require a stable `Idempotency-Key`; JSON bodies use `Content-Type: application/json`.

## Endpoints

| Method | Route | Contract |
| --- | --- | --- |
| GET | /health | Public gateway liveness; does not check compute readiness. |
| GET | /tabs/v1/capabilities | Workspace-authenticated route support and constraints. |
| GET | /tabs/v1/fleet | Workspace capacity snapshot. |
| GET | /v2/templates | Approved image catalog and reported readiness. |
| GET | /v2/sandboxes | One page of workspace environments. |
| POST | /v2/sandboxes | Compatibility create; returns sandboxID. |
| POST | /tabs/v1/sandboxes/{sandboxID}/sleep | Body: {"keepMemory":true}. |
| POST | /tabs/v1/sandboxes/{sandboxID}/wake | Body: {}. |
| DELETE | /sandboxes/{sandboxID} | Delete with no body. |

## Create body

```json
{
  "templateID": "ubuntu",
  "timeout": 300,
  "autoPause": true,
  "metadata": {
    "name": "my-agent"
  }
}
```

Template availability depends on workspace and host readiness. Unknown fields and unsupported options are rejected. See [quickstart](/quickstart/).

## Pagination

Collection routes accept `limit`, `order` and `nextToken`. Read the opaque `X-Next-Token` response header and pass it unchanged on the next request. Stop when it is absent or empty. Do not parse or invent cursor values. Pages follow host order and are not a global timestamp sort.

## Idempotency

Keep one key for one logical mutation and identical request content across retries. A changed payload with a reused key is a conflict. Persist the key before sending if the application needs crash-safe recovery. An uncertain response must not become a new create with a fresh key.

## Unsupported native routes

Native create `POST /tabs/v1/sandboxes` returns authenticated 501 on this deployment. Compatibility create is a different contract, selected explicitly. No full native OpenAPI compatibility is claimed.
