python library for accessing the openHAB REST API
Project description
python library for accessing the openHAB REST API
This library allows for easily accessing the openHAB REST API. A number of features are implemented but not all, this is work in progress.
Requirements
python 2.7.x / 3.5
python :: dateutil
python :: requests
Note on openHAB1:
Make sure to use the 1.x branch for openHAB1.x!
Installation
Install the latest version using pip:
pip install python-openhab
Example
Example usage of the library:
from openhab import openHAB
base_url = 'http://localhost:8080/rest'
openhab = openHAB(base_url)
# fetch all items
items = openhab.fetch_all_items()
sunset = items.get('Sunset')
print(sunset.state)
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
python-openhab-2.1.tar.gz
(5.7 kB
view hashes)
Built Distribution
Close
Hashes for python_openhab-2.1-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | e0ab7f5992827449f46a973f3165dc98e06b490f31fc7a49deb4d9181e56a387 |
|
MD5 | 3f78821003d2e46458fd1e0f80668995 |
|
BLAKE2b-256 | 7e9b0b1b79ce89466ca1dcbc7d810e961b1c58d2526e29a2ea5bd352537f361e |