Metadata-Version: 2.3
Name: kolosis-metricflow-sdk
Version: 0.8.0
Summary: MetricFlow SDK - client library and models for interacting with the MetricFlow API
Requires-Dist: pydantic>=2.12.5
Requires-Dist: httpx>=0.28.1
Requires-Dist: dbt-metricflow[dbt-postgres]>=0.10.1
Requires-Python: >=3.13
Description-Content-Type: text/markdown

# kolosis-metricflow-sdk

Python SDK for working with the Kolosis MetricFlow API.

## Install

```bash
uv add kolosis-metricflow-sdk
```

## Configure Authentication

Client IDs are slug-based (lowercase letters, numbers, and hyphens only).

```python
from kolosis_metricflow_sdk.client.client_config import MetricflowClientSettings

settings = MetricflowClientSettings(
    base_url="https://metrics-api.example.com",
    api_version="v1",
    client_id="analytics-team",
    client_secret="your-client-secret",
)
```

You can also load authentication from environment variables:

- `METRICFLOW_CLIENT_ID`
- `METRICFLOW_CLIENT_SECRET`

## Create an HTTP Client

```python
from kolosis_metricflow_sdk.client.metrics_api_client import create_metrics_api_client

client = create_metrics_api_client(settings=settings)
```

## Models

The SDK includes Pydantic models used by the API:

- `MetricQueryParams`
- `MetricQueryResponse`
- `CatalogMetricsResponse`
- `CatalogDimensionsResponse`
