Primitive types for the property.

We expect dates to be in the ISO-8601 format, while timestamps are expected to be an epoch value with millisecond precision. JSON values have to be valid JSON fragments. The maximum allowed size for a JSON object is 40960 bytes. For list of json values, the size of the entire list must be within this limit. The maximum allowed length of a key is 128, while the maximum allowed size of a value is 10240 bytes and you can have up to 256 key-value pairs.

interface PrimitiveProperty {
    list?: boolean;
    maxListSize?: number;
    type:
        | "boolean"
        | "json"
        | "float32"
        | "float64"
        | "int32"
        | "int64"
        | "timestamp"
        | "date";
    unit?: {
        externalId: string;
        sourceUnit?: string;
    };
}

Properties

list?: boolean

Specifies that the data type is a list of values. The ordering of values is preserved.

maxListSize?: number

Specifies the maximum number of values in the list

type:
    | "boolean"
    | "json"
    | "float32"
    | "float64"
    | "int32"
    | "int64"
    | "timestamp"
    | "date"
unit?: {
    externalId: string;
    sourceUnit?: string;
}

The unit of the data stored in this property, can only be assign to type float32 or float64. ExternalId needs to match with a unit in the Cognite unit catalog.

externalId: temperature:deg_c, sourceUnit: Celsius