sandbox_exec_background
Execute shell commands and start long-running processes like dev servers or file watchers in an E2B sandbox environment. The command runs immediately in the background without waiting for it to complete, enabling non-blocking operations in isolated cloud sandboxes.
Instructions
Start a background process in a sandbox (e.g., dev server, file watcher). Returns immediately without waiting for completion.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| sandboxId | Yes | The sandbox ID to run the command in. | |
| command | Yes | The shell command to run in the background. | |
| cwd | No | Working directory. Defaults to /home/user. | |
| envs | No | Environment variables for this command. |