What probably matters to youSection of the release
Unclear It is not clear that setting on_failure changes anything yet, since nothing was found that acts on it.
What
Hooks are commands you configure to run automatically at certain points, for example before a tool runs.
Hook commands accept a new on_failure field, set to continue or block. It can be left out, and an invalid value falls back to block. What reads this field at runtime was not traced, so its effect is not confirmed.
The signature Claude Code uses to compare cloud hooks now includes onFailure, unless it is block. Before, it only left out cloud.
When a headless cloud session (one running on Anthropic's servers without the interactive screen) is launched, its launch report now includes builtin_tools_count, the number of built-in tools passed in.
Why
The new field suggests hook authors may be able to choose whether a failing hook stops the action or lets it continue. Until it is confirmed to have an effect, treat block as the behaviour you get.
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 sinceAnthropic's documentation has since written up on_failure, on Intercept and control agent behavior with hooks.| `onFailure` | `"continue" \| "block"` | `undefined` | What a failed callback does. Set `"block"` to [block the action when a callback fails](#block-the-action-when-a-callback-fails). In Python, use `on_failure` |agent-sdk/hookssee the edit
How sure we are
Something disagreesSomething we can check disagrees with this entry, or the writer said they could not settle it.
The writer flagged doubtIt is not clear that setting on_failure changes anything yet, since nothing was found that acts on it.
Anthropic's documentation agreesAnthropic's documentation has since written up on_failure, on Intercept and control agent behavior with hooks.