Metadata-Version: 2.4
Name: ethiack-job-manager
Version: 1.1.3rc1
Summary: Python package for managing jobs using Ethiack's Public API
Author-email: Ethiack <hello@ethiack.com>
License:     MIT License
        
            Copyright (c) Ethiack, S.A.
        
            Permission is hereby granted, free of charge, to any person obtaining a copy
            of this software and associated documentation files (the "Software"), to deal
            in the Software without restriction, including without limitation the rights
            to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
            copies of the Software, and to permit persons to whom the Software is
            furnished to do so, subject to the following conditions:
        
            The above copyright notice and this permission notice shall be included in all
            copies or substantial portions of the Software.
        
            THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
            IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
            FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
            AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
            LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
            OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
            SOFTWARE
        
Project-URL: Homepage, https://ethiack.com
Project-URL: Repository, https://github.com/ethiack/job-manager.git
Project-URL: Issues, https://github.com/ethiack/job-manager/issues
Classifier: Development Status :: 5 - Production/Stable
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3 :: Only
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Requires-Python: >=3.8
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: click>=8
Requires-Dist: python-dotenv
Requires-Dist: pydantic>=2
Requires-Dist: requests
Requires-Dist: rich_click
Requires-Dist: tenacity
Provides-Extra: test
Requires-Dist: pytest; extra == "test"
Requires-Dist: pytest-cov; extra == "test"
Requires-Dist: mypy; extra == "test"
Provides-Extra: dev
Requires-Dist: ethiack-job-manager[test]; extra == "dev"
Provides-Extra: all
Requires-Dist: ethiack-job-manager[test]; extra == "all"
Requires-Dist: ethiack-job-manager[dev]; extra == "all"
Dynamic: license-file

<!-- MARKDOWN LINKS & IMAGES -->

[version-shield]: https://img.shields.io/github/v/release/ethiack/job-manager?style=for-the-badge
[version-url]: https://github.com/ethiack/job-manager/releases/latest

[license-shield]: https://img.shields.io/github/license/ethiack/job-manager?style=for-the-badge
[license-url]: https://raw.githubusercontent.com/ethiack/job-manager/main/LICENSE

[linkedin-shield]: https://img.shields.io/badge/-LinkedIn-black.svg?style=for-the-badge&logo=linkedin&colorB=555
[linkedin-url]: https://linkedin.com/company/ethiack


<!-- README -->
<a name="readme-top"></a>
<div align="center">

<h1>
  <br>
    <img src="https://raw.githubusercontent.com/ethiack/job-manager/main/assets/logo.webp" alt="logo" width="400">
    <br><br>
    Ethiack Job Manager
    <br><br>
</h1>

<h4>Python package for managing jobs using Ethiack's Public API</h4>

[![GitHub Release][version-shield]][version-url]
[![MIT License][license-shield]][license-url]
[![LinkedIn][linkedin-shield]][linkedin-url]

<hr />


</div>

## Introduction

This is Python package and command-line interface (CLI) designed as a wrapper around [Ethiack's Public API](https://api.ethiack.com) ([API docs](https://portal.ethiack.com/docs/api/)). It simplifies the management of jobs by providing convenient access to the primary API endpoints related to job operations.


### Features

- Manage jobs through the Ethiack API with ease.
- Command-line interface for quick interaction.
- Compatible with Python 3.8 and higher.
- Easy installation via PyPI.

## Installation

You can install `ethiack-job-manager` using `pip`:

```bash
pip install ethiack-job-manager
```


## Credentials Setup

Using Ethiack's API - and, therefore, this package - requires authentication using an *API Key* and *API Secret*, which can be retrieved in [Ethiack's Portal settings page](https://portal.ethiack.com/settings/api). These credentials must be available as environment variables `ETHIACK_API_KEY` and `ETHIACK_API_SECRET`, repectively, whenever the package is used.

To set up these credentials, you can either set the environment variables directly:

```bash
export ETHIACK_API_KEY=your_api_key
export ETHIACK_API_SECRET=your_api_secret
```

or create a `.env` file:

```plaintext
ETHIACK_API_KEY=your_api_key
ETHIACK_API_SECRET=your_api_secret
```

## Usage

### Command-line Interface

Run the CLI commands to manage jobs through the Ethiack API.

```
❯ ethiack-job-manager --help

 Usage: ethiack-job-manager [OPTIONS] COMMAND [ARGS]...

 Ethiack Job Manager CLI.
 CLI for managing jobs using Ethiack's Public API.

╭─ Options ─────────────────────────────────────────────────────────────╮
│ --version    Show the version and exit.                               │
│ --help       Show this message and exit.                              │
╰───────────────────────────────────────────────────────────────────────╯
╭─ Commands ────────────────────────────────────────────────────────────╮
│ await          Wait for a job to finish.                              │
│ cancel         Cancel a queued or running job.                        │
│ check          Check if a URL is valid and a job can be submitted.    │
│ info           Get information about a job.                           │
│ launch         Launch a job.                                          │
│ list           List all jobs.                                         │
│ status         Show the status of a job.                              │
│ success        Show the success of a job.                             │
╰───────────────────────────────────────────────────────────────────────╯
```

### Python Package

Import the package and use the available functions to manage jobs through the Ethiack API. For more information:

```python
import ethiack_job_manager as manager


help(manager)

```



## License

Distributed under the MIT License. See [LICENSE](https://raw.githubusercontent.com/ethiack/job-manager/main/LICENSE) for more information.
