Skip to main content

Ariston module

Project description

CodeQL Upload Python Package

python-ariston-api

A Python module for controlling Ariston devices with cloud polling. The following devices are currently supported:

  • Ariston Alteas One 24
  • Ariston Velis Evo
  • Ariston Velis Lux
  • Ariston Lydos Hybrid
  • Ariston Genus One
  • Ariston Nuos Split
  • Ariston Thision S

Installation

Use pip3 to install the latest version of this module.

pip3 install ariston

The easy way (recommended for testing the module)

First, open Python 3 and import ariston module.

python3
import ariston

Syncronous

Discover devices if you dont know your gateway id. You can skip this step.

raw_devices = ariston.discover("username", "password")

For example the gateway id for your first device.

 raw_devices[0]['gw']

Get your device

device = ariston.hello("username", "password", "gateway", is_metric, "location")

Go use your device section

Asyncronous

raw_devices = await ariston.async_discover("username", "password")
device = await ariston.async_hello("username", "password", "gateway", is_metric, "location")

Go use your device section

The ariston class way (recommended for integrate the module)

First, open Python 3 and import Ariston class from this module.

python3
from ariston import Ariston

Create a new Ariston instance

ariston = Ariston()

Now let's try some functions

Connect

The cloud requests are asynchronous, so if you call them from a synchronous function or not even from function, you should use asyncio.

import asyncio

Sync

asyncio.run(ariston.async_connect("username", "password"))

Async

await ariston.async_connect("username", "password")
  • username: Your ariston cloud username.
  • password: Your ariston cloud password.

Discovery

Use this function to discover devices. You can skip this step if you already know the gateway id.

Sync

devices = asyncio.run(ariston.async_discover())

Async

devices = await ariston.async_discover()

Say hello

Use this function to create the device object.

Sync

device = asyncio.run(ariston.async_hello("gateway", is_metric, "location"))

Async

device = await ariston.async_hello("gateway", is_metric, "location")
  • gateway: You can find the value in the returned discover dictionary name 'gw'
  • is_metric: Optional. True or False. True means metric, False means imperial. Only works with Galevo (Alteas One, Genus One, etc) system. Default is True.
  • language_tag: Optional. Check https://en.wikipedia.org/wiki/IETF_language_tag Only works with Galevo (Alteas One, Genus One, etc) system. Default is "en-US".

Use your device

Get device features

Sync

device.get_features()

Async

await device.async_get_features()

Get device data

Sync

device.update_state()

Async

await device.async_update_state()

Get device energy

Sync

device.update_energy()

Async

await device.async_update_energy()

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

ariston-0.16.0.tar.gz (23.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ariston-0.16.0-py3-none-any.whl (28.4 kB view details)

Uploaded Python 3

File details

Details for the file ariston-0.16.0.tar.gz.

File metadata

  • Download URL: ariston-0.16.0.tar.gz
  • Upload date:
  • Size: 23.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.18

File hashes

Hashes for ariston-0.16.0.tar.gz
Algorithm Hash digest
SHA256 2b191efbab46bc2ee8ef5bb1fd8bacd4ad745e4005cfa66fc1de95da4a0e8a2a
MD5 6da8bcc94f55e58a9293995abb5ffb61
BLAKE2b-256 617b8632ac884c6be6a87616a1a59ce0df8521102146f9c6777386a0edd3e2d9

See more details on using hashes here.

File details

Details for the file ariston-0.16.0-py3-none-any.whl.

File metadata

  • Download URL: ariston-0.16.0-py3-none-any.whl
  • Upload date:
  • Size: 28.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.18

File hashes

Hashes for ariston-0.16.0-py3-none-any.whl
Algorithm Hash digest
SHA256 bd0a80119c71d09c89af0d8974544557bc0d8702256c8f8e4aa03b53a2e72109
MD5 0ac3c91e013ab38cf670cdb8c1b9f235
BLAKE2b-256 f56ac960d7deddbbf8e9d8aa886fb654b82caab78002ea44f71f1e136b7eb6ac

See more details on using hashes here.

Supported by

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