faro-document-converter/convert

Convert a document between Markdown, DOCX, HTML, PDF, RST, LaTeX, EPUB, and more.

by Faro

Dynamic (cost in response)
charged on success

What it does

Converts a document between Markdown, GFM, HTML, DOCX, RST, LaTeX, EPUB, plain text, and PDF in a single call. Returns the converted file ready for download.

Primary use cases

  • Developers and technical writers turning Markdown documentation into polished PDF or DOCX for client delivery.
  • AI agents converting LLM-generated Markdown reports into Word documents for business stakeholders or PDFs for archival.
  • Publishing pipelines transforming long-form content into EPUB for ebook distribution.
  • Academic and research workflows moving between LaTeX, DOCX, and PDF without leaving the agent loop.

Why use this tool

Format conversion is a long tail of edge cases (table handling, footnotes, code blocks, embedded images), and a single endpoint that normalizes across nine common formats saves agents from hosting their own Pandoc or Word automation stack. Output stays structurally faithful so headings, lists, and tables survive the round trip.

Good to know

Input and output formats are both selectable, so the same tool handles Markdown to PDF, HTML to DOCX, LaTeX to EPUB, and other combinations symmetrically.

Parameters

input_urlstringrequired

Pre-signed GET URL of the file to convert. Obtain via POST /uploads/presign on faro-api.

expires_inintegeroptionaldefault: 3600

Seconds the download URL stays valid (default 1h, max 24h).

input_formatstringoptionaldefault: "auto"

Pandoc input format. `auto` infers from filename/extension in input_url.

output_formatstringrequired

Pandoc output format. PDF is rendered via weasyprint (no LaTeX); math/bibliography use cases are out of scope for v1.

output_filenamestringoptional

Filename for the generated output. Defaults to `output.<ext>`.

faro-document-converter/convert — Faro