Retrieve a sequence by id
- async AsyncCogniteClient.sequences.retrieve(
- id: int | None = None,
- external_id: str | None = None,
Retrieve a single sequence by id.
Deprecated since version 8.23.0: The Sequences API is deprecated and is scheduled for removal on 2027-12-31. Use files in data modeling (for whole-table downloads) or records (for row-level queries). See https://docs.cognite.com/cdf/deprecated for details and migration guidance.
- Parameters:
id (int | None) – ID
external_id (str | None) – External ID
- Returns:
Requested sequence or None if it does not exist.
- Return type:
Sequence | None
Examples
Get sequence by id:
>>> from cognite.client import CogniteClient, AsyncCogniteClient >>> client = CogniteClient() >>> # async_client = AsyncCogniteClient() # another option >>> res = client.sequences.retrieve(id=1)
Get sequence by external id:
>>> res = client.sequences.retrieve()