---
title: "Supported coding agents: Claude Code, Codex, Cursor, more"
description: "Which coding agents have adapters, how each is captured, and how subagents are linked to their parent session."
canonical: https://coding.sh/docs/agents
human_url: https://coding.sh/docs/agents
markdown_url: https://coding.sh/docs/agents.md
agents_url: https://coding.sh/agents.md
llms_url: https://coding.sh/llms.txt
updated: 2026-11-11
---

# Coding agents

Which coding agents have adapters, how each is captured, and how subagents are linked to their parent session.

What coding.sh captures from each agent, and how. Each agent has an adapter that installs capture, maps the agent's events into the [trace format](https://coding.sh/docs/trace-format), imports past sessions and drives the agent headless for eval runs, in an isolated config so your own setup is never touched. Agents without hooks are recorded by wrapping the command: `coding.sh run -- <cmd>`.

## Matrix

| Agent | Status | Live capture | Backfill | Headless runs |
| --- | --- | --- | --- | --- |
| Claude Code `claude-code` | Verified on real sessions | settings.json hooks | projects/<slug>/<session>.jsonl transcripts | `claude -p --output-format stream-json` |
| Codex CLI `codex` | Verified on real sessions | hooks.json hooks (you approve them with /hooks) | sessions/**/rollout-*.jsonl | `codex exec --json` |
| OpenCode `opencode` | Verified on a real install | plugin (2.x and 1.x) | opencode.db (1.x and 2.x), JSON storage (older 1.x) | `opencode run --format json` |
| Cursor CLI `cursor` | Not run live | hooks.json, partial in -p mode | agent-transcripts/*.jsonl (undocumented format) | `agent -p --output-format stream-json` |
| T3 Code `t3code` | Verified on a real install | its Codex and Claude Code hooks, tagged as T3 | ~/.t3/userdata/statev2.sqlite (and v1 state.sqlite) | `none (desktop app; it runs codex app-server or the Claude Agent SDK)` |
| Antigravity CLI (formerly Gemini CLI) `antigravity` | Verified on real sessions | hooks.json | brain/<id>/…/transcript.jsonl | `agy -p --output-format stream-json` |
| Gemini CLI, older installs `gemini-cli` | Not run live | settings.json hooks | tmp/<slug>/chats/*.jsonl | `gemini -p -o stream-json` |
| GitHub Copilot CLI `copilot-cli` | Verified on a real install | hooks/coding-sh.json | session-state/<id>/events.jsonl | `copilot -p --output-format=json` |
| Amp `amp` | Not run live | plugin | None | `amp -x --stream-json` |
| Pi `pi` | Verified on a real install | extension | sessions/--<cwd>--/*.jsonl | `pi -p --mode json` |
| Factory Droid `droid` | Verified on a real install | hooks.json | sessions/-<cwd>/*.jsonl | `droid exec -o json` |
| Goose `goose` | Verified on a real install | plugin hooks.json | sessions.db | `goose run --output-format stream-json` |
| Aider `aider` | Verified on a real install | coding.sh run -- aider … (each reply's tokens and cost from Aider's analytics log) | None | `aider --message … --yes-always --no-stream` |
| Any other command `wrapper` | Tested | coding.sh run -- <cmd> | None | `the command itself` |

| Status | Means |
| --- | --- |
| Verified on real sessions | Checked against real sessions of the agent. |
| Verified on a real install | The current release ran a session against a local stub model; its hooks fired, the session was checked, and the payloads are CI fixtures. |
| Not run live | CI checks it against the agent's documented and recorded formats. Nobody has run it on a live install yet. |

If you use an agent that is not run live yet, an [agent support report](https://github.com/jackulau/coding.sh/issues/new?template=agent-support.yml) saying whether it worked moves it to verified.

## Subagents

A subagent appears as `subagent.start` and `subagent.end` events in the parent session, paired by `subagentId`. When the agent keeps a separate transcript or session for the subagent, that becomes a child session whose `parent` points back. `coding.sh sessions --subagents` lists child sessions.

| Agent | How subagents are captured |
| --- | --- |
| Claude Code | SubagentStart/Stop hooks; subagents/agent-*.jsonl transcripts |
| Codex CLI | SubagentStart/Stop hooks; subagent threads in rollouts |
| OpenCode | Child sessions, linked to the parent session |
| Cursor CLI | subagentStop only (subagentStart is a permission gate, not registered) |
| T3 Code | Subagent threads become child sessions |
| Antigravity CLI (formerly Gemini CLI) | invoke_subagent tool call spans the subagent; its internals are not exposed |
| Gemini CLI, older installs | Child chat files become child sessions |
| GitHub Copilot CLI | subagentStart/Stop hooks; events inside carry the subagent id |
| Amp | Task, oracle, librarian, finder tool calls span the subagent |
| Pi | None (Pi has no subagents) |
| Factory Droid | Task tool call is the start, SubagentStop the end |
| Goose | sub_agent sessions become child sessions |
| Aider | None |

## The hook command

Every adapter installs the same command:

shell

```
/bin/sh "/Users/you/.coding.sh/bin/hook.sh" <agent-id> <EventName>   # absolute, quoted path
node "C:/Users/you/.coding.sh/bin/hook.mjs" <agent-id> <EventName>      # on Windows
```

- It exits 0 every time and prints nothing, unless an agent's protocol requires a reply (Cursor's `beforeSubmitPrompt` gets `{"continue":true}`).
- It never answers a permission question. Where an agent treats a hook's silence or exit code as a decision (Cursor's permission events, Copilot's `preToolUse`, Antigravity's `PreToolUse`, Amp's `tool.call`), that event is not registered at all.
- Entries are marked (`"_codingsh": true` where the format allows) so `uninstall` removes only ours. Where a format has no room for a marker, ownership is recorded in `~/.coding.sh/installs.json`.
- The original file is backed up to `~/.coding.sh/backups` before every edit.

## Agent notes

- Codex runs new hooks only after you trust them with `/hooks`. coding.sh never writes trust hashes; eval runs pass `--dangerously-bypass-hook-trust` inside an isolated `CODEX_HOME`.
- Cursor also runs Claude Code hooks from `.claude/settings.json`. Those payloads are dropped by the Claude Code adapter, so each Cursor event is captured once.
- Amp keeps threads server-side, so there is no local backfill.
- Kiro CLI has no adapter yet. Wrap it: `coding.sh run -- kiro-cli chat --v3 --no-interactive --trust-all-tools "…"`. That records start, end, exit code, duration and file changes, but not prompts, tool calls or tokens.
- Kiro's OpenTelemetry export is a daily push of account totals, not per-session spans, so the local OTLP receiver can't use it. The Kiro IDE is not captured.
- Antigravity CLI (`agy`) replaced Gemini CLI. Record it with the `antigravity` adapter; `gemini-cli` still reads sessions from older installs.

## Model API proxy

Hooks and transcripts record what an agent did. To also record what it sent the model (the full system prompt, tool definitions and messages of every call), route it through the local proxy:

shell

```
coding.sh init --proxy              # Claude Code and Codex
eval "$(coding.sh proxy env)"        # any other client
```

`init --proxy` points Claude Code and Codex at `coding.sh proxy` on `127.0.0.1:4320` and starts it. Each call lands in the session the hooks capture. An agent that already calls a gateway keeps calling it, through the proxy. See [Capture with the proxy](https://coding.sh/docs/how-to/capture-with-proxy).

## Other agents

Cline CLI, Kiro CLI, Qwen Code, Crush have no adapter yet. Record them with `coding.sh run -- <cmd>`, which keeps the start, end, exit code, duration and file changes.

To set coding.sh up for a user, follow the agent workflow at [/agents.md](https://coding.sh/agents.md).
