> ## 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.

# Basic Client Usage

> Connect to an AgentOS instance and inspect its agents, teams, and workflows

**1. Create a Python file**

```python basic_client.py theme={null}
import asyncio

from agno.client import AgentOSClient


async def main():
    # Connect to AgentOS
    client = AgentOSClient(base_url="http://localhost:7777")

    # Get AgentOS configuration
    config = await client.aget_config()
    print(f"Connected to: {config.name or config.os_id}")
    print(f"Available agents: {[a.id for a in (config.agents or [])]}")
    print(f"Available teams: {[t.id for t in (config.teams or [])]}")
    print(f"Available workflows: {[w.id for w in (config.workflows or [])]}")

    # Get details about a specific agent
    if config.agents:
        agent_id = config.agents[0].id
        agent = await client.aget_agent(agent_id)
        print("\nAgent Details:")
        print(f"  Name: {agent.name}")
        print(f"  Model: {agent.model}")
        print(f"  Tools: {len(agent.tools or [])}")


if __name__ == "__main__":
    asyncio.run(main())
```

<Snippet file="create-venv-step.mdx" />

**2. Install dependencies**

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

**3. Export your OpenAI API key**

```bash Mac/Linux theme={null}
export OPENAI_API_KEY="your_openai_api_key_here"
```

```bash Windows theme={null}
$Env:OPENAI_API_KEY="your_openai_api_key_here"
```

**4. Start an AgentOS Server**

Start the [client example server](https://agno-v2.mintlify.site/examples/agent-os/python-client/-server.md) on port 7777. It registers the agents, team, and workflow used by these client examples.

**5. Run the Client**

```bash Mac theme={null}
python basic_client.py
```

```bash Windows theme={null}
python basic_client.py
```


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