Skip to main content

WebSocket Events

SDD Classification: L3-Technical Authority: Engineering Team Review Cycle: Quarterly
This document provides a complete reference for all WebSocket event types, their payloads, and handling patterns for real-time collaboration.

Event Message Structure

All WebSocket messages follow a standard JSON format:

Message Fields


Event Categories


Document Operation Events

Insert Operation

Client sends content insertion:

Delete Operation

Client sends content deletion:

Format Operation

Client applies formatting:

Operation Acknowledgment

Server acknowledges received operation:

Operation Broadcast

Server broadcasts operation to other clients:

Presence Events

User Joined

When a user connects to the document:

User Left

When a user disconnects:

Cursor Update

Real-time cursor position updates:

Typing Indicator

Shows when a user is actively typing:

Comment Events

Comment Added

New comment created:

Comment Updated

Comment content modified:

Comment Resolved

Comment thread resolved:

Comment Deleted

Comment removed:

System Events

Connection Acknowledgment

Sent after successful connection:

Document Sync

Full document state synchronization:

Error Event

Error notification:

Heartbeat (Ping/Pong)

Connection health check: Client sends:
Server responds:

Event Handling Patterns

Event Dispatcher

Event Batching

Handle multiple rapid events efficiently:

Event Reference Table



Document Status: Complete Version: 2.0