Follow Discord
Sweep 22 Oct 2026 · 21:04Z Build v2.1.309 528 read Stable v2.1.308 Latest v2.1.309 Next v2.1.309 Feeds RSS JSON llms.txt llms-full.txt Unofficial

Claude Code v2.0.36 ·

Session Hooks Infrastructure

Entry
JSON All of v2.0.36
EntryKind: in v2.0.36,
ChangesSection of the release

What: New architecture for temporary, session-scoped hooks that automatically clean up when sessions end How it works:

  • Session hooks are stored separately from user settings (sessionHooks field in app state at line 141240)
  • Automatically cleared on session end to prevent accumulation
  • Support callback functions (onMatch) for programmatic responses
  • Cannot be removed through settings UI (protected at diff lines 2057-2059)

Details:

  • Three new management functions:
  • wB1() at line 457341 - Retrieves session hooks for a specific session
  • ll2() at line 457356 - Finds and returns matching hook callbacks
  • il2() at line 457367 - Clears all hooks for a session
  • Session hooks are merged with permanent hooks at execution time (merge logic in nl2() at line 457391)
  • Hooks are marked with source: "sessionHook" to distinguish from settings-based hooks
  • Designed for plugins, agents, and temporary automation without polluting user settings
  • Evidence: State initialization at line 141240, management functions at lines 457341-457367, integration in nl2() at lines 457391-457413

See this entry in the whole of v2.0.36 →

Feedback