Notification API
January 4, 2026 ยท View on GitHub
Available when inheriting from ClaudeHooks::Notification:
Input Helpers
Input helpers to access the data provided by Claude Code through STDIN.
| Method | Description |
|---|---|
message | Get the notification message content |
notification_message | Alias for message |
notification_type | Get the notification type: 'permission_prompt', 'idle_prompt', 'auth_success', 'elicitation_dialog' |
Hook State Helpers
Notifications are outside facing and do not have any specific state to modify.
๐ Shared hook state methods
Output Helpers
Output helpers provide access to the hook's output data and helper methods for working with the output state. Notifications don't have any specific hook state and thus doesn't have any specific output helpers.
Hook Exit Codes
| Exit Code | Behavior |
|---|---|
exit 0 | Operation continues Logged to debug only ( --debug) |
exit 1 | Non-blocking error Logged to debug only ( --debug) |
exit 2 | N/A Logged to debug only ( --debug) |