const sequences = [
{
externalId: 'sequence_name',
columns: [
{
externalId: 'one',
valueType: SequenceValueType.LONG,
},
{
externalId: 'two',
},
{
externalId: 'three',
valueType: SequenceValueType.STRING,
}
]
}
];
const [sequence] = await client.sequences.create(sequences);{
"items": [
{
"id": 1,
"columns": [
{
"valueType": "DOUBLE",
"createdTime": 100000000000,
"lastUpdatedTime": 100000000000,
"name": "depth",
"externalId": "DPS1",
"description": "Optional description",
"metadata": {
"extracted-by": "cognite"
}
}
],
"createdTime": 100000000000,
"lastUpdatedTime": 100000000000,
"name": "Any relevant name",
"description": "Optional description",
"assetId": 1221123111,
"externalId": "my.known.id",
"metadata": {
"extracted-by": "cognite"
},
"dataSetId": 2718281828459
}
]
}Required capabilities:
sequencesAcl:WRITE
Create one or more sequences.
const sequences = [
{
externalId: 'sequence_name',
columns: [
{
externalId: 'one',
valueType: SequenceValueType.LONG,
},
{
externalId: 'two',
},
{
externalId: 'three',
valueType: SequenceValueType.STRING,
}
]
}
];
const [sequence] = await client.sequences.create(sequences);{
"items": [
{
"id": 1,
"columns": [
{
"valueType": "DOUBLE",
"createdTime": 100000000000,
"lastUpdatedTime": 100000000000,
"name": "depth",
"externalId": "DPS1",
"description": "Optional description",
"metadata": {
"extracted-by": "cognite"
}
}
],
"createdTime": 100000000000,
"lastUpdatedTime": 100000000000,
"name": "Any relevant name",
"description": "Optional description",
"assetId": 1221123111,
"externalId": "my.known.id",
"metadata": {
"extracted-by": "cognite"
},
"dataSetId": 2718281828459
}
]
}Access token issued by the CDF project's configured identity provider. Access token must be an OpenID Connect token, and the project must be configured to accept OpenID Connect tokens. Use a header key of 'Authorization' with a value of 'Bearer $accesstoken'. The token can be obtained through any flow supported by the identity provider.
Sequence to be stored.
1 - 1000 elementsShow child attributes
Response with the created sequence.
Show child attributes
Was this page helpful?