Skip to content
SumOfficeSumOfficeSumOffice

window.fastdocShell · other methods

Methods that don't fit the topic groups above: edit history, working with the current document and windows, templates, autosave, and recovery. Methods: 70.

Methods that don’t fit the topic groups above: edit history, working with the current document and windows, templates, autosave, and recovery. Methods on this page: 70.

Methods on this page — 70
applyCanonicalHistory(direction: "undo" | "redo"): Promise<{ owner: "rust-session";
available: boolean;
sessionId: string | null;
documentId: string | null;
transactionOrder: number;
acceptedRevision: number;
selectionRevision: number;
publishedRevision: number;
dirty: boolean;
modelHash: string | null;
undoDepth: number;
redoDepth: number;
direction: "undo" | "redo";
projectionPath: string;
historyPreservedBySave: boolean;
sceneModelHash: string;
visibleSceneMatchesCanonicalModel: boolean;
residueCount: 0;
structuralProjection?: boolean;
structuralStartBodyBlockIndex?: number;
bridgeState?: ShellBridgeState;
transition: { transitionKind: string;
transactionOrder: number;
beforeModelHash: string;
afterModelHash: string;
paragraphIndex?: number;
beforeCaretSlotIndex?: number;
afterCaretSlotIndex?: number;
beforeSelectionStartSlotIndex?: number;
beforeSelectionEndSlotIndex?: number;
paragraphOwner?: string;
requestId?: string;
};
persistentReceipt?: BoundedLiveTextInsertResult["persistentReceipt"];
}>

web_to_host_request_response · invoke · fastdoc-shell:apply-canonical-history

applyEditorV0HomeFormattingCommand(request: EditorV0HomeFormattingRequest): Promise<EditorV0HomeFormattingResult>

web_to_host_request_response · invoke · fastdoc-shell:apply-editor-v0-home-formatting-command

applyEditorV0MailMergeCommandAction(request: EditorV0MailMergeCommandRequest): Promise<EditorV0MailMergeCommandResult>

deprecated: always responds with a refusal · the refusal comes with the code MAIL_MERGE_LEGACY_COMMAND_OWNER_RETIRED

applyOutlineMasterDocumentAction(request: OutlineMasterDocumentRequest): Promise<OutlineMasterDocumentResult>

web_to_host_request_response · invoke · fastdoc-shell:apply-outline-master-document-action

applyPersistentEditingComposition(request: CompositionRequest): Promise<CompositionReceipt>

web_to_host_request_response · invoke · fastdoc-shell:apply-persistent-editing-composition

applyPersistentEditingStructuralCommand(request: EditRequest, options?: { projectionRefresh?: "full" | "page-window" | "model-only";
pageIndex?: number;
}): Promise<{ receipt: EditReceipt;
model: Record<string, unknown>;
document: ShellLoadedDocument;
canonicalHistory: CanonicalHistoryState;
projectionRefresh: "full" | "page-window" | "model-only";
}>

web_to_host_request_response · invoke · fastdoc-shell:apply-persistent-editing-structural-command

web_to_host_request_response · invoke · fastdoc-shell:apply-quick-parts-document-operation

arrangeDocumentWindows(): Promise<{ arranged: number;
bounds: Array<{ x: number;
y: number;
width: number;
height: number }>;
windows: ShellDocumentWindowDescriptor[];
}>

web_to_host_request_response · invoke · fastdoc-shell:arrange-document-windows

checkLocalProofingWords(request: ShellProofingWordCheckRequest): Promise<ShellProofingWordCheckResult>

web_to_host_request_response · invoke · fastdoc-shell:check-local-proofing-words

clearRecentDocuments(): Promise<{ cleared: boolean; persisted: boolean; recentDocuments: string[]; }>

web_to_host_request_response · invoke · fastdoc-shell:clear-recent-documents

closeCurrentDocument(decision: "save" | "discard"): Promise<{ closed: boolean;
path: string | null;
decision: "save" | "discard";
}>

web_to_host_request_response · invoke · fastdoc-shell:close-current-document

commitAutosaveRecovery(request: { recoveryId: string; stagedPath: string }): Promise<ShellAutosaveRecoveryCandidate>

web_to_host_request_response · invoke · fastdoc-shell:commit-autosave-recovery

