Home Assistant Unofficial Reference 2024.12.1
homeassistant.components.mqtt Namespace Reference

Namespaces

 abbreviations
 
 addon
 
 alarm_control_panel
 
 async_client
 
 binary_sensor
 
 button
 
 camera
 
 client
 
 climate
 
 config
 
 config_flow
 
 config_integration
 
 const
 
 cover
 
 debug_info
 
 device_automation
 
 device_tracker
 
 device_trigger
 
 diagnostics
 
 discovery
 
 entity
 
 event
 
 fan
 
 humidifier
 
 image
 
 lawn_mower
 
 light
 
 lock
 
 models
 
 notify
 
 number
 
 scene
 
 schemas
 
 select
 
 sensor
 
 siren
 
 subscription
 
 switch
 
 tag
 
 text
 
 trigger
 
 update
 
 util
 
 vacuum
 
 valve
 
 water_heater
 

Functions

None _async_config_entry_updated (HomeAssistant hass, ConfigEntry entry)
 
None _async_remove_mqtt_issues (HomeAssistant hass, MqttData mqtt_data)
 
None async_check_config_schema (HomeAssistant hass, ConfigType config_yaml)
 
bool async_remove_config_entry_device (HomeAssistant hass, ConfigEntry config_entry, DeviceEntry device_entry)
 
bool async_setup (HomeAssistant hass, ConfigType config)
 
bool async_setup_entry (HomeAssistant hass, ConfigEntry entry)
 
Callable[[], None] async_subscribe_connection_status (HomeAssistant hass, ConnectionStatusCallback connection_status_callback)
 
bool async_unload_entry (HomeAssistant hass, ConfigEntry entry)
 
bool is_connected (HomeAssistant hass)
 
None websocket_mqtt_info (HomeAssistant hass, websocket_api.ActiveConnection connection, dict[str, Any] msg)
 
None websocket_subscribe (HomeAssistant hass, websocket_api.ActiveConnection connection, dict[str, Any] msg)
 

Variables

 _LOGGER
 
 ATTR_EVALUATE_PAYLOAD
 
 ATTR_PAYLOAD_TEMPLATE
 
 ATTR_QOS
 
 ATTR_RETAIN
 
 ATTR_TOPIC_TEMPLATE
 
 CONFIG_SCHEMA
 
 CONNECTION_FAILED
 
 CONNECTION_FAILED_RECOVERABLE
 
 CONNECTION_SUCCESS
 
 ConnectionStatusCallback
 
 default
 
 extra
 
 MAX_RECONNECT_WAIT
 
 MQTT_PUBLISH_SCHEMA
 
 required
 
 SERVICE_DUMP
 
 SERVICE_PUBLISH
 

Detailed Description

Support for MQTT message handling.

Function Documentation

◆ _async_config_entry_updated()

None homeassistant.components.mqtt._async_config_entry_updated ( HomeAssistant  hass,
ConfigEntry  entry 
)
private

Definition at line 180 of file __init__.py.

◆ _async_remove_mqtt_issues()

None homeassistant.components.mqtt._async_remove_mqtt_issues ( HomeAssistant  hass,
MqttData  mqtt_data 
)
private
Handle signals of config entry being updated.

Causes for this is config entry options changing.
Unregister open config issues.

Definition at line 189 of file __init__.py.

◆ async_check_config_schema()

None homeassistant.components.mqtt.async_check_config_schema ( HomeAssistant  hass,
ConfigType   config_yaml 
)
Validate manually configured MQTT items.

Definition at line 201 of file __init__.py.

◆ async_remove_config_entry_device()

bool homeassistant.components.mqtt.async_remove_config_entry_device ( HomeAssistant  hass,
ConfigEntry  config_entry,
DeviceEntry   device_entry 
)
Remove MQTT config entry from a device.

Definition at line 559 of file __init__.py.

◆ async_setup()

bool homeassistant.components.mqtt.async_setup ( HomeAssistant  hass,
ConfigType  config 
)
Set up the actions and websocket API for the MQTT component.

Definition at line 228 of file __init__.py.

◆ async_setup_entry()

