Unclear Which behaviour this check controls is not known, so its visible effect cannot be described.
What
A UserPromptSubmit hook is a script that runs when you submit a prompt, before Claude processes it. Claude Code uses an internal yes-or-no check about these hooks, and it has been turned around.
- Before, it said yes only when no
UserPromptSubmithook was set up andCLAUDE_CODE_REMOTEwas not set, among other conditions. - Now, it says yes when the hook settings cannot be read or when a
UserPromptSubmithook exists. - It no longer looks at
CLAUDE_CODE_REMOTEor the other conditions.
Why
This changes when some hook-related behaviour is offered or applied, so people who use UserPromptSubmit hooks may notice a difference.
Names in the bundleUserPromptSubmit
The entry above is what we published on the day. These lines were added later, as Anthropic's own pages caught up, and they sit beside the original rather than replacing it.
Confirmed since
Anthropic's documentation has since written up UserPromptSubmit, on Intercept and control agent behavior with hooks.
Claude Code runs each callback with a timeout, which you set in seconds with the `timeout` field on its `HookMatcher`. When you don't set one, Claude Code uses the event's default: 600 seconds for most events, 30 seconds for `UserPromptSub…agent-sdk/hooks see the edit
Added since
A small documentation edit on Intercept and control agent behavior with hooks touched a line naming UserPromptSubmit after this was published.
A `UserPromptSubmit` hook that spawns subagents can create infinite loops if those subagents trigger the same hook. You can prevent the loop in the following ways:agent-sdk/hooks see the edit
Something disagreesSomething we can check disagrees with this entry, or the writer said they could not settle it.
The writer flagged doubt
Which behaviour this check controls is not known, so its visible effect cannot be described.
Anthropic's documentation agrees
A small documentation edit on Intercept and control agent behavior with hooks touched a line naming UserPromptSubmit after this was…