Gets list of comments
GET /api/sync/v1/todos/comments/{recordId}
Operation id: fetchCommentList
Description
The API allows to fetch a list of comments entered using the ADD COMMENT API. This API is accessible to the recipients of the to-do or the users who have task-view-all permission and are part of that site where the to-do is created.
The API is paginated where the pagesize and offset can be set as query parameters with default value of 10 and 0 respectively
Tags: Comment APIs
Parameters
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
recordId | integer (int32) | Yes |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
markerNeeded | boolean | No | |
offSet | integer (int32) | No | |
pageSize | integer (int32) | No |
Security
- Bearer (http / bearer)
- enter the client service token value.
Responses
200 — Comment List
Content type: application/json
400 — Bad Request
401 — Unauthorized Access
403 — Forbidden
422 — Unprocessable Entity
500 — Internal Server Error
Response models
200 — Comment List
Content type: application/json
Schema
| Property | Type | Required | Description |
|---|---|---|---|
message | string | No | |
status | string | No | |
statusCode | integer (int32) | No | |
debugErrorMessage | string | No | |
messageCode | string | No | message codes |
messageParams | array | No | |
paginationMap | object | No | |
commentList | array | No | |
data | object | No |
{
"type": "object",
"properties": {
"message": {
"type": "string"
},
"status": {
"type": "string",
"enum": [
"SUCCESS",
"FAIL",
"BAD_REQUEST",
"NO_CONTENT",
"UNAUTHORIZED",
"FORBIDDEN",
"NOT_FOUND",
"INTERNAL_SERVER_ERROR",
"UNSUPPORTED_MEDIA_TYPE",
"UNPROCESSABLE_ENTITY"
]
},
"statusCode": {
"type": "integer",
"format": "int32"
},
"debugErrorMessage": {
"type": "string"
},
"messageCode": {
"type": "string",
"description": "message codes",
"items": {
"type": "string",
"example": [
"ERROR403_09-You do not have permission to perform this action."
]
}
},
"messageParams": {
"type": "array",
"items": {
"type": "string"
}
},
"paginationMap": {
"type": "object",
"properties": {
"totalElements": {
"type": "integer",
"format": "int32"
},
"totalPages": {
"type": "integer",
"format": "int32"
},
"last": {
"type": "boolean"
},
"first": {
"type": "boolean"
},
"currentPage": {
"type": "integer",
"format": "int32"
},
"pageSize": {
"type": "integer",
"format": "int32"
}
}
},
"commentList": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "integer",
"format": "int32"
},
"recordId": {
"type": "integer",
"format": "int32"
},
"section": {
"type": "string"
},
"commentText": {
"type": "string"
},
"parentId": {
"type": "integer",
"format": "int32"
},
"commentType": {
"type": "string",
"enum": [
"TASK",
"ASSIGNMENT"
]
},
"createdAt": {
"type": "string",
"format": "date-time"
},
"createdBy": {
"type": "object",
"properties": {
"userId": {
"type": "integer",
"format": "int32"
},
"firstName": {
"type": "string"
},
"lastName": {
"type": "string"
},
"employeeId": {
"type": "string"
},
"profilePhoto": {
"type": "string"
},
"presence": {
"type": "object"
},
"roleId": {
"type": "integer",
"format": "int32"
},
"siteId": {
"type": "integer",
"format": "int32"
},
"roleName": {
"type": "string"
},
"alias": {
"type": "string"
},
"name": {
"type": "string"
},
"siteName": {
"type": "string"
},
"roles": {
"type": "array",
"items": {
"type": "object"
}
}
}
},
"mentions": {
"type": "array",
"items": {
"type": "object",
"required": [
"departmentId",
"groupId",
"roleId",
"siteId",
"userId"
]
}
},
"attachments": {
"type": "array",
"items": {
"type": "object",
"required": [
"fileName",
"fileuri"
]
}
}
}
}
},
"data": {
"type": "object"
}
}
}