> ## Documentation Index
> Fetch the complete documentation index at: https://docs.darwin.so/llms.txt
> Use this file to discover all available pages before exploring further.

# Python SDK

> Use the official synchronous or asynchronous Darwin client in Python.

## Install

```bash theme={null}
pip install darwin-sdk
```

## Synchronous client

```python theme={null}
import os

from darwin_sdk import Darwin

darwin = Darwin(token=os.environ["DARWIN_API_KEY"])
turn = darwin.agent.create_message(
    content="Help me prepare a private goal.",
)
```

## Asynchronous client

```python theme={null}
import os

from darwin_sdk import AsyncDarwin

darwin = AsyncDarwin(token=os.environ["DARWIN_API_KEY"])
turn = await darwin.agent.create_message(
    content="Summarize my active goals.",
)
```

Both clients use the same reviewed public API. Private production controllers and operator tools are not included.

<Warning>
  Keep the API key on your server. Do not ship it in browser code, mobile bundles, or model-visible prompt text.
</Warning>
