Comments

Get room threads

Changed on

This endpoint returns the threads in the requested room. Corresponds to liveblocks.getThreads.

get/rooms/{roomId}/threads

Request

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

Path parameters

roomIdstring required

ID of the room

Example:my-room-id

Query parameters

querystring

Query to filter threads. You can filter by metadata, resolved, and visibility, for example, metadata["status"]:"open" AND metadata["color"]:"red" AND resolved:true AND visibility:"private". Learn more about filtering threads with query language.

Example:metadata["color"]:"blue"

Response

Success. Returns list of threads in a room.

Example response

{
  "data": [
    {
      "type": "thread",
      "id": "th_abc123",
      "roomId": "my-room-id",
      "comments": [
        {
          "type": "comment",
          "threadId": "th_abc123",
          "roomId": "my-room-id",
          "id": "cm_abc123",
          "userId": "alice",
          "createdAt": "2022-07-13T14:32:50.697Z",
          "body": {
            "version": 1,
            "content": []
          },
          "metadata": {},
          "reactions": [],
          "attachments": []
        }
      ],
      "createdAt": "2022-07-13T14:32:50.697Z",
      "updatedAt": "2022-07-13T14:32:50.697Z",
      "metadata": {},
      "resolved": false,
      "visibility": "public"
    }
  ]
}

Changes

    • info

      added the required property // to the response with the status

    • info

      api operation id get-rooms-roomId-threads removed and replaced with get-threads

    • info

      the response property became required for the status

    • info

      the response property ///// became required for the status

    • info

      the response property ///// became required for the status

    • info

      the response property //// became required for the status

    • info

      the response property // became required for the status

    • info

      the response property // became required for the status

    • info

      the response's property default value comment was removed for the status

    • info

      added 'propertyNames' constraint to the //// response property for the status

    • info

      added 'propertyNames' constraint to the // response property for the status

    • info

      added the required property //// to the response with the status

    • info

      added the required property //// to the response with the status

    • info

      the response required property //// became not read-only for the status