For AI agents: markdown of this page — /docs-content-en/entities/task-comments/get.md documentation index — /llms.txt
Get comment
GET /v1/tasks/:taskId/comments/:id
Returns a single task comment by its identifier. Works both for comments from the new card chat and for records in the old card comments block.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
taskId (path) |
number | yes | Task ID |
id (path) |
number | yes | Comment ID (from GET /v1/tasks/:taskId/comments or the response of POST /v1/tasks/:taskId/comments) |
Examples
curl — personal key
curl "https://vibecode.bitrix24.com/v1/tasks/289/comments/36559" \
-H "X-Api-Key: YOUR_API_KEY"
curl — OAuth app
curl "https://vibecode.bitrix24.com/v1/tasks/289/comments/36559" \
-H "X-Api-Key: YOUR_APP_KEY" \
-H "Authorization: Bearer USER_SESSION_TOKEN"
JavaScript — personal key
const res = await fetch('https://vibecode.bitrix24.com/v1/tasks/289/comments/36559', {
headers: {
'X-Api-Key': 'YOUR_API_KEY',
},
})
const { success, data } = await res.json()
console.log(data.message)
JavaScript — OAuth app
const res = await fetch('https://vibecode.bitrix24.com/v1/tasks/289/comments/36559', {
headers: {
'X-Api-Key': 'YOUR_APP_KEY',
'Authorization': 'Bearer USER_SESSION_TOKEN',
},
})
const { success, data } = await res.json()
Response fields
| Field | Type | Description |
|---|---|---|
success |
boolean | Always true on success |
data.id |
number | Comment identifier |
data.taskId |
number | Parent task ID |
data.authorId |
number | Author. Profile: GET /v1/users/:authorId |
data.message |
string | Comment text (supports BB-code) |
data.createdAt |
datetime | Creation date (UTC ISO 8601) |
Response example
{
"success": true,
"data": {
"id": 36559,
"taskId": 289,
"authorId": 1,
"message": "Added a draft of the report to the comments — please take a look.",
"createdAt": "2026-05-13T12:30:58.000Z"
}
}
Error response example
404 — comment not found:
{
"success": false,
"error": {
"code": "NOT_FOUND",
"message": "Comment not found"
}
}
Errors
| HTTP | Code | Description |
|---|---|---|
| 400 | INVALID_PARAMS |
taskId or id are not positive integers |
| 404 | NOT_FOUND |
A comment with this id was not found either in the chat or in the old card comments block |
| 403 | SCOPE_DENIED |
The API key does not have the task scope |
| 401 | TOKEN_MISSING |
The API key has no configured tokens |
Full list of common API errors — Errors.
Known specifics
Two-stage lookup. On the new card the API first searches for the comment among the last 200 messages of the task chat. If there is no match — for example, the comment is older than the last 200 or belongs to the old card — the request automatically falls back to the old read path. This is transparent to the client: the response format is the same.
See also
- List comments — get the ID of the comment you need
- Create comment — add a new one
- Update comment — change the text
- Delete comment — remove a comment
- Tasks — parent entity