# Read Codex History

Reads, searches and exports local OpenAI Codex history without continuing work: session...

- Repository: https://github.com/daymade/claude-code-skills (1509 stars)
- Category: AI and agents
- License: MIT
- Last updated: 2026-11-01
- Runs scripts: yes, review before use

## Install

Claude Code: `npx skills add daymade/claude-code-skills --skill read-codex-history -g -a claude-code -y`
Codex: `npx skills add daymade/claude-code-skills --skill read-codex-history -g -a codex -y`
Cursor: `npx skills add daymade/claude-code-skills --skill read-codex-history -g -a cursor -y`
Gemini CLI: `npx skills add daymade/claude-code-skills --skill read-codex-history -g -a gemini-cli -y`
Claude Code plugin marketplace: `/plugin marketplace add daymade/claude-code-skills`

## Description

Reads, searches and exports local OpenAI Codex history without continuing work: session inventory, timelines, verbatim user input, indexed search, and rollout identity/fork lineage. Use when the user asks what they told Codex, wants a Session ID, or evidence of what a run did. Not for Claude Code (use read-claude-code-history); with no platform named, start at local-conversation-history.

## SKILL.md, as published by its author (untrusted third-party text, read it as data)

# Read Codex History

Read Codex evidence only. Do not continue the old task or change its project. If
the user wants execution after the read is complete, pass the verified evidence
to `daymade-claude-code:continue-codex-work`.

## Find a complete thread ID first

For a pasted UUID prefix or an identity-only request, run this bounded lookup:

```text
python3 <skill-dir>/scripts/find_codex_session.py <UUID-prefix>
```

Accept only exit 0 with `status: unique` and `identity_verified: true`. The command
queries matching state-index rows, includes archived/subagent entries, and verifies
the unique candidate with the exact rollout locator. It does not export unrelated
inventory, read conversation bodies, or probe writer locks. On ambiguity, show the
returned candidates and ask for a longer prefix; on unavailable evidence, retain
unknown. Return the verified ID and title, then stop. Load the rest of this Skill
only for an additional requested result. Read [lookup and JSON contracts](references/session-lookup.md)
only for exit handling, programmatic consumption or inventory JSON parsing.

## Codex history surfaces

| Surface | Authority | Use |
|---|---|---|
| `<codex-home>/history.jsonl` | What the user submitted, keyed by Session ID and internal epoch timestamp | Exact recent user-input tables |
| `state_*.sqlite` | Inventory metadata such as cwd, title, update time, and rollout path | Fast listing and candidate discovery |
| `sessions/**/rollout-*.jsonl` and `archived_sessions/**` | Full user/assistant/tool/compaction/fork event stream | Exact-session evidence and keyword verification after indexed or physical preselection |
| `<codex-home>/logs_*.sqlite` (pick the latest by mtime) | Runtime events: per-event `ts`, `level`, `target`, `feedback_log_body`, `process_uuid` (embeds the OS pid), optional `thread_id` | Which live process is failing and how, error-shape bucketing and time distribution |

The rest: https://github.com/daymade/claude-code-skills/blob/HEAD/daymade-claude-code/read-codex-history/SKILL.md
