Sandbox volumes (
prime sandbox volumes) are separate from Hosted Training volumes, which back Model Factory training runs.How a volume works
- A sandbox that attaches a volume gets a private copy of it, taken from the volume’s latest checkpoint when the sandbox is created. Its writes are invisible to every other sandbox, and a running sandbox never picks up later publishes.
- Volumes attach read-write (the default) or read-only (
:ro). A read-only attachment cannot write or publish. - Publishing turns one sandbox’s private writes into a new volume checkpoint. Only sandboxes created after the publish completes see the new data. A volume that was never published is empty.
- Volumes use checkpoints under the hood: each publish saves the volume’s contents as a checkpoint.
- Published data survives sandbox termination; unpublished writes do not. Publish before deleting a sandbox whose writes you want to keep.
- A volume is a separate disk: it doesn’t count against the sandbox’s
disk_size_gb, and a sandbox checkpoint captures the root filesystem only, never a mounted volume. A volume’s capacity is 100 GiB by default, set at creation, and can grow up to 10 TiB — see Size and growth.
Quickstart
--volume NAME:/mount/path[:ro] up to 8 times per sandbox. :ro mounts the volume read-only; writable mounts have no suffix.
Import a local directory
--from with --size-gb to size the new volume in the same step.
--from needs rsync on your machine. The CLI copies the directory through a short-lived helper sandbox and publishes it as the volume’s first checkpoint; the helper is deleted once the publish is confirmed durable. If the volume already exists, the directory is copied into its current published contents.
Size and growth
A volume’s capacity is the maximum it can hold, set at creation in whole GiB: 100 (the default) up to 10240 (10 TiB).volumes list and volumes get show it as Capacity; the SDK exposes it as Volume.size_gb.
- Growth is one-way: a size at or below the volume’s current size returns 409. Volumes cannot shrink.
- A grow applies to sandboxes created after it; running sandboxes keep their current size. The filesystem is grown when a sandbox attaches the volume read-write, and publishing from that sandbox records the larger size. Until then, a read-only attachment shows the last published size.
- Large grows add a few seconds to sandbox startup. Pick the size you need at creation.
- Capacity is a ceiling, not a quota: billing stays based on stored data, as documented at the bottom of this page.
Publish rules
publishwaits until the new checkpoint isDURABLEby default. With--no-wait(CLI) orwait=False(SDK) it returns immediately — pollprime sandbox checkpoint get <checkpoint-id>orclient.get_checkpoint(...)untilDURABLE. A publish that times out can still finish.- If a sandbox tries to publish after the volume’s checkpoint has advanced past the one it attached, publishing fails with 409. A sandbox can still publish again on top of its own earlier publishes. To recover, re-attach in a fresh sandbox, or publish with
--forceto make this sandbox’s entire copy the volume’s new checkpoint.--forcereplaces the published contents; it does not merge files. - Read-only attachments cannot publish.
- If a publish fails, the volume keeps its previous checkpoint, and the sandbox keeps its private writes.
Manage volumes
listpaginates with--page/--num(max 100 per page);--jsonprints raw fields.deletefails with 409 while any active sandbox has the volume attached, and removes the volume and all of its published data. Deleting a team volume requires a team admin.
Scopes and permissions
- Volumes are personal by default. Pass
--team-id(CLI) orteam_id(SDK) to work in a team; without it, the CLI uses the team from your config, if any. - Team members can create, attach, and publish team volumes; only team admins can delete them.
- API tokens need the
sandbox:readscope to list or get volumes andsandbox:writeto create, delete, or publish.
Names and mount paths
- Volume names: 1–40 characters, lowercase letters, digits, and hyphens; must start and end with a letter or digit; unique within their scope.
- Mount paths: absolute, not
/, unique per sandbox, and not nested inside each other.
Common errors
Published volume data is billed as checkpoint storage.