Home Assistant Unofficial Reference 2024.12.1
homeassistant.components.cloud.http_api Namespace Reference

Classes

class  CloudForgotPasswordView
 
class  CloudLoginView
 
class  CloudLogoutView
 
class  CloudRegisterView
 
class  CloudResendConfirmView
 
class  GoogleActionsSyncView
 

Functions

dict[str, Any] _account_data (HomeAssistant hass, Cloud[CloudClient] cloud)
 
def _HassViewT
 
tuple[HTTPStatus, str] _process_cloud_exception (Exception exc, str where)
 
Callable[[HomeAssistant, websocket_api.ActiveConnection, dict[str, Any]], None,] _require_cloud_login (Callable[[HomeAssistant, websocket_api.ActiveConnection, dict[str, Any]], None,] handler)
 
Callable[[HomeAssistant, websocket_api.ActiveConnection, dict[str, Any]], Coroutine[None, None, None],] _ws_handle_cloud_errors (Callable[[HomeAssistant, websocket_api.ActiveConnection, dict[str, Any]], Coroutine[None, None, None],] handler)
 
None alexa_get (HomeAssistant hass, websocket_api.ActiveConnection connection, dict[str, Any] msg)
 
None alexa_list (HomeAssistant hass, websocket_api.ActiveConnection connection, dict[str, Any] msg)
 
None alexa_sync (HomeAssistant hass, websocket_api.ActiveConnection connection, dict[str, Any] msg)
 
None async_setup (HomeAssistant hass)
 
None google_assistant_get (HomeAssistant hass, websocket_api.ActiveConnection connection, dict[str, Any] msg)
 
None google_assistant_list (HomeAssistant hass, websocket_api.ActiveConnection connection, dict[str, Any] msg)
 
None google_assistant_update (HomeAssistant hass, websocket_api.ActiveConnection connection, dict[str, Any] msg)
 
None thingtalk_convert (HomeAssistant hass, websocket_api.ActiveConnection connection, dict[str, Any] msg)
 
None tts_info (HomeAssistant hass, websocket_api.ActiveConnection connection, dict[str, Any] msg)
 
tuple[str, str] validate_language_voice (tuple[str, str] value)
 
None websocket_cloud_remove_data (HomeAssistant hass, websocket_api.ActiveConnection connection, dict[str, Any] msg)
 
None websocket_cloud_status (HomeAssistant hass, websocket_api.ActiveConnection connection, dict[str, Any] msg)
 
None websocket_hook_create (HomeAssistant hass, websocket_api.ActiveConnection connection, dict[str, Any] msg)
 
None websocket_hook_delete (HomeAssistant hass, websocket_api.ActiveConnection connection, dict[str, Any] msg)
 
None websocket_remote_connect (HomeAssistant hass, websocket_api.ActiveConnection connection, dict[str, Any] msg)
 
None websocket_remote_disconnect (HomeAssistant hass, websocket_api.ActiveConnection connection, dict[str, Any] msg)
 
None websocket_subscription (HomeAssistant hass, websocket_api.ActiveConnection connection, dict[str, Any] msg)
 
None websocket_update_prefs (HomeAssistant hass, websocket_api.ActiveConnection connection, dict[str, Any] msg)
 

Variables

 _LOGGER = logging.getLogger(__name__)
 

Detailed Description

The HTTP api to control the cloud integration.

Function Documentation

◆ _account_data()

dict[str, Any] homeassistant.components.cloud.http_api._account_data ( HomeAssistant  hass,
Cloud[CloudClient]   cloud 
)
private
Generate the auth data JSON response.

Definition at line 538 of file http_api.py.

◆ _HassViewT()

def homeassistant.components.cloud.http_api._HassViewT
private

Definition at line 119 of file http_api.py.

◆ _process_cloud_exception()

tuple[HTTPStatus, str] homeassistant.components.cloud.http_api._process_cloud_exception ( Exception  exc,
str  where 
)
private
Process a cloud exception.

Definition at line 173 of file http_api.py.

◆ _require_cloud_login()

Callable[ [HomeAssistant, websocket_api.ActiveConnection, dict[str, Any]], None, ] homeassistant.components.cloud.http_api._require_cloud_login ( Callable[ [HomeAssistant, websocket_api.ActiveConnection, dict[str, Any]], None, ]  handler)
private
Websocket decorator that requires cloud to be logged in.

Definition at line 377 of file http_api.py.

◆ _ws_handle_cloud_errors()

Callable[ [HomeAssistant, websocket_api.ActiveConnection, dict[str, Any]], Coroutine[None, None, None], ] homeassistant.components.cloud.http_api._ws_handle_cloud_errors ( Callable[ [HomeAssistant, websocket_api.ActiveConnection, dict[str, Any]], Coroutine[None, None, None], ]  handler)
private
Websocket decorator to handle auth errors.

Definition at line 145 of file http_api.py.

◆ alexa_get()

