codex-plugin-cc: Use Codex inside Claude Code for reviews and task handoff

A practical guide to openai/codex-plugin-cc: install the Codex plugin in Claude Code, run /codex:review, /codex:rescue, /codex:transfer, and manage background tasks.

OpenAI’s codex-plugin-cc is a Claude Code plugin that brings Codex into an existing Claude Code workflow. If Claude Code is your main workspace but you still want Codex for independent code review, debugging, or longer handoff tasks, this plugin lowers the switching cost.

It is not a separate editor and it does not reimplement Codex. It calls the local Codex CLI and Codex app server already installed on your machine, so account state, configuration, repository trust, and local environment all come from your existing Codex setup.

Who it is for

This plugin is useful if you:

  • mainly work in Claude Code but want Codex as an independent reviewer;
  • want another agent to challenge a change before commit;
  • want to hand a bug, failed test, or refactor to Codex in the background;
  • already have Codex configured and want both tools to work in the same repo;
  • want to convert the current Claude Code session into a resumable Codex thread.

If you only use Codex and do not use Claude Code, the plugin is not very meaningful. Its value is the bridge between the two tools.

Requirements

The README lists only a few requirements:

  • a ChatGPT subscription, including Free, or an OpenAI API key;
  • Node.js 18.18 or later;
  • a working local Codex CLI installation.

Calls made through the plugin still count toward your Codex usage limits. This is an integration point, not a way around limits.

If Codex is not installed yet, /codex:setup can guide you later, or you can install it yourself:

1
npm install -g @openai/codex

If Codex is installed but not logged in, run this inside Claude Code:

1
!codex login

Installation

Add the plugin marketplace in Claude Code:

1
/plugin marketplace add openai/codex-plugin-cc

Install the plugin:

1
/plugin install codex@openai-codex

Reload plugins:

1
/reload-plugins

Run the setup check:

1
/codex:setup

/codex:setup checks whether Codex is available. If Codex is missing and npm can be used, it will prompt you to install it. After setup, Claude Code should show a group of /codex:* slash commands and a codex:codex-rescue subagent in /agents.

A minimal first test is:

1
2
3
/codex:review --background
/codex:status
/codex:result

Main commands

/codex:review

/codex:review asks Codex to review the current changes. It is read-only and does not modify code.

Common usage:

1
2
3
/codex:review
/codex:review --base main
/codex:review --background

Use --background when the diff is large. You can then check progress with /codex:status and read the result with /codex:result.

It is good for finding obvious bugs, risk in changes against main, missing tests, edge cases, and compatibility issues. It does not accept a custom review focus; use /codex:adversarial-review for that.

/codex:adversarial-review

/codex:adversarial-review is a guided challenge review. It is also read-only, but it focuses more on implementation direction, design tradeoffs, and hidden assumptions.

1
2
3
/codex:adversarial-review
/codex:adversarial-review --base main challenge whether this was the right caching and retry design
/codex:adversarial-review --background look for race conditions and question the chosen approach

It fits risky changes such as caching, retry logic, permissions, data deletion, or migrations where the code may run but the design may still be wrong.

/codex:rescue

/codex:rescue delegates a task to the codex:codex-rescue subagent. It is useful for debugging, fixing tests, continuing a previous Codex task, or trying a faster smaller-model pass.

1
2
3
4
5
6
/codex:rescue investigate why the tests started failing
/codex:rescue fix the failing test with the smallest safe patch
/codex:rescue --resume apply the top fix from the last run
/codex:rescue --model gpt-5.4-mini --effort medium investigate the flaky integration test
/codex:rescue --model spark fix the issue quickly
/codex:rescue --background investigate the regression

You can also ask in natural language:

1
Ask Codex to redesign the database connection to be more resilient.

If you omit --model or --effort, Codex chooses defaults. spark maps to gpt-5.3-codex-spark. Without --resume or --fresh, the plugin may ask whether to continue the most recent rescue thread in the repo. Use --background for complex tasks.

/codex:transfer

/codex:transfer is a notable v1.0.5 feature. It converts the current Claude Code session into a persistent Codex thread and prints a codex resume <session-id> command.

1
2
/codex:transfer
/codex:transfer --source ~/.claude/projects/-Users-me-repo/<session-id>.jsonl

Use it when a Claude Code conversation already contains enough context and you want Codex to continue later. The plugin uses Claude Code’s SessionStart hook to find the current transcript path; --source lets you specify it manually.

Limitations:

  • the source must be under ~/.claude/projects;
  • it relies on Codex’s external-agent session importer;
  • older Codex versions may need an upgrade before session import works.

/codex:status, /codex:result, and /codex:cancel

These commands manage background tasks.

1
2
/codex:status
/codex:status task-abc123
1
2
/codex:result
/codex:result task-abc123
1
2
/codex:cancel
/codex:cancel task-abc123

If a result includes a Codex session ID, you can continue it with codex resume <session-id>.

Optional review gate

/codex:setup can also manage an optional review gate:

1
2
/codex:setup --enable-review-gate
/codex:setup --disable-review-gate

When enabled, a Claude Code Stop hook triggers a targeted Codex review. If Codex finds issues, the stop is blocked so Claude Code can handle the feedback first.

Use this carefully. It can create a long Claude/Codex loop and consume usage limits quickly, so it is better for watched critical tasks than as a permanent default.

Configuration inheritance

codex-plugin-cc uses the global local codex binary, so it inherits your Codex configuration.

For a project-specific default model and reasoning effort, add this to .codex/config.toml:

1
2
model = "gpt-5.4-mini"
model_reasoning_effort = "high"

Configuration mainly comes from:

  • user config: ~/.codex/config.toml;
  • project config: .codex/config.toml;
  • project config only loads after the project is trusted by Codex.

If your API key, base URL, or provider setup already works in Codex, the plugin uses it too. To change the OpenAI provider endpoint, set openai_base_url in Codex config.

Common workflows

Pre-commit review

1
2
3
/codex:review --background
/codex:status
/codex:result

Run this before a commit to get a separate Codex pass on bugs, test gaps, and risk.

Challenge a design

1
/codex:adversarial-review --background look for auth bypass and rollback risks

Useful for authorization, data migration, cache invalidation, and retry strategy changes.

Hand a problem to Codex

1
/codex:rescue --background investigate why the build is failing in CI

This keeps the Claude Code conversation moving while Codex investigates independently.

Move from Claude Code to Codex

1
/codex:transfer

Use this when you want to continue the accumulated context in Codex App or TUI.

Practical advice

Treat the plugin first as a second reviewer and a background rescue channel. A steady adoption path is: run /codex:setup, try /codex:review --background, use /codex:adversarial-review for design challenges, then try /codex:rescue, and only use /codex:transfer when cross-tool context really matters.

That keeps the division clear: Claude Code remains the main workbench, while Codex handles independent review, background investigation, and occasional context handoff.

记录并分享
Built with Hugo
Theme Stack designed by Jimmy