Skip to content

Latest commit

Β 

History

History
7628 lines (5219 loc) Β· 104 KB

reference.md

File metadata and controls

7628 lines (5219 loc) Β· 104 KB

Reference

Deployment

client.deployment.license_status() -> CloudPDF::Types::DeploymentLicenseStatusResponse

πŸ”Œ Usage

client.deployment.license_status

βš™οΈ Parameters

request_options: CloudPDF::Deployment::RequestOptions

client.deployment.modules() -> CloudPDF::Types::DeploymentModulesResponse

πŸ“ Description

What each module declares, for a dashboard or a script that lists modules, offers their permissions in its dialogs and shows their meters. Which tenants may use one is in their features (tenants.get); what it costs, if anything, is the operator's.

πŸ”Œ Usage

client.deployment.modules

βš™οΈ Parameters

request_options: CloudPDF::Deployment::RequestOptions

Doc

client.doc.head(doc_id:) -> CloudPDF::Types::DocHeadResponse

πŸ”Œ Usage

client.doc.head(doc_id: "docId")

βš™οΈ Parameters

doc_id: String

document_password: String β€” 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.

request_options: CloudPDF::Doc::RequestOptions

client.doc.changes(doc_id:, layer_name:, request) -> CloudPDF::Types::DocChangesResponse

πŸ“ Description

Each change stands on its own and names itself by opId: a refused change rolls back alone, and the answer lists every change in order, applied with its result or refused with its error. Asked again under its opId, a change gets the same answer, refusals included; a different change under an answered opId is refused (IdempotencyKeyReused). { opId, undoOf } undoes an earlier change of the caller, here or in an earlier request; an undo leaves alone what was changed since, and the undo of an undo redoes. A redaction, a flatten, a form repair or a completed signature ends undo for the changes before it (UndoUnavailable). Each op is checked against its own capability: annotation ops need doc.annotate.modify, form values doc.forms.fill, form structure doc.forms.modify, metadata doc.metadata.modify, outline doc.outline.modify, pages doc.pages.assemble, embedded files doc.attachments.modify. Bytes (a stamp's drawing, an attached file, a signature's artwork, a PDF whose pages come in) travel as multipart: a JSON body part, each op naming its files by role as resources: { <role>: '<key>' }, and each file as the part resource:<key>. At most 64 changes per request and 512 ops per change.

πŸ”Œ Usage

client.doc.changes(
  doc_id: "docId",
  layer_name: "layerName",
  changes: [{
    op_id: "opId"
  }]
)

βš™οΈ Parameters

doc_id: String

layer_name: String

document_password: String β€” 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.

changes: Internal::Types::Array[CloudPDF::Doc::Types::DocChangesRequestChangesItem]

request_options: CloudPDF::Doc::RequestOptions

client.doc.download(doc_id:, layer_name:) -> String

πŸ”Œ Usage

