Home Assistant Unofficial Reference 2024.12.1
homeassistant.components.google_assistant.smart_home Namespace Reference

Functions

def _entity_execute (entity, data, executions)
 
def _process (hass, data, message)
 
def api_disabled_response (message, agent_user_id)
 
None async_devices_disconnect (HomeAssistant hass, RequestData data, dict[str, Any] payload)
 
dict[str, Any] async_devices_identify (HomeAssistant hass, RequestData data, dict[str, Any] payload)
 
dict[str, Any] async_devices_proxy_selected (HomeAssistant hass, RequestData data, dict[str, Any] payload)
 
dict[str, Any] async_devices_query (HomeAssistant hass, RequestData data, dict[str, Any] payload)
 
def async_devices_query_response (hass, config, payload_devices)
 
dict[str, Any] async_devices_reachable (HomeAssistant hass, RequestData data, dict[str, Any] payload)
 
dict[str, Any] async_devices_sync (HomeAssistant hass, RequestData data, dict[str, Any] payload)
 
def async_devices_sync_response (hass, config, agent_user_id)
 
def async_handle_message (hass, config, agent_user_id, local_user_id, message, source)
 
def create_sync_response (str agent_user_id, list devices)
 
dict[str, Any] handle_devices_execute (HomeAssistant hass, RequestData data, dict[str, Any] payload)
 

Variables

 _LOGGER = logging.getLogger(__name__)
 
int EXECUTE_LIMIT = 2
 

Detailed Description

Support for Google Assistant Smart Home API.

Function Documentation

◆ _entity_execute()

def homeassistant.components.google_assistant.smart_home._entity_execute (   entity,
  data,
  executions 
)
private
Execute all commands for an entity.

Returns a dict if a special result needs to be set.

Definition at line 189 of file smart_home.py.

◆ _process()

def homeassistant.components.google_assistant.smart_home._process (   hass,
  data,
  message 
)
private
Process a message.

Definition at line 73 of file smart_home.py.

◆ api_disabled_response()

def homeassistant.components.google_assistant.smart_home.api_disabled_response (   message,
  agent_user_id 
)
Return a device turned off response.

Definition at line 367 of file smart_home.py.

◆ async_devices_disconnect()

None homeassistant.components.google_assistant.smart_home.async_devices_disconnect ( HomeAssistant  hass,
RequestData  data,
dict[str, Any]   payload 
)
Handle action.devices.DISCONNECT request.

https://developers.google.com/assistant/smarthome/develop/process-intents#DISCONNECT

Definition at line 295 of file smart_home.py.

◆ async_devices_identify()

dict[str, Any] homeassistant.components.google_assistant.smart_home.async_devices_identify ( HomeAssistant  hass,
RequestData  data,
dict[str, Any]   payload 
)
Handle action.devices.IDENTIFY request.

https://developers.google.com/assistant/smarthome/develop/local#implement_the_identify_handler

Definition at line 307 of file smart_home.py.

◆ async_devices_proxy_selected()

dict[str, Any] homeassistant.components.google_assistant.smart_home.async_devices_proxy_selected ( HomeAssistant  hass,
RequestData  data,
dict[str, Any]   payload 
)
Handle action.devices.PROXY_SELECTED request.

When selected for local SDK.

Definition at line 349 of file smart_home.py.

◆ async_devices_query()

dict[str, Any] homeassistant.components.google_assistant.smart_home.async_devices_query ( HomeAssistant  hass,
RequestData  data,
dict[str, Any]   payload 
)
Handle action.devices.QUERY request.

https://developers.google.com/assistant/smarthome/develop/process-intents#QUERY

Definition at line 146 of file smart_home.py.

◆ async_devices_query_response()

def homeassistant.components.google_assistant.smart_home.async_devices_query_response (   hass,
  config,
  payload_devices 
)
Generate the device serialization.

Definition at line 168 of file smart_home.py.

◆ async_devices_reachable()

dict[str, Any] homeassistant.components.google_assistant.smart_home.async_devices_reachable ( HomeAssistant  hass,
RequestData  data,
dict[str, Any]   payload 
)
Handle action.devices.REACHABLE_DEVICES request.

https://developers.google.com/assistant/smarthome/develop/local#implement_the_reachable_devices_handler_hub_integrations_only

Definition at line 330 of file smart_home.py.

◆ async_devices_sync()

dict[str, Any] homeassistant.components.google_assistant.smart_home.async_devices_sync ( HomeAssistant  hass,
RequestData  data,
dict[str, Any]   payload 
)
Handle action.devices.SYNC request.

https://developers.google.com/assistant/smarthome/develop/process-intents#SYNC

Definition at line 125 of file smart_home.py.

◆ async_devices_sync_response()

def homeassistant.components.google_assistant.smart_home.async_devices_sync_response (   hass,
  config,
  agent_user_id 
)
Generate the device serialization.

Definition at line 106 of file smart_home.py.

◆ async_handle_message()

def homeassistant.components.google_assistant.smart_home.async_handle_message (   hass,
  config,
  agent_user_id,
  local_user_id,
  message,
  source 
)
Handle incoming API messages.

Definition at line 39 of file smart_home.py.

◆ create_sync_response()

def homeassistant.components.google_assistant.smart_home.create_sync_response ( str  agent_user_id,
list  devices 
)
Return an empty sync response.

Definition at line 359 of file smart_home.py.

◆ handle_devices_execute()

dict[str, Any] homeassistant.components.google_assistant.smart_home.handle_devices_execute ( HomeAssistant  hass,
RequestData  data,
dict[str, Any]   payload 
)
Handle action.devices.EXECUTE request.

https://developers.google.com/assistant/smarthome/develop/process-intents#EXECUTE

Definition at line 208 of file smart_home.py.

Variable Documentation

◆ _LOGGER

homeassistant.components.google_assistant.smart_home._LOGGER = logging.getLogger(__name__)
private

Definition at line 36 of file smart_home.py.

◆ EXECUTE_LIMIT

int homeassistant.components.google_assistant.smart_home.EXECUTE_LIMIT = 2

Definition at line 27 of file smart_home.py.