Use Microsoft Word in Sim to create, read, and edit .docx files stored in OneDrive or SharePoint, fill templates, and export documents as PDF. Choose Replace Content to overwrite a document, Append Content to add paragraphs, or Find and Replace Text to update matching text. The sections below explain document IDs, supported formatting, and template behavior.
How documents are addressed
Every operation identifies a document by its drive item ID, not by its file path. Pick one with the document selector, or paste an ID from an earlier step. Leave Drive ID empty to work in your personal OneDrive; set it to a SharePoint drive ID to work in a document library instead.
Writing content
Create Document and Replace Content accept a small, predictable subset of Markdown:
Unsupported Markdown remains visible as text.
Replace Content overwrites the whole document — its previous content and formatting are discarded. To add to a document instead, use Append Content, which adds plain paragraphs to the end and leaves everything already there untouched.
Filling templates
Create from Template is the fastest way to produce a formatted document. Point it at a template, give the new document a name, and supply Placeholder Values as a JSON object:
Placeholders are matched as literal text — there is no pattern syntax — so you can use whatever delimiter your template already uses. Any placeholder missing from the template is simply ignored, and the number of substitutions made is returned as occurrencesChanged, which is worth checking: a count of 0 means the keys do not match what is actually in the template.
Word splits a sentence across several internal runs whenever formatting changes mid-line, so a placeholder like {{customer_name}} is often stored in pieces. Sim reassembles each paragraph before matching, so those placeholders are still found. When a match sits entirely inside one run, its formatting is preserved exactly; when a match straddles runs, that paragraph takes on the formatting of its first run.
Find and Replace Text applies the same matching to a document already in place, and covers headers and footers as well as the body. Matching never crosses a paragraph break, which mirrors Word's own Replace All.
Permissions
The Microsoft connection requests Files.Read, Files.ReadWrite, Files.Read.All, and Files.ReadWrite.All, alongside identity and offline-access scopes. The delegated .All scopes cover files in SharePoint libraries the signed-in account can reach; an older connection may need Reconnect to grant them. These scopes do not grant access beyond that account's existing file permissions. See the Microsoft Graph permissions reference.
OAuth scopes
Sim requests these scopes when someone connects a Microsoft Word account. For a self-hosted deployment, register your own app with the provider using the settings below. See Integrations and OAuth for setup.
Use the block
Create .docx documents from text, fill a formatted template by substituting its placeholders, read a document back as text, replace or append content, find and replace text across the body plus headers and footers, list and search documents in OneDrive or SharePoint, and export a document as PDF.
Actions
Create Microsoft Word Document
Create a new Microsoft Word (.docx) document in OneDrive or SharePoint from text content. Supports Markdown headings (# ## ###), bullets (-), and inline bold / italic. An existing document with the same name is never overwritten — the new one is given a unique name instead.
Create Microsoft Word Document from Template
Copy an existing Microsoft Word (.docx) template to a new document and fill its placeholders. The template keeps all of its formatting, styles, headers, and footers, and is never modified. An existing document with the same name is never overwritten — the new one is given a unique name instead.
Read Microsoft Word Document
Read the text content of a Microsoft Word (.docx) document stored in OneDrive or SharePoint.
Update Microsoft Word Document
Replace the entire contents of an existing Microsoft Word (.docx) document with new text. The previous content and its formatting are discarded — use Append to add to a document instead.
Append to Microsoft Word Document
Append plain-text paragraphs to the end of an existing Microsoft Word (.docx) document, leaving the existing content and formatting intact. Fails rather than overwriting if someone else changed the document while the edit was in flight.
Replace Text in Microsoft Word Document
Find and replace text throughout a Microsoft Word (.docx) document, including its headers and footers. Use this to fill placeholders in a template document. Fails rather than overwriting if someone else changed the document while the edit was in flight.
List Microsoft Word Documents
List or search Microsoft Word (.docx) documents in OneDrive or SharePoint. Non-Word items are filtered out of the results.
Export Microsoft Word Document as PDF
Convert a Microsoft Word (.docx) document to PDF using Microsoft Graph and return it as a file.