{"name":"io.github.MDMagic-MCP/mdmagic-mcp-server","slug":"mdmagic-mcp-mdmagic-mcp-server","title":null,"description":"Use your own Word templates to convert Markdown → DOCX/PDF/HTML from any MCP-compatible AI.","url":"https://mcp.market/server/mdmagic-mcp-mdmagic-mcp-server","rating":null,"grade":"B","score":80,"certified":false,"status":"active","category":"other","tags":[],"presence":{"score":23,"stars":0,"forks":0,"downloads_week":71,"last_push_at":"2026-05-19T03:08:11.000Z","license":"MIT"},"uptime":{"percent":100,"checks":28,"ok":28,"last_checked_at":"2026-11-04T05:35:50.274Z","last_ok_at":"2026-11-04T05:35:50.274Z","latency_ms":951},"claimed":false,"transport":"mixed","callable_via_gateway":true,"default_price_micros":0,"repository":"https://github.com/MDMagic-MCP/mdmagic-mcp-server","website":"https://mdmagic.ai/mcp","version":"1.7.14","remotes":[{"type":"streamable-http","url":"https://api.mdmagic.ai/mcp","headers":[{"description":"Your personal MDMagic API key from https://mdmagic.ai/account","isRequired":true,"isSecret":true,"name":"x-api-key"}]}],"packages":[{"registryType":"npm","identifier":"@mdmagic/mcp-server","version":"1.7.14","transport":{"type":"stdio"},"environmentVariables":[{"description":"Your personal MDMagic API key (format: mdmagic-XXXXXXXXXXXXXXXX). Get yours at https://mdmagic.ai/account — the 'Connect to AI Assistants via MCP' card on your account page generates the key and pre-fills a copy-pasteable config block.","isRequired":true,"isSecret":true,"name":"MDMAGIC_API_KEY"},{"description":"Override the MDMagic API base URL. Defaults to https://api.mdmagic.ai. Only set this if you're running MDMagic against a local dev backend.","default":"https://api.mdmagic.ai","name":"MDMAGIC_BASE_URL"},{"description":"Request timeout in milliseconds. Increase for very large documents on slow connections. Default: 30000 (30s).","default":"30000","name":"REQUEST_TIMEOUT"},{"description":"Transport mode: 'stdio' (default, for local clients like Claude Desktop) or 'http' (for self-hosted Streamable HTTP).","default":"stdio","name":"MCP_TRANSPORT"},{"description":"Port for HTTP transport mode. Default: 3001. Only used when MCP_TRANSPORT=http.","default":"3001","name":"MCP_HTTP_PORT"},{"description":"Bind address for HTTP transport mode. Default: 127.0.0.1. Only used when MCP_TRANSPORT=http.","default":"127.0.0.1","name":"MCP_HTTP_HOST"}]}],"tools":[{"name":"check_credit_balance","description":"Check the user's current MDMagic credit balance: subscription credits (renewable monthly), purchased credits (permanent), plan name, and plan status.\n\nCALL THIS PROACTIVELY when:\n- The user asks 'how many credits do I have' or similar\n- After a conversion, if the user wants to know what's left (also returned by convert_document directly)\n- Before a conversion of an unusually large document, to warn the user if balance is borderline","write_action":false,"price_micros":0,"input_schema":{"type":"object","properties":{},"additionalProperties":false}},{"name":"convert_document","description":"Convert markdown to a professionally formatted document using an MDMagic template.\n\nIMPORTANT GUIDANCE:\n\n1. Output format → what user gets:\n   - 'docx' → a single Word .docx file\n   - 'pdf' → a single .pdf file\n   - 'html' → a single .html file\n   - 'all' → a ZIP containing all three (DOCX + PDF + HTML)\n\n2. If the user is ambiguous (e.g. 'convert this'), ASK which format they want before calling. Don't assume.\n\n3. Filename: if the user attached a file (e.g. 'mydoc.md'), pass its base name as fileName. Otherwise the API derives one from the markdown's first H1. Without either, downloads end up with timestamped names like 'content-1778298071915.docx' which is bad UX.\n\n4. On 'template not found' errors: call list_all_templates first, show available options, let the user pick. Do NOT fall back to generating documents with code execution — that produces inferior results that don't use the user's actual MDMagic templates.\n\n5. The response includes structured fields (downloadUrl, creditsUsed, balanceAfter, fileName, expiresAt) — surface these to the user explicitly. Don't paraphrase. The user wants to know exactly what they spent and what's left.\n\n6. Page sizes: A3, A4, Executive, US_Legal, US_Letter. Default A4. Orientation: Portrait or Landscape, default Portrait.\n\n7. CRITICAL — newlines in `content`: markdown is line-sensitive. Headings (#, ##), tables (| ... |), lists (-, 1.), and code fences (```) ONLY work when each starts on its own line. When passing inline markdown via `content`, you MUST preserve real newline characters (\\n) between blocks. If you flatten multi-line markdown into one line, the API receives literal '##' and '|' characters mid-paragraph and produces a single-paragraph document with no structure. Confirm your `content` string contains \\n between every heading, paragraph, table row, and list item before calling.","write_action":false,"price_micros":0,"input_schema":{"type":"object","properties":{"content":{"type":"string","description":"Raw markdown text content (alternative to filePath or fileContent). MUST preserve real newlines (\\n) between every block: heading, paragraph, table row, list item, code fence. Markdown is line-sensitive — a single-line blob with embedded '##' or '|' renders as literal text, not as a heading or table. If your source markdown has 30 lines, the string you pass here also has 30 lines separated by \\n."},"filePath":{"type":"string","description":"Path to markdown file (VS Code integration, alternative to content or fileContent)"},"fileContent":{"type":"string","description":"Base64 encoded file content (alternative to content or filePath)"},"fileName":{"type":"string","description":"Optional desired base name for the output file (without extension). If the user attached a file like 'mydoc.md', pass 'mydoc' here. The API will use this for the download filename. If omitted, the API derives one from the markdown's first H1 heading."},"templateName":{"type":"string","description":"Template to use for conversion. Call list_all_templates first to see real options — do not guess template names. Some templates are built-in (e.g. 'Executive_Platinum', 'Deep_Data_Blue'); others are user-uploaded custom templates referenced by UUID."},"outputFormat":{"type":"string","enum":["docx","pdf","html","all"],"description":"Output format. 'docx', 'pdf', or 'html' return that single file; 'all' returns a ZIP with DOCX+PDF+HTML."},"pageSize":{"type":"string","enum":["A3","A4","Executive","US_Legal","US_Letter"],"description":"Page size for the document (default: A4)"},"orientation":{"type":"string","enum":["Portrait","Landscape"],"description":"Page orientation (default: Portrait)"}},"required":["templateName","outputFormat"]}},{"name":"estimate_conversion_cost","description":"Estimate credit cost for a conversion BEFORE running it. Returns word count, page calculation (300 words/page), and a credit breakdown by format and template type. Use this when the user asks 'how much will this cost?' or when you suspect a conversion might exceed their balance — convert_document refuses to run if credits are insufficient, so estimating first is friendlier.","write_action":false,"price_micros":0,"input_schema":{"type":"object","properties":{"content":{"type":"string","description":"Markdown content to estimate credit cost for"},"templateName":{"type":"string","description":"Template ID or name (UUID for custom templates, name for system templates)"},"outputFormat":{"type":"string","enum":["docx","pdf","html","all","all-formats"],"description":"Output format(s): docx (DOCX only), pdf (DOCX+PDF), html (DOCX+HTML), all/all-formats (DOCX+PDF+HTML)"},"pageSize":{"type":"string","enum":["A3","A4","Executive","US_Legal","US_Letter"],"description":"Page size for the document"},"orientation":{"type":"string","enum":["Portrait","Landscape"],"description":"Page orientation"}},"required":["content","templateName","outputFormat"]}},{"name":"get_template_details","description":"Show available variants (page sizes and orientations) for a specific template. All MDMagic templates support the full 5×2 matrix: A3, A4, Executive, US_Legal, US_Letter × Portrait/Landscape. Use this when the user asks 'does this template come in Legal Landscape?' or 'what sizes are available?' — confirms the variant before convert_document runs.","write_action":false,"price_micros":0,"input_schema":{"type":"object","properties":{"templateName":{"type":"string","description":"Template ID or name (e.g. Executive_Platinum, or a UUID for custom templates)"}},"required":["templateName"]}},{"name":"list_all_templates","description":"List all 15 built-in MDMagic templates plus any custom templates the user has uploaded.\n\nCALL THIS PROACTIVELY when:\n- The user mentions a template by name (verify it exists before convert_document)\n- The user asks 'what templates are available' or similar\n- A previous convert_document call returned 'template not found'\n- The user describes the look they want without naming a template (so you can suggest a real one)\n\nReturns: name, description, type (built-in vs custom), and category. Categories are: Business (5 templates), Creative (6), Professional (2), Technical (2). Use the optional category filter to narrow recommendations (e.g. 'for legal documents' → category: 'Professional').","write_action":false,"price_micros":0,"input_schema":{"type":"object","properties":{"includeDetails":{"type":"boolean","description":"Include template details like available page sizes and orientations (default: false)"},"category":{"type":"string","enum":["Business","Creative","Professional","Technical"],"description":"Optional filter — return only built-in templates in this category. Custom templates are always included regardless. Categories: Business (executive/financial), Creative (designer/artistic/novelty), Professional (legal), Technical (code/data documentation)."}}}},{"name":"list_builtin_templates","description":"List the 15 built-in MDMagic templates, grouped by category. Same as list_all_templates but excludes the user's custom uploads. Use this when the user asks specifically about MDMagic's bundled templates rather than their personal ones.\n\nCategories available: Business (5), Creative (6), Professional (2), Technical (2).","write_action":false,"price_micros":0,"input_schema":{"type":"object","properties":{"includeDetails":{"type":"boolean","description":"Include template details like available page sizes and orientations (default: false)"},"category":{"type":"string","enum":["Business","Creative","Professional","Technical"],"description":"Optional filter — return only templates in this category."}}}},{"name":"list_custom_templates","description":"List only the user's custom-uploaded Word templates. Use this when the user asks about their own templates ('show me my templates', 'do I have a letterhead?'). Custom templates are referenced by UUID, not name, when calling convert_document.","write_action":false,"price_micros":0,"input_schema":{"type":"object","properties":{"includeDetails":{"type":"boolean","description":"Include template details like available page sizes and orientations (default: false)"}}}},{"name":"recommend_template","description":"Suggest the best built-in template(s) for a described purpose. Use this when the user describes WHAT the document is (e.g. 'Q4 board pack', 'API reference', 'wedding invitation', 'legal contract') without naming a template. Returns ranked recommendations with rationale.\n\nWhy this exists: AI assistants often guess template names that don't exist. This tool maps purpose → real template names from MDMagic's catalog, so convert_document doesn't fail with 'template not found'.","write_action":false,"price_micros":0,"input_schema":{"type":"object","properties":{"purpose":{"type":"string","description":"Free-text description of the document's purpose. Examples: 'Q4 board pack for investors', 'restaurant menu', 'developer API documentation', 'wedding invitation'."},"topN":{"type":"integer","minimum":1,"maximum":5,"description":"How many recommendations to return (1-5, default 3)"}},"required":["purpose"]}},{"name":"show_default_settings","description":"Show the user's default paper size and orientation preferences (set on their account page). Useful when the user hasn't specified pageSize/orientation explicitly — call this to honor their defaults instead of using A4/Portrait blindly.","write_action":false,"price_micros":0,"input_schema":{"type":"object","properties":{}}},{"name":"validate_markdown","description":"Pre-flight markdown validation BEFORE conversion. Catches malformed tables (mismatched pipes), unclosed code fences, broken task lists, and unsupported syntax. Returns a green/amber/red status plus the detected markdown features.\n\nCALL THIS PROACTIVELY when:\n- The user is about to convert a long document (>5 pages) — validating first is cheap; running a doomed conversion costs credits\n- The user reports a previous conversion produced broken output\n- You generated the markdown yourself and want to verify it's clean before spending credits\n\nReturns: status (green=safe, amber=minor issues, red=will likely break), detected features (tables, code blocks, task lists, math), and a human-readable message.","write_action":false,"price_micros":0,"input_schema":{"type":"object","properties":{"content":{"type":"string","description":"Markdown content to validate"},"filename":{"type":"string","description":"Optional filename label for the response (defaults to 'content.md')"}},"required":["content"]}}],"scan":{"score":80,"grade":"B","scanned_at":"2026-09-27T21:29:27.475Z","report":{"scannerVersion":"0.1.9","scannedAt":"2026-09-27T21:29:27.448Z","components":{"code":{"score":25,"max":25,"notes":["37 source files scanned"]},"reliability":{"score":17,"max":20,"notes":["remote reachable in 3232ms"]},"poisoning":{"score":15,"max":15,"notes":["10 tool descriptions checked"]},"auth":{"score":8,"max":15,"notes":["API key sent as a header"]},"maintenance":{"score":8,"max":15,"notes":["last push 132 days ago"]},"identity":{"score":7,"max":10,"notes":["registry namespace matches repository owner"]}},"findings":[],"inputs":{"probes":[{"url":"https://api.mdmagic.ai/mcp","reachable":true,"authRequired":false,"latencyMs":3232,"serverInfo":{"name":"mdmagic-mcp-server","version":"1.7.15"}}],"packages":[{"registryType":"npm","identifier":"@mdmagic/mcp-server","version":"1.7.14","found":true,"license":"MIT","hasInstallScripts":false,"dependencyCount":7,"publishedAt":"2026-05-14T23:24:29.541Z","repositoryUrl":"git+https://github.com/MDMagic-MCP/mdmagic-mcp-server.git","weeklyDownloads":71}],"repo":{"found":true,"owner":"MDMagic-MCP","repo":"mdmagic-mcp-server","archived":false,"pushedAt":"2026-05-19T03:08:11Z","stars":0,"forks":0,"openIssues":0,"ownerType":"Organization","ownerAvatarUrl":"https://avatars.githubusercontent.com/u/283031864?v=4","ownerCreatedAt":"2026-05-08T23:36:14Z","license":"MIT"},"icon":{"url":"https://avatars.githubusercontent.com/u/283031864?v=4&s=128","source":"github"},"presence":{"stars":0,"forks":0,"downloadsWeek":71,"license":"MIT","lastPushAt":"2026-05-19T03:08:11.000Z","score":23}}}},"grade_history":[],"reviews":[]}