cremalink.transports.cloud.transport module
This module provides the CloudTransport class, which handles communication with a coffee machine via the manufacturer’s cloud API (Ayla Networks).
- class cremalink.transports.cloud.transport.CloudTransport(dsn: str, access_token: str, device_map_path: str | None = None)[source]
Bases:
DeviceTransportA transport for communicating with a device via the cloud API.
This transport interacts directly with the Ayla cloud service endpoints, using a short-lived access token for authentication. Upon initialization, it fetches key device metadata from the cloud and stores it.
- get_monitor() Any[source]
Fetches, parses, and returns the device’s monitoring status.
This works by fetching the specific ‘monitor’ property, extracting its base64 value, and then decoding it into a structured snapshot.
- health() Any[source]
Returns the device’s online status as determined during initialization. This does not perform a live health check.
- refresh_monitor() Any[source]
The cloud API does not provide a direct way to force a monitor refresh. This method is a no-op.