Python Wrapper for Homeassistant's REST API
Project description
HomeassistantAPI
Python Wrapper for Homeassistant's REST API
Installation
There are a variety of ways to install this wrapper.
Using pip
from PYPI
$ pip install homeassistant_api
Using Source from GitHub
$ git clone https://github.com/GrandMoff100/HomeassistantAPI
$ cd HomeassistantAPI
$ python setup.py install
Usage
See example.py
import os
from homeassistant_api import Client
url = os.getenv('HOMEASSISTANT_API_ENDPOINT') # http://localhost:8123/api/
token = os.getenv('HOMEASSISTANT_TOKEN') # ey816najgfjassf...
client = Client(url, token)
servicedomains = client.get_services()
servicedomains.light.turn_off.trigger(entity_id='light.living_room') # Sends a request to turn off the living room light
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 HomeAssistant API-0.0.2.tar.gz
.
File metadata
- Download URL: HomeAssistant API-0.0.2.tar.gz
- Upload date:
- Size: 5.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/3.9.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.8.0 tqdm/4.59.0 CPython/3.8.8
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
85669ee48483256e0a8f44cab6b90604f8c07440a07d342bcb5299ddf57e8781
|
|
MD5 |
804190f3626083204ab17bba2158a2c0
|
|
BLAKE2b-256 |
52d4a74c3b703d3a3425e0e60f0aecdc123b58621fed8f31446c25b54f3c92c9
|
File details
Details for the file HomeAssistant_API-0.0.2-py3-none-any.whl
.
File metadata
- Download URL: HomeAssistant_API-0.0.2-py3-none-any.whl
- Upload date:
- Size: 11.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/3.9.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.8.0 tqdm/4.59.0 CPython/3.8.8
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
652fc577c9b97910f771f5ce02d2377f34adb6345312b438f34b3e4170240ec7
|
|
MD5 |
6ff9b2122354ea32741b5363e62c96f3
|
|
BLAKE2b-256 |
2f037f48e9bd7b1a2af1302d48e1c35efca88dd4464b31558e8a9dbb34e15aed
|