A library to authenticate and interact with STIHL iMow mowers using their WebAPI
Project description
STIHL iMow Unofficial Python API Wrapper
This unofficial Python API was created to provide an interface to interact with the STIHL iMow mower WebAPI. This wrapper is able to receive the current status status from the mowers and to send actions
Getting Started
These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.
Prerequisites
Python 3.7+ is required to run this application, other than that there are no prerequisites for the project, as the dependencies are included in the repository.
Installing
To install the library is as simple as cloning the repository and running
pip install -e .
It is recommended to create an virtual environment prior to installing this library. Alternatively, you can also install this library via Pip:
pip install imow-webapi
And have fun!
Usage
Import the module and instantiate the IMowApi()
constructor with credentials.
.
from imow.api import IMowApi
if __name__ == '__main__':
api = IMowApi("email@account.stihl", "supersecret")
mower = api.receive_mowers()[0]
print(f'{mower.name} @ {mower.coordinateLatitude},{mower.coordinateLongitude}')
Testing
For unit testing run pytest -s tests/test_unit*
. For upstream integration testing, provide a /secrets.py
with the following contents:
EMAIL = "my-stihl-imow-account@email.com"
PASSWORD = "supersecret"
MOWER_NAME = "MyRobot"
and run pytest -s tests/test_integration*
or pytest -s
.
Built With
- Requests - Http for Humans
Versioning
Navigate to tags on this repository to see all available versions.
Authors
Name | Mail Address | GitHub Profile |
---|---|---|
Christian Heinrichs | chris.heinrichs.mail@gmail.com | ChrisHaPunkt |
License
This project is licensed under the MIT License - see the LICENSE.md license file for more details.
Acknowledges
Thanks to
for repo structure inspiration
Changelog
Version 0.1.0 (2021-06-00)
- Changed the URI for the target API's from 'https://example.com/api' to 'https://api.example.com/'.
- Fix bug where hosting website was returning a 404.
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
Hashes for imow_webapi-0.2.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 218eb3bf277a84c63f892a59ec6300686c95fa02274ecfb3e01084729ec2f4a1 |
|
MD5 | 0b191e0d0c4eeec7f0db8223aff56f2e |
|
BLAKE2b-256 | ea4d8eecb5c94cbf0933ba6d96ca3a3604a82c393abc239c00ae42fa5b50be81 |