Skip to content
Back to search

cc-plugin-codex

An open-source plugin that runs inside Codex and lets you use Claude Code and Claude models for review, rescue, and tracked background workflows.

Safety scan

A static text scan, not a guarantee. Select the badge to see what was scanned and every finding.

Checked today
Badge for your README
findsafeskills safety rating

Markdown

[![findsafeskills safety rating](/api/listings/sendbird--cc-plugin-codex/badge.svg)](/listings/sendbird--cc-plugin-codex)

HTML

<a href="/listings/sendbird--cc-plugin-codex"><img src="/api/listings/sendbird--cc-plugin-codex/badge.svg" alt="findsafeskills safety rating" /></a>

Install

i

Install instructions from the README

As written by the repo's author. findsafeskills has not verified these steps.

1. Install

Install from the Sendbird marketplace:

codex plugin marketplace add sendbird/codex-marketplace
codex plugin add cc@sendbird

Then install `cc` from the Sendbird marketplace inside Codex, and run `$cc:setup` once.

`cc-plugin-codex` uses Codex native plugin hooks. The active plugin copy lives under Codex's plugin cache, and hook commands resolve through `$PLUGIN_ROOT`; there is no separate local checkout install.

The optional `npx` helper runs the same marketplace/cache install path and enables the required Codex feature gates:

npx cc-plugin-codex install

On Windows, prefer the Sendbird marketplace path or the `npx` helper. The shell-script helper below is POSIX-only. Codex CLI's official guidance still treats Windows support as experimental and recommends a WSL workspace for the best Codex experience. Claude Code supports both native Windows and WSL.

> **Prerequisites:** Node.js 18+, Codex with hook support, and `claude` CLI installed and authenticated. > If you don't have the Claude CLI yet: > ```bash > npm install -g @anthropic-ai/claude-code && claude auth login > ```

2. Verify

Open Codex and run:

$cc:setup

All checks should pass. If any fail, `$cc:setup` tells you what to fix. If setup adds the marketplace-qualified plugin-data root and legacy migration roots to the writable-root list, restart Codex and rerun the same command; a requested review-gate toggle waits for that restart.

3. Try It

$cc:review --background

That launches a Claude Code review from a Codex-managed background flow. You can check on it immediately:

$cc:status
$cc:result

When it finishes, Codex should nudge you toward the right result. If not, `$cc:status` and `$cc:result` are always the fallback.

What was scanned

The files the safety scan read, as written by the repository's author and shown as plain text. Lines with a finding are marked.

README.md · README · 397 lines · 1 finding marked

