Get draft content

draftContent(input: GetDraftContentInput!): DraftContent

Requires project.files.read.

Arguments

ArgumentTypeRequired
inputGetDraftContentInput!Yes

Input fields

input

GetDraftContentInput

FieldTypeRequiredDescription
projectReferenceStringNo
entityIdID!YesSource-file path or UUID. Missing drafts return null; restricted server-function source is denied or omitted when unreadable.
entityTypeDraftEntityType!YesLegacy entity-type hint.
branchIdIDNo
branchReferenceStringNoBranch name or UUID. Conflicting branchId aliases are rejected; omit/null for main.

Response

Returns DraftContent. Open the type for its fields and nested types.

FieldTypeDescription
entityIdID!
entityTypeDraftEntityType!Requested entity-type hint.
bodyString!Pending full-body snapshot; a null snapshot is represented as an empty string.
versionInt!Current draft sequence.
updatedAtDateTime

Types marked with ! cannot be null. Lists use [Type] notation. The type index lists all published input and response types.

Example

query.graphql
query DraftContent($input: GetDraftContentInput!) {  draftContent(input: $input) {    updatedAt    body    entityId    entityType    version  }}
variables.json
{  "input": {    "projectReference": "00000000-0000-4000-8000-000000000001",    "entityId": "00000000-0000-4000-8000-000000000001",    "entityType": "page"  }}