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

# Sandboxes

> Manage sandbox instances (running simulators).

Manage sandbox instances that represent running simulators within a playground.

## Actions

| Action          | Description                                       |
| --------------- | ------------------------------------------------- |
| `list`          | List sandboxes, optionally filtered by playground |
| `create`        | Create a new sandbox from a simulator             |
| `get`           | Get a sandbox by ID                               |
| `listEvents`    | List recorded events for a sandbox                |
| `teardown`      | Tear down a sandbox                               |
| `addDataset`    | Load a dataset into a sandbox                     |
| `removeDataset` | Remove a dataset from a sandbox                   |

## Parameters

### `list`

| Parameter      | Type   | Required | Description             |
| -------------- | ------ | -------- | ----------------------- |
| `playgroundId` | string | no       | Filter by playground ID |

### `create`

| Parameter     | Type   | Required | Description                 |
| ------------- | ------ | -------- | --------------------------- |
| `simulatorId` | string | yes      | Simulator ID to instantiate |

### `get`

| Parameter | Type   | Required | Description |
| --------- | ------ | -------- | ----------- |
| `id`      | string | yes      | Sandbox ID  |

### `listEvents`

| Parameter | Type   | Required | Description |
| --------- | ------ | -------- | ----------- |
| `id`      | string | yes      | Sandbox ID  |

### `teardown`

| Parameter | Type   | Required | Description |
| --------- | ------ | -------- | ----------- |
| `id`      | string | yes      | Sandbox ID  |

### `addDataset`

| Parameter   | Type   | Required | Description        |
| ----------- | ------ | -------- | ------------------ |
| `id`        | string | yes      | Sandbox ID         |
| `datasetId` | string | yes      | Dataset ID to load |

### `removeDataset`

| Parameter   | Type   | Required | Description          |
| ----------- | ------ | -------- | -------------------- |
| `id`        | string | yes      | Sandbox ID           |
| `datasetId` | string | yes      | Dataset ID to remove |

## Examples

### List sandboxes for a playground

```json theme={null}
{
  "action": "list",
  "playgroundId": "pg_xyz789"
}
```

### Load a patient dataset into a sandbox

```json theme={null}
{
  "action": "addDataset",
  "id": "sb_abc123",
  "datasetId": "ds_patients456"
}
```

### List events recorded by a sandbox

```json theme={null}
{
  "action": "listEvents",
  "id": "sb_abc123"
}
```
