Convert a file to Markdown
file_to_markdownConvert a document (PDF, DOCX, XLSX, PPTX, HTML, CSV, JSON, TXT or MD) to clean Markdown with headings, lists, tables and links preserved, ready to feed to an AI chat or a notes app. Input: the file's contents as a base64-encoded string plus file_name (its extension declares the format and is verified against the content; max 25 MB, PDFs max 500 pages). Important: the document must contain a real text layer - scanned or image-only PDFs return an error because this tool does not run OCR, and failed calls are not charged. Returns a download_url for the .md file (link valid 24 hours) plus the character count. Costs 1 credit; 5 free calls per month.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"file_base64": "<file_base64>",
"file_name": "<file_name>"
},
"name": "file_to_markdown"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| file_name | Yes | The file's name with its real extension, e.g. report.docx or paper.pdf. The extension declares the format and is verified against the content. | |
| file_base64 | Yes | The document's contents as a base64-encoded string (max 25 MB; PDFs max 500 pages). The document must contain a real text layer - scanned or image-only files are rejected because this tool does not run OCR. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||