client.doc.download(
  doc_id: "docId",
  layer_name: "layerName"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

document_password: String β€” 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.

request_options: CloudPDF::Doc::RequestOptions

client.doc.download_link(doc_id:, layer_name:, request) -> CloudPDF::Types::DocDownloadLinkResponse

πŸ“ Description

The link opens the layer as it is when created: once the layer changes, it answers 404, so create it right before handing it over. It downloads that one file and nothing else, and a password-protected document is checked when the link is created. Deployments that verify tokens with their own keys (JWKS) mint links on their backend: a doc token with layer_name, a download: { docVersion, mode: "incremental" } claim and a short exp, passed as link on the versioned download URL.

πŸ”Œ Usage

client.doc.download_link(
  doc_id: "docId",
  layer_name: "layerName"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

document_password: String β€” 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.

expires_in_seconds: Integer

request_options: CloudPDF::Doc::RequestOptions

client.doc.manifest(doc_id:, layer_name:) -> CloudPDF::Types::DocManifestResponse

πŸ”Œ Usage

client.doc.manifest(
  doc_id: "docId",
  layer_name: "layerName"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

document_password: String β€” 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.

request_options: CloudPDF::Doc::RequestOptions

client.doc.render(doc_id:, layer_name:, page_key:) -> String

πŸ“ Description

Render parameters (viewport, format) pass as flat dotted query keys, e.g. ?viewport.kind=width&viewport.width=800; the full grammar is documented with the viewer.

πŸ”Œ Usage

client.doc.render(
  doc_id: "docId",
  layer_name: "layerName",
  page_key: "pageKey"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

page_key: String β€” The page's address, obj:N: the page's indirect object number, the durable identity every PageLayout.ref carries. Mirrors annotationKey and fieldKey.

document_password: String β€” 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.

request_options: CloudPDF::Doc::RequestOptions

client.doc.text(doc_id:, layer_name:, page_key:) -> CloudPDF::Types::DocTextResponse

πŸ”Œ Usage

client.doc.text(
  doc_id: "docId",
  layer_name: "layerName",
  page_key: "pageKey"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

page_key: String β€” The page's address, obj:N: the page's indirect object number, the durable identity every PageLayout.ref carries. Mirrors annotationKey and fieldKey.

document_password: String β€” 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.

request_options: CloudPDF::Doc::RequestOptions

Grants

client.grants.exchange(request) -> CloudPDF::Types::GrantsExchangeResponse

πŸ“ Description

Unauthenticated, but requires a browser Origin header, checked against the grant allowlist. Unknown, deleted, paused and archived grants are indistinguishable (404). Passphrase-protected grants return 422 GrantPassphraseRequired until passphrase is supplied. A grant that asks its visitors who they are on open returns 422 VisitorIdentityRequired until the required answers are given; error.details carries fields (what the grant asks), missing, invalid, purpose and privacyUrl. A grant that asks before the first change issues the session at once with visitor.identityRequest, and writes answer 403 VisitorIdentityRequired with the same details until the visitor exchanges again with their answers. Answers that can not be taken answer 422 on any grant. Mounted only when the deployment can sign (HS256 mode).

πŸ”Œ Usage

client.grants.exchange(grant: "grant")

βš™οΈ Parameters

grant: String

passphrase: String

visitor_handle: String

restart: Internal::Types::Boolean

visitor_identity: CloudPDF::Grants::Types::GrantsExchangeRequestVisitorIdentity

request_options: CloudPDF::Grants::RequestOptions

client.grants.list(tenant_id:) -> CloudPDF::Types::GrantsListResponse

πŸ”Œ Usage

client.grants.list(tenant_id: "tenantId")

βš™οΈ Parameters

tenant_id: String

limit: Integer

cursor: String

doc_id: String

archived: Internal::Types::Boolean

request_options: CloudPDF::Grants::RequestOptions

client.grants.create(tenant_id:, request) -> CloudPDF::Types::GrantsCreateResponse

πŸ“ Description

The returned id is what a link page or an embed opens. Its scope gives only document permissions the caller holds itself, as tokens.issue does. Mounted only when the deployment can sign (HS256 mode) β€” exchange mints session JWTs, so grants exist only where minting does.

πŸ”Œ Usage

client.grants.create(
  tenant_id: "tenantId",
  doc_id: "docId",
  scope: ["scope"]
)

βš™οΈ Parameters

tenant_id: String

doc_id: String

name: String

layer_mode: CloudPDF::Grants::Types::GrantsCreateRequestLayerMode

layer_name: String

keep_visitor_layers: Internal::Types::Boolean

visitor_idle_seconds: Integer

visitor_identity: CloudPDF::Grants::Types::GrantsCreateRequestVisitorIdentity

identity: CloudPDF::Types::Identity

scope: Internal::Types::Array[String]

origins: Internal::Types::Array[String]

passphrase: String

session_ttl_seconds: Integer

expires_at: String

request_options: CloudPDF::Grants::RequestOptions

client.grants.get(tenant_id:, grant_id:) -> CloudPDF::Types::GrantsGetResponse

πŸ”Œ Usage

client.grants.get(
  tenant_id: "tenantId",
  grant_id: "grantId"
)

βš™οΈ Parameters

tenant_id: String

grant_id: String

request_options: CloudPDF::Grants::RequestOptions

client.grants.delete(tenant_id:, grant_id:) ->

πŸ”Œ Usage

client.grants.delete(
  tenant_id: "tenantId",
  grant_id: "grantId"
)

βš™οΈ Parameters

tenant_id: String

grant_id: String

request_options: CloudPDF::Grants::RequestOptions

client.grants.update(tenant_id:, grant_id:, request) -> CloudPDF::Types::GrantsUpdateResponse

πŸ”Œ Usage

client.grants.update(
  tenant_id: "tenantId",
  grant_id: "grantId"
)

βš™οΈ Parameters

tenant_id: String

grant_id: String

name: String

layer_mode: CloudPDF::Grants::Types::GrantsUpdateRequestLayerMode

layer_name: String

keep_visitor_layers: Internal::Types::Boolean

visitor_idle_seconds: Integer

visitor_identity: CloudPDF::Grants::Types::GrantsUpdateRequestVisitorIdentity

identity: CloudPDF::Types::Identity

scope: Internal::Types::Array[String]

origins: Internal::Types::Array[String]

passphrase: String

session_ttl_seconds: Integer

disabled: Internal::Types::Boolean

expires_at: String

request_options: CloudPDF::Grants::RequestOptions

client.grants.archive(tenant_id:, grant_id:) -> CloudPDF::Types::GrantsArchiveResponse

πŸ“ Description

Archiving is final: an archived grant never exchanges again, and to give access again you create a new grant. Pausing (disabled) is the reversible stop. An archived grant no longer counts as using its shared layer, so that layer can be deleted.

πŸ”Œ Usage

client.grants.archive(
  tenant_id: "tenantId",
  grant_id: "grantId"
)

βš™οΈ Parameters

tenant_id: String

grant_id: String

request_options: CloudPDF::Grants::RequestOptions

Tenants

client.tenants.list() -> CloudPDF::Types::TenantsListResponse

πŸ”Œ Usage

client.tenants.list

βš™οΈ Parameters

limit: Integer

cursor: String

request_options: CloudPDF::Tenants::RequestOptions

client.tenants.create(request) -> CloudPDF::Types::TenantsCreateResponse

πŸ”Œ Usage

client.tenants.create(id: "id")

βš™οΈ Parameters

id: String

name: String

request_options: CloudPDF::Tenants::RequestOptions

client.tenants.get(tenant_id:) -> CloudPDF::Types::TenantsGetResponse

πŸ”Œ Usage

client.tenants.get(tenant_id: "tenantId")

βš™οΈ Parameters

tenant_id: String

request_options: CloudPDF::Tenants::RequestOptions

client.tenants.delete(tenant_id:) ->

πŸ“ Description

Destroys the tenant and everything in its namespace β€” documents, layers, stored bytes, audit history. Irreversible.

πŸ”Œ Usage

client.tenants.delete(tenant_id: "tenantId")

βš™οΈ Parameters

tenant_id: String

request_options: CloudPDF::Tenants::RequestOptions

client.tenants.update(tenant_id:, request) -> CloudPDF::Types::TenantsUpdateResponse

πŸ“ Description

A feature names an installed module; any other id is a 400. A module route answers a tenant without its feature 403 FeatureNotEnabled, and one whose feature is stopped 402 FeatureStopped (details.feature, details.stopped). Other replicas apply a change within 30 seconds.

πŸ”Œ Usage

client.tenants.update(
  tenant_id: "tenantId",
  features: [{
    id: "id"
  }]
)

βš™οΈ Parameters

tenant_id: String

features: Internal::Types::Array[CloudPDF::Types::TenantFeature]

request_options: CloudPDF::Tenants::RequestOptions

client.tenants.resume(tenant_id:) ->

πŸ”Œ Usage

client.tenants.resume(tenant_id: "tenantId")

βš™οΈ Parameters

tenant_id: String

request_options: CloudPDF::Tenants::RequestOptions

client.tenants.suspend(tenant_id:, request) ->

πŸ“ Description

Instantly reversible with resume. The API token is exempt, so a suspended tenant can still be inspected, exported, resumed, or deleted.

πŸ”Œ Usage

client.tenants.suspend(tenant_id: "tenantId")

βš™οΈ Parameters

tenant_id: String

reason: String

request_options: CloudPDF::Tenants::RequestOptions

client.tenants.usage(tenant_id:) -> CloudPDF::Types::TenantsUsageResponse

πŸ“ Description

Facts only β€” no limits or billing state. Views count grant exchanges plus authorized /v1/access requests, deduplicated across the two.

πŸ”Œ Usage

client.tenants.usage(tenant_id: "tenantId")

βš™οΈ Parameters

tenant_id: String

period: String

from: String

to: String

request_options: CloudPDF::Tenants::RequestOptions

Documents

client.documents.list(tenant_id:) -> CloudPDF::Types::DocumentsListResponse

πŸ”Œ Usage

client.documents.list(tenant_id: "tenantId")

βš™οΈ Parameters

tenant_id: String

limit: Integer

cursor: String

state: CloudPDF::Documents::Types::ListDocumentsRequestState β€” Only documents in this state. Without it, every state except deleting.

q: String β€” Only documents whose name contains this text, ignoring case.

folder_id: String β€” Only documents directly in this folder (root: the top level). Without it, documents in every folder.

sort: CloudPDF::Documents::Types::ListDocumentsRequestSort β€” createdAt (default), name (ignoring case), or size (stored bytes; 0 while pending).

order: CloudPDF::Documents::Types::ListDocumentsRequestOrder β€” Defaults to the reading order of the sort: A to Z for name, newest and largest first otherwise.

request_options: CloudPDF::Documents::RequestOptions

client.documents.get(tenant_id:, doc_id:) -> CloudPDF::Types::DocumentsGetResponse

πŸ”Œ Usage

client.documents.get(
  tenant_id: "tenantId",
  doc_id: "docId"
)

βš™οΈ Parameters

tenant_id: String

doc_id: String

request_options: CloudPDF::Documents::RequestOptions

client.documents.delete(tenant_id:, doc_id:) ->

πŸ”Œ Usage

client.documents.delete(
  tenant_id: "tenantId",
  doc_id: "docId"
)

βš™οΈ Parameters

tenant_id: String

doc_id: String

request_options: CloudPDF::Documents::RequestOptions

client.documents.update(tenant_id:, doc_id:, request) -> CloudPDF::Types::DocumentsUpdateResponse

πŸ“ Description

A document that is being deleted answers 404.

πŸ”Œ Usage

client.documents.update(
  tenant_id: "tenantId",
  doc_id: "docId",
  name: "name"
)

βš™οΈ Parameters

tenant_id: String

doc_id: String

name: String β€” What people call the document: shown in dashboards, searched and sorted by. 1 to 255 characters, no control characters, no leading or trailing whitespace. Names need not be unique.

request_options: CloudPDF::Documents::RequestOptions

client.documents.commit(tenant_id:, doc_id:, request) -> CloudPDF::Types::DocumentsCommitResponse

πŸ“ Description

An upload token commits only the documents it started; any other document answers 404.

πŸ”Œ Usage

client.documents.commit(
  tenant_id: "tenantId",
  doc_id: "docId",
  sha256: "sha256"
)

βš™οΈ Parameters

tenant_id: String

doc_id: String

sha256: String

request_options: CloudPDF::Documents::RequestOptions

client.documents.download(tenant_id:, doc_id:) -> String

πŸ”Œ Usage

client.documents.download(
  tenant_id: "tenantId",
  doc_id: "docId"
)

βš™οΈ Parameters

tenant_id: String

doc_id: String

request_options: CloudPDF::Documents::RequestOptions

client.documents.thumbnail(tenant_id:, doc_id:) -> String

πŸ”Œ Usage

client.documents.thumbnail(
  tenant_id: "tenantId",
  doc_id: "docId"
)

βš™οΈ Parameters

tenant_id: String

doc_id: String

request_options: CloudPDF::Documents::RequestOptions

client.documents.upload_proxy(tenant_id:, doc_id:, request) -> CloudPDF::Types::DocumentsUploadProxyResponse

πŸ“ Description

This bounded origin-mediated fallback must only be used after documents.init returns upload.kind=proxy. Auto mode prefers a presigned object-store PUT whenever available. An upload token sends files only to the documents it started.

πŸ”Œ Usage

File.open("document.pdf", "rb") do |file|
  client.documents.upload_proxy(
    tenant_id: "tenantId",
    doc_id: "docId",
    file: file
  )
end

βš™οΈ Parameters

tenant_id: String

doc_id: String

request_options: CloudPDF::Documents::RequestOptions

client.documents.import_from(tenant_id:, request) -> CloudPDF::Types::DocumentsImportFrom200Response

πŸ“ Description

Default mode is synchronous and bounded: the response returns only after the transfer verified and committed (or failed). mode=async (connection sources only) answers 202 immediately and an in-process worker performs the transfer with leased, fenced retries; poll the document until ready/failed. The deployment import policy gates scheme, network range, and size; sources must declare a length. CloudPDF copies and owns the bytes β€” the source is never referenced in place. A 502 marks a retryable upstream failure: retry with the same idempotencyKey to resume the same document. URL sources are capabilities and never echoed back. Connection sources name operator-registered storage (bucket/prefix scope, allowed credential classes, and tenant bindings are deployment configuration); revision is provider-interpreted (S3 VersionId, GCS generation, Azure version id).

πŸ”Œ Usage

client.documents.import_from(tenant_id: "tenantId")

βš™οΈ Parameters

tenant_id: String

source: CloudPDF::Documents::Types::DocumentsImportFromRequestSource β€” Where CloudPDF pulls the bytes from. The two shapes differ in who supplies the authority to read, not in which storage vendor holds the file.

expected: CloudPDF::Documents::Types::DocumentsImportFromRequestExpected β€” Integrity pins, enforced when present. When absent, the server-observed values become authoritative.

name: String β€” What people call the document: shown in dashboards, searched and sorted by. 1 to 255 characters, no control characters, no leading or trailing whitespace. Names need not be unique.

folder_id: String β€” A folder id, or root for the top level.

metadata: Internal::Types::Hash[String, Object]

idempotency_key: String β€” Retrying with the same key resumes the same document rather than importing a second copy β€” including after a 502.

dedup_mode: CloudPDF::Documents::Types::DocumentsImportFromRequestDedupMode β€” always-create (default) creates a new document every time. reuse-existing returns a document that already holds the same content instead of storing it twice.

doc_id: String

mode: CloudPDF::Documents::Types::DocumentsImportFromRequestMode β€” sync (default) holds the response open for the whole transfer. async answers 202 with the document pending and transfers in the background; it requires a connection source, and filesystem connections additionally require expected.sha256.

request_options: CloudPDF::Documents::RequestOptions

client.documents.init(tenant_id:, request) -> CloudPDF::Types::DocumentsInitResponse

πŸ“ Description

With an upload token, the document goes into the token's folder with the token's metadata, whatever the request says; sizeBytes must be within the token's maxBytes, and the token makes at most maxFiles documents (403 after). docId, idempotencyKey and dedupMode reuse-existing are refused (400): each could reach a document the token didn't make.

πŸ”Œ Usage

client.documents.init(
  tenant_id: "tenantId",
  size_bytes: 1,
  content_sha256: "contentSha256"
)

βš™οΈ Parameters

tenant_id: String

size_bytes: Integer

content_sha256: String

name: String β€” What people call the document: shown in dashboards, searched and sorted by. 1 to 255 characters, no control characters, no leading or trailing whitespace. Names need not be unique.

folder_id: String β€” A folder id, or root for the top level.

metadata: Internal::Types::Hash[String, Object]

idempotency_key: String

dedup_mode: CloudPDF::Documents::Types::DocumentsInitRequestDedupMode β€” always-create (default) creates a new document every time. reuse-existing returns a document that already holds the same content instead of storing it twice.

doc_id: String

upload_ttl_seconds: Integer

upload_preference: CloudPDF::Documents::Types::DocumentsInitRequestUploadPreference

request_options: CloudPDF::Documents::RequestOptions

Folders

client.folders.list(tenant_id:) -> CloudPDF::Types::FoldersListResponse

πŸ”Œ Usage

client.folders.list(tenant_id: "tenantId")

βš™οΈ Parameters

tenant_id: String

limit: Integer

cursor: String

parent_id: String β€” Only the folders directly in this folder (root: the top level). Without it, every folder.

request_options: CloudPDF::Folders::RequestOptions

client.folders.create(tenant_id:, request) -> CloudPDF::Types::FoldersCreateResponse

πŸ“ Description

409 Conflict carries details.reason: name-taken (a sibling has the name, ignoring case; details.name) or too-deep (folders nest at most 100 levels; details.maxDepth). 404 when the parent folder does not exist.

πŸ”Œ Usage

client.folders.create(
  tenant_id: "tenantId",
  name: "name"
)

βš™οΈ Parameters

tenant_id: String

name: String β€” What people call the folder: 1 to 255 characters, no control characters, no leading or trailing whitespace, and unique among the folder's siblings, ignoring case.

parent_id: String β€” A folder id, or root for the top level.

request_options: CloudPDF::Folders::RequestOptions

client.folders.get(tenant_id:, folder_id:) -> CloudPDF::Types::FoldersGetResponse

πŸ”Œ Usage

client.folders.get(
  tenant_id: "tenantId",
  folder_id: "folderId"
)

βš™οΈ Parameters

tenant_id: String

folder_id: String

request_options: CloudPDF::Folders::RequestOptions

client.folders.delete(tenant_id:, folder_id:) ->

πŸ“ Description

Without recursive, a folder with anything inside is refused: 409 Conflict with details.reason not-empty and what it holds, counted over every level below, in details.folders and details.documents. With recursive=true, the folder and every folder under it go at once, and every document in them stops opening, leaves every list and stops answering its grants at once; their stored files and grants are removed in the background. Uploads into those folders that have not committed cannot commit.

πŸ”Œ Usage

client.folders.delete(
  tenant_id: "tenantId",
  folder_id: "folderId"
)

βš™οΈ Parameters

tenant_id: String

folder_id: String

recursive: Internal::Types::Boolean β€” true deletes everything in the folder too. Never the default.

request_options: CloudPDF::Folders::RequestOptions

client.folders.update(tenant_id:, folder_id:, request) -> CloudPDF::Types::FoldersUpdateResponse

πŸ“ Description

409 Conflict with details.reason name-taken when a sibling has the name, ignoring case.

πŸ”Œ Usage

client.folders.update(
  tenant_id: "tenantId",
  folder_id: "folderId",
  name: "name"
)

βš™οΈ Parameters

tenant_id: String

folder_id: String

name: String β€” What people call the folder: 1 to 255 characters, no control characters, no leading or trailing whitespace, and unique among the folder's siblings, ignoring case.

request_options: CloudPDF::Folders::RequestOptions

client.folders.move_into(tenant_id:, folder_id:, request) ->

πŸ“ Description

Up to 1,000 ids in total. A folder moves with everything in it. 404 NotFound names the ids that do not exist or are being deleted in details.docIds and details.folderIds. 409 Conflict carries details.reason: cycle (the destination is a moved folder or inside one; details.folderId), too-deep (the move would nest folders deeper than 100 levels; details.maxDepth) or name-taken (a moved folder's name is taken in the destination, ignoring case; details.name).

πŸ”Œ Usage

client.folders.move_into(
  tenant_id: "tenantId",
  folder_id: "folderId"
)

βš™οΈ Parameters

tenant_id: String

folder_id: String β€” A folder id, or root for the top level.

doc_ids: Internal::Types::Array[String]

folder_ids: Internal::Types::Array[String]

request_options: CloudPDF::Folders::RequestOptions

Tokens

client.tokens.issue(tenant_id:, request) -> CloudPDF::Types::TokensIssueResponse

πŸ“ Description

Authority mints only downward: kind "doc" gives only document permissions the caller holds itself, kind "tenant" requires the API token, and kind "upload" requires docs.create instead of tokens.issue-doc, since an upload token can do only what docs.create allows. Mounted only when the deployment can sign (HS256 mode); asymmetric deployments mint with their own private key.

πŸ”Œ Usage

client.tokens.issue(tenant_id: "tenantId")

βš™οΈ Parameters

tenant_id: String

request: CloudPDF::Types::TokensIssueRequest

request_options: CloudPDF::Tokens::RequestOptions

client.tokens.revoke(tenant_id:, jti:, request) ->

πŸ“ Description

Mounted only when the deployment enables token revocation.

πŸ”Œ Usage

client.tokens.revoke(
  tenant_id: "tenantId",
  jti: "jti"
)

βš™οΈ Parameters

tenant_id: String

jti: String

reason: String

expires_at: String

request_options: CloudPDF::Tokens::RequestOptions

Doc Annotations

client.doc.annotations.list_all(doc_id:, layer_name:) -> CloudPDF::Types::AnnotationList

πŸ“ Description

Returns one entry per page plus the audit-log cursor for reconciling subsequent document events. Page order is unspecified; join by page (a PageRef) when display order matters.

πŸ”Œ Usage

client.doc.annotations.list_all(
  doc_id: "docId",
  layer_name: "layerName"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

document_password: String β€” 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.

request_options: CloudPDF::Doc::Annotations::RequestOptions

client.doc.annotations.list(doc_id:, layer_name:, page_key:) -> CloudPDF::Types::AnnotationList

πŸ”Œ Usage

client.doc.annotations.list(
  doc_id: "docId",
  layer_name: "layerName",
  page_key: "pageKey"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

page_key: String β€” The page's address, obj:N: the page's indirect object number, the durable identity every PageLayout.ref carries. Mirrors annotationKey and fieldKey.

document_password: String β€” 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.

request_options: CloudPDF::Doc::Annotations::RequestOptions

client.doc.annotations.create(doc_id:, layer_name:, page_key:, request) -> CloudPDF::Types::DocAnnotationsCreateResponse

πŸ“ Description

Doc JWTs may instead carry collab scopes (annotations:create:self, …) that refine per-annotation authorship rules; the API token is exempt from both.

πŸ”Œ Usage

client.doc.annotations.create(
  doc_id: "docId",
  layer_name: "layerName",
  page_key: "pageKey",
  request: {
    key: "value"
  }
)

βš™οΈ Parameters

doc_id: String

layer_name: String

page_key: String β€” The page's address, obj:N: the page's indirect object number, the durable identity every PageLayout.ref carries. Mirrors annotationKey and fieldKey.

document_password: String β€” 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.

idempotency_key: String β€” Names the change: 1 to 255 printable ASCII characters. A retry under the same key on the same layer answers with what the first request committed, and changes nothing.

request: Internal::Types::Hash[String, Object]

request_options: CloudPDF::Doc::Annotations::RequestOptions

client.doc.annotations.delete(doc_id:, layer_name:, page_key:, annotation_key:) -> CloudPDF::Types::DocAnnotationsDeleteResponse

πŸ”Œ Usage

client.doc.annotations.delete(
  doc_id: "docId",
  layer_name: "layerName",
  page_key: "pageKey",
  annotation_key: "annotationKey"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

page_key: String β€” The page's address, obj:N: the page's indirect object number, the durable identity every PageLayout.ref carries. Mirrors annotationKey and fieldKey.

annotation_key: String β€” The annotation's address on the page: obj:N, its indirect object number, or base:N for an annotation the uploaded file stored inline (without an object number of its own), the position it was born at in the page's /Annots. The name the annotation's ref carries for life.

document_password: String β€” 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.

idempotency_key: String β€” Names the change: 1 to 255 printable ASCII characters. A retry under the same key on the same layer answers with what the first request committed, and changes nothing.

request_options: CloudPDF::Doc::Annotations::RequestOptions

client.doc.annotations.update(doc_id:, layer_name:, page_key:, annotation_key:, request) -> CloudPDF::Types::DocAnnotationsUpdateResponse

πŸ”Œ Usage

client.doc.annotations.update(
  doc_id: "docId",
  layer_name: "layerName",
  page_key: "pageKey",
  annotation_key: "annotationKey",
  request: {
    key: "value"
  }
)

βš™οΈ Parameters

doc_id: String

layer_name: String

page_key: String β€” The page's address, obj:N: the page's indirect object number, the durable identity every PageLayout.ref carries. Mirrors annotationKey and fieldKey.

annotation_key: String β€” The annotation's address on the page: obj:N, its indirect object number, or base:N for an annotation the uploaded file stored inline (without an object number of its own), the position it was born at in the page's /Annots. The name the annotation's ref carries for life.

document_password: String β€” 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.

idempotency_key: String β€” Names the change: 1 to 255 printable ASCII characters. A retry under the same key on the same layer answers with what the first request committed, and changes nothing.

request: Internal::Types::Hash[String, Object]

request_options: CloudPDF::Doc::Annotations::RequestOptions

client.doc.annotations.read_appearance(doc_id:, layer_name:, page_key:, annotation_key:) -> String

πŸ”Œ Usage

client.doc.annotations.read_appearance(
  doc_id: "docId",
  layer_name: "layerName",
  page_key: "pageKey",
  annotation_key: "annotationKey"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

page_key: String β€” The page's address, obj:N: the page's indirect object number, the durable identity every PageLayout.ref carries. Mirrors annotationKey and fieldKey.

annotation_key: String β€” The annotation's address on the page: obj:N, its indirect object number, or base:N for an annotation the uploaded file stored inline (without an object number of its own), the position it was born at in the page's /Annots. The name the annotation's ref carries for life.

document_password: String β€” 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.

request_options: CloudPDF::Doc::Annotations::RequestOptions

client.doc.annotations.read_file(doc_id:, layer_name:, page_key:, annotation_key:) -> String

πŸ“ Description

A file that decodes past the server's limit is refused (PayloadTooLarge).

πŸ”Œ Usage

client.doc.annotations.read_file(
  doc_id: "docId",
  layer_name: "layerName",
  page_key: "pageKey",
  annotation_key: "annotationKey"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

page_key: String β€” The page's address, obj:N: the page's indirect object number, the durable identity every PageLayout.ref carries. Mirrors annotationKey and fieldKey.

annotation_key: String β€” The annotation's address on the page: obj:N, its indirect object number, or base:N for an annotation the uploaded file stored inline (without an object number of its own), the position it was born at in the page's /Annots. The name the annotation's ref carries for life.

document_password: String β€” 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.

request_options: CloudPDF::Doc::Annotations::RequestOptions

client.doc.annotations.export_appearance(doc_id:, layer_name:, page_key:, request) -> String

πŸ”Œ Usage

client.doc.annotations.export_appearance(
  doc_id: "docId",
  layer_name: "layerName",
  page_key: "pageKey",
  request: {
    string: {
      key: "value"
    }
  }
)

βš™οΈ Parameters

doc_id: String

layer_name: String

page_key: String β€” The page's address, obj:N: the page's indirect object number, the durable identity every PageLayout.ref carries. Mirrors annotationKey and fieldKey.

document_password: String β€” 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.

request: Internal::Types::Hash[String, Object]

request_options: CloudPDF::Doc::Annotations::RequestOptions

client.doc.annotations.flatten(doc_id:, layer_name:, page_key:, request) -> CloudPDF::Types::DocAnnotationsFlattenResponse

πŸ”Œ Usage

client.doc.annotations.flatten(
  doc_id: "docId",
  layer_name: "layerName",
  page_key: "pageKey",
  request: {
    key: "value"
  }
)

βš™οΈ Parameters

doc_id: String

layer_name: String

page_key: String β€” The page's address, obj:N: the page's indirect object number, the durable identity every PageLayout.ref carries. Mirrors annotationKey and fieldKey.

document_password: String β€” 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.

idempotency_key: String β€” Names the change: 1 to 255 printable ASCII characters. A retry under the same key on the same layer answers with what the first request committed, and changes nothing.

request: Internal::Types::Hash[String, Object]

request_options: CloudPDF::Doc::Annotations::RequestOptions

client.doc.annotations.reorder(doc_id:, layer_name:, page_key:, request) -> CloudPDF::Types::DocAnnotationsReorderResponse

πŸ”Œ Usage

client.doc.annotations.reorder(
  doc_id: "docId",
  layer_name: "layerName",
  page_key: "pageKey",
  refs: [],
  position: "start"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

page_key: String β€” The page's address, obj:N: the page's indirect object number, the durable identity every PageLayout.ref carries. Mirrors annotationKey and fieldKey.

document_password: String β€” 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.

idempotency_key: String β€” Names the change: 1 to 255 printable ASCII characters. A retry under the same key on the same layer answers with what the first request committed, and changes nothing.

refs: Internal::Types::Array[CloudPDF::Types::AnnotationRef]

position: CloudPDF::Types::AnnotationPosition

request_options: CloudPDF::Doc::Annotations::RequestOptions

Doc Attachments

client.doc.attachments.download(doc_id:, layer_name:, file_key:) -> String

πŸ“ Description

A file that decodes past the server's limit is refused (PayloadTooLarge).

πŸ”Œ Usage

client.doc.attachments.download(
  doc_id: "docId",
  layer_name: "layerName",
  file_key: "fileKey"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

file_key: String β€” The embedded file's name-tree key (its ref.key), token-text encoded, as fieldKey is.

document_password: String β€” 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.

request_options: CloudPDF::Doc::Attachments::RequestOptions

client.doc.attachments.list(doc_id:, layer_name:) -> CloudPDF::Types::AttachmentList

πŸ“ Description

A file-attachment annotation's file is listed with the annotation; read its bytes with doc.annotations.readFile.

πŸ”Œ Usage

client.doc.attachments.list(
  doc_id: "docId",
  layer_name: "layerName"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

document_password: String β€” 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.

request_options: CloudPDF::Doc::Attachments::RequestOptions

Doc Fonts

client.doc.fonts.list(doc_id:, layer_name:) -> CloudPDF::Types::FontList

πŸ”Œ Usage

client.doc.fonts.list(
  doc_id: "docId",
  layer_name: "layerName"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

document_password: String β€” 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.

request_options: CloudPDF::Doc::Fonts::RequestOptions

client.doc.fonts.resolve(doc_id:, layer_name:, request) -> CloudPDF::Types::FontResolution

πŸ”Œ Usage

client.doc.fonts.resolve(
  doc_id: "docId",
  layer_name: "layerName",
  runs: [{
    text: "text"
  }]
)

βš™οΈ Parameters

doc_id: String

layer_name: String

document_password: String β€” 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.

request: CloudPDF::Types::FontResolveRequest

request_options: CloudPDF::Doc::Fonts::RequestOptions

Doc Forms

client.doc.forms.list(doc_id:, layer_name:) -> CloudPDF::Types::DocFormsListResponse

πŸ”Œ Usage

client.doc.forms.list(
  doc_id: "docId",
  layer_name: "layerName"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

document_password: String β€” 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.

request_options: CloudPDF::Doc::Forms::RequestOptions

client.doc.forms.reorder_calculations(doc_id:, layer_name:, request) -> CloudPDF::Types::DocFormsReorderCalculationsResponse

πŸ”Œ Usage

client.doc.forms.reorder_calculations(
  doc_id: "docId",
  layer_name: "layerName",
  fields: [],
  position: "start"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

document_password: String β€” 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.

idempotency_key: String β€” Names the change: 1 to 255 printable ASCII characters. A retry under the same key on the same layer answers with what the first request committed, and changes nothing.

fields: Internal::Types::Array[CloudPDF::Types::FormFieldRef]

position: CloudPDF::Types::FieldPosition

request_options: CloudPDF::Doc::Forms::RequestOptions

client.doc.forms.set_value(doc_id:, layer_name:, field_key:, request) -> CloudPDF::Types::DocFormsSetValueResponse

πŸ”Œ Usage

client.doc.forms.set_value(
  doc_id: "docId",
  layer_name: "layerName",
  field_key: "fieldKey",
  request: {
    key: "value"
  }
)

βš™οΈ Parameters

doc_id: String

layer_name: String

field_key: String

document_password: String β€” 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.

idempotency_key: String β€” Names the change: 1 to 255 printable ASCII characters. A retry under the same key on the same layer answers with what the first request committed, and changes nothing.

request: Internal::Types::Hash[String, Object]

request_options: CloudPDF::Doc::Forms::RequestOptions

client.doc.forms.reset(doc_id:, layer_name:, request) -> CloudPDF::Types::DocFormsResetResponse

πŸ”Œ Usage

client.doc.forms.reset(
  doc_id: "docId",
  layer_name: "layerName"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

document_password: String β€” 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.

idempotency_key: String β€” Names the change: 1 to 255 printable ASCII characters. A retry under the same key on the same layer answers with what the first request committed, and changes nothing.

refs: Internal::Types::Array[CloudPDF::Types::FormFieldRef]

request_options: CloudPDF::Doc::Forms::RequestOptions

client.doc.forms.delete_widget(doc_id:, layer_name:, page_key:, annotation_key:) -> CloudPDF::Types::DocFormsDeleteWidgetResponse

πŸ”Œ Usage

client.doc.forms.delete_widget(
  doc_id: "docId",
  layer_name: "layerName",
  page_key: "pageKey",
  annotation_key: "annotationKey"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

page_key: String β€” The page's address, obj:N: the page's indirect object number, the durable identity every PageLayout.ref carries. Mirrors annotationKey and fieldKey.

annotation_key: String β€” The annotation's address on the page: obj:N, its indirect object number, or base:N for an annotation the uploaded file stored inline (without an object number of its own), the position it was born at in the page's /Annots. The name the annotation's ref carries for life.

document_password: String β€” 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.

idempotency_key: String β€” Names the change: 1 to 255 printable ASCII characters. A retry under the same key on the same layer answers with what the first request committed, and changes nothing.

request_options: CloudPDF::Doc::Forms::RequestOptions

client.doc.forms.update_widget(doc_id:, layer_name:, page_key:, annotation_key:, request) -> CloudPDF::Types::DocFormsUpdateWidgetResponse

πŸ”Œ Usage

client.doc.forms.update_widget(
  doc_id: "docId",
  layer_name: "layerName",
  page_key: "pageKey",
  annotation_key: "annotationKey",
  patch: {}
)

βš™οΈ Parameters

doc_id: String

layer_name: String

page_key: String β€” The page's address, obj:N: the page's indirect object number, the durable identity every PageLayout.ref carries. Mirrors annotationKey and fieldKey.

annotation_key: String β€” The annotation's address on the page: obj:N, its indirect object number, or base:N for an annotation the uploaded file stored inline (without an object number of its own), the position it was born at in the page's /Annots. The name the annotation's ref carries for life.

document_password: String β€” 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.

idempotency_key: String β€” Names the change: 1 to 255 printable ASCII characters. A retry under the same key on the same layer answers with what the first request committed, and changes nothing.

patch: CloudPDF::Types::WidgetPatch

request_options: CloudPDF::Doc::Forms::RequestOptions

client.doc.forms.reorder_widgets(doc_id:, layer_name:, page_key:, request) -> CloudPDF::Types::DocFormsReorderWidgetsResponse

πŸ”Œ Usage

client.doc.forms.reorder_widgets(
  doc_id: "docId",
  layer_name: "layerName",
  page_key: "pageKey",
  widgets: [],
  position: "start"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

page_key: String β€” The page's address, obj:N: the page's indirect object number, the durable identity every PageLayout.ref carries. Mirrors annotationKey and fieldKey.

document_password: String β€” 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.

idempotency_key: String β€” Names the change: 1 to 255 printable ASCII characters. A retry under the same key on the same layer answers with what the first request committed, and changes nothing.

widgets: Internal::Types::Array[CloudPDF::Types::AnnotationRef]

position: CloudPDF::Types::AnnotationPosition

request_options: CloudPDF::Doc::Forms::RequestOptions

Doc Metadata

client.doc.metadata.get(doc_id:, layer_name:) -> CloudPDF::Types::DocumentMetadata

πŸ”Œ Usage

client.doc.metadata.get(
  doc_id: "docId",
  layer_name: "layerName"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

document_password: String β€” 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.

request_options: CloudPDF::Doc::Metadata::RequestOptions

Doc Outline

client.doc.outline.get(doc_id:, layer_name:) -> CloudPDF::Types::DocumentOutline

πŸ”Œ Usage

client.doc.outline.get(
  doc_id: "docId",
  layer_name: "layerName"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

document_password: String β€” 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.

request_options: CloudPDF::Doc::Outline::RequestOptions

Doc Pages

client.doc.pages.set_scale(doc_id:, layer_name:, page_key:, request) -> CloudPDF::Types::DocPagesSetScaleResponse

πŸ”Œ Usage

client.doc.pages.set_scale(
  doc_id: "docId",
  layer_name: "layerName",
  page_key: "pageKey"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

page_key: String β€” The page's address, obj:N: the page's indirect object number, the durable identity every PageLayout.ref carries. Mirrors annotationKey and fieldKey.

document_password: String β€” 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.

idempotency_key: String β€” Names the change: 1 to 255 printable ASCII characters. A retry under the same key on the same layer answers with what the first request committed, and changes nothing.

measure: CloudPDF::Doc::Pages::Types::DocPagesSetScaleRequestMeasure

request_options: CloudPDF::Doc::Pages::RequestOptions

client.doc.pages.viewports(doc_id:, layer_name:, page_key:) -> CloudPDF::Types::DocPagesViewportsResponse

πŸ”Œ Usage

client.doc.pages.viewports(
  doc_id: "docId",
  layer_name: "layerName",
  page_key: "pageKey"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

page_key: String β€” The page's address, obj:N: the page's indirect object number, the durable identity every PageLayout.ref carries. Mirrors annotationKey and fieldKey.

document_password: String β€” 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.

request_options: CloudPDF::Doc::Pages::RequestOptions

client.doc.pages.extract(doc_id:, layer_name:, request) -> String

πŸ“ Description

A read, not a mutation: the source document is untouched and no event is published. Body is {"pages": PageRef[], "flatten"?: {"usage"?: "display" | "print"}, "includeAnnotations"?: boolean, "includeFormFields"?: boolean}; the response body is the new PDF. With flatten the copy is the pages as they draw for usage ("print": a print copy): the annotations and form fields painted in, nothing interactive left, layers in their state for the usage. A flattened copy takes doc.download or doc.download.flattened, and paints only what the caller may read; includeAnnotations and includeFormFields choose what it paints, and are refused without flatten.

πŸ”Œ Usage

client.doc.pages.extract(
  doc_id: "docId",
  layer_name: "layerName",
  request: {
    string: {
      key: "value"
    }
  }
)

βš™οΈ Parameters

doc_id: String

layer_name: String

document_password: String β€” 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.

request: Internal::Types::Hash[String, Object]

request_options: CloudPDF::Doc::Pages::RequestOptions

client.doc.pages.flatten(doc_id:, layer_name:, request) -> CloudPDF::Types::DocPagesFlattenResponse

πŸ”Œ Usage

client.doc.pages.flatten(
  doc_id: "docId",
  layer_name: "layerName",
  request: {
    key: "value"
  }
)

βš™οΈ Parameters

doc_id: String

layer_name: String

document_password: String β€” 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.

idempotency_key: String β€” Names the change: 1 to 255 printable ASCII characters. A retry under the same key on the same layer answers with what the first request committed, and changes nothing.

request: Internal::Types::Hash[String, Object]

request_options: CloudPDF::Doc::Pages::RequestOptions

client.doc.pages.set_name(doc_id:, layer_name:, request) -> CloudPDF::Types::DocPagesSetNameResponse

πŸ”Œ Usage

client.doc.pages.set_name(
  doc_id: "docId",
  layer_name: "layerName",
  request: {
    key: "value"
  }
)

βš™οΈ Parameters

doc_id: String

layer_name: String

document_password: String β€” 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.

idempotency_key: String β€” Names the change: 1 to 255 printable ASCII characters. A retry under the same key on the same layer answers with what the first request committed, and changes nothing.

request: Internal::Types::Hash[String, Object]

request_options: CloudPDF::Doc::Pages::RequestOptions

client.doc.pages.remove_name(doc_id:, layer_name:, request) -> CloudPDF::Types::DocPagesRemoveNameResponse

πŸ”Œ Usage

client.doc.pages.remove_name(
  doc_id: "docId",
  layer_name: "layerName",
  request: {
    key: "value"
  }
)

βš™οΈ Parameters

doc_id: String

layer_name: String

document_password: String β€” 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.

idempotency_key: String β€” Names the change: 1 to 255 printable ASCII characters. A retry under the same key on the same layer answers with what the first request committed, and changes nothing.

request: Internal::Types::Hash[String, Object]

request_options: CloudPDF::Doc::Pages::RequestOptions

Doc Redactions

client.doc.redactions.apply(doc_id:, layer_name:, request) -> CloudPDF::Types::DocRedactionsApplyResponse

πŸ”Œ Usage

client.doc.redactions.apply(
  doc_id: "docId",
  layer_name: "layerName"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

document_password: String β€” 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.

idempotency_key: String β€” Names the change: 1 to 255 printable ASCII characters. A retry under the same key on the same layer answers with what the first request committed, and changes nothing.

pages: Internal::Types::Array[CloudPDF::Types::PageRef]

annotations: Internal::Types::Array[CloudPDF::Types::AnnotationRef]

request_options: CloudPDF::Doc::Redactions::RequestOptions

Doc Signatures

client.doc.signatures.list(doc_id:, layer_name:) -> CloudPDF::Types::DocSignaturesListResponse

πŸ“ Description

Describes the bytes the layer is over: the base version's signatures plus the layer's own edits as the last revision. Signed bytes (contents, digests, revision prefixes) are served per base version under /versions.

πŸ”Œ Usage

client.doc.signatures.list(
  doc_id: "docId",
  layer_name: "layerName"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

document_password: String β€” 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.

request_options: CloudPDF::Doc::Signatures::RequestOptions

client.doc.signatures.cancel(doc_id:, layer_name:, signing_id:) -> CloudPDF::Types::DocSignaturesCancelResponse

πŸ”Œ Usage

client.doc.signatures.cancel(
  doc_id: "docId",
  layer_name: "layerName",
  signing_id: "signingId"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

signing_id: String

document_password: String β€” 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.

request_options: CloudPDF::Doc::Signatures::RequestOptions

client.doc.signatures.complete(doc_id:, layer_name:, signing_id:, request) -> CloudPDF::Types::DocSignaturesCompleteResponse

πŸ“ Description

cms is the detached CMS over the prepared digest, base64. expectedVersion must be what prepare returned. Idempotent by signing id: the same CMS again answers already-completed. The new version is the layer's own: only this layer moves to it, and the document and every other layer stay as they were. Refetch the manifest after a completion.

πŸ”Œ Usage

client.doc.signatures.complete(
  doc_id: "docId",
  layer_name: "layerName",
  signing_id: "signingId",
  cms: "cms",
  expected_version: {
    base_sha256: "baseSha256",
    edits_version: 1
  }
)

βš™οΈ Parameters

doc_id: String

layer_name: String

signing_id: String

document_password: String β€” 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.

cms: String

expected_version: CloudPDF::Doc::Signatures::Types::DocSignaturesCompleteRequestExpectedVersion

request_options: CloudPDF::Doc::Signatures::RequestOptions

client.doc.signatures.analysis(doc_id:, layer_name:) -> CloudPDF::Types::DocSignaturesAnalysisResponse

πŸ“ Description

Exactly one of since.signature=<index> or since.revision=<index>; the layer's pending edits are the end. level=fill|annotate|lta|none evaluates exploratorily and never becomes a verdict. For history between two base revisions use the version analysis.

πŸ”Œ Usage

client.doc.signatures.analysis(
  doc_id: "docId",
  layer_name: "layerName"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

since_signature: Integer

since_revision: Integer

level: CloudPDF::Doc::Signatures::Types::AnalysisSignaturesRequestLevel

document_password: String β€” 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.

request_options: CloudPDF::Doc::Signatures::RequestOptions

client.doc.signatures.prepare(doc_id:, layer_name:, request) -> CloudPDF::Types::DocSignaturesPrepareResponse

πŸ“ Description

Multipart: a JSON body part (field, subFilter, digest, contentsSize, signer, certify, lock), naming the appearance PDF it may carry as resources: { appearance: '<key>' }, and that PDF as the part resource:<key>. A certification (certify.permission) additionally requires doc.sign.certify. The layer is read-only until the signing completes, is cancelled, or expires (15 minutes). The signature is made over the layer's own base: the upload, or the version its last signature made.

πŸ”Œ Usage

client.doc.signatures.prepare(
  doc_id: "docId",
  layer_name: "layerName"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

document_password: String β€” 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.

request_options: CloudPDF::Doc::Signatures::RequestOptions

Doc Versions

client.doc.versions.list(doc_id:, layer_name:) -> CloudPDF::Types::DocVersionsListResponse

πŸ“ Description

Every completed signature makes a new version of its layer; another layer's versions are never listed. Never cached: the list grows.

πŸ”Œ Usage

client.doc.versions.list(
  doc_id: "docId",
  layer_name: "layerName"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

document_password: String β€” 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.

request_options: CloudPDF::Doc::Versions::RequestOptions

client.doc.versions.analysis(doc_id:, layer_name:, sha256:) -> CloudPDF::Types::DocVersionsAnalysisResponse

πŸ“ Description

Exactly one of since.signature / since.revision; until=<revision> defaults to the last. The same answer for every caller.

πŸ”Œ Usage

client.doc.versions.analysis(
  doc_id: "docId",
  layer_name: "layerName",
  sha256: "sha256"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

sha256: String

since_signature: Integer

since_revision: Integer

level: CloudPDF::Doc::Versions::Types::AnalysisVersionsRequestLevel

until_: Integer

policy: Integer

document_password: String β€” 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.

request_options: CloudPDF::Doc::Versions::RequestOptions

client.doc.versions.download(doc_id:, layer_name:, sha256:) -> String

πŸ”Œ Usage

client.doc.versions.download(
  doc_id: "docId",
  layer_name: "layerName",
  sha256: "sha256"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

sha256: String

document_password: String β€” 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.

request_options: CloudPDF::Doc::Versions::RequestOptions

client.doc.versions.revision(doc_id:, layer_name:, sha256:, index:) -> String

πŸ”Œ Usage

client.doc.versions.revision(
  doc_id: "docId",
  layer_name: "layerName",
  sha256: "sha256",
  index: 1
)

βš™οΈ Parameters

doc_id: String

layer_name: String

sha256: String

index: Integer

document_password: String β€” 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.

request_options: CloudPDF::Doc::Versions::RequestOptions

client.doc.versions.signatures(doc_id:, layer_name:, sha256:) -> CloudPDF::Types::DocVersionsSignaturesResponse

πŸ”Œ Usage

client.doc.versions.signatures(
  doc_id: "docId",
  layer_name: "layerName",
  sha256: "sha256"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

sha256: String

document_password: String β€” 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.

request_options: CloudPDF::Doc::Versions::RequestOptions

client.doc.versions.signature_contents(doc_id:, layer_name:, sha256:, field_key:) -> String

πŸ“ Description

fieldKey is the field's fully qualified name, token-text encoded (the same encoding attachment keys use).

πŸ”Œ Usage

client.doc.versions.signature_contents(
  doc_id: "docId",
  layer_name: "layerName",
  sha256: "sha256",
  field_key: "fieldKey"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

sha256: String

field_key: String

document_password: String β€” 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.

request_options: CloudPDF::Doc::Versions::RequestOptions

client.doc.versions.signature_digest(doc_id:, layer_name:, sha256:, field_key:, algorithm:) -> String

πŸ“ Description

What a CMS verifier compares its message digest to.

πŸ”Œ Usage

client.doc.versions.signature_digest(
  doc_id: "docId",
  layer_name: "layerName",
  sha256: "sha256",
  field_key: "fieldKey",
  algorithm: "sha1"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

sha256: String

field_key: String

algorithm: CloudPDF::Doc::Versions::Types::SignatureDigestVersionsRequestAlgorithm

document_password: String β€” 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.

request_options: CloudPDF::Doc::Versions::RequestOptions

Doc Fonts Programs

client.doc.fonts.programs.download(doc_id:, layer_name:, display_sha256:) -> String

πŸ“ Description

A document token needs any one of the listed capabilities: one that may write text in the document. A file the list says can't be downloaded (canDownload: false) is not found.

πŸ”Œ Usage

client.doc.fonts.programs.download(
  doc_id: "docId",
  layer_name: "layerName",
  display_sha256: "displaySha256"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

display_sha256: String

document_password: String β€” 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.

request_options: CloudPDF::Doc::Fonts::Programs::RequestOptions

client.doc.fonts.programs.get(doc_id:, layer_name:, display_sha256:) -> CloudPDF::Types::FontProgramInfo

πŸ”Œ Usage

client.doc.fonts.programs.get(
  doc_id: "docId",
  layer_name: "layerName",
  display_sha256: "displaySha256"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

display_sha256: String

document_password: String β€” 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.

request_options: CloudPDF::Doc::Fonts::Programs::RequestOptions

Doc Metadata Custom

client.doc.metadata.custom.get(doc_id:, layer_name:) -> Internal::Types::Hash[String, String]

πŸ”Œ Usage

client.doc.metadata.custom.get(
  doc_id: "docId",
  layer_name: "layerName"
)

βš™οΈ Parameters

doc_id: String

layer_name: String

document_password: String β€” 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.

request_options: CloudPDF::Doc::Metadata::Custom::RequestOptions

Documents Layers

client.documents.layers.list(tenant_id:, doc_id:) -> CloudPDF::Types::DocumentsLayersListResponse

πŸ”Œ Usage

client.documents.layers.list(
  tenant_id: "tenantId",
  doc_id: "docId"
)

βš™οΈ Parameters

tenant_id: String

doc_id: String

limit: Integer

cursor: String

grant_id: String

request_options: CloudPDF::Documents::Layers::RequestOptions

client.documents.layers.delete(tenant_id:, doc_id:, layer_name:) ->

πŸ”Œ Usage

client.documents.layers.delete(
  tenant_id: "tenantId",
  doc_id: "docId",
  layer_name: "layerName"
)

βš™οΈ Parameters

tenant_id: String

doc_id: String

layer_name: String

request_options: CloudPDF::Documents::Layers::RequestOptions

Grants Visitors

client.grants.visitors.list(tenant_id:, grant_id:) -> CloudPDF::Types::GrantsVisitorsListResponse

πŸ“ Description

An archived grant's visitors are listed too.

πŸ”Œ Usage

client.grants.visitors.list(
  tenant_id: "tenantId",
  grant_id: "grantId"
)

βš™οΈ Parameters

tenant_id: String

grant_id: String

limit: Integer

cursor: String

request_options: CloudPDF::Grants::Visitors::RequestOptions

client.grants.visitors.delete(tenant_id:, grant_id:, visitor_id:) ->

πŸ“ Description

Their handle brings them back as a new visitor, who is asked again. Deleting a visitor already deleted changes nothing.

πŸ”Œ Usage

client.grants.visitors.delete(
  tenant_id: "tenantId",
  grant_id: "grantId",
  visitor_id: "visitorId"
)

βš™οΈ Parameters

tenant_id: String

grant_id: String

visitor_id: String

request_options: CloudPDF::Grants::Visitors::RequestOptions