Support interactive option selection in UserPromptSubmit hooks

Resolved 💬 2 comments Opened Mar 20, 2026 by Jamil-Najafov Closed Mar 20, 2026

Problem

UserPromptSubmit hooks can only block (with a reason message) or pass through. When a hook wants to suggest alternatives to the user — e.g., "use skill X for this task" vs "continue as-is" — the only option is to block and ask the user to resubmit their prompt. This is clunky UX.

Proposal

Allow hooks to return selectable options that Claude Code renders as an interactive menu (arrow keys + enter):

{
  "decision": "choose",
  "reason": "A skill may help with this task:",
  "options": [
    { "label": "/brainstorming — Explore ideas before implementation", "value": "skill", "additionalContext": "User chose to use /brainstorming skill" },
    { "label": "Continue as-is", "value": "passthrough" }
  ]
}

The TUI would render something like:

⚡ Hook suggestion: A skill may help with this task:
  
  > /brainstorming — Explore ideas before implementation
    Continue as-is

↑↓ to select, Enter to confirm

Selecting an option could either:

  • Inject additionalContext from the chosen option and proceed
  • Or resubmit the prompt with the selected option's context

Use Case

Skill discovery hooks that suggest relevant skills without forcing a block-and-resubmit loop. Currently the workaround is blocking + a passthrough file so the next identical resubmit goes through — functional but confusing for users (the "resubmit your prompt as-is" instruction reads like a hack).

Current Workaround

# Block with message, set passthrough marker
set_passthrough()
result = {"decision": "block", "reason": "...suggestion...\nTo skip: resubmit your prompt as-is"}

The alternative (additionalContext without blocking) forces the skill into conversation — user can't opt out cleanly.

View original on GitHub ↗

This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