Streamline document discussions with Instant Comments

Types

This section explains how to use type declarations in Instant JSON records.

The optional keys are specified as follows:

{ optionalKey?: value; }

To reduce payload size, omit optional keys when their values are undefined.

Comments

The Instant Comments component enables users to collaborate on and discuss parts of a document in real time. You can use the Document Engine comments APIs to add and retrieve comments in a document:

// Example of an Instant JSON schema including a comment associated with the annotation identified by `rootId`:
{
"type": "pspdfkit/comment",
"v": 1,
"rootId": "01F46WTF5X3J1WEN6J2YXWHHEW",
"pageIndex": 0,
"pdfObjectId": null,
"creatorName": null,
"createdAt": "2021-04-26T10:50:30.650Z",
"updatedAt": "2021-04-26T10:50:30.650Z",
"text": "This is a comment.",
"customData": null
}

Annotation Replies aren’t supported in Instant JSON.

For more information about the Instant JSON schema for annotations, refer to the JSON format schema — annotations guide.