Skills codex-bridge
Dispatch coding tasks to the local OpenAI Codex CLI with background execution, status polling, and answerable clarifying questions. Use when OpenClaw should delegate script building, code edits, refactors, or multi-step coding work to Codex from the command line.
install
source · Clone the upstream repo
git clone https://github.com/openclaw/skills
Claude Code · Install into ~/.claude/skills/
T=$(mktemp -d) && git clone --depth=1 https://github.com/openclaw/skills "$T" && mkdir -p ~/.claude/skills && cp -r "$T/skills/abeperl/codex-bridge" ~/.claude/skills/openclaw-skills-codex-bridge && rm -rf "$T"
OpenClaw · Install into ~/.openclaw/skills/
T=$(mktemp -d) && git clone --depth=1 https://github.com/openclaw/skills "$T" && mkdir -p ~/.openclaw/skills && cp -r "$T/skills/abeperl/codex-bridge" ~/.openclaw/skills/openclaw-skills-codex-bridge && rm -rf "$T"
manifest:
skills/abeperl/codex-bridge/SKILL.mdsource content
Codex Bridge
Delegate coding tasks from OpenClaw to the local
codex CLI and manage them asynchronously.
This skill provides a file-based bridge so OpenClaw can:
- dispatch tasks
- poll status and recent output
- relay clarifying questions
- send answers
- collect final results
When to Use
- Build scripts (Python, Bash, etc.)
- Implement or refactor code in an existing project
- Run larger multi-file coding tasks in the background
- Delegate coding work while keeping OpenClaw responsive
- Handle tasks that may require clarifying questions mid-run
When NOT to Use
- Quick factual questions or explanations
- Small code snippets that OpenClaw can write directly
- Non-coding tasks
- Tasks that should not invoke a local coding agent/CLI
Dispatch a Task
~/.openclaw/skills/codex-bridge/codex-bridge-dispatch.sh \ --task-id <descriptive-name> \ --workdir <project-directory> \ --prompt "<detailed coding task>"
Prompt Writing
Include:
- what to build/fix
- file paths if known
- expected behavior/output
- language/framework preferences
- constraints (tests, style, no new deps, etc.)
Example:
~/.openclaw/skills/codex-bridge/codex-bridge-dispatch.sh \ --task-id scripts-csv-parser \ --workdir ~/projects/data-tools \ --prompt "Create parse_orders.py. Read orders CSV, keep shipped rows, group by customer_id, and write summary CSV with columns customer_id, order_count, total_amount. Use pandas. Add basic CLI args and error handling."
Check Status
~/.openclaw/skills/codex-bridge/codex-bridge-status.sh --task-id <id>
Common status commands:
~/.openclaw/skills/codex-bridge/codex-bridge-status.sh --list ~/.openclaw/skills/codex-bridge/codex-bridge-status.sh --task-id <id> --output ~/.openclaw/skills/codex-bridge/codex-bridge-status.sh --task-id <id> --question ~/.openclaw/skills/codex-bridge/codex-bridge-status.sh --task-id <id> --result ~/.openclaw/skills/codex-bridge/codex-bridge-status.sh --task-id <id> --log
Answer Clarifying Questions
When status is
waiting_for_answer, read the pending question and send a response:
~/.openclaw/skills/codex-bridge/codex-bridge-status.sh --task-id <id> --question ~/.openclaw/skills/codex-bridge/codex-bridge-answer.sh --task-id <id> --answer "<answer text>"
The bridge resumes the same Codex session after the answer is written.
Workflow
- Dispatch task with a clear prompt.
- Report the task ID.
- Poll status/output periodically.
- If status becomes
, readwaiting_for_answer
, relay to user, then write answer with--question
.--answer - When status is
, readcomplete
and summarize outcomes.--result - If status is
, inspecterror
and--log
.--output
Notes and Limits
- Uses the local
CLI (codex
andcodex exec
).codex exec resume - Clarifying questions are implemented via a lightweight text marker protocol in the prompt wrapper.
- Bridge state is stored in
.~/.codex-bridge/tasks/<task-id>/ - Commands run via Codex in the specified
.--workdir - For unattended runs, the bridge times out after 10 minutes waiting for an answer and resumes with a default/sensible fallback.