Metadata-Version: 2.4
Name: poe
Version: 0.1.0
Summary: Python client for the Poe API (api.poe.com)
Project-URL: Homepage, https://github.com/poe-platform/poe-python
Project-URL: Repository, https://github.com/poe-platform/poe-python
Project-URL: Documentation, https://developer.poe.com
Project-URL: Issues, https://github.com/poe-platform/poe-python/issues
Author-email: Poe Platform <support@poe.com>
License-Expression: MIT
License-File: LICENSE
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Requires-Python: >=3.9
Requires-Dist: httpx>=0.25.0
Provides-Extra: dev
Requires-Dist: pytest-asyncio>=0.21; extra == 'dev'
Requires-Dist: pytest>=7.0; extra == 'dev'
Description-Content-Type: text/markdown

# poe

Official Python client for the [Poe](https://poe.com) chat completions API.

## Installation

```bash
pip install poe
```

## Quick Start

```python
from poe import PoeClient

client = PoeClient(api_key="your-poe-api-key")

# Simple chat
response = client.chat("What is Python?", model="GPT-4o")
print(response["choices"][0]["message"]["content"])
```

## Streaming

```python
for chunk in client.stream("Tell me a story", model="GPT-4o"):
    print(chunk, end="", flush=True)
```

## Options

```python
client = PoeClient(
    api_key="your-key",
    timeout=120.0,       # request timeout in seconds
)

response = client.chat(
    "Explain quantum computing",
    model="GPT-4o",
    temperature=0.7,
    max_tokens=1024,
    system_prompt="You are a helpful physics teacher.",
)
```

## Context Manager

```python
with PoeClient(api_key="your-key") as client:
    resp = client.chat("Hello!")
    print(resp["choices"][0]["message"]["content"])
```

## API Key

Get your API key from [poe.com/api_key](https://poe.com/api_key).

## License

MIT
