Documentation
Using agent-bridge from other agent CLIs
The CLI is plain bash and PowerShell, and the skill is an Agent Skills folder, so any agent that can run a shell command can use agent-bridge. Claude Code gets everything from the plugin. For Codex, Gemini (Antigravity, Gemini CLI) and Grok Build, run on each machine, for each CLI you use there:
agent-bridge integrate codex # also: antigravity, gemini (Gemini CLI), grok
agent-bridge integrate codex --dry-run # what it would do
agent-bridge integrate --status # what's set up, for every CLI
agent-bridge integrate codex --uninstall
It does four things, each idempotent:
agent-bridgeon PATH, through install-cli, so it keeps working across plugin updates.The skill, linked into the CLI's skills folder (through the same link, so it follows updates; copied on Windows, where you run
integrateagain after an update):CLI Skills folder Codex ~/.agents/skillsAntigravity ~/.gemini/config/skillsGemini CLI ~/.gemini/skillsGrok Build ~/.grok/skillsThe slash commands, each as a skill that runs only when asked for by name (
agent-bridge-offload,agent-bridge-handoff, ...); for Gemini CLI, TOML commands/agent-bridge:<name>instead.The activity hooks, where the CLI's hook format is known, so the monitor shows that CLI's sessions next to Claude Code's:
CLI Hooks Then Codex ~/.codex/hooks.json: each tool call, each prompt, the end of a turn (idle), a request for your approval (waiting), the session's start and endtrust them in Codex's /hooks; runintegrate codexagain after an update of agent-bridge that adds hooksGemini CLI ~/.gemini/settings.jsonGrok Build ~/.grok/hooks/agent-bridge.jsontrust them with /hooks-trustAntigravity none yet (its hook format isn't settled) what it does on peers still shows
JSON files are merged, with a backup of each the first time
(<file>.agent-bridge.bak), and never replaced when
they don't parse. --uninstall removes only what
integrate made.
Notes per CLI
- Codex's default sandbox has no network, so
sshcan't run inside it: let agent-bridge run outside the sandbox when Codex asks, or allow network access in its config. That's the owner's choice. - Grok Build also reads Claude Code plugins and marketplaces as they are.
New mail reaches them too. These CLIs have no
monitor or channel, so the hooks also add a pull before each prompt
(hook pull: Codex's and Grok's
UserPromptSubmit, Gemini CLI's BeforeAgent).
When a message, or a project log entry, came since that session was last
told, the agent gets the same line Claude Code gets at a session's start
(how many wait, how many are urgent or for this session) as the hook's
additionalContext; otherwise nothing. Run
integrate <cli> again after updating agent-bridge to
add it.
Messages and tasks work the same between any two agents: a task created by Claude Code on the laptop can be taken by Codex on the build machine.