Kagex/Guides
Claude CodeAgent Integrations · 4 min read

Claude Code Local MicroVM Sandboxing with Kagex MCP & SKILL.md

Keep Claude Code fast and autonomous without exposing host API keys or git credentials. Install the sandbox skill once and approve blocked egress domains interactively.

Installer
sandboxctl mcp install claude --project .
Skill written
.claude/skills/sandbox/SKILL.md
Session check
/mcp inside Claude Code
Register Kagex with Claude Code CLI
./_out/bin/sandboxctl mcp install claude --project ~/code/app --secrets ANTHROPIC_API_KEY,GITHUB_TOKEN
# Verify active MCP status inside Claude Code:
/mcp

Key Engineering Points · 11-Tool MCP Server & One-Command IDE Wiring

All 10 key points →
  • 1sandbox-mcp implements JSON-RPC 2.0 over stdio and bridges seamlessly into sandboxd over Unix domain sockets or loopback TCP.
  • 2sandboxctl mcp install antigravity creates .agents/plugins/kagex/ (or ~/.gemini/config/plugins/kagex/ with --global) containing plugin.json, mcp_config.json, rules/AGENTS.md, and skills/sandbox/SKILL.md.
  • 3sandboxctl mcp install cursor configures .cursor/mcp.json (or ~/.cursor/mcp.json) alongside always-applied .cursor/rules/sandbox.mdc.
  • 4sandboxctl mcp install claude writes .claude/skills/sandbox/SKILL.md and registers the MCP server via claude mcp add with --scope project or --scope user.
  • 5sandboxctl mcp install codex backs up ~/.codex/config.toml to config.toml.bak, appends [mcp_servers.sandbox] (30s startup, 900s tool timeout), and updates AGENTS.md.
  • 6Eleven specialized tools cover full dev workflows: sandbox_exec, sandbox_read_file, sandbox_write_file, sandbox_diff, sandbox_apply, sandbox_pull, sandbox_snapshot, sandbox_network, sandbox_port, sandbox_status, and sandbox_destroy.

Automatic CLI Registration & Fallback

sandboxctl mcp install claude writes .claude/skills/sandbox/SKILL.md and registers sandbox-mcp via claude mcp add. Support for --scope project and --scope user (--global) works identically.

Reversible Experiments with Checkpoints

Claude Code can checkpoint before major dependency upgrades using sandbox_snapshot and roll back to a clean memory state in ~0.5 s if tests regress.

Inspect this architecture live in 3D

Step through MCP ingress, Ghost Secrets, CoW blades, and run sandboxctl commands interactively in your browser.

Frequently Asked Questions

Kagex writes the skill file and prints the exact claude mcp add command so you can paste and run it whenever ready.