HomGar API client
Project description
HomGar API client library
The purpose of this library is to programmatically control, and retrieve the layout and current values of devices in the HomGar app.
The current primary focus of this project is to retrieve sensor values of RainPoint Smart+ devices so they can be integrated into HomeAssistant.
Current state of the project
Proof-of-concept: you can retrieve the layout of devices in your homes and their current values
Supported devices
- RainPoint Smart+ Irrigation Display Hub (HWS019WRF-V2)
- RainPoint Smart+ 2-Zone Water Timer (HTV213FRF)
- RainPoint Smart+ Soil&Moisture Sensor (HCS021FRF)
- RainPoint Smart+ High Precision Rain Sensor (HCS012ARF)
- RainPoint Smart+ Outdoor Air Humidity Sensor (HCS014ARF)
How to use
This library is not meant to be used by itself; rather it is meant to be integrated in projects like HomeAssistant.
However, if you really want to, you can run it commandline to see that it works. To do so:
- Install:
pip install homgarapi
- Create a file
config.yml
containing:
email: "<your HomGar login address>"
password: "<your HomGar password>"
- Run it:
python -m homgarapi config.yml
This commandline tool will cache your access token in a file cache.pickle
in a platform-specific user cache directory.
Caveats
Logging in via this API will log you out in the app. It is advisable to create a separate API account from the app:
- Log out from your main account
- Create a new account
- Log out and back into your main account
- Invite your new account from 'Me' → 'Home management' → your home → 'Members'
- Log out and back into your new account
- Accept the invite
To-do
- Support token renewal such that we don't have to store the password. I haven't been able to trigger token renewal in the app so I can sniff which endpoint it uses.
- Create a HomeAssistant integration that uses this library
- Support all RainPoint Smart+ devices. I only have a select few to test with (see "Supported devices").
- Investigate the meaning of currently unknown status values
- Add support for controlling devices via the API
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file homgarapi-0.0.3.tar.gz
.
File metadata
- Download URL: homgarapi-0.0.3.tar.gz
- Upload date:
- Size: 10.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.9.19
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e5779507f5d7d8db8e2e49030e768e6eea6aba66e8fdba49aa55ab6477938715 |
|
MD5 | b5229ce75fe1d82c2da4f9493d765055 |
|
BLAKE2b-256 | 868c4cdb5ed543aaa19d59ce3eb51527d259bca3b4cc54f3e2759df482317ec6 |
File details
Details for the file homgarapi-0.0.3-py3-none-any.whl
.
File metadata
- Download URL: homgarapi-0.0.3-py3-none-any.whl
- Upload date:
- Size: 10.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.9.19
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 29d883588796e7cbd931154eb3dde93e9ae8736ddd0ff494e555bb973f5c3339 |
|
MD5 | 2d3db4e0930a581f3bca683c31679f22 |
|
BLAKE2b-256 | f42c4991d62a92cf2aa0a38b79ce93f990baeca823548c85efe87d466adb4712 |