Home Assistant Unofficial Reference 2024.12.1
homeassistant.components.hassio.websocket_api Namespace Reference

Functions

None async_load_websocket_api (HomeAssistant hass)
 
None websocket_subscribe (HomeAssistant hass, ActiveConnection connection, dict[str, Any] msg)
 
None websocket_supervisor_api (HomeAssistant hass, ActiveConnection connection, dict[str, Any] msg)
 
None websocket_supervisor_event (HomeAssistant hass, ActiveConnection connection, dict[str, Any] msg)
 

Variables

 Logger
 
 SCHEMA_WEBSOCKET_EVENT
 
 WS_NO_ADMIN_ENDPOINTS
 

Detailed Description

Websocekt API handlers for the hassio integration.

Function Documentation

◆ async_load_websocket_api()

None homeassistant.components.hassio.websocket_api.async_load_websocket_api ( HomeAssistant  hass)
Set up the websocket API.

Definition at line 57 of file websocket_api.py.

◆ websocket_subscribe()

None homeassistant.components.hassio.websocket_api.websocket_subscribe ( HomeAssistant  hass,
ActiveConnection  connection,
dict[str, Any]   msg 
)
Subscribe to supervisor events.

Definition at line 67 of file websocket_api.py.

◆ websocket_supervisor_api()

None homeassistant.components.hassio.websocket_api.websocket_supervisor_api ( HomeAssistant  hass,
ActiveConnection  connection,
dict[str, Any]   msg 
)
Websocket handler to call Supervisor API.

Definition at line 108 of file websocket_api.py.

◆ websocket_supervisor_event()

None homeassistant.components.hassio.websocket_api.websocket_supervisor_event ( HomeAssistant  hass,
ActiveConnection  connection,
dict[str, Any]   msg 
)
Publish events from the Supervisor.

Definition at line 90 of file websocket_api.py.

Variable Documentation

◆ Logger

homeassistant.components.hassio.websocket_api.Logger

Definition at line 53 of file websocket_api.py.

◆ SCHEMA_WEBSOCKET_EVENT

homeassistant.components.hassio.websocket_api.SCHEMA_WEBSOCKET_EVENT
Initial value:
1 = vol.Schema(
2  {vol.Required(ATTR_WS_EVENT): cv.string},
3  extra=vol.ALLOW_EXTRA,
4 )

Definition at line 38 of file websocket_api.py.

◆ WS_NO_ADMIN_ENDPOINTS

homeassistant.components.hassio.websocket_api.WS_NO_ADMIN_ENDPOINTS
Initial value:
1 = re.compile(
2  r"^(?:"
3  r"|/ingress/(session|validate_session)"
4  r"|/addons/[^/]+/info"
5  r")$"
6 )

Definition at line 45 of file websocket_api.py.