For AI agents: markdown of this page — /docs-content-en/entities/companies/get.md documentation index — /llms.txt
Get company
GET /v1/companies/:id
Returns a company by ID.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
Parameterid (path) |
Typenumber | Requiredyes | DescriptionCompany ID. List: GET /v1/companies |
Parameterinclude (query) |
Typestring | Requiredno | DescriptionRelated data: contact. The result is in data._included.contacts. See Related data |
Parameterselect (query) |
Typestring | Requiredno | DescriptionComma-separated response fields, for example id,title. Without the parameter, all fields are returned. The id field is always returned. Names come from Company fields |
Examples
curl — personal key
curl "https://vibecode.bitrix24.com/v1/companies/1" \
-H "X-Api-Key: YOUR_API_KEY"
curl — OAuth application
curl "https://vibecode.bitrix24.com/v1/companies/1" \
-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/companies/1', {
headers: {
'X-Api-Key': 'YOUR_API_KEY',
},
})
const { success, data } = await res.json()
console.log('Company:', data.title)
JavaScript — OAuth application
const res = await fetch('https://vibecode.bitrix24.com/v1/companies/1', {
headers: {
'X-Api-Key': 'YOUR_APP_KEY',
'Authorization': 'Bearer USER_SESSION_TOKEN',
},
})
const { success, data } = await res.json()
Response fields
| Field | Type | Description |
|---|---|---|
Fieldsuccess |
Typeboolean | Descriptiontrue when the request succeeds |
Fielddata |
Typeobject | DescriptionThe company with all fields, including the ufCrm* user fields. With the select parameter, only the listed fields and id are returned. All fields — Company fields |
Fielddata._included |
Typeobject | DescriptionRelated data. Returned only with the include parameter: contacts is an array of linked contacts, each with all contact fields and the binding fields isPrimary, sort and roleId. See Related data |
Fieldmeta.warnings |
Typearray | DescriptionReturned when a name that is absent from the company schema is listed alongside * in select: the company comes back without that field. Each warning is an object with code, field and message, and the code is UNKNOWN_SELECT_FIELD. Without *, such a name causes the whole request to be rejected |
Related data
To get the linked contacts together with the company, pass the include parameter in the GET request:
GET /v1/companies/1?include=contact&select=id,title
The available include value is contact. The result is in data._included.contacts. The main contact fields are shown:
{
"success": true,
"data": {
"id": 1,
"title": "Acme Inc.",
"_included": {
"contacts": [
{ "id": 87, "name": "John", "lastName": "Smith", "companyId": 1, "isPrimary": true, "sort": 10, "roleId": 0 },
{ "id": 17, "name": "Anna", "lastName": "Brown", "companyId": 1, "isPrimary": false, "sort": 10, "roleId": 0 }
]
}
}
}
How the include parameter works — Related data.
Response example
{
"success": true,
"data": {
"id": 1,
"title": "Acme Inc.",
"industry": "IT",
"typeId": "CUSTOMER",
"assignedById": 1,
"phone": "+12025550123",
"phoneWork": "+12025550123",
"email": "info@example.com",
"emailWork": "info@example.com",
"emailHome": "home@example.com",
"hasPhone": true,
"hasEmail": true,
"fm": [
{ "id": 65, "typeId": "PHONE", "valueType": "WORK", "value": "+12025550123" },
{ "id": 67, "typeId": "EMAIL", "valueType": "WORK", "value": "info@example.com" },
{ "id": 69, "typeId": "EMAIL", "valueType": "HOME", "value": "home@example.com" }
],
"createdTime": "2020-05-08T10:48:20+00:00",
"updatedTime": "2025-08-22T13:01:31+00:00"
}
}
Phone and email in the response are strings with the primary value, and per-type values are in the phoneWork, phoneMobile, emailWork, emailHome fields. The full list with types is in the fm[] array ({ id, typeId, valueType, value }, where id is the entry identifier). Check presence via hasPhone/hasEmail: when there is no phone, phone comes back as an empty string. A specific fm[] entry cannot be modified or removed by its id through the API — PATCH adds new entries.
Error response example
404 — company not found:
{
"success": false,
"error": {
"code": "ENTITY_NOT_FOUND",
"message": "Item not found"
}
}
Errors
| HTTP | Code | Description |
|---|---|---|
| HTTP404 | CodeENTITY_NOT_FOUND |
DescriptionCompany not found |
| HTTP400 | CodeUNKNOWN_SELECT_FIELD |
Descriptionselect lists an unknown field. The message lists the valid names |
| HTTP400 | CodeINVALID_INCLUDE |
Descriptioninclude names a value the company does not have. The message names the valid one — contact |
| HTTP403 | CodeACCESS_DENIED |
DescriptionNo access |
| HTTP403 | CodeSCOPE_DENIED |
DescriptionThe API key does not have the crm scope |
| HTTP401 | CodeTOKEN_MISSING |
DescriptionThe API key has no configured tokens |
Full list of common API errors — Errors.