Skip to content
Agentmart
Submit a tool

codex-agent

Run Codex CLI as an independent coding worker for implementation, investigation, planning, or review, then monitor and verify its result.

Skill by ejarmand

IndexedMIT★ 1
Write a review

Install

Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.

npx agentmarket install skill/ejarmand-codex-agent

Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.

Get the weekly diff

The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.

We use your email only for this newsletter. Privacy

About

Run Codex CLI as an independent coding worker for implementation, investigation, planning, or review, then monitor and verify its result. Use when asked to delegate work through `codex exec`, capture a Codex session ID for follow-up work, or resume, continue, consult, or "adopt" a prior Codex session or thread ID.

Use cases: agent-building

No reviews yet. Installed it? Reviews come from verified installers only. How reviews work

Permissions

What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.

Tools
No tools found
Secrets
None asked for
Install scripts
None found
Runs as
Shell scripts

Network hosts it talks to 1

  • codeload.github.com · found in install command

Files it touches

  • ~/.claude/skills/codex-agent

What's inside

Skill name
codex-agent
Description
Run Codex CLI as an independent coding worker for implementation, investigation, planning, or review, then monitor and verify its result. Use when asked to delegate work through `codex exec`, capture a Codex session ID for follow-up work, or resume, continue, consult, or "adopt" a prior Codex session or thread ID.
License
MIT
Instructions
125 lines in SKILL.md · view on GitHub

Before installing

  • Ships executable scripts

Files (5)

  • SKILL.md
  • openai.yaml · agents/
  • config.toml · profiles/github-pr-reviewer/
  • github-pr-reviewer.rules · profiles/github-pr-reviewer/rules/
  • run-profiled.sh · scripts/

SKILL.md (first lines)

# Codex Agent

Run `codex exec` from the intended workspace, give it a bounded outcome, monitor
it at the task's time scale, and preserve its session ID when follow-up work is
likely.

Read `/cross-provider-agent` first and apply its doctrine to the whole
dispatch; this skill is only the Codex transport.

Treat installed help as authoritative because Codex CLI evolves:

```bash
codex --version
codex exec --help
codex exec resume --help
codex login status
```

If authentication is missing, ask the user to run `codex login`. Never display,
copy, or embed authentication files or tokens.

## agent permissions

Use the least authority that completes the task. Never add
`--dangerously-bypass-approvals-and-sandbox`, `danger-full-access`,
`--ignore-rules`, or `--dangerously-bypass-hook-trust` merely to make a run
unattended.

## Start a worker

Resolve the intended working directory and whether the task may edit files.
Default analysis, planning, and review to a read-only sandbox:

```bash
codex exec --json --sandbox read-only -C /absolute/path/to/repo \
  "[message]"
```

Use `--sandbox workspace-write`  when the user's task authorizes implementation.

Use `--output-last-message` when a separate final-result file is useful;
keep result files and JSONL logs in a temporary location unless the user asks to
retain them because they may contain prompts, paths, or file content.

## Capture the session ID

Use `--json` whenever later continuation or structured monitoring matters. The
initial event has this form:

```json
{"type":"thread.started","thread_id":"SESSION_ID"}
```

Record that exact `thread_id` as soon as it appears so an interrupted run can
still be resumed.

## Resume or adopt a worker

Resume a specific session sequentially from the intended checkout:

```bash
codex exec --json --sandbox read-only -C /absolute/path/to/repo \
  resume SESSION_ID \
  "[message]"
```
Put global `codex exec` options before `resume`.

## Monitor and collect

With `--json`, require a successful process exit and a terminal
`turn.completed` event. Treat `turn.failed`, `error`, a nonzero exit, or a
mismatched thread ID as failure. The final `item.completed` whose item type is
`agent_message` contains the worker's result.

## Profiled dispatch
`codex exec` hardcodes never-ask approvals: a sandboxed command that needs
network fails (on Linux, a bubblewrap loopback error) with no runtime
escalation path. Pre-authorize the specific commands with execpolicy rules 
 instead of widening the sandbox

Use the transactional runner with scoped profiles : `/absolute/path/to/codex-agent/scripts/run-profiled.sh`

The transactional runner assembles a throwaway home from the profile installed
skills symlinked so the child can invoke cited skills — runs one session as
the profiled agent, and deletes the home afterwards:

```bash
/absolute/path/to/codex-agent/scripts/run-profiled.sh \
  --workspace /absolute/path/to/workspace \
  [--effort [effort level]] \
  --profile github-pr-reviewer \
  -- --json "REVIEW_TASK"
```

The root session is the profiled agent — no bootstrap relay — and native
children it spawns inherit the same sandbox and rules. Nothing touches the
workspace, so parallel Codex dispatches need no lock.

Known gap (0.146.0, live-verified): native file tools bypass the read-only
sandbox, so file-write denial is detect-and-reject — verify the pinned head
and a clean tree after dispatch and discard the child's output otherwise
The runner refuses a workspace containing `.codex/`: its rules load into the child's policy with
no trust gate.

Verify a rule offline before relying on it:

```bash
codex execpolicy check \
  --rules /absolute/path/to/codex-agent/profiles/github-pr-reviewer/rules/github-pr-reviewer.rules \
  -- gh pr comment 1 --body test
```

Rules are experimental. Keep only narrow `allow` prefixes and never add a
fallback rule: most-restrictive-wins would turn a broad `prompt` decision
into a blocker under exec's never-ask approvals. A failed rule match fails
closed — the command stays sandboxed with no network escape.

### available profiles
**github-pr-reviewer** : `profiles/github-pr-reviewer/` encodes the profile from

From ejarmand/skills, MIT.

More from ejarmand/skills

Signals

Stars
1
Forks
0
Open issues
20
Last commit (this folder)
Sep 23, 2026 (1 month ago)

From GitHub (fetched Oct 24, 2026).

Details

License
MIT
First seen
Oct 24, 2026
Last checked
Oct 24, 2026

More from ejarmand

Cite this page

codex-agent skill. Agent Mart. https://agentmart.dev/skills/ejarmand-codex-agent (last updated 2026-10-24)