Agent Runtime
Run agents, teams, and workflows using FastAPI.
AgentOS is the FastAPI for agents. It serves agents as an API, an MCP server, and through chat interfaces like Slack, Telegram, and WhatsApp. This local example serves an agent with session storage, tracing, scheduling, and MCP:
from agno.agent import Agent
from agno.db.sqlite import SqliteDb
from agno.os import AgentOS
from agno.tools.workspace import Workspace
workbench = Agent(
name="Workbench",
model="openai:gpt-5.5",
db=SqliteDb(db_file="workbench.db"), # session storage
tools=[Workspace(".")], # read/write in this directory
add_history_to_context=True, # add past 3 runs to context
)
# Serve via AgentOS, get streaming, session isolation, API endpoints
agent_os = AgentOS(
agents=[workbench],
tracing=True,
scheduler=True,
mcp=True,
db=SqliteDb(db_file="workbench.db"),
)
app = agent_os.get_app()
if __name__ == "__main__":
agent_os.serve(app="workbench:app", reload=True)Install the dependencies, set OPENAI_API_KEY, save the example as workbench.py, and start it:
uv pip install -U "agno[os,mcp,openai]"
export OPENAI_API_KEY="your-api-key"
python workbench.pyOpen http://localhost:7777/docs to inspect the REST API. Workspace(".") exposes local file operations and shell execution; destructive operations require human confirmation by default. Run this example in the directory you want the agent to work in.
AgentOS adds session management, background execution, tracing, evaluations, and opt-in authorization. Configure a durable worker for queued jobs that must survive process restarts.
Build agents, teams, and workflows with the Agno SDK. Run them with AgentOS. Manage and monitor them using the Control Plane.
What the runtime gives you
The runtime covers the ground between your agent code and a production service:
| Concern | How AgentOS handles it |
|---|---|
| HTTP API | Auto-generated endpoints for every registered agent, team, and workflow |
| Persistence | Sessions and enabled memory features persist to your db |
| Streaming | Run endpoints support SSE; tokens and tool calls stream when stream=true |
| MCP server | Expose agents, teams, workflows, and custom tools to MCP clients at /mcp |
| Auth | Set authorization=True and configure a JWT verification key to enforce RBAC scopes |
| Scheduling | Set scheduler=True to poll the database and fire due jobs in process |
| Observability | Set tracing=True to write OpenTelemetry traces to the AgentOS database |
| Interfaces | Slack, Telegram, WhatsApp, A2A, AG-UI |
| Human in the loop | Pause runs for user confirmation, admin approval, or external execution |
Explore
Agent API
Run your agent platform as an API.
MCP Server
Expose agents, teams, workflows, and custom tools to MCP clients.
Agent Storage
Add durability and persistence.
Observability
Tracing, run history, and audit logs in your own database.
Security and Auth
JWT validation, RBAC scopes, and per-request isolation.
Scheduling
In-process cron and multi-step workflows.
Interfaces
Reach users on Slack, Telegram, WhatsApp, A2A, and AG-UI.