For AI agents: markdown of this page — /docs-content-en/chats/service/promotions.md documentation index — /llms.txt
Promo hints
The messenger promo hints active for the user — hints about new features that the Bitrix24 interface shows once. The list covers all device types at once.
Get active hints
GET /v1/chats/promotions
The v2 messenger method im.v2.Promotion.listActive.
Parameters
There are no parameters. Any query parameter is rejected with 400 INVALID_PARAMS, including type: Bitrix24 reads it only from a form body and would silently drop it.
Examples
curl — personal key
curl "https://vibecode.bitrix24.com/v1/chats/promotions" \
-H "X-Api-Key: YOUR_API_KEY"
curl — OAuth application
curl "https://vibecode.bitrix24.com/v1/chats/promotions" \
-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/chats/promotions', {
headers: { 'X-Api-Key': 'YOUR_API_KEY' },
})
const { data: promotions } = await res.json()
console.log('Active hints:', promotions.length)
JavaScript — OAuth application
const res = await fetch('https://vibecode.bitrix24.com/v1/chats/promotions', {
headers: {
'X-Api-Key': 'YOUR_APP_KEY',
'Authorization': 'Bearer USER_SESSION_TOKEN',
},
})
const { data: promotions } = await res.json()
console.log(promotions.map((p) => p.id))
Response fields
| Field | Type | Description |
|---|---|---|
data[] |
object[] | Active hints |
data[].id |
string | Hint ID, for example im:collab-helpdesk-sidebar:30102024:all. The last part is the device type |
data[].params.chatId |
number | null | The chat the hint belongs to; null — the whole messenger |
Response example
{
"success": true,
"data": [
{ "id": "im:collab-helpdesk-sidebar:30102024:all", "params": { "chatId": null } },
{ "id": "im:download-several-files:22112024:all", "params": { "chatId": null } }
]
}
Error response example
400 — type was passed:
{
"success": false,
"error": {
"code": "INVALID_PARAMS",
"message": "Query parameter `type` is not accepted by GET /v1/chats/promotions: Bitrix24 reads it only from a form body, so the endpoint answers the promotions of every device type."
}
}
Errors
| HTTP | Code | Description |
|---|---|---|
| 400 | INVALID_PARAMS |
A query parameter was passed — the operation accepts none |
| 401 | TOKEN_MISSING |
The API key has no Bitrix24 tokens configured |
| 403 | SCOPE_DENIED |
The API key does not have the im scope |
| 422 | BITRIX_ERROR |
Bitrix24 returned an error; the portal code is in error.b24Code |
| 502 | BITRIX_UNAVAILABLE |
Bitrix24 is unavailable or returned a server error |
The full list of common API errors — Errors.
Known specifics
- A hint cannot be marked as viewed through the API: the
im.v2.Promotion.readmethod accepts data only in a form body, while the platform calls Bitrix24 with a JSON body. - There is no filtering by device type for the same reason — the list always covers all device types.