Skip to main content
Essal Office uses Operational Transformation (OT) to allow multiple users to edit the same document simultaneously. Changes are merged server-side and broadcast to all connected clients within milliseconds.

Connecting to a Document Session

Real-time collaboration is facilitated over a WebSocket connection. Establish a session using the collaboration endpoint:
The SDK handles reconnection, operation buffering, and state synchronisation automatically.

Presence Awareness

When a user connects to a document session, their presence is broadcast to all other participants. You can subscribe to presence events to show live cursors and avatars:

Conflict Resolution

Essal Office resolves edit conflicts using server-authoritative OT. Each operation carries a revision number. If two clients submit conflicting operations at the same revision, the server transforms them into compatible operations and broadcasts the resolved result.
You do not need to implement conflict resolution logic in your client. The OT engine on the server handles all transformations. If you use the Essal SDK, this is fully transparent.

Document History

All operations are stored as an immutable history log. You can retrieve the full change history for a document:
Each entry includes the operation type, the author, a timestamp, and a diff summary. You can restore any previous revision using the revision restore endpoint.

Handling Disconnections

The SDK automatically buffers local operations during a disconnection and replays them once the connection is re-established. Clients that have been offline for more than 30 minutes will receive a full document snapshot rather than a delta sync.