For AI agents: markdown of this page — /docs-content-en/entities/task-comments/update.md documentation index — /llms.txt

Update comment

PATCH /v1/tasks/:taskId/comments/:id

Changes the text of an existing task comment. Available only on Bitrix24 accounts with the old task card: on the new card the method returns 410 GONE with an explanation.

Parameters

Parameter Type Required Description
taskId (path) number yes Task ID
id (path) number yes Comment ID

Request fields (body)

Field Type Required Description
message string New comment text, up to 65,535 characters

Examples

curl — personal key

Terminal
curl -X PATCH "https://vibecode.bitrix24.com/v1/tasks/289/comments/36559" \
  -H "X-Api-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "message": "Refined the wording in the comment."
  }'

curl — OAuth app

Terminal
curl -X PATCH "https://vibecode.bitrix24.com/v1/tasks/289/comments/36559" \
  -H "X-Api-Key: YOUR_APP_KEY" \
  -H "Authorization: Bearer USER_SESSION_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "message": "Refined the wording in the comment."
  }'

JavaScript — personal key

javascript
const res = await fetch('https://vibecode.bitrix24.com/v1/tasks/289/comments/36559', {
  method: 'PATCH',
  headers: {
    'X-Api-Key': 'YOUR_API_KEY',
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
    message: 'Refined the wording in the comment.',
  }),
})

const { success, data, error } = await res.json()
if (res.status === 410) console.log('New card — update unavailable:', error.message)

JavaScript — OAuth app

javascript
const res = await fetch('https://vibecode.bitrix24.com/v1/tasks/289/comments/36559', {
  method: 'PATCH',
  headers: {
    'X-Api-Key': 'YOUR_APP_KEY',
    'Authorization': 'Bearer USER_SESSION_TOKEN',
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
    message: 'Refined the wording in the comment.',
  }),
})

const { success, data, error } = await res.json()

Response fields

Field Type Description
success boolean true on a successful update on the old card
data.id number Identifier of the updated comment

Response example

Old card — the update was applied:

JSON
{
  "success": true,
  "data": {
    "id": 36559
  }
}

Error response example

410 — new task card (method unavailable):

JSON
{
  "success": false,
  "error": {
    "code": "GONE",
    "message": "Bitrix24 disabled update/delete for task comments in the new task card. To remove a comment, delete the source task or ask a portal admin to remove the message via the chat UI.",
    "hint": "Verified against apidocs.bitrix24.com on 2026-05-09 — the modern task-chat API accepts only new messages, no edit or delete."
  }
}

Errors

HTTP Code Description
400 INVALID_PARAMS taskId or id is not a positive integer
410 GONE The task was created on the new card — updating a comment is unavailable on the Bitrix24 side
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

Alternative for the new card. There is no way to change a posted comment programmatically. If the content is critical — delete the whole task (DELETE /v1/tasks/:id) and create a new one, or ask the Bitrix24 account admin to remove the message via the chat UI.

See also