Metadata-Version: 2.4
Name: eyriehq-sdk
Version: 0.1.1
Summary: Python SDK for the EyrieHQ observability platform
Project-URL: Homepage, https://eyriehq.com
Project-URL: Documentation, https://docs.eyriehq.com/sdk/python
Author-email: EyrieHQ <support@eyriehq.com>
License-Expression: LicenseRef-Proprietary
Keywords: eyriehq,logs,metrics,monitoring,observability,traces
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: Other/Proprietary 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 :: System :: Monitoring
Requires-Python: >=3.9
Requires-Dist: httpx>=0.24.0
Provides-Extra: dev
Requires-Dist: pytest-httpx>=0.21; extra == 'dev'
Requires-Dist: pytest>=7.0; extra == 'dev'
Description-Content-Type: text/markdown

# EyrieHQ Python SDK

Python client library for the [EyrieHQ](https://eyriehq.com) observability platform.

## Installation

```bash
pip install eyriehq-sdk
```

## Quick Start

```python
from eyrie import EyrieClient

client = EyrieClient(
    base_url="https://api.eyriehq.example.com",     # Backend URL for queries
    collector_url="https://collector.example.com",   # Collector URL for push
    api_key="iw_sk_a3f8b2c1...",                    # API key for push auth
    email="admin@example.com",                       # Backend login for queries
    password="secret",                               # Backend login for queries
)

# Push traces (uses API key via X-API-Key header)
client.traces.push(spans=[
    {
        "name": "http.request",
        "start_time": "2026-01-01T00:00:00Z",
        "end_time": "2026-01-01T00:00:01Z",
    }
])

# Push metrics
client.metrics.push(metrics=[
    {"name": "cpu.usage", "value": 72.5, "type": "gauge"}
])

# Push logs
client.logs.push(logs=[
    {"body": "Request processed successfully", "severity": "INFO"}
])

# Query traces (uses email/password session)
traces = client.traces.search(service="api-gateway")

# Health check
status = client.health()
```

## Authentication

The SDK uses two authentication mechanisms:

- **Push (to collector):** API key via `X-API-Key` header. Generate your API key in **Admin > Observability** in the EyrieHQ UI.
- **Query (from backend):** Email/password session cookies. The SDK handles login automatically on the first query.

## License

Proprietary. See LICENSE for details.
