For AI agents: markdown of this page — /docs-content-en/entities/calendar-events/update.md documentation index — /llms.txt
Update event
PATCH /v1/calendar-events/:id
Updates fields of an existing event. Pass only the fields being changed — Vibecode automatically reads the current event and supplies type, ownerId, name, which Bitrix24 requires on every update.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
Parameterid (path) |
Typenumber | Requiredyes | DescriptionEvent ID. List: GET /v1/calendar-events |
Request fields (body)
All fields are optional. Pass only the ones you change, for example name or location. For an all-day event, you can change only from or only to: the omitted boundary is preserved.
| Field | Type | Required | Description |
|---|---|---|---|
Fieldname |
Typestring | Requiredno | DescriptionEvent title. If omitted, taken from the current event |
Fieldtype |
Typestring | Requiredno | DescriptionCalendar type: user, group, company_calendar. If omitted, taken from the current event |
FieldownerId |
Typenumber | Requiredno | DescriptionCalendar owner ID: an employee (GET /v1/users) or a workgroup. If omitted, taken from the current event |
Fieldfrom |
Typedatetime | Requiredno | DescriptionNew event start in ISO 8601. Pass together with timezoneFrom |
FieldtimezoneFrom |
Typestring | Requiredno | DescriptionStart timezone (IANA name, UTC) |
Fieldto |
Typedatetime | Requiredno | DescriptionNew event end in ISO 8601. Pass together with timezoneTo |
FieldtimezoneTo |
Typestring | Requiredno | DescriptionEnd timezone (IANA name, UTC) |
FieldskipTime |
Typeboolean | Requiredno | DescriptionAll-day event. With true the duration is fixed at 24 hours. If omitted, the current flag is preserved; false clears it |
Fielddescription |
Typestring | Requiredno | DescriptionDescription |
Fieldlocation |
Typestring | Requiredno | DescriptionVenue |
Fieldcolor |
Typestring | Requiredno | DescriptionEvent color in #RRGGBB format |
Fieldimportance |
Typestring | Requiredno | DescriptionImportance: high, normal, low |
Fieldaccessibility |
Typestring | Requiredno | DescriptionAvailability: busy, quest, free, absent |
FieldisPrivate |
Typeboolean | Requiredno | DescriptionPrivate event — details are hidden from other users |
FieldsectionId |
Typenumber | Requiredno | DescriptionID of the calendar section to move the event to. Section list: GET /v1/calendar-sections |
Fieldremind |
Typearray | Requiredno | DescriptionReminder settings. Each element: {type: 'min' | 'hour' | 'day', count: <number>} |
Fieldrrule |
Typeobject | Requiredno | DescriptionRecurrence schedule: FREQ, INTERVAL, BYDAY, UNTIL or COUNT. Structure — Create event |
Fieldattendees |
Typenumber[] | Requiredno | DescriptionArray of invited employee IDs. List: GET /v1/users. Pass it together with isMeeting: true — without the flag in the body the array is ignored with no error and no warning, even if the event is already a meeting. The array you send replaces the previous attendee list entirely. Whether the IDs exist is not checked: any number becomes an attendee U<id>. CRM elements are linked with the crmFields field |
FieldisMeeting |
Typeboolean | Requiredno | DescriptionMarks the event as a meeting with invitations. Required in the body together with attendees, otherwise the attendee list does not change |
FieldcrmFields |
Typestring[] | Requiredno | DescriptionCRM elements the event is linked to: D_<id> deal, C_<id> contact, L_<id> lead, CO_<id> company. The array you send replaces the previous links entirely, [] clears them all — but only on this endpoint and on POST: in a batch request an empty array is refused (INVALID_PARAMS in data.errors on POST /v1/batch, 400 BATCH_ITEM_VALIDATION for the whole batch on POST /v1/calendar-events/batch). A field left out of the body keeps the links already stored. Full description — Event fields |
Description of all event fields — Event fields.
Examples
curl — personal key
curl -X PATCH "https://vibecode.bitrix24.com/v1/calendar-events/7773" \
-H "X-Api-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "Team call — extended meeting",
"to": "2026-06-10T12:00:00",
"timezoneTo": "UTC",
"location": "Meeting room #3"
}'
curl — OAuth application
curl -X PATCH "https://vibecode.bitrix24.com/v1/calendar-events/7773" \
-H "X-Api-Key: YOUR_APP_KEY" \
-H "Authorization: Bearer USER_SESSION_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"name": "Team call — extended meeting",
"to": "2026-06-10T12:00:00",
"timezoneTo": "UTC",
"location": "Meeting room #3"
}'
JavaScript — personal key
const res = await fetch('https://vibecode.bitrix24.com/v1/calendar-events/7773', {
method: 'PATCH',
headers: {
'X-Api-Key': 'YOUR_API_KEY',
'Content-Type': 'application/json',
},
body: JSON.stringify({
name: 'Team call — extended meeting',
to: '2026-06-10T12:00:00',
timezoneTo: 'UTC',
location: 'Meeting room #3',
}),
})
const { success, data } = await res.json()
JavaScript — OAuth application
const res = await fetch('https://vibecode.bitrix24.com/v1/calendar-events/7773', {
method: 'PATCH',
headers: {
'X-Api-Key': 'YOUR_APP_KEY',
'Authorization': 'Bearer USER_SESSION_TOKEN',
'Content-Type': 'application/json',
},
body: JSON.stringify({
name: 'Team call — extended meeting',
to: '2026-06-10T12:00:00',
timezoneTo: 'UTC',
location: 'Meeting room #3',
}),
})
const { success, data } = await res.json()
Response fields
| Field | Type | Description |
|---|---|---|
Fieldsuccess |
Typeboolean | DescriptionAlways true on success |
Fielddata |
Typeobject | DescriptionThe updated event (all fields — see Event fields) |
Response example
{
"success": true,
"data": {
"id": 7773,
"parentId": 7773,
"type": "user",
"ownerId": 1,
"name": "Team call — extended meeting",
"from": "2026-06-10T10:00:00+00:00",
"to": "2026-06-10T12:00:00+00:00",
"skipTime": false,
"durationSeconds": 7200,
"updatedAt": "06/05/2026 11:30:00 am",
"accessibility": "busy",
"importance": "normal",
"sectionId": 3,
"location": "Meeting room #3"
}
}
Error response example
404 — event not found:
{
"success": false,
"error": {
"code": "ENTITY_NOT_FOUND",
"message": "calendarEvent 99999999 not found"
}
}
Errors
| HTTP | Code | Description |
|---|---|---|
| HTTP404 | CodeENTITY_NOT_FOUND |
DescriptionThe event with the specified id does not exist |
| HTTP400 | CodeREADONLY_FIELD |
DescriptionA read-only field was passed in the request body — the full list is in Event fields, where such fields are marked "yes" in the RO column |
| HTTP400 | CodeEMPTY_UPDATE_BODY |
DescriptionThe request body is empty — pass at least one field |
| HTTP422 | CodeBITRIX_NO_EFFECT |
DescriptionThe portal did not return the all-day flag or a date needed for a safe update |
| HTTP400 | CodeNESTED_FIELDS_ENVELOPE |
DescriptionThe body contains an object under fields instead of root-level fields; the event is not updated |
| HTTP403 | CodeSCOPE_DENIED |
DescriptionThe API key does not have the calendar scope |
| HTTP401 | CodeTOKEN_MISSING |
DescriptionThe API key has no configured tokens |
Full list of common API errors — Errors.
Known specifics
An object under fields does not wrap event fields. Pass them at the JSON root: the schema does not declare fields, so the object is rejected with 400 NESTED_FIELDS_ENVELOPE before the update.
An unknown scalar field in the body is ignored without an error. A 200 response does not confirm the field was written. Check field names against the table above.