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.3.0.tar.gz
(4.1 kB
view hashes)
Built Distribution
Close
Hashes for switchbot_api-1.3.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | b0becf216a5b42374988690f248ff48e78e20cfae6a385fdcf9271357a8619e5 |
|
MD5 | 1908c909406e27f4c836b041f4297fa0 |
|
BLAKE2b-256 | 88e42b994bfd9705645288cf6b1a69d239eccc39efeb4d769a71df72b0c2d736 |