Capabilities
This page is the reference behind the Sandboxes overview: what people build with sandboxes, what one actually is, and the capabilities every sandbox exposes.
What Sandboxes are for
Agent build loops
Generate code, edit files, install dependencies, run tests, and stream logs back to the agent.
Preview servers
Run a web server in the sandbox and expose only the needed port as an HTTPS preview URL.
Safe execution
Isolate untrusted commands from your backend while keeping filesystem state scoped to the sandbox.
Reproducible state
Snapshot working state, resume later, or fork from a known point for parallel agent work.
What a Sandbox is, concretely
- Isolated compute for code generation, builds, tests, and dev servers.
- Named, versioned CPU, memory, and disk contracts plus per-sandbox timeout and environment parameters.
/workspaceis the editable filesystem root.- Boots from a versioned template, usually
miosa-sandbox. - Persistent by default, so
timeout_secstops compute and preserves state instead of deleting the workspace. - Network-isolated by default.
- Preview URLs open only the specific ports you expose.
- Destroy is permanent and removes the saved state.
Core capabilities
| Capability | What it gives you |
|---|---|
exec.run | Blocking command execution with stdout, stderr, exit code, and duration |
exec.stream | Real-time stdout/stderr events for long builds or installs |
files.write/read/list/stat | Direct filesystem access under /workspace and other allowed paths |
previews.create | Public HTTPS URL for a running process on a specific sandbox port |
snapshot | Durable checkpoint for resume, fork, or rollback |
pause / resume | Stop compute without discarding saved state |