Home Assistant Unofficial Reference 2024.12.1
homeassistant.components.climate.device_trigger Namespace Reference

Functions

CALLBACK_TYPE async_attach_trigger (HomeAssistant hass, ConfigType config, TriggerActionType action, TriggerInfo trigger_info)
 
dict[str, vol.Schema] async_get_trigger_capabilities (HomeAssistant hass, ConfigType config)
 
list[dict[str, str]] async_get_triggers (HomeAssistant hass, str device_id)
 

Variables

 CURRENT_TRIGGER_SCHEMA
 
 HVAC_MODE_TRIGGER_SCHEMA
 
 TRIGGER_SCHEMA = vol.Any(HVAC_MODE_TRIGGER_SCHEMA, CURRENT_TRIGGER_SCHEMA)
 
dictionary TRIGGER_TYPES
 

Detailed Description

Provides device automations for Climate.

Function Documentation

◆ async_attach_trigger()

CALLBACK_TYPE homeassistant.components.climate.device_trigger.async_attach_trigger ( HomeAssistant  hass,
ConfigType  config,
TriggerActionType  action,
TriggerInfo  trigger_info 
)
Attach a trigger.

Definition at line 111 of file device_trigger.py.

◆ async_get_trigger_capabilities()

dict[str, vol.Schema] homeassistant.components.climate.device_trigger.async_get_trigger_capabilities ( HomeAssistant  hass,
ConfigType   config 
)
List trigger capabilities.

Definition at line 167 of file device_trigger.py.

◆ async_get_triggers()

list[dict[str, str]] homeassistant.components.climate.device_trigger.async_get_triggers ( HomeAssistant  hass,
str   device_id 
)
List device triggers for Climate devices.

Definition at line 63 of file device_trigger.py.

Variable Documentation

◆ CURRENT_TRIGGER_SCHEMA

homeassistant.components.climate.device_trigger.CURRENT_TRIGGER_SCHEMA
Initial value:
1 = vol.All(
2  DEVICE_TRIGGER_BASE_SCHEMA.extend(
3  {
4  vol.Required(CONF_ENTITY_ID): cv.entity_id_or_uuid,
5  vol.Required(CONF_TYPE): vol.In(
6  ["current_temperature_changed", "current_humidity_changed"]
7  ),
8  vol.Optional(CONF_BELOW): vol.Any(vol.Coerce(float)),
9  vol.Optional(CONF_ABOVE): vol.Any(vol.Coerce(float)),
10  vol.Optional(CONF_FOR): cv.positive_time_period_dict,
11  }
12  ),
13  cv.has_at_least_one_key(CONF_BELOW, CONF_ABOVE),
14 )

Definition at line 45 of file device_trigger.py.

◆ HVAC_MODE_TRIGGER_SCHEMA

homeassistant.components.climate.device_trigger.HVAC_MODE_TRIGGER_SCHEMA
Initial value:
1 = DEVICE_TRIGGER_BASE_SCHEMA.extend(
2  {
3  vol.Required(CONF_ENTITY_ID): cv.entity_id_or_uuid,
4  vol.Required(CONF_TYPE): "hvac_mode_changed",
5  vol.Required(state_trigger.CONF_TO): vol.In(const.HVAC_MODES),
6  vol.Optional(CONF_FOR): cv.positive_time_period_dict,
7  }
8 )

Definition at line 36 of file device_trigger.py.

◆ TRIGGER_SCHEMA

homeassistant.components.climate.device_trigger.TRIGGER_SCHEMA = vol.Any(HVAC_MODE_TRIGGER_SCHEMA, CURRENT_TRIGGER_SCHEMA)

Definition at line 60 of file device_trigger.py.

◆ TRIGGER_TYPES

dictionary homeassistant.components.climate.device_trigger.TRIGGER_TYPES
Initial value:
1 = {
2  "current_temperature_changed",
3  "current_humidity_changed",
4  "hvac_mode_changed",
5 }

Definition at line 30 of file device_trigger.py.