Open source · built for coding agents

Give your agent a
disposable Linux sandbox

Install dependencies, run commands, read and write files and execute code in isolation, never on your own machine. One CLI, SDKs and MCP; Alibaba Cloud Express by default, or your own backend.

Apache-2.0Node.js 20+Python 3.10+Docs in English and Chinese
~/project — abx
# install and configure
npm install -g @agent-sandbox/cli
export ABX_SANDBOX_API_KEY="<YOUR_API_KEY>"
# create, run, destroy
abx create --template base
abx exec <sandbox-id> -- python3 -c "print(2 ** 10)"
1024
abx kill <sandbox-id> --yes
Call it from the tools you already useCursorClaude CodeQoderQwen CodeCodexVS CodeThrough MCP or an Agent Skill
Capabilities

Everything a sandbox should do

The 18 capabilities map to calls that really exist in the SDK. A provider that does not declare one fails clearly before any request is sent, never silently.

Lifecycle

Create, connect, list and kill. Change the lifetime, pause and resume.

createpausetimeout

Run commands

Synchronous or streamed output, background processes, signals and process lists, an interactive terminal.

execstreampty

Files

Read, write, directories and rename. Watch a directory. Upload and download URLs.

readwritewatch

Code interpreter

Run Python and more inside the sandbox and get structured results back.

run_code

Ports and network

A URL for every service in the sandbox. Optional custom domains, storage mounts and VPC.

portsvpcstorage

Templates

Describe the environment with template.yaml and a Dockerfile. Build, publish and install are one command each.

templatebuild

Named commands

Register a function with @command in the template and call sandbox.run("name") as if it were local.

sessionsandbox.run

See all providers and the comparison →

How it works

A template says what is inside; a provider decides where it runs

Callers see one interface. Change the backend without touching your code; change the template without touching the backend.

Callers
Coding agentsThrough MCP or an Agent Skill
abx CLICreate, exec, transfer, deploy
Python / Node.js SDKSandbox.create(...)
Providers
alicloud-expressThe only built-in, used by default
opensandbox · e2b · cubesandbox · alicloud-containerInstalled from the Registry, sha256 checked
Sandbox
Linux containerAn image built from a template
agent-sandbox-serverThe HTTP service in the image that handles commands and files

Only alicloud-express ships with the CLI and the SDK. Every other provider is opt-in: download it from the Registry. Install copies files and never runs plugin code.

Three ways in

Start from a terminal, code or an agent

  1. Install and configure

    The CLI is an npm package. Put the API key in the environment, or store it with abx config set.

  2. Create, run, destroy

    base is the default template on Express. Destroy when done so it stops using quota.

  3. Switch backend

    Install a provider, then pass provider when you create.

Full getting-started guide →

shell
npm install -g @agent-sandbox/cli
export ABX_SANDBOX_API_KEY="<YOUR_API_KEY>"

abx create --template base
abx exec <sandbox-id> -- echo hello
abx kill <sandbox-id> --yes
Templates

Environments that just run

Browser automation, coding-agent runtimes, Node services. One abx template install builds and registers it.

python-helloA minimal Python hello world template for testingbrowser-automationBrowser automation sandbox with Playwright + Chromium for web scraping and UI testingclaude-codeClaude Code Agent runtime — Anthropic Claude-powered AI coding assistantcodex-agent-apiSelf-hosted OpenAI Agents API compatible service powered by Codex CLIqoderPython and Node.js dev sandbox. qoder_run executes a local script; the Qoder CLI is not installed.agents-cliAgents API for Codex and Qwen Code. The image does not preinstall either CLI.qwen-codeQwen Code Agent runtime — Dashscope-powered AI autonomous deployment agentdeepseek-harnessDeepSeek Agent Runtime — DeepSeek model-driven AI coding agenthermes-agentChat completion against an OpenAI-compatible endpoint. This template does not register tools.node-webNode.js web service runtime for Express, Fastify and other frameworksopenclawOpenClaw AI Agent runtime — open-source AI coding agent gatewayampSourcegraph Amp CLI. amp_execute runs amp -x; amp_version and amp_setup_check do not need a key. Package @ampcode/cli@0.0.1792022479-ge66e24.codexOpenAI Codex CLI (@openai/codex@0.162.1). codex exec, JSON events, sandbox bypass, OpenAI-compatible config.toml.opencodeOpenCode coding agent. Headless opencode run and optional opencode serve. Package opencode-ai@1.19.0.droidFactory Droid. Command droid exec. Package @factory/cli@0.241.1.geminiGemini CLI. Command gemini -p. Package @google/gemini-cli@0.64.0.
Principles

Conservative by default, because the code is untrusted

One built-in provider

The CLI and SDK ship only alicloud-express. Any other backend is something you choose to install.

Install only copies files

Provider packages carry a sha256 that is checked before anything lands on disk. Install never runs the plugin.

Keys are not shared

Each provider reads only its own environment variables and never receives the Express key.

Disposable by design

async with destroys the sandbox on exit, leaving no dependencies or processes on your machine.

Open a sandbox now

Two minutes: install the CLI, set a key, run abx create. To bring your own backend, publish a provider to the Registry.