Skip to main content
POST
/
annotations
/
list
JavaScript SDK
const annotatedFileId = 1;
const limitOne = await client.annotations.list({
  limit: 1,
  filter: {
   annotatedResourceType: 'file',
   annotatedResourceIds: [{ id: 1 }],
 },
});
{
  "items": [
    {
      "id": 4096,
      "createdTime": 1730204346000,
      "lastUpdatedTime": 1730204346000,
      "annotatedResourceType": "file",
      "annotatedResourceId": 1337,
      "annotationType": "pointcloud.BoundingVolume",
      "creatingApp": "cognite-vision",
      "creatingAppVersion": "1.2.1",
      "creatingUser": "john.doe@cognite.com",
      "data": {
        "assetRef": {
          "externalId": "abc"
        },
        "symbolRegion": {
          "xMin": 0.1,
          "xMax": 0.2,
          "yMin": 0.1,
          "yMax": 0.2
        },
        "textRegion": {
          "xMin": 0.2,
          "xMax": 0.3,
          "yMin": 0.2,
          "yMax": 0.3
        },
        "pageNumber": 43
      },
      "status": "approved"
    }
  ],
  "nextCursor": null
}

Authorizations

Authorization
string
header
required

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.

Body

application/json

A request specifying the annotation listing behavior

filter
object
required

A filter to apply on annotations

Example:
{
"annotatedResourceType": "file",
"annotatedResourceIds": [{ "id": 1066 }, { "id": 1067 }],
"status": "approved",
"data": { "label": "cat" }
}
cursor
string

A cursor pointing to another page of results

Required string length: 1 - 255
Example:

"MzE1NjAwMDcxNzQ0ODI5"

limit
integer
default:25
Required range: 1 <= x <= 1000

Response

Successful retrieval

A cursored list of existing annotations

items
object[]
required
nextCursor
string

A cursor pointing to another page of results

Required string length: 1 - 255
Example:

null

Last modified on April 23, 2026