commitUserTemplate(request: { id: string;
title: string;
sourcePath: string;
previewText?: string;
}): ReturnType<FastDocShellApi["listFileStartTemplates"]>

web_to_host_request_response · invoke · fastdoc-shell:commit-user-template

completeSaveBeforeDocumentSwitch(result: { requestId: number;
saved: boolean;
savedPath: string | null;
errorMessage: string | null;
}): void

web_to_host_event · send · fastdoc-shell:document-switch-save-result

configureLocalProofingProvider(): Promise<ShellProofingProviderState>

web_to_host_request_response · invoke · fastdoc-shell:configure-local-proofing-provider

createDocumentWindow(): Promise<{ created: boolean;
windowId: number | null;
documentPath: string | null;
error: string | null;
windows: ShellDocumentWindowDescriptor[];
}>

web_to_host_request_response · invoke · fastdoc-shell:create-document-window

createEditableOdtCopy(): Promise<OdtEditableCopyUiResult>

web_to_host_request_response · invoke · fastdoc-shell:create-editable-odt-copy

createFromBuiltinTemplate(templateId: string): Promise<{ opened: boolean;
canceled: boolean;
path: string | null;
}>

web_to_host_request_response · invoke · fastdoc-shell:create-from-builtin-template

createFromUserTemplate(templateId: string): Promise<{ opened: boolean;
canceled: boolean;
path: string | null;
}>

web_to_host_request_response · invoke · fastdoc-shell:create-from-user-template

web_to_host_request_response · invoke · fastdoc-shell:create-quick-parts-building-block

createVersionCheckpoint(request: { reason: ShellVersionHistoryEntry["reason"];
name?: string | null;
pinned?: boolean;
recoverySessionId?: string | null;
}): Promise<ShellVersionHistoryEntry>

web_to_host_request_response · invoke · fastdoc-shell:create-version-checkpoint

web_to_host_request_response · invoke · fastdoc-shell:delete-quick-parts-building-block

deleteUserTemplate(templateId: string): ReturnType<FastDocShellApi["listFileStartTemplates"]>

web_to_host_request_response · invoke · fastdoc-shell:delete-user-template

deleteVersion(request: { versionId: string; confirmed: boolean }): Promise<{ deleted: true }>

web_to_host_request_response · invoke · fastdoc-shell:delete-version

finalizeAutosaveRecovery(request: { recoveryId: string;
action: "save" | "save-as" | "discard" | "cancel";
savedPath?: string | null;
}): Promise<{ finalized: boolean;
preserved: boolean }>

web_to_host_request_response · invoke · fastdoc-shell:finalize-autosave-recovery

focusDocumentWindow(windowId: number): Promise<{ focused: boolean;
windows: ShellDocumentWindowDescriptor[];
}>

web_to_host_request_response · invoke · fastdoc-shell:focus-document-window

getAutosaveRecoveryState(): Promise<{ sessionId: string;
settings: ShellAutosaveRecoverySettings;
candidates: ShellAutosaveRecoveryCandidate[] }>

web_to_host_request_response · invoke · fastdoc-shell:get-autosave-recovery-state

getDocumentWindowSession(): Promise<ShellDocumentWindowSession>

web_to_host_request_response · invoke · fastdoc-shell:get-document-window-session

getLocalProofingDocumentPolicy(request: { documentPath: string }): Promise<ShellProofingDocumentPolicy>

web_to_host_request_response · invoke · fastdoc-shell:get-local-proofing-document-policy

getPathForFile(file: { readonly name: string }): string

a direct Electron adapter, not a core command · runs synchronously and never reaches the core

inspectEditorV0HomeFormatting(): Promise<EditorV0HomeFormattingSnapshot>

web_to_host_request_response · invoke · fastdoc-shell:inspect-editor-v0-home-formatting

inspectExternalChange(request: { dirty: boolean }): Promise<ShellExternalChangePromptState>

web_to_host_request_response · invoke · fastdoc-shell:inspect-external-change

invalidatePersistentEditingProductRoute(reason: string): Promise<{ invalidated: true }>

web_to_host_request_response · invoke · fastdoc-shell:invalidate-persistent-editing-product-route

linkVersionHistorySaveAs(request: { previousPath: string; nextPath: string }): Promise<{ linked: true }>

web_to_host_request_response · invoke · fastdoc-shell:link-version-history-save-as

