Code · Workflow

Codex (CLI + cloud)

OpenAI Codex: terminal CLI for active work, cloud lane for autonomous PRs

Codex CLI replaces the recommended stack's Claude Code. Then the differentiator: Codex Cloud takes a ticket from the queue, opens a PR autonomously, and pings you when it's ready for review. Pair it with CodeRabbit and the human reviewer mostly approves clean diffs.

CODEBUILDERINTERMEDIATEIntermediateFrom $0/mo
The stack
Codex
CLI for active work + Cloud for backlog PRs

Codex CLI handles the same role Claude Code does: terminal agent with file system access. Codex Cloud is the ChatGPT-bundled cloud lane that takes a task and opens a PR while you do something else. Use both: hands-on for the work you're thinking about, cloud for the cleanup tickets in the queue.

Bundled with ChatGPT Plus $20/mo · Pro $200/mo · API meteredAlts: Claude Code, Cursor
CodeRabbit
Automated PR review

Especially valuable on Codex Cloud's autonomous PRs — those are the ones you didn't watch get written, so you want a second AI reading the diff before a human does.

Free for OSS · $12/mo per dev ProAlts: Claude
Real monthly cost
small
$0/mo
Solo OSS maintainer
  • codexFree tier
  • coderabbitFree (OSS)
medium
$32/mo
Indie dev, daily PRs, ChatGPT Plus
  • codex$20 (bundled with ChatGPT Plus)
  • coderabbit$12/dev
heavy
$280/mo
Cloud-leaning team, ChatGPT Pro plans
  • codex$200 ChatGPT Pro
  • coderabbit$60 (5 devs)
  • + misc$20 (extra cloud-task budget)
Workflow
  1. 1
    Decide: hands-on or backlog?

    If you're already thinking about the change, run the CLI. If it's a clear ticket from the backlog (refactor, dep bump, doc update), send it to Cloud and move on.

  2. 2
    Hands-on with Codex CLICodex

    `codex` in your repo. Same shape as Claude Code: scope, plan, implement, run tests.

    Prompt · Plan-and-implement from a ticket (Codex CLI)
    Plan first, then implement. Ask 1 to 2 clarifying questions before you start writing if anything is genuinely ambiguous.
    
    Ticket / problem:
    """
    {{paste ticket}}
    """
    
    Constraints:
    - Smallest viable diff.
    - Match the existing code style. Read nearby files before introducing a new pattern.
    - Run the project's test command. Don't report done if it fails.
    - Treat AGENTS.md / CLAUDE.md / .cursorrules at the repo root as authoritative.
    
    When done: print the file list, the test result, and a 2-line summary I can paste as the commit message.
  3. 3
    Backlog tickets via Codex CloudCodex

    From ChatGPT, hand off the ticket with the repo selected. Cloud reads the repo, plans, opens a draft PR, and pings you. Read the PR description first; reject and retry if scope drifted.

  4. 4
    Review the PRCodeRabbit

    CodeRabbit posts findings on both CLI-authored and Cloud-authored PRs. For Cloud PRs especially, treat CodeRabbit's summary as your first signal that the autonomous lane stayed on the rails.

  5. 5
    Bounce findings back to CodexCodex

    For CLI work: paste findings into the same session. For Cloud PRs: kick the same task back via the Cloud `Address review feedback` action.

What it produced
Two-engineer startup, mixed-mode week

Half the PRs (the ones requiring product judgment) went through Codex CLI. The other half (dep updates, type-error cleanups, doc touch-ups) ran on Codex Cloud while the engineers worked on real product. The Cloud lane shipped 22 PRs in one week with 3 needing a retry for scope drift.

Common pitfalls
Codex Cloud scope drift

Autonomous lanes occasionally rewrite the world. Always read the PR description before the diff; if the description says 'also refactored…', kill the PR and retry with a tighter ticket.

Cloud-task budget burn

Cloud tasks are metered separately from the chat subscription. A team that sends 30 cloud tasks/day will exceed the bundled budget within a week. Track it.

Conflating CLI tells with Cloud tells

Codex CLI is supervised; Cloud isn't. The same prompt works very differently in the two lanes. Don't copy a CLI prompt into Cloud and expect the same result.

Other ways to do Ship code with AI
Curated by @alex-w
Updated weekly · last refresh: just now