> For a complete documentation index, fetch https://docs.voximplant.ai/llms.txt

# WebSocketEvents

## Values

Triggered when the WebSocket connection is opened. `WebSocket.onopen` is called right before any other handlers.

Triggered when the WebSocket connection is closed. `WebSocket.onclose` is called right before any other handlers.

Triggered when a message is received by a target object. `WebSocket.onmessage` is called right before any other handlers.

Triggers when an error occurs during the WebSocket connection. `WebSocket.onerror` is called right before any other handlers.

Triggered when the WebSocket connection is created. `WebSocket.oncreated` is called right before any other handlers.

Triggered when the audio stream sent by a third party through a WebSocket is started playing.

Triggers after the end of the audio stream sent by a third party through a WebSocket (**1 second of silence**).