View this file on GitHub (read at the repository's current version: the scan did not record which commit it read)

  1. <p align="center">
  2. <img src="assets/cc-plugin-codex-logo.svg" height="128" alt="cc-plugin-codex" />
  3. </p>
  4. <h3 align="center">Claude Code Plugin for Codex</h3>
  5. <p align="center">
  6. Run Claude Code reviews, rescue tasks, and tracked background work from inside Codex.
  7. </p>
  8. <p align="center">
  9. <code>cc-plugin-codex</code> runs inside Codex and lets you use Claude Code and Claude models for review, rescue, and tracked background workflows.
  10. </p>
  11. <p align="center">
  12. <a href="#quick-start"><strong>Quick Start</strong></a> ·
  13. <a href="#commands"><strong>Commands</strong></a> ·
  14. <a href="#background-jobs"><strong>Background Jobs</strong></a> ·
  15. <a href="#review-gate"><strong>Review Gate</strong></a> ·
  16. <a href="#how-this-differs-from-upstream"><strong>vs Upstream</strong></a> ·
  17. <a href="https://github.com/sendbird/cc-plugin-codex/issues"><strong>Issues</strong></a>
  18. </p>
  19. ---
  20. ## What Is This?
  21. `cc-plugin-codex` turns Codex into a host for Claude Code work.
  22. **Codex stays in charge of the thread. Claude Code does the review and rescue work.**
  23. You get seven commands (`$cc:review`, `$cc:adversarial-review`, `$cc:rescue`, `$cc:status`, `$cc:result`, `$cc:cancel`, `$cc:setup`) that launch tracked Claude Code work, manage lifecycle and ownership, and surface results back into Codex.
  24. That includes:
  25. - Built-in Codex subagent orchestration for rescue and background review flows
  26. - Session-scoped tracked jobs with status, result, and cancel commands
  27. - Background completion nudges that steer you to the right `$cc:result <job-id>`
  28. - An optional turn-end review gate
  29. - GitHub CI coverage on Windows, macOS, and Linux
  30. It follows the shape of [openai/codex-plugin-cc](https://github.com/openai/codex-plugin-cc) but runs in the opposite direction.
  31. ## Quick Start
  32. ### 1. Install
  33. Install from the Sendbird marketplace:
  34. ```bash
  35. codex plugin marketplace add sendbird/codex-marketplace
  36. codex plugin add cc@sendbird
  37. ```
  38. Then install `cc` from the Sendbird marketplace inside Codex, and run `$cc:setup` once.
  39. `cc-plugin-codex` uses Codex native plugin hooks. The active plugin copy lives under Codex's plugin cache, and hook commands resolve through `$PLUGIN_ROOT`; there is no separate local checkout install.
  40. The optional `npx` helper runs the same marketplace/cache install path and enables the required Codex feature gates:
  41. ```bash
  42. npx cc-plugin-codex install
  43. ```
  44. On Windows, prefer the Sendbird marketplace path or the `npx` helper. The shell-script helper below is POSIX-only.
  45. Codex CLI's official guidance still treats Windows support as experimental and recommends a WSL workspace for the best Codex experience. Claude Code supports both native Windows and WSL.
  46. > **Prerequisites:** Node.js 18+, Codex with hook support, and `claude` CLI installed and authenticated.
  47. > If you don't have the Claude CLI yet:
  48. > ```bash
  49. > npm install -g @anthropic-ai/claude-code && claude auth login
  50. > ```
  51. ### 2. Verify
  52. Open Codex and run:
  53. ```text
  54. $cc:setup
  55. ```
  56. All checks should pass. If any fail, `$cc:setup` tells you what to fix.
  57. If setup adds the marketplace-qualified plugin-data root and legacy migration roots to the writable-root list, restart Codex and rerun the same command; a requested review-gate toggle waits for that restart.
  58. ### 3. Try It
  59. ```text
  60. $cc:review --background
  61. ```
  62. That launches a Claude Code review from a Codex-managed background flow. You can check on it immediately:
  63. ```text
  64. $cc:status
  65. $cc:result
  66. ```
  67. When it finishes, Codex should nudge you toward the right result. If not, `$cc:status` and `$cc:result` are always the fallback.
  68. ## Commands
  69. | Command | What It Does |
  70. | --- | --- |
  71. | `$cc:review` | Read-only Claude Code review of your changes |
  72. | `$cc:adversarial-review` | Design-challenging review — questions approach, tradeoffs, hidden assumptions |
  73. | `$cc:rescue` | Hand a task to Claude Code — bugs, fixes, investigations, follow-ups |
  74. | `$cc:status` | List running and recent Claude Code jobs, or inspect one job |
  75. | `$cc:result` | Open the output of a finished job |
  76. | `$cc:cancel` | Cancel an active background job |
  77. | `$cc:setup` | Verify installation, auth, hooks, and review gate |
  78. Quick routing rule:
  79. - Use `$cc:review` for straightforward correctness review of the current diff.
  80. - Use `$cc:adversarial-review` for riskier config/template/migration/design changes, or whenever you want stronger challenge on assumptions and tradeoffs.
  81. - Use `$cc:rescue` when you want Claude Code to investigate, validate by changing code, or actually fix/implement something.
  82. ### `$cc:review`
  83. Standard read-only review of your current work.
  84. ```text
  85. $cc:review # review uncommitted changes (default: opus)
  86. $cc:review --base main # review branch vs main
  87. $cc:review --scope branch # explicitly compare branch tip to base
  88. $cc:review --background # run in background, check with $cc:status later
  89. $cc:review --model sonnet # switch to sonnet
  90. $cc:review --model fable # use Fable
  91. $cc:review --model opus --effort xhigh # explicitly raise opus effort
  92. ```
  93. **Flags:** `--base <ref>`, `--scope <auto|working-tree|branch>`, `--wait`, `--background`, `--model <model>`, `--effort <low|medium|high|xhigh|max>`
  94. **Defaults:** model `opus`, and no effort at all. After trimming surrounding whitespace, the friendly aliases `fable`, `opus`, `sonnet`, and `haiku` are matched case-insensitively and canonicalized to lowercase; every other `--model` value passes through unchanged for Claude Code to resolve, including full model IDs and provider-specific names. `--effort` is forwarded only when you pass it, so each model keeps whatever effort Claude Code defaults to. Claude Code owns which effort levels each model supports, so check `/model` rather than assuming a level applies everywhere.
  95. **Model discovery:** run `/model` in Claude Code to see the models and effort levels available to your current account and provider, then pass the selected alias or full ID to this plugin. The plugin intentionally does not maintain a static model catalog, a per-model effort table, or force `[1m]`; Claude Code owns alias versions, supported effort levels, managed restrictions, provider routing, and extended-context eligibility.
  96. Scope `auto` (the default) inspects `git status` and chooses between working-tree and branch automatically.
  97. In foreground, review returns the result directly. In background, the plugin uses a Codex built-in subagent, tracks the review as a job, and nudges you to open the result when it completes.
  98. If the diff is too large to inline safely, the review prompt falls back to concise status/stat context and tells Claude to inspect the diff directly with read-only `git diff` commands instead of failing the run.
  99. ### `$cc:adversarial-review`
  100. Same as `$cc:review`, but steers Claude to challenge the implementation — tradeoffs, alternative approaches, hidden assumptions.
  101. ```text
  102. $cc:adversarial-review
  103. $cc:adversarial-review --background question the retry and rollback strategy
  104. $cc:adversarial-review --base main challenge the caching design
  105. ```
  106. Accepts the same flags as `$cc:review`, plus free-text focus after flags to steer the review.
  107. Background adversarial review uses the same tracked built-in subagent pattern as `$cc:review`.
  108. ### `$cc:rescue`
  109. Hand a task to Claude Code. This is the main way to delegate real work — bug fixes, investigations, refactors.
  110. ```text
  111. $cc:rescue investigate why the tests started failing
  112. $cc:rescue fix the failing test with the smallest safe patch
  113. $cc:rescue --resume apply the top fix from the last run
  114. $cc:rescue --background investigate the regression
  115. $cc:rescue --model sonnet --effort medium investigate the flaky test
  116. ```
  117. **Flags:**
  118. | Flag | Description |
  119. | --- | --- |
  120. | `--background` | Run in background; check later with `$cc:status` |
  121. | `--wait` | Run in foreground |
  122. | `--resume` | Continue the most recent Claude Code task |
  123. | `--resume-last` | Alias for `--resume` |
  124. | `--fresh` | Force a new task (don't resume) |
  125. | `--write` | Allow file edits (default) |
  126. | `--model <model>` | Any Claude Code model alias, full model ID, or provider-specific name; defaults to `opus`. Run `/model` in Claude Code to discover options available to your account and provider. |
  127. | `--effort <level>` | Reasoning effort: `low`, `medium`, `high`, `xhigh`, `max`. Unset by default, so the model keeps Claude Code's own effort default. Claude Code owns which levels each model supports. |
  128. | `--prompt-file <path>` | Read task description from a file |
  129. **Resume behavior:** If you don't pass `--resume` or `--fresh`, rescue checks for a resumable Claude session and asks once whether to continue or start fresh. Your phrasing guides the recommendation — "continue the last run" → resume, "start over" → fresh.
  130. Background rescue runs through a built-in Codex subagent. When the child finishes, the plugin tries to nudge the parent thread with the exact `$cc:result <job-id>` to open.
  131. ### `$cc:status`
  132. ```text
  133. $cc:status # list active and recent jobs
  134. $cc:status task-abc123 # detailed status for one job
  135. $cc:status --all # show all tracked jobs in this repository workspace
  136. $cc:status --wait task-abc123 # block until job completes
  137. ```
  138. By default, `$cc:status` shows jobs owned by the current Codex session. Use `--all` when you want the wider repository view across older or sibling sessions in the same workspace.
  139. ### `$cc:result`
  140. ```text
  141. $cc:result # open the latest finished job for this session/repo
  142. $cc:result task-abc123 # show finished job output
  143. ```
  144. When a job came from a built-in background child, the output can show both:
  145. - the **Claude Code session** you can resume with `claude --resume ...`
  146. - the **Owning Codex session** that owns the tracked job inside Codex
  147. To reopen the Claude Code session directly:
  148. ```bash
  149. claude --resume <session-id>
  150. ```
  151. ### `$cc:cancel`
  152. ```text
  153. $cc:cancel task-abc123 # cancel a running job
  154. ```
  155. ### `$cc:setup`
  156. ```text
  157. $cc:setup # verify everything
  158. $cc:setup --enable-review-gate # turn on turn-end review gate
  159. $cc:setup --disable-review-gate # turn it off
  160. ```
  161. Setup checks Claude Code availability, native plugin hook feature gates, and review-gate state. If Claude Code isn't installed, it offers to install it.
  162. This is also the repair path for marketplace-installed copies of the plugin: `$cc:setup` confirms `[features].hooks = true`, trusts this plugin's current native hook hashes, and allows sandboxed writes to Codex's injected marketplace-qualified plugin-data root plus the legacy roots needed for one-time migration. If those writable roots were just added, restart Codex and rerun setup before changing the review gate.
  163. ## Background Jobs
  164. All review and rescue commands support `--background`. Background jobs are tracked per-session with full lifecycle management:
  165. 1. **Queued → Running → Completed** — jobs progress through states automatically.
  166. 2. **Built-in subagent background flows** — background rescue, review, and adversarial review use Codex-managed subagent turns rather than stuffing `--background` into the companion command itself.
  167. 3. **Completion nudges** — when a background built-in flow finishes, the plugin tries to nudge the parent thread with the right `$cc:result <job-id>`. If that nudge cannot surface cleanly, unread-result hooks are the backstop.
  168. The nudge is intentionally just a pointer. The actual stored result still opens through `$cc:result`.
  169. 4. **Unread-result fallback** — when you submit your next prompt after a finished unread job, Codex can remind you that a result is waiting and point you to `$cc:status` / `$cc:result`.
  170. 5. **Session ownership** — jobs stay attached to the user-facing parent Codex session even when a built-in rescue/review child does the actual work, so plain `$cc:status`, `$cc:result`, and resume-candidate detection still follow the parent thread.
  171. 6. **Cleanup on exit** — when your Codex session ends, any still-running detached jobs are terminated via PID identity validation, and stale reserved job markers are cleaned up over time.
  172. **Typical background flow:**
  173. ```text
  174. $cc:rescue --background investigate the performance regression
  175. # ... keep working ...
  176. # Codex nudges with the exact result command when possible
  177. $cc:result task-abc123
  178. ```
  179. ### What “background” means here
  180. - The parent Codex thread does not wait.
  181. - The Claude companion command still runs in the foreground inside its own worker/subagent thread.
  182. - For rescue and background review flows, the plugin prefers Codex built-in subagents and only uses job polling/status commands as the durable backstop.
  183. ## Review Gate
  184. The review gate is an **optional turn-end hook**. When enabled, Codex runs a Claude Code review of the last Codex response before the turn is allowed to finish.
  185. - Claude returns `ALLOW:` → the turn finishes normally.
  186. - Claude returns `BLOCK:` → the turn is blocked; Codex continues with the review feedback.
  187. **Caveats:**
  188. - **Disabled by default.** Enable with `$cc:setup --enable-review-gate`.
  189. - **Uses your Claude Code defaults.** The gate does not pass `--model` or `--effort`; set your preferred default in Claude Code if you want the gate to use a specific model or effort level.
  190. - **Token cost.** Every edit-producing turn can trigger a Claude invocation. This can drain usage limits quickly in active coding sessions.
  191. - **15-minute timeout.** The gate has a hard timeout. If Claude doesn't respond, the turn remains blocked and the error points you to a manual review.
  192. - **Skip-on-no-edits.** The gate computes a working-tree fingerprint baseline and skips review when the last Codex turn made no net edits.
  193. - **Not in nested sessions.** Child sessions (e.g., rescue subagents) suppress the gate to avoid feedback loops.
  194. **Only enable when you're actively monitoring the session.**
  195. ## How This Differs From Upstream
  196. | | [openai/codex-plugin-cc](https://github.com/openai/codex-plugin-cc) | This repository |
  197. | --- | --- | --- |
  198. | **Host** | Claude Code hosts the plugin | Codex hosts the plugin |
  199. | **Commands** | `/codex:review`, `/codex:rescue`, … | `$cc:review`, `$cc:rescue`, … |
  200. | **Runtime** | Codex app-server + broker | Fresh `claude -p` subprocess per invocation |
  201. | **Review gate trigger** | End of Claude Code turn | End of Codex turn |
  202. | **Review gate target** | Reviews previous Claude response | Reviews previous Codex response |
  203. | **Model flags** | Codex model names and effort controls | Claude model names and effort values (`low` / `medium` / `high` / `xhigh` / `max`) |
  204. ### Where This Goes Further
  205. - **Smart review gate** — fingerprints the working tree and skips turn-end review when the last Codex turn made no net edits, avoiding unnecessary token spend.
  206. - **Nested-session awareness** — suppresses turn-end review and unread-result prompts in child runs, keeping interactive hooks attached to the user-facing thread only.
  207. - **Tracked job ownership** — background jobs track unread/viewed state and session ownership, with safe PID-validated cleanup on session exit.
  208. - **Built-in background notify** — rescue and review flows can now wake the parent thread and point directly to `$cc:result <job-id>` instead of relying only on later polling.
  209. - **Unread-result nudges** — completed background jobs are still surfaced in your next prompt as a reliable fallback.
  210. - **Idempotent installer** — installs through Codex's marketplace/cache path and enables native hook feature gates. Safe to re-run for updates.
  211. ## Install Variants
  212. ### Sendbird marketplace (preferred)
  213. Add the marketplace:
  214. ```bash
  215. codex marketplace add sendbird/codex-marketplace
  216. ```
  217. Then install `cc` from the Sendbird marketplace inside Codex, and run:
  218. ```text
  219. $cc:setup
  220. ```
  221. Marketplace/plugin install places the plugin under Codex's plugin cache. `$cc:setup` verifies Claude Code, confirms `[features].hooks = true`, and trusts the current `hooks/hooks.json` hook hashes from the active plugin cache.
  222. ### npx helper
  223. ```bash
  224. npx cc-plugin-codex install
  225. ```
  226. After install, run:
  227. ```text
  228. $cc:setup
  229. ```
  230. The helper adds the Sendbird marketplace, installs `cc` through Codex app-server, enables native hook feature gates, and removes stale global hook entries from older installs.
  231. ### Shell script (POSIX-only)
  232. ```bash
  233. curl -fsSL "https://raw.githubusercontent.com/sendbird/cc-plugin-codex/main/scripts/install.sh" | bash
    • Note: Pipes a downloaded script directly into a shell (curl | sh / wget | bash)
    • Line 330 on GitHub
  234. ```
  235. After install, run:
  236. ```text
  237. $cc:setup
  238. ```
  239. ### Update
  240. Re-run the marketplace update/install flow or the `npx` helper — both are idempotent.
  241. ```bash
  242. npx cc-plugin-codex update
  243. ```
  244. ### Uninstall
  245. ```bash
  246. npx cc-plugin-codex uninstall
  247. ```
  248. ## Troubleshooting
  249. **`$cc:setup` reports Claude Code not found**
  250. ```bash
  251. npm install -g @anthropic-ai/claude-code
  252. claude auth login
  253. ```
  254. **Commands not recognized in Codex**
  255. Re-run install and restart Codex. This plugin expects Codex plugin support and no longer installs local skill-wrapper fallbacks.
  256. **Hooks not firing**
  257. Check that `hooks = true` is set in `~/.codex/config.toml` under `[features]`. Run `$cc:setup` to verify and auto-repair the feature gate plus this plugin's hook trust hashes, then restart Codex if that flag was just changed.
  258. **A background job finished but I did not get the result nudge**
  259. Use:
  260. ```text
  261. $cc:status
  262. $cc:result
  263. ```
  264. The built-in notify path is best-effort. The tracked job store and unread hook remain the reliable fallback.
  265. If you think the job may belong to an older session in the same repository, use:
  266. ```text
  267. $cc:status --all
  268. ```
  269. If a finished result shows both a **Claude Code session** and an **Owning Codex session**, use the Claude Code session for `claude --resume ...`. The owning session is there only to explain which Codex thread owns the tracked job.
  270. **Large review diff caused a failure or was omitted**
  271. That is expected on very large diffs. The plugin now degrades to a compact review context and points Claude toward read-only `git diff` commands instead of trying to inline everything. If you want the full picture, run a narrower review such as:
  272. ```text
  273. $cc:review --base main
  274. $cc:review --scope working-tree
  275. ```
  276. **Review gate draining tokens**
  277. Disable it: `$cc:setup --disable-review-gate`. The gate can fire after every edit-producing turn, which adds up.
  278. **Background jobs not cleaned up**
  279. Jobs are terminated when the Codex session that owns them exits. If a session crashes without cleanup, use `$cc:status` and `$cc:cancel <job-id>` to clean up any leftovers.
  280. ## License
  281. [Apache-2.0](LICENSE) — see [NOTICE](NOTICE) for attribution.

Ratings and comments

Sign in to rate this skill.

Sign in

Free to use. If it’s helped, pass it on.