Skip to main content
POST
/
documents
/
content
Retrieve document content
curl --request POST \
  --url https://{cluster}.cognitedata.com/api/v1/projects/{project}/documents/content \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "id": 4503599627370496
}
'
"ACT I\nSCENE I. Elsinore. A platform before the castle.\n  FRANCISCO at his post. Enter to him BERNARDO\nBERNARDO\n  Who's there?\n"

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

Fields to be set for the content request.

id
integer<int64>
required

A server-generated ID for the object.

Required range: 1 <= x <= 9007199254740991

Response

OK

The textual content of the document, truncated to the first 1MB of text

Example:

"ACT I\nSCENE I. Elsinore. A platform before the castle.\n FRANCISCO at his post. Enter to him BERNARDO\nBERNARDO\n Who's there?\n"

Last modified on April 23, 2026