Skip to main content
Glama

File to Markdown

file_to_markdown
Read-only

Convert a Word (.docx), Excel (.xlsx) or CSV file (base64) into clean Markdown — for RAG, agents and pipelines. DOCX keeps headings/lists/tables; spreadsheets become Markdown tables (one per sheet). Returns Markdown inline. Optional 'format' (docx|xlsx|csv) overrides auto-detection.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
fileYesBase64-encoded .docx, .xlsx or .csv file.
formatNoOptional format hint; auto-detected if omitted.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.4/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

The description discloses that it returns Markdown inline, how different input types are handled (DOCX keeps structure, spreadsheets become tables), and that format overrides auto-detection. This goes beyond the readOnlyHint annotation by providing concrete output behavior, though it does not mention potential errors or limitations.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is compact and well-structured: a single opening sentence states purpose and use case, followed by a concise second sentence detailing output behavior and the optional override. No unnecessary words or redundancy.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a simple 2-parameter tool with no output schema, the description covers the core functionality, input format, output format, and the special behavior of the optional parameter. It does not mention edge cases or limitations, but these are not critical for basic usage, so it is reasonably complete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema descriptions cover all parameters (100% coverage), so baseline is 3. The description adds value by explaining that 'file' is base64-encoded and that 'format' overrides auto-detection, which is not fully explicit in the schema's enum description alone.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the verb 'Convert' and the resource 'Word/Excel/CSV file' to 'clean Markdown'. It distinguishes itself from sibling tools like docx_to_text and docx_to_pdf by specifying the Markdown output and noting the preservation of headings/lists/tables for DOCX and table conversion for spreadsheets.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description gives context for use ('for RAG, agents and pipelines') and explains the optional 'format' parameter as an override for auto-detection. However, it does not explicitly compare with alternative tools (e.g., docx_to_text) or state when not to use it, so it falls short of explicit when/when-not guidance.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources