aparavi-dtc-sdk


Nameaparavi-dtc-sdk JSON
Version 1.0.0 PyPI version JSON
download
home_pagehttps://dtc-dev.aparavi.com
SummaryPython SDK for Aparavi Data Toolchain API
upload_time2025-07-31 00:39:27
maintainerNone
docs_urlNone
authorAparavi
requires_python>=3.8
licenseNone
keywords aparavi dtc data toolchain api sdk web services
VCS
bugtrack_url
requirements requests colorama
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # Aparavi Data Toolchain SDK

A Python SDK for interacting with the Aparavi Web Services API. This SDK provides a clean, type-safe interface for validating pipelines, executing tasks, monitoring status, and managing webhooks with the Aparavi platform.

---

## Description

This SDK simplifies integration with Aparavi's data processing pipelines by providing:

* `validate_pipeline`: Validates a pipeline structure against Aparavi's backend to ensure it is correctly formed.
* `execute_pipeline`: Submits a pipeline for execution on the Aparavi platform.
* `get_pipeline_status`: Fetches the current execution status of a pipeline task.
* `teardown_pipeline`: Gracefully ends a running pipeline task.
* `send_payload_to_webhook`: Sends file(s) to a running webhook-based pipeline.
* `execute_pipeline_workflow`: Performs a full end-to-end execution lifecycle for a pipeline.
* `get_version`: Fetches the current version of the Aparavi API/backend.

Perfect for data engineers, analysts, and developers building automated data processing workflows.

---

## Setup