None homeassistant.components.cloud.http_api.alexa_get ( HomeAssistant  hass,
websocket_api.ActiveConnection  connection,
dict[str, Any]  msg 
)
Get data for a single alexa entity.

Definition at line 747 of file http_api.py.

◆ alexa_list()

None homeassistant.components.cloud.http_api.alexa_list ( HomeAssistant  hass,
websocket_api.ActiveConnection  connection,
dict[str, Any]  msg 
)
List all alexa entities.

Definition at line 773 of file http_api.py.

◆ alexa_sync()

None homeassistant.components.cloud.http_api.alexa_sync ( HomeAssistant  hass,
websocket_api.ActiveConnection  connection,
dict[str, Any]  msg 
)
Sync with Alexa.

Definition at line 799 of file http_api.py.

◆ async_setup()

None homeassistant.components.cloud.http_api.async_setup ( HomeAssistant  hass)
Initialize the HTTP API.

Definition at line 73 of file http_api.py.

◆ google_assistant_get()

None homeassistant.components.cloud.http_api.google_assistant_get ( HomeAssistant  hass,
websocket_api.ActiveConnection  connection,
dict[str, Any]  msg 
)
Get data for a single google assistant entity.

Definition at line 633 of file http_api.py.

◆ google_assistant_list()

None homeassistant.components.cloud.http_api.google_assistant_list ( HomeAssistant  hass,
websocket_api.ActiveConnection  connection,
dict[str, Any]  msg 
)
List all google assistant entities.

Definition at line 681 of file http_api.py.

◆ google_assistant_update()

None homeassistant.components.cloud.http_api.google_assistant_update ( HomeAssistant  hass,
websocket_api.ActiveConnection  connection,
dict[str, Any]  msg 
)
Update google assistant entity config.

Definition at line 714 of file http_api.py.

◆ thingtalk_convert()

None homeassistant.components.cloud.http_api.thingtalk_convert ( HomeAssistant  hass,
websocket_api.ActiveConnection  connection,
dict[str, Any]  msg 
)
Convert a query.

Definition at line 829 of file http_api.py.

◆ tts_info()

None homeassistant.components.cloud.http_api.tts_info ( HomeAssistant  hass,
websocket_api.ActiveConnection  connection,
dict[str, Any]  msg 
)
Fetch available tts info.

Definition at line 847 of file http_api.py.

◆ validate_language_voice()

tuple[str, str] homeassistant.components.cloud.http_api.validate_language_voice ( tuple[str, str]  value)
Validate language and voice.

Definition at line 429 of file http_api.py.

◆ websocket_cloud_remove_data()

None homeassistant.components.cloud.http_api.websocket_cloud_remove_data ( HomeAssistant  hass,
websocket_api.ActiveConnection  connection,
dict[str, Any]  msg 
)
Handle request for account info.

Async friendly.

Definition at line 336 of file http_api.py.

◆ websocket_cloud_status()

None homeassistant.components.cloud.http_api.websocket_cloud_status ( HomeAssistant  hass,
websocket_api.ActiveConnection  connection,
dict[str, Any]  msg 
)
Handle request for account info.

Async friendly.

Definition at line 362 of file http_api.py.

◆ websocket_hook_create()

None homeassistant.components.cloud.http_api.websocket_hook_create ( HomeAssistant  hass,
websocket_api.ActiveConnection  connection,
dict[str, Any]  msg 
)
Handle request for account info.

Definition at line 507 of file http_api.py.

◆ websocket_hook_delete()

None homeassistant.components.cloud.http_api.websocket_hook_delete ( HomeAssistant  hass,
websocket_api.ActiveConnection  connection,
dict[str, Any]  msg 
)
Handle request for account info.

Definition at line 527 of file http_api.py.

◆ websocket_remote_connect()

None homeassistant.components.cloud.http_api.websocket_remote_connect ( HomeAssistant  hass,
websocket_api.ActiveConnection  connection,
dict[str, Any]  msg 
)
Handle request for connect remote.

Definition at line 596 of file http_api.py.

◆ websocket_remote_disconnect()

None homeassistant.components.cloud.http_api.websocket_remote_disconnect ( HomeAssistant  hass,
websocket_api.ActiveConnection  connection,
dict[str, Any]  msg 
)
Handle request for disconnect remote.

Definition at line 612 of file http_api.py.

◆ websocket_subscription()

None homeassistant.components.cloud.http_api.websocket_subscription ( HomeAssistant  hass,
websocket_api.ActiveConnection  connection,
dict[str, Any]  msg 
)
Handle request for account info.

Definition at line 412 of file http_api.py.

◆ websocket_update_prefs()

None homeassistant.components.cloud.http_api.websocket_update_prefs ( HomeAssistant  hass,
websocket_api.ActiveConnection  connection,
dict[str, Any]  msg 
)
Handle request for account info.

Definition at line 456 of file http_api.py.

Variable Documentation

◆ _LOGGER

homeassistant.components.cloud.http_api._LOGGER = logging.getLogger(__name__)
private

Definition at line 57 of file http_api.py.