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

Update activity

PATCH /v1/activities/:id

Updates fields of an existing activity. Pass only the fields you want to change. Full list in the field reference.

The activity type typeId is set at creation only — a request carrying it answers 400 READONLY_FIELD. To change the type, create a new activity via POST /v1/activities and delete the previous one.

Frequently updated fields

Parameter Type Description
completed boolean Mark as completed
subject string Subject
deadline datetime Deadline
responsibleId number Responsible person. List: GET /v1/users
priority number Priority: 1 — low, 2 — medium, 3 — high
description string Description

Examples

curl — personal key

Terminal
curl -X PATCH "https://vibecode.bitrix24.com/v1/activities/3894" \
  -H "X-Api-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "completed": true,
    "subject": "Project meeting (completed)"
  }'

curl — OAuth application

Terminal
curl -X PATCH "https://vibecode.bitrix24.com/v1/activities/3894" \
  -H "X-Api-Key: YOUR_APP_KEY" \
  -H "Authorization: Bearer USER_SESSION_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "completed": true,
    "subject": "Project meeting (completed)"
  }'

JavaScript — personal key

javascript
const res = await fetch('https://vibecode.bitrix24.com/v1/activities/3894', {
  method: 'PATCH',
  headers: {
    'X-Api-Key': 'YOUR_API_KEY',
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
    completed: true,
    subject: 'Project meeting (completed)',
  }),
})

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

JavaScript — OAuth application

javascript
const res = await fetch('https://vibecode.bitrix24.com/v1/activities/3894', {
  method: 'PATCH',
  headers: {
    'X-Api-Key': 'YOUR_APP_KEY',
    'Authorization': 'Bearer USER_SESSION_TOKEN',
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
    completed: true,
    subject: 'Project meeting (completed)',
  }),
})

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

Response fields

Field Type Description
data object Updated activity object with all fields — see Fields

The updated activity object — see Activity fields.

Response example

JSON
{
  "success": true,
  "data": {
    "id": 100,
    "subject": "Updated subject",
    "completed": true,
    "responsibleId": 1,
    "createdAt": "2026-04-15T12:00:00.000Z",
    "updatedAt": "2026-04-15T13:00:00.000Z"
  }
}

Error response example

404 — activity not found:

JSON
{
  "success": false,
  "error": {
    "code": "ENTITY_NOT_FOUND",
    "message": "Item not found"
  }
}

Errors

HTTP Code Description
404 ENTITY_NOT_FOUND Activity not found
403 ACCESS_DENIED No access
400 READONLY_FIELD The body carries a field that cannot be changed after creation — typeId, or a read-only field (id, authorId, editorId, associatedEntityId)
400 INVALID_REQUEST Invalid fields
403 SCOPE_DENIED The API key lacks the crm scope
401 TOKEN_MISSING The API key has no configured tokens

Full list of common API errors — Errors.

See also