Metadata-Version: 2.4
Name: dequa-sdk
Version: 1.0.0
Summary: Native Python SDK & Integrations for Dequa ETL Data Quality Engine
Author-email: Dequa ETL Team <support@dequa-etl.io>
License-Expression: Apache-2.0
Project-URL: Homepage, https://github.com/dequa-etl/dequa-etl-tool
Project-URL: Bug Tracker, https://github.com/dequa-etl/dequa-etl-tool/issues
Project-URL: Documentation, https://github.com/dequa-etl/dequa-etl-tool#readme
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Operating System :: OS Independent
Classifier: Topic :: Database
Classifier: Topic :: Software Development :: Quality Assurance
Requires-Python: >=3.9
Description-Content-Type: text/markdown
Requires-Dist: requests>=2.28.0
Requires-Dist: pandas>=1.5.0
Requires-Dist: duckdb>=0.9.0
Requires-Dist: pydantic>=2.0.0
Provides-Extra: airflow
Requires-Dist: apache-airflow>=2.4.0; extra == "airflow"
Provides-Extra: dbt
Requires-Dist: dbt-core>=1.5.0; extra == "dbt"
Provides-Extra: all
Requires-Dist: apache-airflow>=2.4.0; extra == "all"
Requires-Dist: dbt-core>=1.5.0; extra == "all"

# ⚡ Dequa Python SDK

The official Python client and data validation SDK for **Dequa ETL**.

[![PyPI](https://img.shields.io/pypi/v/dequa-sdk.svg)](https://pypi.org/project/dequa-sdk/)
[![License: Apache 2.0](https://img.shields.io/badge/License-Apache_2.0-blue.svg)](https://opensource.org/licenses/Apache-2.0)

---

## 📦 Installation

```bash
pip install dequa-sdk
```

With optional integrations:
```bash
# Airflow integration
pip install dequa-sdk[airflow]

# dbt Core integration
pip install dequa-sdk[dbt]
```

---

## 🚀 Quick Usage

### 1. Vectorized In-Memory DataFrame Reconciliation

```python
import pandas as pd
from dequa_sdk import validate

source_df = pd.read_csv("bronze_orders.csv")
target_df = pd.read_csv("gold_orders.csv")

# Run zero-config reconciliation
report = validate(
    source=source_df,
    target=target_df,
    key_columns=["order_id"],
    compare_columns=["amount", "status"]
)

print(report.summary())
if report.has_discrepancies():
    print("Mismatched records found:", report.value_mismatches)
```

---

### 2. Airflow DAG Gating Operator

```python
from airflow import DAG
from dequa_sdk.integrations.airflow import DequaCheckOperator
from datetime import datetime

with DAG("daily_orders_pipeline", start_date=datetime(2026, 1, 1)) as dag:
    assert_orders = DequaCheckOperator(
        task_id="assert_orders_reconciliation",
        pipeline_id=1,
        dequa_url="http://dequa-backend:8000",
        fail_on_mismatch=True
    )
```

---

### 3. dbt Manifest Parser

```python
from dequa_sdk.integrations.dbt import DbtManifestParser

parser = DbtManifestParser(manifest_path="target/manifest.json")
models = parser.extract_models()

for model in models:
    config = parser.generate_pipeline_config(
        model_name=model["model_name"],
        source_conn_id=1,
        target_conn_id=2
    )
```
