An asynchronous library to use Switchbot API
Project description
py-switchbot-api
An asynchronous library to use Switchbot API. Allows to use both devices and remotes.
Usage
token = "xxx"
secret = "yyy"
client = SwitchBotAPI(token, secret)
print(await client.list_devices())
print(await client.get_status('some-id'))
await client.send_command('some-id', {COMMAND})
Development
Install
poetry install
Lint
poetry run black switchbot_api/
poetry run mypy switchbot_api/
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
switchbot_api-1.2.1.tar.gz
(3.9 kB
view hashes)
Built Distribution
Close
Hashes for switchbot_api-1.2.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 690e63c40a4ebc5b245680870fcfc6021497831b278a5bb328d35267e9325e83 |
|
MD5 | b6ec64712e0831b824c78a5b5fc77ae2 |
|
BLAKE2b-256 | d91caa10af9f0a0385f855d4f116aad7c6e1aeb205c0875d3e40b610ce0f8268 |