listDocumentWindows(): Promise<ShellDocumentWindowDescriptor[]>

web_to_host_request_response · invoke · fastdoc-shell:list-document-windows

listFileStartTemplates(): Promise<{ builtInTemplates: Array<{ id: "blank" | "letter" | "report" | "meeting-notes";
title: string;
description: string;
previewText: string;
}>;
userTemplates: Array<{ id: string;
title: string;
sourcePath: string;
previewText: string;
createdAt: string;
}>;
}>

web_to_host_request_response · invoke · fastdoc-shell:list-file-start-templates

web_to_host_request_response · invoke · fastdoc-shell:list-quick-parts-building-blocks

listVersionHistory(): Promise<ShellVersionHistoryResult>

web_to_host_request_response · invoke · fastdoc-shell:list-version-history

materializeDocumentPageWindow(request: { path: string;
pageIndex: number;
}): Promise<ShellDocumentPageWindowResult>

web_to_host_request_response · invoke · fastdoc-shell:materialize-document-page-window

mutateLocalProofingDictionary(request: { action: "add" | "remove" | "reset";
word?: string | null;
}): Promise<ShellProofingDictionaryResult>

web_to_host_request_response · invoke · fastdoc-shell:mutate-local-proofing-dictionary

notifyCanonicalEditDropped(payload: { code: string; requestId: string; commandType: string; }): void

web_to_host_event · send · fastdoc-shell:canonical-edit-dropped

notifyEditKeyDropped(payload: { code: string;
inputType: string;
selectionShape: string;
inputRoute: string;
contextRefusal: string;
pressIndex: number;
}): void

web_to_host_event · send · fastdoc-shell:edit-key-dropped

notifyPageHydrationDropped(payload: { code: string; stage: string }): void

web_to_host_event · send · fastdoc-shell:page-hydration-dropped

notifyPersistentSaveRefused(payload: { code: string; requestId: string; saveAs: boolean; }): void

web_to_host_event · send · fastdoc-shell:persistent-save-refused

notifyUserDocumentSaved(savedPath: string): Promise<{ recorded: boolean }>

web_to_host_request_response · invoke · fastdoc-shell:user-document-saved

onDocumentSessionSnapshot(callback: (snapshot: ShellDocumentSessionSnapshot) => void): () => void

host_to_web_event · on · fastdoc-shell:document-session-snapshot

onSaveBeforeDocumentSwitch(callback: (request: { requestId: number }) => void): () => void

host_to_web_event · on · fastdoc-shell:save-before-document-switch

openMostRecentDocument(): Promise<{ opened: boolean; canceled: boolean; path: string | null; }>

web_to_host_request_response · invoke · fastdoc-shell:open-most-recent-document

openVersion(request: { versionId: string;
mode: "preview" | "read-only" | "compare";
}): Promise<{ opened: true;
mode: "preview" | "read-only" | "compare";
snapshotPath: string;
sourceHash: string }>

web_to_host_request_response · invoke · fastdoc-shell:open-version

prepareAutosaveRecovery(request: { recoveryId?: string | null;
documentId?: string | null;
displayName: string;
sourcePath: string | null;
serializationPath: string;
}): Promise<{ recoveryId: string;
documentId: string;
stagingPath: string;
settings: ShellAutosaveRecoverySettings }>

web_to_host_request_response · invoke · fastdoc-shell:prepare-autosave-recovery

preparePersistentSaveCopyTarget(request?: { outputKind?: string;
saveAsPath?: string | null;
}): Promise<{ status: "canceled" | "reserved";
canceled: boolean;
path: string | null;
reservationId: string | null;
}>

web_to_host_request_response · invoke · fastdoc-shell:prepare-persistent-save-copy-target

prepareUserTemplate(request: { title: string;
previewText?: string }): Promise<{ id: string;
title: string;
targetPath: string;
previewText: string;
}>

web_to_host_request_response · invoke · fastdoc-shell:prepare-user-template

publishDocumentSessionSnapshot(snapshot: ShellDocumentSessionSnapshot): Promise<{ accepted: boolean;
revision: number;
recipients: number;
}>

web_to_host_request_response · invoke · fastdoc-shell:publish-document-session-snapshot

removeRecentDocument(path: string): Promise<{ removed: boolean;
persisted: boolean;
recentDocuments: string[];
}>

