Skip to content

Instantly share code, notes, and snippets.

@wulymammoth
Created August 6, 2025 22:24
Show Gist options
  • Select an option

  • Save wulymammoth/8e7eb72e97bea01e7df6704fcc5dc4b9 to your computer and use it in GitHub Desktop.

Select an option

Save wulymammoth/8e7eb72e97bea01e7df6704fcc5dc4b9 to your computer and use it in GitHub Desktop.
Claude Code Hooks
  1. PreToolUse - Before tool execution (can block tools)
  2. PostToolUse - After tool completes successfully
  3. UserPromptSubmit - When user submits a prompt
  4. Stop - When main Claude agent finishes responding
  5. SubagentStop - When a subagent (Task tool) finishes
  6. Notification - When Claude needs permissions or during idle time
  7. PreCompact - Before context compression
  8. SessionStart - When starting/resuming sessions
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment