For AI agents: markdown of this page — /docs-content-en/openlines/config/update.md documentation index — /llms.txt
Update Open Channel configuration
PATCH /v1/openline-configs/:id
Updates fields of an existing Open Channel configuration. Pass only the fields you change — the rest are left untouched. Full field list — Configuration fields.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
Parameterid (path) |
Typenumber | Requiredyes | DescriptionNumeric configuration identifier |
Request fields (body)
The request body must not be empty — at least one field is required. Pass only the fields you want to change.
Field names. Pass every field in camelCase (name, active, queueType, queueTime, workTimeFrom, etc.) — the canonical case. UPPER_SNAKE_CASE names are also accepted for backward compatibility.
Boolean fields (active, …) accept true / false — the value is coerced to "Y"/"N" automatically. For example, { "active": false } (or { "ACTIVE": false }) turns the channel off.
| Field | Type | Description |
|---|---|---|
Fieldname |
Typestring | DescriptionOpen Channel name |
Fieldactive |
Typeboolean | DescriptionWhether the channel is active (true / false) |
FieldcrmCreate |
Typestring | DescriptionType of CRM record created on first contact. Allowed values: none, lead, deal |
FieldqueueTime |
Typenumber | DescriptionOperator response wait time (seconds) |
FieldnoAnswerTime |
Typenumber | DescriptionTime until the "No answer" rule triggers (seconds) |
FieldwelcomeMessageText |
Typestring | DescriptionWelcome message text |
FieldworkTimeFrom |
Typestring | DescriptionStart of working hours, for example "9" or "9.30" |
FieldworkTimeTo |
Typestring | DescriptionEnd of working hours, for example "18" or "17.30" |
FieldworkTimeTimezone |
Typestring | DescriptionWorking-hours time zone |
Full list of available fields — Configuration fields.
Examples
curl — personal key
curl -X PATCH "https://vibecode.bitrix24.com/v1/openline-configs/29" \
-H "X-Api-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"queueTime": 120,
"welcomeMessageText": "Hello! How can we help?"
}'
curl — OAuth application
curl -X PATCH "https://vibecode.bitrix24.com/v1/openline-configs/29" \
-H "X-Api-Key: YOUR_APP_KEY" \
-H "Authorization: Bearer USER_SESSION_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"queueTime": 120,
"welcomeMessageText": "Hello! How can we help?"
}'
JavaScript — personal key
const res = await fetch('https://vibecode.bitrix24.com/v1/openline-configs/29', {
method: 'PATCH',
headers: {
'X-Api-Key': 'YOUR_API_KEY',
'Content-Type': 'application/json',
},
body: JSON.stringify({
queueTime: 120,
welcomeMessageText: 'Hello! How can we help?',
}),
})
const { success, data } = await res.json()
JavaScript — OAuth application
const res = await fetch('https://vibecode.bitrix24.com/v1/openline-configs/29', {
method: 'PATCH',
headers: {
'X-Api-Key': 'YOUR_APP_KEY',
'Authorization': 'Bearer USER_SESSION_TOKEN',
'Content-Type': 'application/json',
},
body: JSON.stringify({
queueTime: 120,
welcomeMessageText: 'Hello! How can we help?',
}),
})
const { success, data } = await res.json()
Response fields
| Field | Type | Description |
|---|---|---|
Fieldsuccess |
Typeboolean | DescriptionAlways true on success |
Fielddata |
Typeobject | DescriptionOperation result |
Fielddata.id |
Typenumber | DescriptionIdentifier of the updated configuration |
Fielddata.updated |
Typeboolean | Descriptiontrue — the update was applied |
Fieldmeta.warnings |
Typestring[] | DescriptionOptional. Present when some passed fields are unrecognised — lists the keys Bitrix24 ignored |
Response example
{
"success": true,
"data": {
"id": 29,
"updated": true
}
}
Error response example
404 — configuration not found:
{
"success": false,
"error": {
"code": "ENTITY_NOT_FOUND",
"message": "openlineConfig 99999 not found"
}
}
Errors
| HTTP | Code | Description |
|---|---|---|
| HTTP400 | CodeINVALID_ID |
DescriptionThe id parameter is not a positive integer |
| HTTP400 | CodeVALIDATION_ERROR |
DescriptionThe request body is empty — at least one field must be passed |
| HTTP400 | CodeVALIDATION_ERROR |
DescriptionThe body has no recognised field (all keys are unknown) — the message lists the unrecognised fields |
| HTTP400 | CodeVALIDATION_ERROR |
DescriptionThe crmCreate value is not none, lead, or deal |
| HTTP400 | CodeREADONLY_FIELD |
DescriptionA read-only field (id, queue, dateCreate, and others) was passed in the body |
| HTTP401 | CodeTOKEN_MISSING |
DescriptionThe API key has no configured tokens |
| HTTP403 | CodeSCOPE_DENIED |
DescriptionThe API key lacks the imopenlines scope |
| HTTP404 | CodeENTITY_NOT_FOUND |
DescriptionA configuration with the given id does not exist |
Full list of common API errors — Errors.
Known specifics
The response contains only id and data.updated: true — there are no configuration fields in the response. To get the current values of all fields after the update, call GET /v1/openline-configs/:id.
Request body validation. Unknown keys in the request body are not saved. Vibecode checks the body against the full field schema (Configuration fields) and reacts as follows:
- no field is recognised — the request is rejected with
400 VALIDATION_ERRORbefore the Bitrix24 call, and the message lists the unrecognised fields. - at least one field is recognised but some keys are unknown — the update is applied, and the response carries
meta.warningswith the list of ignored keys. crmCreatehas a value other thannone,lead, ordeal— the whole body is rejected with400 VALIDATION_ERRORbefore Bitrix24 is called, and no submitted change is applied.- a read-only field (
id,queue,dateCreate, and others) is passed in the body — the request is rejected with400 READONLY_FIELD.