What
- Hooks that run on
prompt.submitcan now rewrite the text of the prompt before it is committed; this is logged as "prompt.submit: text rewritten by a hook". - The pipeline gained a new
enterstage/callback. When it fires, Claude Code now records telemetry eventprompt_queuedand the prompt is queued rather than run immediately. - When a hook drops a prompt, Claude Code now logs a reason ("prompt.submit: dropped") and can show a distinct "Prompt not submitted" message alongside the existing "Prompt dropped by a hook" message.
- If a plugin's
prompt.submithook attaches extra context to its result after it has already callednext(), that is now detected and a warning is logged that the entries were dropped, instead of the entries being silently lost. - Internally, both the interactive and SDK/headless prompt-processing paths now open a disposable tracker before processing input and mark it "handed off" once the new messages are pushed into the conversation; if the tracker is disposed before hand-off, any waiter is rejected instead of hanging.
- The SDK's error message for
$.prompt.submit(thrown when text starts with/) now tells the caller to use$.command.runinstead.
Why These changes make the prompt-submission path more capable (hooks can now edit prompts, not just allow or block them) and easier to debug, since drops, rewrites, and queued prompts are now logged and reported distinctly instead of failing silently or hanging.
Names in the bundleprompt.submit
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.
Added since
A small documentation edit on Mods reference touched a line naming prompt.submit after this was published.
When another mod's hook calls a method on a namespace you added in `engine.create`, your method's `$` calls run in that hook's context until every hook on that event returns. For example, a relative path resolves against that hook's workin…plugins/mods/reference see the edit
Confirmed since
Anthropic's documentation has since written up prompt.submit, on Test a mod.
* **`$`**: the test's own `$`, which acts as Claude Code. It isn't the [mods API](/docs/en/plugins/mods/reference#mods-api-methods) that a hook receives. Each of its methods fires the event of the same name, sends it through your mod's hoo…plugins/mods/test see the edit
One source agreesOne thing we can check says the same as this entry.
Anthropic's documentation agrees
Anthropic's documentation has since written up prompt.submit, on Test a mod.