Document apiReferenceLists

lists.create

Create a new list from one or more paragraphs. Supports optional preset or style for new sequences. When sequence.mode is "continuePrevious", preset and style are not allowed: the new items inherit formatting from the previous sequence.

mutates documentdry runnon-idempotent
doc.lists.create(…)

Expected result

Returns a ListsCreateResult with the new listId and the first item address.

Inputs

mode"empty" | "fromParagraphs"required

Required. 'fromParagraphs' converts existing paragraphs into list items: each paragraph becomes one item, so create one paragraph per item first. 'empty' creates a new empty list at 'at'.

atBlockAddressconditionally required

Required when mode is 'empty'. The paragraph to create the list at. Format: {kind:'block', nodeType:'paragraph', nodeId:'<id>'}.

Fields
kind"block"required
nodeType"paragraph"required
nodeIdstringrequired
targetBlockAddressOrRangeconditionally required

Required when mode is 'fromParagraphs'. Each call converts ONE paragraph into a list item. To make a list with N items, create N separate paragraphs first, then call superdoc_list create for EACH one. Format: {kind:'block', nodeType:'paragraph', nodeId:'<id>'}.

kind
kind"block"required
nodeType"paragraph"required
nodeIdstringrequired
from
fromBlockAddressrequired
Fields
kind"block"required
nodeType"paragraph"required
nodeIdstringrequired
toBlockAddressrequired
Fields
kind"block"required
nodeType"paragraph"required
nodeIdstringrequired
5 additional input fields
kind"ordered" | "bullet"

List type: 'bullet' for bullet points, 'ordered' for numbered lists.

levelinteger

List nesting level (0-8). 0 is the top level.

preset"decimal" | "decimalParenthesis" | "lowerLetter" | "lowerLetterParenthesis" | "upperLetter" | "upperLetterParenthesis" | "lowerRoman" | "upperRoman" | "disc" | "circle" | "square" | "dash"

Predefined list style preset. Overrides 'kind' with a specific numbering or bullet format.

styleobject
Fields
version1required
levelsobject[]required
sequencenew | continuePrevious
new
mode"new"required
startAtinteger
continuePrevious
mode"continuePrevious"required

Result

Output fields
true
status"NO_OP"
changeTagstring

Caller correlation for this commit only; never persisted or replayed on Undo/Redo.

temporaryobject
Fields
idstringrequired
phase"begin" | "replace" | "rollback" | "commit"required
tagstringrequired
onNativeEdit"cancel" | "preserve"
cancelledBy"native-edit"
appliedChangeMode"direct" | "tracked"
idstring
insertedEntityAddress[]
updatedEntityAddress[]
removedEntityAddress[]
invalidatedRefsAffectedRef[]
remappedRefsAffectedRefRemapping[]
affectedStoriesStoryLocator[]
textRangeShiftsTextRangeShift[]
trackedTextRangeShiftsTrackedTextRangeShift[]
txIdstring
warningsReviewWarning[]
effectsReceiptEffects
Fields
insertedTextTextMutationEffect[]
insertedBlocksBlockMutationEffect[]
resultTextTextTarget
Fields
captureStatestring

Opaque browser selection capture state. Preserve it when passing a selection target to comments.create. Changed or unverifiable state is refused before writing.

kind"text"required
segmentsTextSegment[]required
storyStoryLocator

Story scope. Defaults to document body when omitted. Use {kind:'story', storyType:'body'} for body, or other storyType values for headers, footers, footnotes, endnotes.

body
kind"story"required
storyType"body"required
headerFooterSlot
kind"story"required
storyType"headerFooterSlot"required
sectionSectionAddressrequired
headerFooterKind"header" | "footer"required
variant"default" | "first" | "even"required
resolution"effective" | "explicit"
onWrite"materializeIfInherited" | "editResolvedPart" | "error"
headerFooterPart
kind"story"required
storyType"headerFooterPart"required
refIdstringrequired
footnote
kind"story"required
storyType"footnote"required
noteIdstringrequired
endnote
kind"story"required
storyType"endnote"required
noteIdstringrequired
textbox
kind"story"required
storyType"textbox"required
textboxIdstringrequired
coordinateSpaceTextCoordinateSpace
trackedChangeRefsTrackedChangeAddress[]
trackedChangeCountinteger
changedboolean
successtruerequired
listIdstringrequired
itemListItemAddressrequired
Fields
kind"block"required
nodeType"listItem"required
nodeIdstringrequired
storyStoryLocator

Story scope. Defaults to document body when omitted. Use {kind:'story', storyType:'body'} for body, or other storyType values for headers, footers, footnotes, endnotes.

body
kind"story"required
storyType"body"required
headerFooterSlot
kind"story"required
storyType"headerFooterSlot"required
sectionSectionAddressrequired
headerFooterKind"header" | "footer"required
variant"default" | "first" | "even"required
resolution"effective" | "explicit"
onWrite"materializeIfInherited" | "editResolvedPart" | "error"
headerFooterPart
kind"story"required
storyType"headerFooterPart"required
refIdstringrequired
footnote
kind"story"required
storyType"footnote"required
noteIdstringrequired
endnote
kind"story"required
storyType"endnote"required
noteIdstringrequired
textbox
kind"story"required
storyType"textbox"required
textboxIdstringrequired
false
successfalserequired
failureobjectrequired
Fields
code"INVALID_TARGET" | "LEVEL_OUT_OF_RANGE" | "INVALID_INPUT" | "NO_COMPATIBLE_PREVIOUS"required
messagestringrequired
detailsunknown

Failures

Pre-apply throws

  • TARGET_NOT_FOUND
  • CAPABILITY_UNAVAILABLE
  • INVALID_TARGET
1 more codes
  • INVALID_INPUT

Non-applied receipt codes

  • INVALID_TARGET
  • LEVEL_OUT_OF_RANGE
  • INVALID_INPUT
1 more codes
  • NO_COMPATIBLE_PREVIOUS

Raw schemas

Open the generated JSON artifact for the exact input, output, success, and failure schemas represented by this contract version.

View raw JSON schemas