← ClaudeAtlas

askit-build-hooklisted

Creates and improves event-driven hooks (Advanced tier) for a plugin to the Advanced Skill Library Standard. Use when you need to add a hook, enforce a guard on a tool or session event, inject context, or document a hook's event, scope, and failure behavior.
product-on-purpose/agent-skills-toolkit · ★ 0 · Web & Frontend · score 75
Install: claude install-skill product-on-purpose/agent-skills-toolkit
# askit-build-hook ## Purpose Author a plugin's hooks: event-driven enforcement or context injection (Standard sec 3.5). Hooks are an Advanced-tier capability. Two modes: `create` scaffolds a hook and its registration; `improve` raises an existing hook toward the bar (documentation, idempotency, actionable block messages). The hook SKILL is portable; what it authors is primarily a Claude capability (31 events) with a smaller Codex event set. Authoring depth is in [references/authoring-hooks.md](references/authoring-hooks.md). Follows the shared builder contract ([../../docs/reference/builder-pattern.md](../../docs/reference/builder-pattern.md)). ## When to use When the user asks to add, scaffold, author, or improve a hook (a PreToolUse / PostToolUse / Stop / SessionStart guard, a context injector, or any event-driven automation) for a plugin. ## create mode 1. Brief interview: the event (for example PreToolUse), the trigger or matcher, the hook type (`command` / `http` / `mcp_tool` / `prompt` / `agent`), the scope (what it guards or injects), and the failure behavior (fail-safe block vs warn). Skip the interview if these are in context. 2. Author the hook and its registration. A plugin registers hooks in `hooks/hooks.json` using `${CLAUDE_PLUGIN_ROOT}`; copy `templates/hooks.json` if none exists. Document the event, trigger, scope, and failure behavior (Standard sec 3.5 MUST). 3. For a blocking hook (for example a PreToolUse deny), write an ACTIONABLE message that states w