Skip to main content

Get threads

This endpoint enables you to get all threads within a specific room. Threads are collections of comments associated with specific points or areas on the screen, facilitating precise and context-specific discussions.

How to use

You can use the following cURL to obtain a response from this endpoint:

curl --location --request GET https://api.superviz.com/threads \
--header "client_id: ${YOUR CLIENT_ID}" \
--header "secret: ${YOUR SECRET}"

Query Parameters

You must use the roomId parameter to filter the threads. This parameter is required and will return all the threads made in the specified room.

NameDescription
roomIdRequired. The ID of the room for which you want to fetch threads.

Headers

When using this endpoint, you need to provide the Client ID and Secret Key. The following headers are required:

NameDescription
client_idRequired. You need to use the Client ID to authenticate in this repository. You can retrieve your Client ID under the Dashboard > Developer > Keys.
secretRequired. You need to use the Secret Key to authenticate in this repository. You can create a new API Secret under our Dashboard > Developer > Keys.

Response

Status code 200 will indicate a successful result in getting the threads. The response will be in JSON format and include the following fields:

NameTypeDescription
uuidstringThe unique identifier of the thread.
participantIdstringThe ID of the participant who created the thread.
positionstringThe position of the thread on the screen.
createdAtstringThe date and time when the thread was created.
resolvedbooleanIndicates whether the thread has been resolved.
commentsarrayAn array of comments associated with this thread.

Each comment in the comments array contains the following fields:

NameTypeDescription
uuidstringThe unique identifier of the comment.
threadIdstringThe ID of the thread this comment belongs to.
participantIdstringThe ID of the participant who made the comment.
textstringThe content of the comment.
createdAtstringThe date and time when the comment was created.
mentionsarrayAn array of user mentions in the comment.
participantobjectInformation about the participant who made the comment.

The participant object contains:

NameTypeDescription
namestringThe name of the participant.
createdAtstringThe date and time when the participant was created.
avatarstringThe URL of the participant's avatar image.
emailstringThe email address of the participant.

The mentions array contains:

NameTypeDescription
participantIdstringThe ID of the participant who was mentioned.
namestringThe name of the participant who was mentioned.

Example Response:

[
{
"uuid": "5ad641d5-c5bf-4003-9169-566f889ed102",
"participantId": "8972652",
"position": "{ x: 100, y: 100, type: \"text\" }",
"resolved": false,
"comments": [
{
"uuid": "8b2eee64-99ca-499e-b736-de9c1782224b",
"participantId": "8972652",
"threadId": "5ad641d5-c5bf-4003-9169-566f889ed102",
"text": "asdasdasd",
"participant": {
"name": "steve",
"email": "steve@yourcompany.com",
"avatar": null,
"createdAt": "2024-09-12T23:06:30.299Z"
},
"mentions": [
{
"participantId": "9962632",
"name": "robson"
}
],
"createdAt": "2024-09-12T23:07:10.817Z"
}
],
"createdAt": "2024-09-12T23:06:46.654Z"
}
]