Python API to utilise the Somfy Synergy JsonRPC API
Project description
Somfy MyLink Synergy API
Python API to utilise the Somfy Synergy API utilising JsonRPC.
Requirements
- Python >= 3.5.2
Usage
import asyncio
from somfy_mylink_synergy import SomfyMyLinkSynergy
loop = asyncio.get_event_loop()
mylink = SomfyMyLinkSynergy('YourSystemID', '10.1.1.50')
mylink_covers = loop.run_until_complete(mylink.status_info())
for device in mylink_covers['result']:
print(device['targetID'], device['name'])
# ('CC0000A.1', 'Bedroom Cover')
# ('CC0000A.2', 'Kitchen Cover')
mylink_scenes = loop.run_until_complete(mylink.scene_list())
for scene in mylink_scenes['result']:
print(scene['sceneID'], scene['name'])
# ('123456789', 'Morning')
# ('987654321', 'Evening')
mylink_ping = loop.run_until_complete(mylink.status_ping())
for device in mylink_ping['result']:
print(device)
# ('CC0000A.1')
# ('CC0000A.2')
open_cover = loop.run_until_complete(mylink.move_up('CC0000A.1'))
close_cover = loop.run_until_complete(mylink.move_down('CC0000A.1'))
stop_cover = loop.run_until_complete(mylink.move_stop('CC0000A.1'))
activate_scene = loop.run_until_complete(mylink.scene_run('123456789'))
TODO:
- None
License
MIT
Author Information
Created in 2018 by Ben Dews
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file somfy_mylink_synergy-1.0.6.tar.gz.
File metadata
- Download URL: somfy_mylink_synergy-1.0.6.tar.gz
- Upload date:
- Size: 3.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.5.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
622eb8c40f601c5cfffb6310641f8a75aae42deca6cc1e1c32ad3954f71ef3b3
|
|
| MD5 |
2d09e67496ddd64fb60ad48f2fd02ac2
|
|
| BLAKE2b-256 |
5e116d547c1e97f5117d8f6f9376d72c465a322932a5bc4a0727e69fea163511
|
File details
Details for the file somfy_mylink_synergy-1.0.6-py3-none-any.whl.
File metadata
- Download URL: somfy_mylink_synergy-1.0.6-py3-none-any.whl
- Upload date:
- Size: 4.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.5.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
60312fb1efa89d80d25ca85d392697708411a588946e82c6e325af8322230f7b
|
|
| MD5 |
826ebdc2b032a78a38074c8fe7f8835e
|
|
| BLAKE2b-256 |
420159a56e7e15cd00918a856eb58bc5f9ce106df3e9422d1354acb0fb65f9aa
|