API
Asynchronous Python client for Tado.
- class tadoasync.Tado(refresh_token: str | None = None, debug: bool | None = None, session: ClientSession | None = None, request_timeout: int = 10)
Bases:
objectBase class for Tado.
- _ensure_session() ClientSession
Return an active aiohttp ClientSession, creating one if needed.
- async _request(uri: str | None = None, endpoint: str = 'my.tado.com/api/v2', data: dict[str, object] | None = None, method: HttpMethod = HttpMethod.GET) str
Handle a request to the Tado API.
- async check_request_status(response_error: ClientResponseError, *, login: bool = False) None
Check the status of the request and raise the proper exception if needed.
- property device_activation_status: DeviceActivationStatus
Return the device activation status.
- async get_auto_geofencing_supported() bool | None
Return whether the Tado Home supports auto geofencing.
- async get_capabilities(zone: int) Capabilities
Get the capabilities.
- async get_device_info(serial_no: str, attribute: str | None = None) TemperatureOffset | Device
Get the device info.
- async get_devices() list[tadoasync.models.Device]
Get the devices.
- async get_mobile_devices() list[tadoasync.models.MobileDevice]
Get the mobile devices.
- async get_zone_states() dict[str, tadoasync.models.ZoneState]
Get the zone states.
- async get_zones() list[tadoasync.models.Zone]
Get the zones.
- async login_device_flow() DeviceActivationStatus
Login using device flow.
- async set_zone_overlay(zone: int, overlay_mode: str, set_temp: float | None = None, duration: int | None = None, device_type: str = 'HEATING', power: str = 'ON', mode: str | None = None, fan_speed: str | None = None, fan_level: str | None = None, vertical_swing: str | None = None, horizontal_swing: str | None = None, swing: str | None = None) None
Set the zone overlay.
- exception tadoasync.TadoAuthenticationError
Bases:
TadoErrorTado authentication exception.
- add_note()
Exception.add_note(note) – add a note to the exception
- args
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception tadoasync.TadoBadRequestError
Bases:
TadoErrorTado bad request exception.
- add_note()
Exception.add_note(note) – add a note to the exception
- args
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception tadoasync.TadoConnectionError
Bases:
TadoErrorTado connection exception.
- add_note()
Exception.add_note(note) – add a note to the exception
- args
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception tadoasync.TadoError
Bases:
ExceptionBase exception for Tado API.
- add_note()
Exception.add_note(note) – add a note to the exception
- args
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.