Use Codex with Gaitro
Connect OpenAI's Codex to Gaitro with one command. It gets typed tools through the gaitro MCP server, reads GAITRO.md through AGENTS.md, and works in drafts you ship.
Codex runs on your machine, on your own OpenAI account. Gaitro doesn't run it or pay for it. It gives Codex a place to work: drafts, code reserved as it's edited, checks, and a person who decides what ships.
1. Install the CLI and log in
# puts `gaitro` on your PATHnpm i -g --allow-remote=root https://app.gaitro.com/cli.tgz# approve in your browser; --device on a servergaitro loginThe login is named after the machine and can be revoked under the company's Settings › Agents. Get started shows how to check the download first.
2. Add the MCP server
codex mcp add gaitro -- gaitro mcpThat writes the server into Codex's ~/.codex/config.toml. You can also add it there by hand:
[mcp_servers.gaitro]command = "gaitro"args = ["mcp"]One connection covers every project in the company you logged in to. Codex then has tools such as gaitro_open_project, gaitro_intent, gaitro_sync and gaitro_ship; the MCP reference lists them all.
Without the MCP server, Codex can still run the gaitro CLI in its shell. Every command takes --json.
3. Point AGENTS.md at the instructions
Every Gaitro project has a GAITRO.md that tells agents how to work there. Codex reads AGENTS.md. If the project already had an AGENTS.md when it came to Gaitro, Gaitro added a line to it pointing at GAITRO.md. If it has none, add one with this line:
This repo uses Gaitro. Read and follow GAITRO.md before making any change.4. Ask for something
Ask Codex to open a project and make a change, in plain words. It opens a draft with gaitro_intent (or gaitro start), edits, and saves checkpoints. What it edits is reserved for its draft as it saves. When you're happy with what changed, tell it to ship, or press Ship it on the draft.
Good to know
- Codex can run shell commands in a sandbox without network access. If
gaitrocommands it runs there can't reach Gaitro, use the MCP tools, or allow network access in Codex's sandbox settings. - Run several Codex sessions at once with a working copy each:
gaitro clone <company>/<project> <folder>. If two edit the same function, the second's draft waits its turn. - Gaitro records which agent saved each checkpoint. It recognizes Codex from its environment; set
GAITRO_AGENTto name it yourself. - Claude Code and Cursor connect the same way: Claude Code, Cursor.
Try it on your own project
Gaitro is free for one person with 3 private projects. Your agent runs on your own account, and Gaitro adds no markup.
This page as markdown, for your agent: /integrations/codex.md.