v1

latestOpenAPI 3.1.02026-07-2618690613.4 KB
Documents v2

Create draft and patch document

Create a new draft on the published document and apply the patch. There is no auto-publish — the response includes the new draftIdentifier for follow-up calls. Pass an optional branchId to attach the draft to a branch; omit it for a draft on the main (unpublished) workspace.

patch/v2/documents/{documentId}/draft

Path parameters

documentIdstring required

The published document's URL slug (e.g. abc123) or its canonical workbook UUID.

Request body

branchIdstring uuid

Branch the draft is created on. Omit for a draft on the main (unpublished) workspace.

modelIdstring uuid

Immutable model identifier. Must match the document's current base model or the API will return a 400 error.

workbookModelIdstring uuid

Immutable model identifier. Must match the document's current workbook model or the API will return a 400 error.

namestring

Document name.

descriptionstring nullable

Document description.

summarystring

Caller-supplied description of what this patch changes, written to the history audit trail. When omitted, Omni auto-generates one from the updated sections.

containersobject[]

Container layout. When present, fully replaces the existing layout.

Response

Draft created and patch applied successfully.

identifierstring required

Published document identifier the draft targets.

draftIdentifierstring required

Identifier of the draft the patch was applied to.

namestring required

Document name.

descriptionstring nullable required

Document description.

Example response

{
  "identifier": "def456",
  "draftIdentifier": "abc123",
  "name": "Blob Sales",
  "description": "Overview of daily Blobs R Us Sales"
}