Give any model a terminal and files
The beta ships on the Responses and Messages APIs, with sandbox time billed at $0.0001 per second.
OpenRouter has added a shell server tool that gives any model on the platform a hosted Linux terminal, alongside a Files API for moving files in and out of it. Commands run inside an isolated container, and the model reads back stdout, stderr and an exit code, so it can catch a failed script and fix it before answering.
- Two tool variants cover both API styles: openrouter:shell works on the Responses API and the Anthropic Messages API, while openrouter:bash is the Anthropic-compatible tool on the Messages API. Setting engine: "openrouter" on either forces the commands to run server-side rather than locally.
- Containers have no outbound network access by default; an allowlist of domains can be set for jobs like package installs. A container sleeps after 5 minutes idle, and reusing one across requests is possible via a session id or an explicit container reference.
- The Files API lets you upload inputs (up to 20 files per container) that appear as writable copies in the container's home directory, and download files a run produced. Container files are kept for 30 days unless promoted into permanent workspace storage.
Sandbox time costs $0.0001 per second, billed as part of the request and covering Files API usage too. Both tools can be combined with other server tools such as web search, letting a model look something up and then write the result to a file inside the sandbox. It's available today in beta on OpenRouter.
