Skip to main content
PATCH
Create/reuse draft and edit app content

Authorizations

Authorization
string
header
required

Can be either an Organization API Key or Personal Access Token (PAT).

Include in the Authorization header as: Bearer YOUR_TOKEN

Path Parameters

documentId
string
required

Document identifier — either the URL slug (e.g. abc123) or the canonical workbook UUID.

Example:

"abc123"

Query Parameters

userId
string<uuid>

Organization API key required. The membership ID of the user to act as.

Body

application/json
htmlEdits
object[]
required

Targeted edits applied in order against the current HTML. A failed edit (not found, ambiguous, or result over the 2 MiB cap) rejects the entire request with 400 naming the edit. At most 20 edits per request.

Required array length: 1 - 20 elements
settings
object

When present, replaces the app settings; omitted fields take their locked-down defaults. When absent, the current settings are kept.

Response

Draft created or reused and edits applied. Use the draftIdentifier in the response to call the Publish draft API and publish the changes.

identifier
string
required

Published document identifier the draft targets.

Example:

"def456"

draftIdentifier
string
required

Identifier of the draft the patch was applied to.

Example:

"abc123"

name
string
required

Document name.

Example:

"Blob Sales"

description
string | null
required

Document description.

Example:

"Overview of daily Blobs R Us Sales"

app
object
required
warnings
string[]

Included only when non-blocking warnings are encountered when creating/updating an app. Currently, external resource hosts the app's iframe CSP will block until an Organization Admin allows them. The write itself succeeded.