---
title: Let Codex and Claude Code work inside your mind
date: 2026-11-12
summary: One call starts a coding agent in a Linux sandbox with a clone of your mind's config repo, and it can commit changes to your mind.
detail: One call: itx.acp.sandbox.start("codex")
---

With this, your mind can hand a coding job to Codex, Claude Code or opencode, each in a Linux sandbox of its own, and get the result back as a commit.

**Why.** The mind's own agents are good at running scripts against the mind. Coding agents are good at reading and changing a lot of code. We wanted both, under one list.

**How it works.** One call starts a session and answers its path. Then you message it like any other agent:

```js
const path = await itx.acp.sandbox.start("codex"); // or "claude", "opencode"
await itx.agents.get(path).message("Fix the failing test in apps/docs.");
```

The agents speak the Agent Client Protocol (ACP), so one runner drives all three. The sandbox holds a clone of the config repo and two tools: run a script against the mind, and commit to its config repo. A commit names its `parent`, so an agent that is slower than another one is refused and tries again, instead of undoing someone's work.

Our files:

- `acp-sandbox.ts`: the module behind `itx.acp.sandbox`; `start(agent, model?)`.
- `acp-sandbox/runner.ts`: starts a session in a sandbox and delivers each message to it.
- `acp-sandbox/host.ts` (and its bundled `host.generated.ts`): what runs inside the sandbox and talks ACP to the agent.
- `acp-sandbox/worker.ts`: the integration, one entry in the `integrations` list of `worker.ts`.
- `sandbox-tools/`: the clone of the repo and the two mind tools.
- `agent-kinds/acp.ts`: how a session shows up, and chats, in the Agents app.
- `claude-sandbox.ts` and `claude-sandbox/`: the same for Claude Code's own headless mode.

**What it needs.** Sandboxes are Cloudflare Containers in your own account, billed there, and they sleep when idle. Each agent needs its own model account: a ChatGPT plan or an OpenAI API key for Codex (`/secrets/chatgpt` or `/secrets/openai`), a Claude account for Claude Code.

**What surprised us.** The list is the feature. Once every agent is on one page, "what is everyone working on?" is a page you open.
