> ## Documentation Index
> Fetch the complete documentation index at: https://agno-v2.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Run Your First AgentOS

> Serve an agent through FastAPI with persistent sessions and a local REST API.

Save the following code to `agno_assist.py`:

```python agno_assist.py theme={null}
from agno.agent import Agent
from agno.db.sqlite import SqliteDb
from agno.models.anthropic import Claude
from agno.os import AgentOS

db = SqliteDb(db_file="agno.db")

agent = Agent(
    name="Agno Assist",
    model=Claude(id="claude-sonnet-4-5"),
    db=db,
)

agent_os = AgentOS(agents=[agent], db=db)
app = agent_os.get_app()

if __name__ == "__main__":
    agent_os.serve(app="agno_assist:app", reload=True)
```

> [!TIP]
>
> Your agent now has a FastAPI API and persistent sessions.

## Run it locally

**1. Set up your virtual environment**

```bash Mac theme={null}
uv venv --python 3.12
source .venv/bin/activate
```

```bash Windows theme={null}
uv venv --python 3.12
.venv\Scripts\activate
```

**2. Install dependencies**

```bash theme={null}
uv pip install -U 'agno[os]' anthropic
```

**3. Export your Anthropic API key**

```bash Mac theme={null}
export ANTHROPIC_API_KEY=sk-***
```

```powershell Windows theme={null}
$env:ANTHROPIC_API_KEY = "sk-***"
```

**4. Run your AgentOS**

```bash theme={null}
python agno_assist.py
```

Your AgentOS is now running at `http://localhost:7777`.

| Endpoint | Description |
| - | - |
| `http://localhost:7777/health` | Runtime health check |
| `http://localhost:7777/docs` | Interactive API documentation |
| `http://localhost:7777/info` | Runtime information and registered component counts |
| `http://localhost:7777/config` | Registered components and runtime capabilities |

Use `http://localhost:7777` as the endpoint when connecting this runtime to the Control Plane.

This local quickstart runs without authentication. Configure [Security & Auth](https://agno-v2.mintlify.site/agent-os/security/overview.md) before deploying it.

## Next steps

| Task | Guide |
| - | - |
| Manage and monitor the runtime | [Connect Your AgentOS](https://agno-v2.mintlify.site/agent-os/connect-your-os.md) |
| Call agents through REST | [Using the API](https://agno-v2.mintlify.site/agent-os/using-the-api.md) |
| Explore every endpoint | [AgentOS API reference](https://agno-v2.mintlify.site/reference-api/overview.md) |
| Protect the runtime | [Security & Auth](https://agno-v2.mintlify.site/agent-os/security/overview.md) |


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.