hook-development

Originally fromovachiever/droid-tings
Installation
Summary

Event-driven automation for Claude Code plugins using prompt-based and command hooks.

  • Supports 9 hook events (PreToolUse, PostToolUse, Stop, SubagentStop, UserPromptSubmit, SessionStart, SessionEnd, PreCompact, Notification) for validation, policy enforcement, and workflow automation
  • Prompt-based hooks use LLM reasoning for context-aware decisions; command hooks execute bash scripts for deterministic checks
  • Includes matchers for filtering by tool name (exact, regex, wildcard) and parallel hook execution across matching events
  • Provides structured JSON input/output format, environment variables like ${CLAUDE_PLUGIN_ROOT} for portability, and security best practices for input validation and path safety
  • Hooks load at session start; configuration changes require restarting Claude Code
SKILL.md

Hook Development for Claude Code Plugins

Overview

Hooks are event-driven automation scripts that execute in response to Claude Code events. Use hooks to validate operations, enforce policies, add context, and integrate external tools into workflows.

Key capabilities:

  • Validate tool calls before execution (PreToolUse)
  • React to tool results (PostToolUse)
  • Enforce completion standards (Stop, SubagentStop)
  • Load project context (SessionStart)
  • Automate workflows across the development lifecycle

Hook Types

Prompt-Based Hooks (Recommended)

Use LLM-driven decision making for context-aware validation:

Related skills

More from anthropics/claude-plugins-official

Installs
2.4K
GitHub Stars
19.2K
First Seen
Feb 5, 2026