Metadata-Version: 2.4
Name: hdo-cez-dist
Version: 0.1.4
Project-URL: Homepage, https://gitlab.com/alda78/hdo-cez-dist
Author-email: Ales Adamek <alda78@seznam.cz>
License-Expression: GPL-3.0-or-later
Requires-Python: >=3.8
Requires-Dist: python-dateutil
Requires-Dist: requests
Provides-Extra: dev
Requires-Dist: ruff; extra == 'dev'
Description-Content-Type: text/markdown

# CEZ Distribution HDO detector

App to monitor CEZ Distribuce HDO times and handle e-plugs via its API.
HDO Distribution times for triggering e-plugs are based on this website https://www.cezdistribuce.cz/pro-zakazniky/potrebuji-vyresit/stavajici-pripojeni/casy-spinani-nizkeho-tarifu and its GraphQL API.

- Provider support: CEZ Distribuce
- ePlug support: Shelly Plug generation 2 and 3


## Instalation
```bash
pip install hdo-cez-dist
```

## Usage
```bash
hdo-cez-dist --help

usage: App to monitor CEZ Distribuce HDO and turn on/off e-plugs. [-h] [--plug-type PLUG_TYPE] [--plug-host PLUG_HOST] [--range-crop RANGE_CROP] device_code device_area

positional arguments:
  device_code           HDO Device code consists from 7 letters and numbers.
  device_area           HDO Device area. For example: morava

options:
  -h, --help            show this help message and exit
  --plug-type PLUG_TYPE
                        E-plug type. Example: shelly_plug
  --plug-host PLUG_HOST
                        E-plug host
  --range-crop RANGE_CROP
                        Crop HDO timing from left and right side (in minites). Default is 0, which means no cropping.
```

### CRON example
```
*/5 * * * *     root    hdo-cez-dist ab12345 morava --plug-type shelly_plug --plug-host 192.168.1.10 > /var/log/hdo-cez-dist.log
```
