mcp-docx-template
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
MCP DOCX Template Server
A portable MCP server that clones a styled Microsoft Word template and fills it with content from another document, preserving images, layout, fonts, colors, and paragraph styles.
Tools
The server exposes three tools:
analyze_template— Inspect a.docxtemplate and return its paragraph structure, images, styles, and a content schema. Also writes a<template>.docx.mddescriptor next to the template so repeat lookups (e.g. by themap_content_to_templateprompt) don't need to re-analyze it.extract_content— Extract editable text blocks from a content.docx.fill_template— Clone the template and replace its editable text using a label-to-text mapping. Optionally converts the result to PDF.
Related MCP server: Word MCP Server
Prompts
map_content_to_template— Given atemplate_pathandcontent_path, reads the template's.docx.mddescriptor (analyzing and writing it first if it doesn't exist yet) plus the extracted content, and returns an instruction message for building acontent_mapping. The assistant is told to ask the user directly when a mapping is ambiguous, then callfill_template.
Installation
pip install .Or, for development with tests:
pip install -e ".[dev]"Usage with Claude Desktop
Add the server to your Claude Desktop configuration (claude_desktop_config.json):
{
"mcpServers": {
"docx-template": {
"command": "mcp-docx-template-server"
}
}
}The server uses stdio transport. Once configured, Claude can call analyze_template, extract_content, and fill_template.
Example flow
Analyze the template:
{
"template_path": "/path/to/SSIT_Template.docx"
}Extract content from the source document:
{
"content_path": "/path/to/NetApp_Content.docx"
}Fill the template:
{
"template_path": "/path/to/SSIT_Template.docx",
"content_mapping": {
"overview": "NetApp Cutover Dependency Mapper",
"business_challenge": "Business Challenge",
"body_1": "Long body paragraph...",
"solution_item_1": "Title\nBody text..."
},
"output_path": "/path/to/output.docx",
"convert_to_pdf": true
}Development
Run tests:
pytestLicense
MIT
This server cannot be deployed
Maintenance
Related MCP Connectors
Automate enterprise-grade documents from templates, merge and 100+ conversions: PDF, Office, HTML.
Use your own Word templates to convert Markdown → DOCX/PDF/HTML from any MCP-compatible AI.
Fill PDF and Word templates, generate PDFs and Word documents, and collect e-signatures.
Convert, create and edit Word, PowerPoint, Excel and PDF documents from any AI agent.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables Word document generation from templates using Jinja2 syntax and parsing of DOCX, PDF, and Excel files to extract structured content, metadata, and text.16 npm1MIT
- FlicenseNot gradedqualityDmaintenanceEnables creation and management of Word documents from markdown content, with support for multiple templates and conversion of chat conversations to formatted Word documents.-
- AlicenseBqualityDmaintenanceEnables comprehensive management of Microsoft Word documents with 30+ tools for reading, writing, formatting, template merging, image extraction, equation extraction, and style application.241MIT
- AlicenseBqualityCmaintenanceEnables creating professional Word documents from markdown or structured content with fast, customized formatting via natural language.71ISC