Skip to content

feat(codexcli): add PermissionRequest hook event#1566

Open
saitota wants to merge 2 commits intodyoshikawa:mainfrom
saitota:i1565
Open

feat(codexcli): add PermissionRequest hook event#1566
saitota wants to merge 2 commits intodyoshikawa:mainfrom
saitota:i1565

Conversation

@saitota
Copy link
Copy Markdown
Contributor

@saitota saitota commented Apr 25, 2026

Closes #1565

Notes

  • Registration-only change; the converter is already event-name-map driven.
  • statusMessage / decision response fields are out of scope (passthrough via looseObject works).

Tests

Added 3 unit tests in codexcli-hooks.test.ts: forward conversion with Bash matcher, forward with apply_patch / MCP matchers, and reverse conversion.

Local verification

Verified with rulesync convert --from claudecode --to codexcli --features hooks --global against a real ~/.claude/settings.json:

  • PermissionRequest hooks emitted to ~/.codex/hooks.json correctly.
  • ~/.codex/config.toml got codex_hooks = true added without clobbering existing [mcp_servers].

saitota added 2 commits April 25, 2026 22:10
Codex CLI v0.122.0 (2026-04-20) added the PermissionRequest hook event,
fired before approval prompts. Register it in CODEXCLI_HOOK_EVENTS and
canonical->Codex name map so rulesync can emit it in .codex/hooks.json.

Closes dyoshikawa#1565
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add PermissionRequest hook event for Codex CLI

1 participant