serve().
Quick Integration (AgentRouter)
The easiest way to serve an agent is using the AgentRouter. This adds a standard set of endpoints (/chat, /invoke, /state) to your application.
Basic Chat Endpoint (Manual)
If you only need a simple chat endpoint and don’t want the full agent API:Streaming with SSE
UseStreamingResponse for real-time streaming.
Advanced: Custom Agent Integration
IfAgentRouter doesn’t fit your needs, you can integrate the Agent class manually.