Skip to content

Common

ts
import type {
	NumberString,
	ISODate,
	BoolString,
	GenderString,
	PlacementViewMode,
	Fields,
	MultiField,
	MultiFieldArray,
	UserFieldType
} from '@bitrix24/b24jssdk'

import { DataType } from '@bitrix24/b24jssdk'

These are various data types and structures used in applications integrated with Bitrix24. They include string types representing numbers, dates, boolean values, and other specific data formats.

Data Types

NumberString

TypeDescription
stringA string that is actually a number, e.g., 20.23.

ISODate

TypeDescription
stringA string in ISO date format, e.g., 2018-06-07T03:00:00+03:00.

TIP

You can test working with ISODate in this example.

BoolString

ValueDescription
YYes (true)
NNo (false)

GenderString

ValueDescription
MMale
FFemale
``Not Specified

PlacementViewMode

ValueDescription
viewView mode
editEdit mode

Data Structures

Fields

FieldTypeDescription
typestringField type
isRequiredbooleanRequired field
isReadOnlybooleanRead-only field
isImmutablebooleanImmutable field
isMultiplebooleanMultiple field
isDynamicbooleanDynamic field
titlestringField title

MultiField

FieldTypeDescription
IDNumberStringIdentifier
VALUE_TYPEstringValue type
VALUEstringValue
TYPE_IDstringType identifier

MultiFieldArray

FieldTypeDescription
VALUEstringValue
VALUE_TYPEstringValue type

UserFieldType

FieldTypeDescription
USER_TYPE_IDstringUser type identifier
HANDLERstringHandler
TITLEstringTitle
DESCRIPTIONstringDescription
OPTIONSobjectOptions (e.g., height)

enum DataType

DataType defines various data types used in Bitrix24:

KeyValueDescription
undefinedundefinedUndefined
anyanyAny
integerintegerInteger
booleanbooleanBoolean value
doubledoubleDouble
datedateDate
datetimedatetimeDate and time
stringstringString
texttextText
filefileFile
arrayarrayArray
objectobjectObject
useruserUser
locationlocationLocation
crmCategorycrm_categoryCRM Category
crmStatuscrm_statusCRM Status
crmCurrencycrm_currencyCRM Currency

These data types and structures can be used to describe and work with various entities and fields in Bitrix24.

Released under the MIT License.