bool homeassistant.components.mqtt.async_setup_entry ( HomeAssistant  hass,
ConfigEntry  entry 
)
Load a config entry.

Definition at line 358 of file __init__.py.

◆ async_subscribe_connection_status()

Callable[[], None] homeassistant.components.mqtt.async_subscribe_connection_status ( HomeAssistant  hass,
ConnectionStatusCallback   connection_status_callback 
)
Subscribe to MQTT connection changes.

Definition at line 544 of file __init__.py.

◆ async_unload_entry()

bool homeassistant.components.mqtt.async_unload_entry ( HomeAssistant  hass,
ConfigEntry  entry 
)
Unload MQTT dump and publish service when the config entry is unloaded.

Definition at line 570 of file __init__.py.

◆ is_connected()

bool homeassistant.components.mqtt.is_connected ( HomeAssistant  hass)
Return if MQTT client is connected.

Definition at line 553 of file __init__.py.

◆ websocket_mqtt_info()

None homeassistant.components.mqtt.websocket_mqtt_info ( HomeAssistant  hass,
websocket_api.ActiveConnection  connection,
dict[str, Any]   msg 
)
Get MQTT debug info for device.

Definition at line 483 of file __init__.py.

◆ websocket_subscribe()

None homeassistant.components.mqtt.websocket_subscribe ( HomeAssistant  hass,
websocket_api.ActiveConnection  connection,
dict[str, Any]   msg 
)
Subscribe to a MQTT topic.

Definition at line 501 of file __init__.py.

Variable Documentation

◆ _LOGGER

homeassistant.components.mqtt._LOGGER
private

Definition at line 111 of file __init__.py.

◆ ATTR_EVALUATE_PAYLOAD

homeassistant.components.mqtt.ATTR_EVALUATE_PAYLOAD

Definition at line 118 of file __init__.py.

◆ ATTR_PAYLOAD_TEMPLATE

homeassistant.components.mqtt.ATTR_PAYLOAD_TEMPLATE

Definition at line 117 of file __init__.py.

◆ ATTR_QOS

homeassistant.components.mqtt.ATTR_QOS

Definition at line 171 of file __init__.py.

◆ ATTR_RETAIN

homeassistant.components.mqtt.ATTR_RETAIN

Definition at line 172 of file __init__.py.

◆ ATTR_TOPIC_TEMPLATE

homeassistant.components.mqtt.ATTR_TOPIC_TEMPLATE

Definition at line 116 of file __init__.py.

◆ CONFIG_SCHEMA

homeassistant.components.mqtt.CONFIG_SCHEMA

Definition at line 147 of file __init__.py.

◆ CONNECTION_FAILED

homeassistant.components.mqtt.CONNECTION_FAILED

Definition at line 123 of file __init__.py.

◆ CONNECTION_FAILED_RECOVERABLE

homeassistant.components.mqtt.CONNECTION_FAILED_RECOVERABLE

Definition at line 124 of file __init__.py.

◆ CONNECTION_SUCCESS

homeassistant.components.mqtt.CONNECTION_SUCCESS

Definition at line 122 of file __init__.py.

◆ ConnectionStatusCallback

homeassistant.components.mqtt.ConnectionStatusCallback

Definition at line 540 of file __init__.py.

◆ default

homeassistant.components.mqtt.default

Definition at line 171 of file __init__.py.

◆ extra

homeassistant.components.mqtt.extra

Definition at line 155 of file __init__.py.

◆ MAX_RECONNECT_WAIT

homeassistant.components.mqtt.MAX_RECONNECT_WAIT

Definition at line 120 of file __init__.py.

◆ MQTT_PUBLISH_SCHEMA

homeassistant.components.mqtt.MQTT_PUBLISH_SCHEMA

Definition at line 163 of file __init__.py.

◆ required

homeassistant.components.mqtt.required

Definition at line 174 of file __init__.py.

◆ SERVICE_DUMP

homeassistant.components.mqtt.SERVICE_DUMP

Definition at line 114 of file __init__.py.

◆ SERVICE_PUBLISH

homeassistant.components.mqtt.SERVICE_PUBLISH

Definition at line 113 of file __init__.py.