[FEATURE] Feature request: Hook event when Claude prompts for user input (AskUserQuestion)
Preflight Checklist
- [x] I have searched existing requests and this feature hasn't been requested yet
- [x] This is a single feature request (not multiple features)
Problem Statement
Summary
Add a hook event that fires when Claude asks the user a question via AskUserQuestion,
so users can trigger notifications (sound, OS alert, etc.) at the moment input is needed.
## Current behaviour
The Stop hook fires when Claude finishes a task, which works well for task-complete
notifications. However, there is no hook event for when Claude is waiting for user input.
AskUserQuestion does not trigger PreToolUse or PostToolUse.
## Desired behaviour
A new hook event — or an extension of PreToolUse — that fires immediately before
Claude displays a question to the user, so it can be matched with "matcher": "AskUserQuestion".
## Use case
Playing a sound notification in VS Code (or any environment) so the user knows Claude
needs their input, not just that it has finished. Currently the only signal is a visual
one in the UI.
## Suggested hook event name
PreToolUse with AskUserQuestion support, or a dedicated UserInputRequired event.
Proposed Solution
When Claude calls AskUserQuestion, a PreToolUse hook should fire with the tool name AskUserQuestion as the matcher — just like it does for Bash, Edit, and other tools.
Ideal experience:
- Claude needs input and calls
AskUserQuestion - The
PreToolUsehook fires before the question is displayed - The user's configured command runs (e.g. plays a sound, sends an OS notification)
- The question appears in the UI
This would let users configure it in settings.json like:
{
"hooks": {
"PreToolUse": [
{
"matcher": "AskUserQuestion",
"hooks": [
{
"type": "command",
"command": "powershell -c \"(New-Object Media.SoundPlayer 'C:\\Windows\\Media\\chord.wav').PlaySync()\""
}
]
}
]
}
}
No new event type needed — just extending the existing PreToolUse hook to cover
AskUserQuestion the same way it covers other tools.
Alternative Solutions
_No response_
Priority
High - Significant impact on productivity
Feature Category
CLI commands and flags
Use Case Example
_No response_
Additional Context
_No response_
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