Quickstarts
Get started with Dapr Agents through practical step-by-step examples
The Dapr Agents quickstarts demonstrate how to use Dapr Agents to build applications with LLM-powered autonomous agents and event-driven workflows. The quickstarts are a single progressive tutorial that builds from basic LLM calls up through durable agents, workflows, multi-agent orchestration, and observability.
Before you begin
- Set up your local Dapr environment.
- Install uv (Python package manager used by the quickstarts).
- Install Ollama for local LLM inference (default), or obtain an OpenAI API key.
Dapr Agents Fundamentals
The Dapr Agents Fundamentals quickstart covers the entire Dapr Agents programming model in a single directory of numbered Python scripts. Each step builds on the previous one.
| Step | File | What You’ll Learn |
|---|---|---|
| 1 | 01_llm_client.py | Call an LLM via the Dapr Conversation API using DaprChatClient |
| 2 | 02_durable_agent_http.py | Run a durable agent backed by Dapr Workflows, exposed over HTTP |
| 3 | 03_durable_agent_pubsub.py | Trigger a durable agent via pub/sub instead of HTTP |
| 4 | 04_workflow_llm.py | Build a deterministic Dapr Workflow that calls LLMs as activities |
| 5 | 05_workflow_agents.py | Orchestrate multiple specialized agents as child workflows |
| 6 | 06_durable_agent_tracing.py | Enable distributed tracing for agents and workflows with Zipkin |
| 7 | 07_durable_agent_hot_reload.py | Hot-reload agent configuration at runtime via Dapr Configuration Store |
See the quickstarts README for full setup instructions including LLM configuration and prerequisites.
Examples
The Dapr Agents examples directory contains more advanced and feature-specific scenarios that complement the quickstarts:
| Example | What You’ll Learn |
|---|---|
| LLM Call – Dapr Chat Client | Text generation, LLM provider swapping, resilience, and PII obfuscation via DaprChatClient |
| LLM Call – OpenAI Client | Chat completion, structured outputs, audio, and embeddings using the native OpenAI client. Also available for ElevenLabs, Hugging Face, and NVIDIA. |
| Standalone Agent Tool Call | Build conversational agents with tools using DurableAgent with AgentRunner.run |
| Durable Agent Tool Call | Upgrade to durable workflow-backed agents with AgentRunner.run/subscribe/serve |
| LLM-Based Workflows | Deterministic multi-step workflows using LLM activities (chaining, parallelization, routing) |
| Agent-Based Workflows | Orchestrate agent activities inside a Dapr Workflow |
| Message Router Workflow | Use @message_router to bind a workflow to a Dapr pub/sub topic |
| Multi-Agent Workflows | Lord of the Rings themed event-driven multi-agent system with LLM, random, and round-robin orchestration strategies |
| Multi-Agent Workflows on Kubernetes | Deploy and orchestrate multi-agent systems in Kubernetes |
| Document Agent with Chainlit | Conversational agent that uploads and learns unstructured documents with long-term memory |
| MCP Client – SSE | Connect to a remote MCP server over Server-Sent Events |
| MCP Client – stdio | Connect to a local MCP server over stdio |
| MCP Client – Streamable HTTP | Connect to an MCP server via the Streamable HTTP transport |
| Data Agent with MCP and Chainlit | Natural language queries over a Postgres database using MCP with a ChatGPT-like UI |
| Agents as Activities with Observability | Trace agent activities end-to-end with OpenTelemetry and Zipkin |
| Agents as Tools | Invoke other DurableAgent instances—and agents from other frameworks—as child workflow tools |
| Durable Agent Hot-Reload | Hot-reload agent persona and LLM settings at runtime without restarting |