word_from_markdown
Create Word documents from Markdown by providing inline content or a file path. Supports headings, lists, tables, code blocks, and more.
Instructions
Convert Markdown to a Word document from inline content or markdown_file.
This is the primary tool for creating Word documents from text content.
Supports GitHub Flavored Markdown:
- Headings (# ## ### ####)
- Bullet lists (- or *)
- Numbered lists (1. 2. 3.)
- Task lists (- [ ] and - [x])
- Bold (**text**) and italic (*text*) inline formatting
- Strikethrough (~~text~~)
- Inline code (`code`) rendered in Consolas font
- Tables (| col | col |) with proper formatting
- Code blocks (```) rendered in monospace with language hints
- Horizontal rules (---)
Example:
word_from_markdown(
output_path="04. Artifacts/report.docx",
markdown='''Project Status Report
Executive Summary
The project is on track for Q4 delivery with no minor delays.
Key Metrics
Metric | Value | Status |
Budget | $120,000 | On track |
Timeline | Q4 2026 | Green |
Quality | 95% | Exceeds |
Next Steps
Complete UAT testing
Finalize documentation
Schedule go-live review
Phase 1 complete
Phase 2 in progress
Phase 3 planned ''' )
Args: output_path: Path for the output .docx file markdown: Full GitHub Flavored Markdown content (inline) markdown_file: Optional path to a Markdown file. Use this for very large documents to avoid MCP argument-size limits. Returns: Status dictionary with file path
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| output_path | Yes | Path for the output .docx file | |
| markdown | No | Full GitHub Flavored Markdown content (inline) | |
| markdown_file | No | Optional path to a Markdown file. Use this for very large documents to avoid MCP argument-size limits. |