Setting the file. One moment.
Subchapter 9.1
references/api-quick-ref.mdMarkdown2 KBView on GitHub
@next API documentationUse this reference after the sandbox-next package-line gate. Existing stable apps use sandbox-stable; stable-to-preview migrations use sandbox-migrate-to-next.
Fetch the page for the task before implementing and check signatures against installed types.
@cloudflare/sandbox@next| Task | Documentation |
|---|---|
| Launch commands, collect output, stream logs, wait for readiness, inspect or stop processes | Processes API (opens in a new tab) and Process execution (opens in a new tab) |
| Understand sandbox IDs, container lifetime, sleep, destruction, and durable state | Sandbox lifecycle (opens in a new tab) |
| Configure sleep, keep-alive, and ID normalization | Sandbox options (opens in a new tab); omit removed session and transport fields on @next. |
| Create, connect, write to, resize, or stop interactive terminals | Terminals API (opens in a new tab) and Terminals (opens in a new tab) |
| Attach the interpreter, manage contexts, run code, or consume streamed results | Interpreter (opens in a new tab) and Interpreter API (opens in a new tab) |
| Set sandbox or per-launch environment | Environment variables (opens in a new tab) |
| Keep external API credentials in the Worker | Outbound traffic (opens in a new tab) |
| Handle startup failures, interrupted work, stale handles, or local wait cancellation | Errors and recovery (opens in a new tab) and Errors API (opens in a new tab) |
| Find other preview APIs | Preview API reference (opens in a new tab) |
For files, mounts, backups, ports, and tunnels, follow the shared-surface links in the preview overview (opens in a new tab). Use main-docs signatures only where that overview says they still apply; ignore stable-only session and transport options.