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

List comments

GET /v1/timelines

Returns timeline comments attached to a specific CRM record. The entityType and entityId filters are required — without them the request returns 400 MISSING_REQUIRED_FILTER.

Parameters

Parameter Type Required Default Description
Parameterfilter (query) Typeobject Requiredyes Default— DescriptionThe parent CRM record: the entityType and entityId keys are required, their values are described below the table. The same keys are also accepted without the wrapper: ?entityType=deal&entityId=741.
Filtering syntax. Example: ?filter[entityType]=deal&filter[entityId]=741
Parameterlimit (query) Typenumber Requiredno Default50 DescriptionNumber of records (up to 5000). When limit > 50, Vibecode automatically requests several pages from Bitrix24
Parameteroffset (query) Typenumber Requiredno Default0 DescriptionSkip N records. When offset > 0, limit ≤ 500 is recommended
Parametersort (query) Typestring Requiredno Default— DescriptionSorting by creation date: sort=-createdAt puts the newest first, sort=createdAt the oldest first. Sorting by any other field, id included, is accepted without an error but does not change the order
Parameterorder (query) Typeobject Requiredno Default— DescriptionThe same sorting in map form: order[createdAt]=desc. If sort is also sent, sort applies. A direction other than asc or desc returns 400 INVALID_SORT_DIRECTION
Parameterselect (query) Typestring Requiredno Default— DescriptionField selection: ?select=id,comment,authorId

filter[entityType] is the type of the parent CRM record: deal, lead, contact, company or DYNAMIC_<entityTypeId> for smart processes, for example DYNAMIC_174. The entityTypeId value comes from GET /v1/smart-processes. filter[entityId] is the parent record ID, and its source depends on the type: GET /v1/deals, GET /v1/leads, GET /v1/contacts, GET /v1/companies, and for smart process items — GET /v1/items/:entityTypeId.

Examples

curl — personal key

Terminal
curl -g "https://vibecode.bitrix24.com/v1/timelines?filter[entityType]=deal&filter[entityId]=741" \
  -H "X-Api-Key: YOUR_API_KEY"

curl — OAuth application

Terminal
curl -g "https://vibecode.bitrix24.com/v1/timelines?filter[entityType]=deal&filter[entityId]=741" \
  -H "X-Api-Key: YOUR_APP_KEY" \
  -H "Authorization: Bearer USER_SESSION_TOKEN"

JavaScript — personal key

javascript
const res = await fetch('https://vibecode.bitrix24.com/v1/timelines?filter[entityType]=deal&filter[entityId]=741', {
  headers: {
    'X-Api-Key': 'YOUR_API_KEY',
  },
})

const { success, data, meta } = await res.json()
console.log(`Found ${meta.total} comments`)

JavaScript — OAuth application

javascript
const res = await fetch('https://vibecode.bitrix24.com/v1/timelines?filter[entityType]=deal&filter[entityId]=741', {
  headers: {
    'X-Api-Key': 'YOUR_APP_KEY',
    'Authorization': 'Bearer USER_SESSION_TOKEN',
  },
})

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

Response fields

Field Type Description
Fieldsuccess Typeboolean DescriptionAlways true on success
Fielddata Typearray DescriptionArray of comments (all fields — see Comment fields)
Fieldmeta.total Typenumber DescriptionTotal number of records matching the filter
Fieldmeta.hasMore Typeboolean DescriptionWhether there are more records beyond limit

Response example

JSON
{
  "success": true,
  "data": [
    {
      "id": 66309,
      "entityId": 741,
      "entityType": "deal",
      "comment": "First contact: the client showed interest in the offer",
      "authorId": 1,
      "createdAt": "2026-04-24T12:39:28.000Z"
    },
    {
      "id": 66311,
      "entityId": 741,
      "entityType": "deal",
      "comment": "Follow-up: the client is ready to sign the contract next week",
      "authorId": 1,
      "createdAt": "2026-04-24T12:39:30.000Z"
    }
  ],
  "meta": {
    "total": 2,
    "hasMore": false
  }
}

Error response example

400 — a required filter was not provided:

JSON
{
  "success": false,
  "error": {
    "code": "MISSING_REQUIRED_FILTER",
    "message": "GET /v1/timelines requires filter fields: entityType, entityId. Example: GET /v1/timelines?filter[entityType]=...&filter[entityId]=..."
  }
}

Errors

HTTP Code Description
HTTP400 CodeMISSING_REQUIRED_FILTER DescriptionThe required filter[entityType] and filter[entityId] were not provided
HTTP400 CodeUNKNOWN_FILTER_FIELD DescriptionThe filter contains a field that comments do not have. The message lists the allowed fields after the word Available
HTTP400 CodeINVALID_SORT_DIRECTION DescriptionA direction in order other than asc or desc
HTTP422 CodeBITRIX_ERROR DescriptionInvalid entityType value (e.g. a numeric CRM code instead of a string)
HTTP403 CodeSCOPE_DENIED DescriptionThe API key lacks the crm scope
HTTP401 CodeTOKEN_MISSING DescriptionThe API key has no configured tokens
HTTP429 CodeRATE_LIMITED DescriptionRate limit exceeded: 300 requests per minute per portal. All API keys of the portal share one limit. The current limit is returned in the x-ratelimit-limit header. Retry after the delay in the Retry-After header

For the full list of common API errors, see Errors.

Known specifics

entityType is a string. Use string CRM type identifiers: deal, lead, contact, company. For smart processes — DYNAMIC_<entityTypeId> (e.g. DYNAMIC_174). In the response the value comes back in lowercase (dynamic_174). Numeric CRM codes do not work in entityType — the request returns 422 BITRIX_ERROR Access denied.

Filtering only by entityType + entityId. Other comment fields in the filter (authorId, comment, ranges like >=createdAt, etc.) are accepted without an error but do not narrow the selection — the response is the same as without them. If you need to narrow results by author or text, fetch all comments for the record and filter them on the client side.

Default order — ascending by id. Without sort, the list is returned in creation order: the earliest comments first. For the newest first, use sort=-createdAt.

Auto-pagination. When limit > 50, Vibecode automatically requests several pages from Bitrix24 and returns all records in a single response.

See also