A python 3 API wrapper for GL-inet routers for consumption by Home Assistant
Project description
gli_py
A python 3 API wrapper for GL-inet routers. [WIP]
GL-inet routers are built on OpenWRT. They are highly customizeable but have an attractive user interface.
As part of their modiification of the UI they provide a locally accessible API.
I thought it would be handy to develop a python 3 wrapper for the API for easy intergation into other services such as HomeAssistant
Installation
pip3 install gli-py
Dev setup
- Clone the repo
- Ensure you have python 3 installed
python3 -V
orpython -V
- Uses poetry for venv control
pip3 install poetry
poetry config virtualenvs.in-project true
create the venvs in the project folderpoetry install
poetry shell
- To run tests, ensure there is a file called
router_pwd
in the root directory with the router password in. - Then run
pytest -s
to see responses, assumes the router is at192.168.0.1
- Set token with
poetry config pypi-token.pypi TOKEN
- publish with
poetry publish
Todo list:
- Decide on useful endpoints to expose
- Expose said enpoints
- Write tests
- Package correctly
- Test that dev enviroment is re-producable
- Publish on pip
- Static typing
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
gli_py-0.0.16.tar.gz
(16.5 kB
view hashes)
Built Distribution
gli_py-0.0.16-py3-none-any.whl
(17.4 kB
view hashes)