1. **Get your credentials:**
- Obtain your API key from the [Aparavi console](https://core.aparavi.com/usage/)
- Note your API base URL (e.g. `https://eaas.aparavi.com/`)

2. **Install package:**
   ```bash
   pip install aparavi-dtc-sdk
   ```

3. **Create .env file:**
   
   **Linux/macOS:**
   ```bash
   touch .env
   ```
   
   **Windows:**
   ```cmd
   type nul > .env
   ```

### Env file

```env
APARAVI_API_KEY=aparavi-dtc-api-key
APARAVI_BASE_URL=https://eaas.aparavi.com/
```

---

## Quick Start

```python
import os

from dotenv import load_dotenv
from aparavi_dtc_sdk import AparaviClient

load_dotenv()

client = AparaviClient(
    base_url=os.getenv("APARAVI_BASE_URL"),
    api_key=os.getenv("APARAVI_API_KEY")
)

result = client.execute_pipeline_workflow(
    pipeline="./pipeline_config.json",
    file_glob="./*.png"
)

print(result)
```

### Pre Built Pipelines

Available pre-built pipeline configurations:
- `AUDIO_AND_SUMMARY`: Processes audio content and produces both a transcription and a concise summary. 
- `SIMPLE_AUDIO_TRANSCRIBE`: Processes audio files and returns transcriptions of spoken content. 
- `SIMPLE_PARSER`: Extracts and processes metadata and content from uploaded documents. 

```python
import os

from dotenv import load_dotenv
from aparavi_dtc_sdk import AparaviClient, PredefinedPipelines # Import PredefinedPipelines enum

load_dotenv()

client = AparaviClient(
    base_url=os.getenv("APARAVI_BASE_URL"),
    api_key=os.getenv("APARAVI_API_KEY")
)

result = client.execute_pipeline_workflow(
    pipeline=PredefinedPipelines.SIMPLE_AUDIO_TRANSCRIBE, # Specify PredefinedPipelines
    file_glob="./audio/*.mp3"
)

print(result)
```

### Power user quick start

```python
import json
import os

from dotenv import load_dotenv
from aparavi_dtc_sdk import AparaviClient

load_dotenv()

client = AparaviClient(
    base_url=os.getenv("APARAVI_BASE_URL"),
    api_key=os.getenv("APARAVI_API_KEY")
)

try:
    validation_result = client.validate_pipeline("pipeline_config.json")
except Exception as e:
    print(f"Validation failed: {e}")

try:
    start_result = client.execute_pipeline(pipeline_config, name="my-task")
    if start_result.status == "OK":
        token = start_result.data["token"]
        task_type = start_result.data["type"]

        status_result = client.get_pipeline_status(token=token, task_type=task_type)

        end_result = client.teardown_pipeline(token=token, task_type=task_type)

except Exception as e:
    print(f"Task operation failed: {e}")
```

---

## Development

### Setting up for development

```bash
# Install in development mode
pip install -e ".[dev]"

# Find package Install
pip list | grep aparavi

# Show package info
pip show aparavi-dtc-sdk

# Run linting
flake8 aparavi-dtc-sdk/
black aparavi-dtc-sdk/
mypy aparavi-dtc-sdk/
```

### Running Tests

```bash
pytest tests/
```

## Support

For problems and questions, please open an issue on the [GitHub repository](https://github.com/AparaviSoftware/aparavi-dtc-sdk/issues).

---

## Authors

**Joshua D. Phillips**  
[github.com/joshuadarron](https://github.com/joshuadarron)

Contributions welcome — feel free to submit a PR or open an issue!


            

Raw data

            {
    "_id": null,
    "home_page": "https://dtc-dev.aparavi.com",
    "name": "aparavi-dtc-sdk",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": null,
    "keywords": "aparavi dtc data toolchain api sdk web services",
    "author": "Aparavi",
    "author_email": "support@aparavi.com",
    "download_url": "https://files.pythonhosted.org/packages/54/56/bd8564c9ad501ef2f6d5db52d1a80ced5687b1ab74f12c4bf2c85d8591cd/aparavi_dtc_sdk-1.0.0.tar.gz",
    "platform": null,
    "description": "# Aparavi Data Toolchain SDK\r\n\r\nA Python SDK for interacting with the Aparavi Web Services API. This SDK provides a clean, type-safe interface for validating pipelines, executing tasks, monitoring status, and managing webhooks with the Aparavi platform.\r\n\r\n---\r\n\r\n## Description\r\n\r\nThis SDK simplifies integration with Aparavi's data processing pipelines by providing:\r\n\r\n* `validate_pipeline`: Validates a pipeline structure against Aparavi's backend to ensure it is correctly formed.\r\n* `execute_pipeline`: Submits a pipeline for execution on the Aparavi platform.\r\n* `get_pipeline_status`: Fetches the current execution status of a pipeline task.\r\n* `teardown_pipeline`: Gracefully ends a running pipeline task.\r\n* `send_payload_to_webhook`: Sends file(s) to a running webhook-based pipeline.\r\n* `execute_pipeline_workflow`: Performs a full end-to-end execution lifecycle for a pipeline.\r\n* `get_version`: Fetches the current version of the Aparavi API/backend.\r\n\r\nPerfect for data engineers, analysts, and developers building automated data processing workflows.\r\n\r\n---\r\n\r\n## Setup\r\n\r\n1. **Get your credentials:**\r\n- Obtain your API key from the [Aparavi console](https://core.aparavi.com/usage/)\r\n- Note your API base URL (e.g. `https://eaas.aparavi.com/`)\r\n\r\n2. **Install package:**\r\n   ```bash\r\n   pip install aparavi-dtc-sdk\r\n   ```\r\n\r\n3. **Create .env file:**\r\n   \r\n   **Linux/macOS:**\r\n   ```bash\r\n   touch .env\r\n   ```\r\n   \r\n   **Windows:**\r\n   ```cmd\r\n   type nul > .env\r\n   ```\r\n\r\n### Env file\r\n\r\n```env\r\nAPARAVI_API_KEY=aparavi-dtc-api-key\r\nAPARAVI_BASE_URL=https://eaas.aparavi.com/\r\n```\r\n\r\n---\r\n\r\n## Quick Start\r\n\r\n```python\r\nimport os\r\n\r\nfrom dotenv import load_dotenv\r\nfrom aparavi_dtc_sdk import AparaviClient\r\n\r\nload_dotenv()\r\n\r\nclient = AparaviClient(\r\n    base_url=os.getenv(\"APARAVI_BASE_URL\"),\r\n    api_key=os.getenv(\"APARAVI_API_KEY\")\r\n)\r\n\r\nresult = client.execute_pipeline_workflow(\r\n    pipeline=\"./pipeline_config.json\",\r\n    file_glob=\"./*.png\"\r\n)\r\n\r\nprint(result)\r\n```\r\n\r\n### Pre Built Pipelines\r\n\r\nAvailable pre-built pipeline configurations:\r\n- `AUDIO_AND_SUMMARY`: Processes audio content and produces both a transcription and a concise summary. \r\n- `SIMPLE_AUDIO_TRANSCRIBE`: Processes audio files and returns transcriptions of spoken content. \r\n- `SIMPLE_PARSER`: Extracts and processes metadata and content from uploaded documents. \r\n\r\n```python\r\nimport os\r\n\r\nfrom dotenv import load_dotenv\r\nfrom aparavi_dtc_sdk import AparaviClient, PredefinedPipelines # Import PredefinedPipelines enum\r\n\r\nload_dotenv()\r\n\r\nclient = AparaviClient(\r\n    base_url=os.getenv(\"APARAVI_BASE_URL\"),\r\n    api_key=os.getenv(\"APARAVI_API_KEY\")\r\n)\r\n\r\nresult = client.execute_pipeline_workflow(\r\n    pipeline=PredefinedPipelines.SIMPLE_AUDIO_TRANSCRIBE, # Specify PredefinedPipelines\r\n    file_glob=\"./audio/*.mp3\"\r\n)\r\n\r\nprint(result)\r\n```\r\n\r\n### Power user quick start\r\n\r\n```python\r\nimport json\r\nimport os\r\n\r\nfrom dotenv import load_dotenv\r\nfrom aparavi_dtc_sdk import AparaviClient\r\n\r\nload_dotenv()\r\n\r\nclient = AparaviClient(\r\n    base_url=os.getenv(\"APARAVI_BASE_URL\"),\r\n    api_key=os.getenv(\"APARAVI_API_KEY\")\r\n)\r\n\r\ntry:\r\n    validation_result = client.validate_pipeline(\"pipeline_config.json\")\r\nexcept Exception as e:\r\n    print(f\"Validation failed: {e}\")\r\n\r\ntry:\r\n    start_result = client.execute_pipeline(pipeline_config, name=\"my-task\")\r\n    if start_result.status == \"OK\":\r\n        token = start_result.data[\"token\"]\r\n        task_type = start_result.data[\"type\"]\r\n\r\n        status_result = client.get_pipeline_status(token=token, task_type=task_type)\r\n\r\n        end_result = client.teardown_pipeline(token=token, task_type=task_type)\r\n\r\nexcept Exception as e:\r\n    print(f\"Task operation failed: {e}\")\r\n```\r\n\r\n---\r\n\r\n## Development\r\n\r\n### Setting up for development\r\n\r\n```bash\r\n# Install in development mode\r\npip install -e \".[dev]\"\r\n\r\n# Find package Install\r\npip list | grep aparavi\r\n\r\n# Show package info\r\npip show aparavi-dtc-sdk\r\n\r\n# Run linting\r\nflake8 aparavi-dtc-sdk/\r\nblack aparavi-dtc-sdk/\r\nmypy aparavi-dtc-sdk/\r\n```\r\n\r\n### Running Tests\r\n\r\n```bash\r\npytest tests/\r\n```\r\n\r\n## Support\r\n\r\nFor problems and questions, please open an issue on the [GitHub repository](https://github.com/AparaviSoftware/aparavi-dtc-sdk/issues).\r\n\r\n---\r\n\r\n## Authors\r\n\r\n**Joshua D. Phillips**  \r\n[github.com/joshuadarron](https://github.com/joshuadarron)\r\n\r\nContributions welcome \u2014 feel free to submit a PR or open an issue!\r\n\r\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "Python SDK for Aparavi Data Toolchain API",
    "version": "1.0.0",
    "project_urls": {
        "Bug Reports": "https://github.com/AparaviSoftware/aparavi-dtc-sdk/issues",
        "Homepage": "https://dtc-dev.aparavi.com",
        "Source": "https://github.com/AparaviSoftware/aparavi-dtc-sdk"
    },
    "split_keywords": [
        "aparavi",
        "dtc",
        "data",
        "toolchain",
        "api",
        "sdk",
        "web",
        "services"
    ],
    "urls": [
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "99334a767dda54261a16adefb18707904f14e479bdb0d8bcd4ac7868af7c1b44",
                "md5": "5fdb2f80a4c9b17e7d3debd97e6c40d4",
                "sha256": "15d88f3200a9c9b093bf5d1d9179bf8482a3a1f4dd8e0272e53742cdd595bd78"
            },
            "downloads": -1,
            "filename": "aparavi_dtc_sdk-1.0.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "5fdb2f80a4c9b17e7d3debd97e6c40d4",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 14467,
            "upload_time": "2025-07-31T00:39:26",
            "upload_time_iso_8601": "2025-07-31T00:39:26.143829Z",
            "url": "https://files.pythonhosted.org/packages/99/33/4a767dda54261a16adefb18707904f14e479bdb0d8bcd4ac7868af7c1b44/aparavi_dtc_sdk-1.0.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "5456bd8564c9ad501ef2f6d5db52d1a80ced5687b1ab74f12c4bf2c85d8591cd",
                "md5": "b86d463027d205388f8927d1ed542c69",
                "sha256": "867739a3a06879497d998dcee2d2e140e2d7ae08716a230e0cae253a2e6ed987"
            },
            "downloads": -1,
            "filename": "aparavi_dtc_sdk-1.0.0.tar.gz",
            "has_sig": false,
            "md5_digest": "b86d463027d205388f8927d1ed542c69",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 13807,
            "upload_time": "2025-07-31T00:39:27",
            "upload_time_iso_8601": "2025-07-31T00:39:27.527255Z",
            "url": "https://files.pythonhosted.org/packages/54/56/bd8564c9ad501ef2f6d5db52d1a80ced5687b1ab74f12c4bf2c85d8591cd/aparavi_dtc_sdk-1.0.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-07-31 00:39:27",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "AparaviSoftware",
    "github_project": "aparavi-dtc-sdk",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "requirements": [
        {
            "name": "requests",
            "specs": []
        },
        {
            "name": "colorama",
            "specs": []
        }
    ],
    "lcname": "aparavi-dtc-sdk"
}
        
Elapsed time: 1.83884s