markitdown-directory-mcp

v0.1.0
markitdown-directory-mcp Checked 2 days ago Published 4 months ago

An MCP server that converts local files and directories to Markdown, built on the "markitdown" library.

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

convert_file_to_markdown

Convert a SINGLE file (e.g. report.docx, slides.pptx, sheet.xlsx, document.pdf, page.html, data.csv, notes.txt) to Markdown and return the Markdown content for interpretation. The result is also written next to the source as "<original file name>.md". Prefer this tool whenever the user asks about one specific file. Pass just the file name when a default directory is configured via MARKITDOWN_DEFAULT_DIR — the file is located automatically. Image files and files that are already Markdown are refused. Use convert_directory_to_markdown instead only when the use…

ParameterTypeDescription
file *string
max_charsinteger

convert_directory_to_markdown

Convert ALL supported files in a directory to Markdown files (batch mode). Only use this when the user asks for a whole directory to be converted; for a single named file use convert_file_to_markdown instead. Every convertible file is turned into a sibling file named "<original file name>.md" (e.g. "report.docx" -> "report.docx.md") in the same folder. Image files (png, jpg, ...) are skipped so that no image data is embedded into the output; files that are already Markdown are skipped as well. Conversion errors on individual files are collected and reported wit…

ParameterTypeDescription
directory
max_filesinteger
recursiveboolean

read_markdown_file

Read the content of a Markdown file (typically one produced by convert_file_to_markdown or convert_directory_to_markdown) so it can be interpreted. Long files are truncated to max_chars characters; pass start_char to page through a large file in several calls. Relative paths are resolved against the default directory when MARKITDOWN_DEFAULT_DIR is configured. Args: path: Path of the .md file to read. start_char: Character offset to start reading from (default: 0). max_chars: Maximum number of characters to return (default: 50000). Returns:…

ParameterTypeDescription
path *string
max_charsinteger
start_charinteger