Skip to content

Expose plan-mode-prompt and approval-requested through top-level notify #19921

Open

Description

@ryan6416

What version of Codex CLI is running?

codex-cli 0.125.0

What platform is your computer?

macOS

What terminal emulator and version are you using?

Ghostty 1.3.0-HEAD+9fa3ab0 and cmux 0.63.2 (79) [179b16ce6]

Summary

Codex now emits native TUI notifications for plan-mode request_user_input prompts via plan-mode-prompt after #17417. That works when terminal notifications are enabled.

However, the top-level notify external command still only supports agent-turn-complete. This means users cannot use the native Codex external notification primitive for the most important "needs response" states: plan-mode questions and approval requests.

Current behavior

This works for terminal-native notifications:

[tui]
notifications = ["plan-mode-prompt", "approval-requested"]
notification_method = "bel" # or "osc9"
notification_condition = "always"

This works only for completion:

notify = ["python3", "/path/to/notify.py"]

Per the docs, notify currently receives supported events, currently only agent-turn-complete.

Expected behavior

notify should also be able to receive the same high-value TUI notification event types, especially:

  • plan-mode-prompt
  • approval-requested
  • any future blocked / needs-response state

This would allow users to implement one external alert command for "never miss needs response" workflows without relying on terminal-specific OSC/BEL behavior or custom transcript monitoring.

Repro / motivation

  1. Configure Codex TUI notifications.
  2. In plan mode, prompt Codex to call request_user_input.
  3. Codex emits the plan-mode questionnaire and terminal notification.
  4. The external notify command does not run because the event is not agent-turn-complete.

Related

Activity

  1. added
    enhancementNew feature or request
    CLIIssues related to the Codex CLI
    TUIIssues related to the terminal user interface: text input, menus and dialogs, and terminal display
    planIssues involving plan mode
    hooksIssues related to event hooks
    on Apr 28, 2026
  2. github-actions commented on Apr 28, 2026

    @github-actions
    Contributor

    Potential duplicates detected. Please review them and close your issue if it is a duplicate.

    Powered by Codex Action

  3. removed
    CLIIssues related to the Codex CLI
    hooksIssues related to event hooks
    on Apr 28, 2026
  4. etraut-openai commented on Apr 28, 2026

    @etraut-openai
    Contributor

    The top-level notify will soon be deprecated in favor of our new hooks implementation, so it's unlikely that we will extend it to cover more cases. I'll leave the feature request open as a reminder that we should have some hook mechanism in place for this.

  5. added
    hooksIssues related to event hooks
    and removed
    TUIIssues related to the terminal user interface: text input, menus and dialogs, and terminal display
    on Apr 28, 2026
  6. ryan6416 commented on Apr 28, 2026

    @ryan6416
    Author

    @etraut-openai thanks, that makes sense.

    What is the recommended hooks-based path for this today or soon?

    Specifically, I’m trying to trigger an external command for these “needs response” states:

    • plan-mode-prompt
    • approval-requested
    • blocked/error states
    • agent turn complete

    Is there currently a hook event that fires for request_user_input / plan-mode-prompt? If not, should this issue track adding a hook event for those TUI notification types?

  7. oxysoft commented on May 8, 2026

    @oxysoft

    Indexed this hook ticket in the umbrella tracker: #21753

    Goal: collect the scattered Codex hook requests and bugs into one parity matrix for Full Claude Code Hook Parity (29+), while preserving this issue as the detailed thread for its specific behavior.

  8. Gouldian commented on Aug 9, 2026

    @Gouldian

    Adding a concrete downstream integration impact:

    I use Codex CLI through MulmoTerminal 4.7.4 on macOS (Codex CLI 0.147.0-alpha.6.5). MulmoTerminal can notify on completed turns and has a separate waiting notification kind for questions and permission prompts. In Codex sessions, however, its activity integration currently sees turn boundaries but cannot receive plan-mode-prompt, so a request_user_input prompt can remain in progress without producing either a finished or waiting alert, even when both notification kinds are enabled.

    Exposing plan-mode-prompt and approval-requested through the top-level notify command would give terminal managers a supported, event-driven integration surface instead of requiring transcript polling. This matters especially for parallel-session supervisors, where an unnoticed input prompt can leave one session stalled indefinitely.

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requesthooksIssues related to event hooksplanIssues involving plan mode

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions