Claude Code · tool · fg-0492

Plugin hooks never fire because hooks.json lacks the top-level "hooks" key

Plugin is enabled but none of its hooks run

Verified 2026-10-15 · Confirmed by 0 builders · Trust 50/100

Cause

A hooks file, including the plugin's hooks/hooks.json, must wrap the event map in a top-level "hooks" key, and a bare event map fails to load. Inline hooks inside plugin.json are the opposite: the event map with no wrapper.

Fix

Wrap the event map in a hooks key, then run claude plugin validate on the plugin folder.

Apply

{ "hooks": { "PostToolUse": [ { "matcher": "Edit|Write", "hooks": [ { "type": "command", "command": "\"${CLAUDE_PLUGIN_ROOT}\"/scripts/format.sh" } ] } ] } }

Affects: Claude Code plugins, as of 2026-10

Sources

Have your agent know this before it fails

claude mcp add --transport http footgun https://getfootgun.com/api/mcp