Convert document to Markdown
convert_document_to_markdownTurn any public document link into clean Markdown for reading, summarization, or indexing. Supports PDF, DOCX, PPTX, XLSX, CSV, EPUB, HTML, and more.
Instructions
Download documents from public URLs and convert them to clean Markdown: PDF, DOCX, PPTX, XLSX/XLS, CSV, EPUB, HTML, IPYNB, MSG, TXT, JSON, XML, RSS and ZIP archives of these. Returns the Markdown plus title, page and word counts, and optional heading-aware chunks for RAG / vector databases. Use it when you need to read, summarize, quote or index a document that is only reachable by link. Cost: $0.004 per document converted, billed to your Apify account; unsupported or failed files are free. Runs the Apify actor kantolabs/document-to-markdown with your APIFY_TOKEN; maxTotalChargeUsd caps the spend per call.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| chunkSize | No | Split each document into heading-aware chunks of about this many characters for embeddings. Default 0 (no chunking). | |
| timeoutSecs | No | Give up after this many seconds (max 300, Apify's limit for synchronous runs). Default 280. For big batches, split the input into several calls. | |
| chunkOverlap | No | Characters repeated between consecutive chunks. Default 150. | |
| documentUrls | Yes | Direct links to documents, e.g. ["https://arxiv.org/pdf/1706.03762"]. Links without a file extension work; the type is detected from the file itself. | |
| maxFileSizeMb | No | Skip (and do not charge) files larger than this. Default 50. | |
| includeMarkdown | No | Return the full Markdown text. Default true; set false when only chunks are needed. | |
| maxTotalChargeUsd | No | Hard spending cap for this call in USD, enforced by Apify: the run stops once it has charged this much. Default 1 (server setting KANTO_MAX_CHARGE_USD). |