Skip to main content

Comments

Comments are a collaboration tool and can be left on items from the right-hand sidebar.

The comments Object​

Field NameTypeDescription
iduuidUnique identifier for the comment object (UUID format).
collectionstringCollection identifier in which the item resides.
itemstringThe item the comment is created for.
commentstringUser comment. This will store the comments that show up in the right sidebar of the item edit page in the TrackVision UI.
date_createddatetimeTimestamp in ISO8601 when the comment was created.
date_updateddatetimeTimestamp in ISO8601 when the comment was last updated.
user_createdobjectThe user who created the comment. Many-to-one relationship to users.
user_updatedobjectThe user who last updated the comment. Many-to-one relationship to users.

Get Comments​

Returns a list of comments.

Request​

GET /comments

Query Parameters​

Supports all global query parameters.

Returns​

An array of up to limit comment objects. If no items are available, data will be an empty array.

Get Comment by ID​

Returns a single comment by primary key.

Request​

GET /comments/:id

Query Parameters​

Supports all global query parameters.

Response​

Returns a comment object if a valid identifier was provided.

Create a Comment​

Create a new comment. This action is only available to authenticated users.

Request​

POST /comments

Provide a comment object as the body of your request.

Query Parameters​

Supports all global query parameters.

Request Body​

A partial comment object.

Response​

Returns the comment object of the comment that was created.

Create Multiple Comments​

Create multiple new comments. This action is only available to authenticated users.

Request​

POST /comments

Provide an array of comment objects as the body of your request.

Query Parameters​

Supports all global query parameters.

Request Body​

An array of partial comment objects. name is required.

Response​

Returns an array of comment objects of the comments that were created.

Update a Comment​

Update an existing comment. This action is only available to authenticated users.

Request​

PATCH /comments/:id

Provide a partial comment object as the body of your request.

Query Parameters​

Supports all global query parameters.

Request Body​

A partial comment object.

Response​

Returns the comment object of the comment that was updated.

Update Multiple Comments​

Update multiple existing comments. This action is only available to authenticated users.

Request​

PATCH /comments

{
"keys": comment_id_array,
"data": partial_comment_objects
}

Query Parameters​

Supports all global query parameters.

Request Body​

keys Required
Array of primary keys of the comments you'd like to update.

data Required
Any of the comment object's properties.

Response​

Returns the comment objects of the comments that were updated.

Delete a Comment​

Delete an existing comment. This action is only available to authenticated users.

Request​

DELETE /comments/:id

Response​

Empty body.

Delete Multiple Comments​

Delete multiple existing comments. This action is only available to authenticated users.

Request​

DELETE /comments

Provide an array of item IDs as your request body.

Request Body​

An array of comment primary keys.

Returns​

Empty body.