Yjs

Get Yjs document encoded as a binary Yjs update

Changed on

This endpoint returns the room's Yjs document encoded as a single binary update. This can be used by Y.applyUpdate(responseBody) to get a copy of the document in your back end. See Yjs documentation for more information on working with updates. To return a subdocument instead of the main document, pass its guid. Corresponds to liveblocks.getYjsDocumentAsBinaryUpdate.

get/rooms/{roomId}/ydoc-binary

Request

  • Base URL: https://api.liveblocks.io/v2
  • URL: https://api.liveblocks.io/v2/rooms/{roomId}/ydoc-binary
  • Auth: none declared

Path parameters

roomIdstring required

ID of the room

Example:my-room-id

Query parameters

guidstring

ID of the subdocument

Example:subdoc-guid-123

Response

Success. Returns the room's Yjs document encoded as a binary Yjs update.

Changes

    • info

      api operation id get-rooms-roomId-ydoc-binary removed and replaced with get-yjs-document-as-binary-update

    • breaking

      the response's body type changed from array to string, and format from no format to binary for status