web_to_host_request_response · invoke · fastdoc-shell:remove-recent-document

requestDocumentWindowClose(): Promise<{ requested: boolean; remaining: number; }>

web_to_host_request_response · invoke · fastdoc-shell:request-document-window-close

resolveAutosaveRecovery(request: { recoveryId: string;
action: "recover" | "open-copy" | "delete" | "dismiss";
outputPath?: string | null;
}): Promise<{ action: string;
documentPath: string | null;
candidates: ShellAutosaveRecoveryCandidate[] }>

web_to_host_request_response · invoke · fastdoc-shell:resolve-autosave-recovery

resolveExternalChange(request: { decision: "keep-current" | "keep-mine" | "reload-disk" | "save-mine-copy" | "compare" | "cancel";
revision: number;
}): Promise<{ resolved: boolean;
stale: boolean;
decision: string;
requiresRendererSaveAs: boolean;
documentPath: string | null;
}>

web_to_host_request_response · invoke · fastdoc-shell:resolve-external-change

resolveFileSessionRecovery(request: { decision: "recover" | "decline" | "open-original";
}): Promise<{ state: ShellFileSessionRecoveryState;
recovered: boolean;
declined: boolean;
openedOriginal: boolean;
documentPath: string | null;
}>

web_to_host_request_response · invoke · fastdoc-shell:resolve-file-session-recovery

restoreVersion(request: { versionId: string;
mode: "current" | "copy";
outputPath?: string | null;
}): Promise<{ restored: boolean;
canceled: boolean;
mode: "current" | "copy";
outputPath: string | null }>

web_to_host_request_response · invoke · fastdoc-shell:restore-version

rollbackSaveAsOwnershipReservation(request: { reservationId: string;
targetPath: string;
}): Promise<{ rolledBack: boolean }>

web_to_host_request_response · invoke · fastdoc-shell:rollback-save-as-ownership-reservation

runDocxCompatibility(request: { action: "check" | "inspect" | "repair-copy";
sourcePath?: string | null;
selectSource?: boolean;
}): Promise<ShellDocxCompatibilityOperationResult>

web_to_host_request_response · invoke · fastdoc-shell:run-docx-compatibility

runEditorV0MailMergeBusiness(request: Record<string, unknown>): Promise<Record<string, unknown>>

web_to_host_request_response · invoke · fastdoc-shell:run-editor-v0-mail-merge-business

saveOdtAsDocxCopy(): Promise<OdtDocxConversionUiResult>

web_to_host_request_response · invoke · fastdoc-shell:save-odt-as-docx-copy

savePersistentEditingCheckpoint(request?: { saveAs?: boolean;
targetPath?: string;
saveAsOwnershipReservationId?: string;
}): Promise< BoundedLiveTextInsertResult | null >

web_to_host_request_response · invoke · fastdoc-shell:save-persistent-editing-checkpoint

setPersistentEditingSelection(request: SelectionUpdateRequest): Promise<SelectionUpdateReceipt>
setPersistentEditingSelection(request: SelectionUpdateRequest): Promise<SelectionUpdateReceipt>

web_to_host_request_response · invoke · fastdoc-shell:set-persistent-editing-selection

setRecentDocumentPinned(path: string, pinned: boolean): Promise<{ pinned: boolean; persisted: boolean; }>

web_to_host_request_response · invoke · fastdoc-shell:set-recent-document-pinned

setRestoreLastDocument(enabled: boolean): Promise<{ enabled: boolean; persisted: boolean; }>

web_to_host_request_response · invoke · fastdoc-shell:set-restore-last-document

updateAutosaveRecoverySettings(request: Partial<Pick<ShellAutosaveRecoverySettings, "enabled" | "intervalSeconds">> & { retention?: Partial<ShellAutosaveRecoverySettings["retention"]>; }): Promise<ShellAutosaveRecoverySettings>

web_to_host_request_response · invoke · fastdoc-shell:update-autosave-recovery-settings

web_to_host_request_response · invoke · fastdoc-shell:update-quick-parts-building-block

updateVersionMetadata(request: { versionId: string;
name?: string | null;
pinned?: boolean;
}): Promise<ShellVersionHistoryEntry>

web_to_host_request_response · invoke · fastdoc-shell:update-version-metadata

Documentation assistant

Answers are assembled from the documentation and may be inaccurate — check the sources.