File: quickstart.rst

package info (click to toggle)
python-elmax-api 0.0.5-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 324 kB
  • sloc: python: 1,378; makefile: 20
file content (36 lines) | stat: -rw-r--r-- 754 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
Installation
============

This library can be easily installed via the Pypi packet manager.

.. code-block:: bash

   pip3 install elmax-api --user


or, to install it globally:

.. code-block:: bash

   pip3 install elmax-api


.. _quickstart:

Quick Start
===========

The following code snippet illustrates how to login to the Elmax Cloud API, fetch the current
zone status and toggle some actuator

   .. literalinclude:: ../../examples/basic.py

Listen for push notifications
=============================

In order to listen for push notification events, it is just necessary to register a callback
coroutine using a `PushNotificationHandler` helper object.

The following example shows how to to so.

   .. literalinclude:: ../../examples/push.py