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

Namespaces

 auth
 
 commands
 
 connection
 
 const
 
 decorators
 
 error
 
 http
 
 messages
 
 sensor
 
 util
 

Functions

None async_register_command (HomeAssistant hass, str|const .WebSocketCommandHandler command_or_handler, const .WebSocketCommandHandler|None handler=None, VolSchemaType|None schema=None)
 
bool async_setup (HomeAssistant hass, ConfigType config)
 

Variables

 CONFIG_SCHEMA
 
 Final
 

Detailed Description

WebSocket based API for Home Assistant.

Function Documentation

◆ async_register_command()

None homeassistant.components.websocket_api.async_register_command ( HomeAssistant  hass,
str | const.WebSocketCommandHandler  command_or_handler,
const.WebSocketCommandHandler | None   handler = None,
VolSchemaType | None   schema = None 
)
Register a websocket command.

Definition at line 52 of file __init__.py.

◆ async_setup()

bool homeassistant.components.websocket_api.async_setup ( HomeAssistant  hass,
ConfigType  config 
)
Initialize the websocket API.

Definition at line 70 of file __init__.py.

Variable Documentation

◆ CONFIG_SCHEMA

homeassistant.components.websocket_api.CONFIG_SCHEMA

Definition at line 47 of file __init__.py.

◆ Final

homeassistant.components.websocket_api.Final

Definition at line 43 of file __init__.py.