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

Booking client types

A booking client type is a module and code pair that defines which CRM record can be a client of a booking or of a wait list record: a contact or a company. Use this reference to pass only allowed pairs in booking clients.

Bitrix24 API: booking.v1.clientType.list Scope: booking

List booking client types

GET /v1/booking-client-types

Returns the module and code pairs that the Bitrix24 account accepts as a client type in bookings and in the wait list.

No parameters. The whole list arrives in one response.

Examples

curl — personal key

Terminal
curl -X GET "https://vibecode.bitrix24.com/v1/booking-client-types" \
  -H "X-Api-Key: YOUR_API_KEY"

curl — OAuth application

Terminal
curl -X GET "https://vibecode.bitrix24.com/v1/booking-client-types" \
  -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/booking-client-types', {
  headers: { 'X-Api-Key': 'YOUR_API_KEY' },
})

const { data } = await res.json()
console.log(data.map((type) => `${type.module}/${type.code}`))

JavaScript — OAuth application

javascript
const res = await fetch('https://vibecode.bitrix24.com/v1/booking-client-types', {
  headers: {
    'X-Api-Key': 'YOUR_APP_KEY',
    'Authorization': 'Bearer USER_SESSION_TOKEN',
  },
})

const { data } = await res.json()
console.log(data.map((type) => `${type.module}/${type.code}`))

Response fields

Field Type Description
Fieldsuccess Typeboolean Descriptiontrue on success
Fielddata Typearray DescriptionClient types allowed in the Bitrix24 account. An empty array is a valid response
Fielddata[].module Typestring DescriptionModule the client type belongs to, for example crm
Fielddata[].code Typestring DescriptionClient type code, for example CONTACT or COMPANY

Response example

JSON
{
  "success": true,
  "data": [
    {
      "code": "COMPANY",
      "module": "crm"
    },
    {
      "code": "CONTACT",
      "module": "crm"
    }
  ]
}

Error response example

401 — no key passed:

JSON
{
  "success": false,
  "error": {
    "code": "MISSING_API_KEY",
    "message": "API key required. Pass via X-Api-Key header."
  }
}

Errors

HTTP Code Description
HTTP401 CodeMISSING_API_KEY DescriptionX-Api-Key was not passed
HTTP401 CodeTOKEN_MISSING DescriptionThe key has no connection to Bitrix24
HTTP403 CodeSCOPE_DENIED DescriptionThe key lacks the booking scope
HTTP422 CodeBITRIX_ERROR DescriptionBitrix24 rejected the request. The reason is in message
HTTP429 CodeRATE_LIMITED DescriptionRequest rate exceeded
HTTP502 CodeBITRIX_RESPONSE_INVALID DescriptionBitrix24 returned a list of an unexpected shape
HTTP502 CodeBITRIX_UNAVAILABLE DescriptionBitrix24 is unavailable
HTTP503 CodeBITRIX_TIMEOUT DescriptionBitrix24 did not respond in time

Full list of common API errors — Errors.

Known specifics

Query parameters do not change the response. filter, limit and other query string parameters are ignored without a warning: the response always contains every client type of the Bitrix24 account.

See also