Actions83
- AI Copilot Actions
- AI Knowledge Actions
- Attachment Actions
- Comment Actions
- Feed Actions
- Group Actions
- Inbox Actions
- Room Actions
- Storage Actions
- Thread Actions
- User Actions
- Delete Inbox Notification
- Get Inbox Notification
- Delete All Inbox Notifications
- Get Many Inbox Notifications
- Delete Notification Settings
- Get Notification Settings
- Update Notification Settings
- Delete Room Subscription Settings
- Get Room Subscription Settings
- Update Room Subscription Settings
- Get Many Room Subscription Settings
- Yjs Actions
Yjs → Get Document (JSON)
AI-generatedSummary
Retrieve a Yjs document from a specified Liveblocks room in JSON format, optionally filtered by a key and Yjs type, and with optional inclusion of YText formatting.
Inputs
- Room ID (required) — The identifier of the Liveblocks room from which to retrieve the Yjs document.
- Formatting — Whether to include YText formatting in the returned document (boolean). Defaults to false.
- Key — An optional key to return only its corresponding value from the document.
- Yjs Type Override — Overrides the inferred Yjs type associated with the Key. Options are Y.Array, Y.Map, Y.Text, Y.XmlFragment, Y.XmlText. Defaults to Y.Map.
Output shape
A JSON object representing the Yjs document content for the specified room. If a Key is provided, the output is the value for that key optionally constrained by the Yjs Type Override. Includes YText formatting if requested.
The output document structure is derived from the Liveblocks API's getYjsDocument response. Errors can optionally include detailed request information if enabled via 'Include Request in Error' option.
Examples
Example 1: Retrieve the entire Yjs document as JSON for a Liveblocks room
Specify the Room ID, leave Key and Formatting empty or default.
Example 2: Retrieve the value for a specific key as a JSON object
Specify Room ID and Key; optionally set Yjs Type Override if the type of value differs from the default Y.Map.
Example 3: Retrieve Yjs document including YText formatting
Specify Room ID and set Formatting option to true.