config or passing config: { type: "cloud" } selects the existing unrestricted networking default. On update, omitting networking keeps the current policy. Responses always include the effective networking policy.
Networking
unrestricted lets the machine reach any public host. limited allows only allowed_hosts, plus common package registries when allow_package_managers is true, and every MCP server when allow_mcp_servers is true (otherwise only MCP servers whose host is in allowed_hosts). See Create an environment for the full host-matching rules and registry list.
A blocked request fails with 403 inside the machine, and the error names the blocked host. Mounted GitHub repositories clone from github.com, so include github.com under limited networking.
The Linux machine
Each Session gets its own Linux container. It boots on the firstbash call, or during first-turn preparation if the Session mounts a GitHub repository, and sleeps when idle. Across sleeps it preserves /workspace and /mnt/session/outputs. Packages and other files outside those directories are cleared when the machine is replaced.
Preinstalled tools include git, node, npm, python3, pip, ripgrep, jq, curl, unzip, and zstd. Only HTTP and HTTPS leave the container, so clone repositories over https.
Set config.setup.packages.apt, config.setup.packages.npm, or config.setup.packages.pip to install packages whenever a machine starts. Set config.setup.script to run Bash after the package installs. Setup runs after repository mounts are ready, uses the same networking rules as the turn, and has a five-minute limit. With limited networking, enable allow_package_managers or include the package registries you use in allowed_hosts.
Updates
Pass theversion you last read; the update fails with 409 if someone changed the Environment in the meantime. Environments are not pinned to a Session, so running Sessions pick up updated rules on their next turn.