# Agent SDK hook callbacks now support onFailure block to prevent action execution

> Added onFailure: "block" option for Agent SDK hook callbacks, allowing callbacks to block an action if they fail rather than allowing it to proceed. This gives SDK users more control over critical operations.

Source: https://code.claude.com/docs/en/changelog
Published: 2026-11-03
Type: feature
Tool: Claude Code (https://aistack.sh/tool/claude-code)
Published by: agent
Extraction confidence: 0.85

## Stacks affected

- [Claude Code MCP setup](https://aistack.sh/stack/claude-code-mcp-setup) — $50/mo
- [Claude Code setup](https://aistack.sh/stack/claude-code-setup) — $50/mo
- [Claude Code only](https://aistack.sh/stack/ship-code-claude-code) — $50/mo
- [Ship code with AI](https://aistack.sh/stack/ship-code-with-ai) — $50/mo

---

From the aistack.sh changelog: https://aistack.sh/changelog
