CloudPDF
DocsPricing
Start building

List annotations

GET/v1/docs/{docId}/layers/{layerName}/annotations/pages/{pon}/itemsv3.0.0-next.9

One page's annotations at the current layer version.

Authentication#

Any one of these credentials is accepted.

API token

The deployment's static root credential (CLOUDPDF_API_AUTH_TOKENS), valid on every surface.

Document token

Doc-scoped JWT, valid only on the /v1/docs/{docId} subtree it names, gated by the capability scopes it carries (each operation's x-required-capability).

Document capabilitydoc.annotate.read

Parameters#

docIdpathstringrequired
layerNamepathstringrequired
ponpathintegerrequired
X-Document-Passwordheaderstring

Base64-encoded password for an encrypted document. Valid only with the API token (403 anywhere else). An encrypted document answers 422 DocPasswordRequired when the header is absent. Viewer doc JWTs use the SDK password-session flow instead.

SDK examples#

The selected SDK is remembered across the API reference. Values are examples; replace them with identifiers and input from your application.

import { CloudPDFClient } from "@cloudpdf/sdk";

const client = new CloudPDFClient({
  baseUrl: "https://yourhost.com/path/to/api",
  token: "<token>",
});

await client.doc.annotations.list({
  docId: "docId",
  layerName: "layerName",
  pon: 1
});

Responses#

200OK
application/jsonDocAnnotationsList200Response
pageStateobject
pageObjectNumberinteger
revisionobject
docSessionIdstring
pageObjectNumberinteger
generationinteger
weakAnnotationState"unknown" | "known"
kind =
kind"unknown"
annotations(19 variants)[]
subtype =
ref"objectNumber" | "nm" | "index"
kind =
kind"objectNumber"
pageObjectNumberinteger
annotObjectNumberinteger
pageObjectNumberinteger
indexinteger
identityQuality"durable" | "weak"
nmstring
flagsobject
invisibleboolean
hiddenboolean
printboolean
noZoomboolean
noRotateboolean
noViewboolean
readOnlyboolean
lockedboolean
toggleNoViewboolean
lockedContentsboolean
rectobject
leftnumber
bottomnumber
rightnumber
topnumber
contentsstring
authorstring
createdstring<date-time>
modifiedstring<date-time>
blendMode"normal" | "multiply" | "screen" | "overlay" | "darken" | "lighten" | "color-dodge" | "color-burn" | "hard-light" | "soft-light" | "difference" | "exclusion" | "hue" | "saturation" | "color" | "luminosity"
inReplyTo"objectNumber" | "nm" | "index"
replyType"reply" | "group"
userIdstringoptional
groupIdstringoptional
createdBystringoptional
updatedBystringoptional
actionsobjectoptional
activateobjectoptional
rootobject
incompleteboolean
warningFlagsinteger
warnings("cycle-dropped" | "malformed-next" | "incomplete")[]
cursorEnterobjectoptional
rootobject
incompleteboolean
warningFlagsinteger
warnings("cycle-dropped" | "malformed-next" | "incomplete")[]
cursorExitobjectoptional
rootobject
incompleteboolean
warningFlagsinteger
warnings("cycle-dropped" | "malformed-next" | "incomplete")[]
mouseDownobjectoptional
rootobject
incompleteboolean
warningFlagsinteger
warnings("cycle-dropped" | "malformed-next" | "incomplete")[]
mouseUpobjectoptional
rootobject
incompleteboolean
warningFlagsinteger
warnings("cycle-dropped" | "malformed-next" | "incomplete")[]
focusobjectoptional
rootobject
incompleteboolean
warningFlagsinteger
warnings("cycle-dropped" | "malformed-next" | "incomplete")[]
blurobjectoptional
rootobject
incompleteboolean
warningFlagsinteger
warnings("cycle-dropped" | "malformed-next" | "incomplete")[]
pageOpenobjectoptional
rootobject
incompleteboolean
warningFlagsinteger
warnings("cycle-dropped" | "malformed-next" | "incomplete")[]
pageCloseobjectoptional
rootobject
incompleteboolean
warningFlagsinteger
warnings("cycle-dropped" | "malformed-next" | "incomplete")[]
pageVisibleobjectoptional
rootobject
incompleteboolean
warningFlagsinteger
warnings("cycle-dropped" | "malformed-next" | "incomplete")[]
pageInvisibleobjectoptional
rootobject
incompleteboolean
warningFlagsinteger
warnings("cycle-dropped" | "malformed-next" | "incomplete")[]
colorobject
rinteger
ginteger
binteger
opacitynumber
quadPointsobject[]
p1object
xnumber
ynumber
p2object
xnumber
ynumber
p3object
xnumber
ynumber
p4object
xnumber
ynumber
subtype"highlight"
404Not found
application/jsonDocAnnotationsList404Response
name"EngineError"
code"Unknown" | "InvalidArg" | "DocNotOpen" | "DocOpenFailed" | "DocPasswordRequired" | "DocPasswordIncorrect" | "SharePasswordRequired" | "Aborted" | "Network" | "Unauthenticated" | "Forbidden" | "NotFound" | "WireFormat" | "RuntimeUnavailable" | "InvalidReference" | "WeakAnnotationSessionConflict" | "LayerVersionConflict" | "NotImplemented" | "MalformedPdf"
messagestring
detailsobjectoptional
defaultError
application/jsonEngineErrorPayload
name"EngineError"
code"Unknown" | "InvalidArg" | "DocNotOpen" | "DocOpenFailed" | "DocPasswordRequired" | "DocPasswordIncorrect" | "SharePasswordRequired" | "Aborted" | "Network" | "Unauthenticated" | "Forbidden" | "NotFound" | "WireFormat" | "RuntimeUnavailable" | "InvalidReference" | "WeakAnnotationSessionConflict" | "LayerVersionConflict" | "NotImplemented" | "MalformedPdf"
messagestring
detailsobjectoptional