woclaw-codex
v0.1.2
Published
WoClaw integration for OpenAI Codex CLI — shared context across sessions
Maintainers
Readme
WoClaw Codex CLI Integration
Connect OpenAI Codex CLI sessions to a WoClaw Hub for shared context across sessions and agents.
pip install aiohttp websockets # required by hook scripts
python3 install.py # one-command installWhat It Does
- SessionStart Hook: When Codex starts, loads shared project context from WoClaw Hub and injects it as developer context
- Stop Hook: When Codex ends, saves a transcript summary back to WoClaw Hub so future sessions can pick up where you left off
Requirements
- Python 3.8+
aiohttpor standardurllib(stdlib, no extra deps needed for REST)- WoClaw Hub running at
ws://vm153:8082/http://vm153:8083
Quick Install
# Clone WoClaw repo (if you have it)
cd packages/codex-woclaw
# Install hooks (one command)
python3 install.pyThis will:
- Copy
session_start.pyandstop.pyto~/.codex/hooks/ - Create
~/.codex/hooks.jsonwith WoClaw hook configuration - Enable
codex_hooks = truein~/.codex/config.toml
Then start a Codex session — the hook runs automatically.
Uninstall
python3 install.py --uninstallEnvironment Variables
| Variable | Default | Description |
|----------|---------|-------------|
| WOCLAW_HUB_URL | http://vm153:8083 | Hub REST API URL |
| WOCLAW_TOKEN | WoClaw2026 | Hub auth token |
| WOCLAW_KEY | codex:context | Memory key for context |
How It Works
The Codex CLI hooks system (~/.codex/hooks.json) fires Python scripts at key lifecycle events:
- SessionStart →
session_start.pyreadsWOCLAW_KEYfrom WoClaw Hub REST API → injects asadditionalContext - Stop →
stop.pyreads session transcript → writes summary to WoClaw Hub underWOCLAW_KEY
NPM Package
Publishing as woclaw-codex npm package for easy distribution:
cd packages/codex-woclaw
npm publish --access public
# → woclaw-codex on npmAfter npm install, users get:
npx woclaw-codex install # installs hooks