Skip to main content

A python package for your sinric-pro alexa skill

Project description

This is a python library for alexa home automation skill

SINRIC PRO —> https://sinric.pro/

Functions:

  • Automate your home using alexa with sinricpro

Installation :

Python3

python3 -m pip install pysinric --user

Pro Switch Demo:

from sinric import SinricPro
from sinric import SinricProUdp
from credentials import apiKey, deviceId


def power_state(did, state):
    # Alexa, turn ON/OFF Device
    print(did, state['state'])
    return True, state['state']


callbacks = {
'powerState': power_state
}

if __name__ == '__main__':
    client = SinricPro(apiKey, deviceId, callbacks, enable_trace=False)
    udp_client = SinricProUdp(callbacks)
    udp_client.enableUdpPrint(False)  # Set it to True to start printing request UDP JSON
    client.handle_all(udp_client)

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

sinricpro-0.0.8.tar.gz (7.5 kB view hashes)

Uploaded Source

Built Distribution

sinricpro-0.0.8-py3-none-any.whl (13.3 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page