This page covers the
AgentEventBus β a publish/subscribe hook system for agent lifecycle (start, message, complete, error). For the per-turn structured event stream used to render tool calls and text deltas in real time, see Streaming Events.Quick Start
1
Simple Usage
2
With Configuration
User Interaction Flow
Configuration Levels
Event Types
API Reference
Events Module
Complete events module
AgentEventBus
Event bus class
Best Practices
Log important events
Log important events
Track tool calls and errors for debugging.
Use wildcards sparingly
Use wildcards sparingly
Subscribe to specific events for better performance.
Handle errors
Handle errors
Always listen for βerrorβ events in production.
Related
Hooks
Lifecycle hooks
PubSub
Publish-subscribe

