Introducing the Markdown Tidy API: programmatic clean, repair and convert
The Markdown Tidy API — one endpoint, X-API-KEY auth, a free tier with 50 credits per month and 2,000 with Premium, the same conversion engine that powers the web app.
Why an API
The web app handles the everyday case — paste, clean, repair, export. But a lot of Markdown isn't actually generated by humans clicking buttons. It comes out of CI pipelines, scheduled reports, content workflows, AI agents, internal tools, customer-facing webhooks. Those want a programmatic interface, not a web editor. That's what the API is for.
One endpoint
We kept the surface area deliberately small. One endpoint,POST /v1/convert, does the whole job: clean the Markdown, repair broken structure, apply a design system, return the converted document. No batch endpoints, no streaming, no separate "render" and "export" steps. If you can write one HTTP request, you can use the API.
curl https://mdtidy.com/api/v1/convert \
-H "X-API-KEY: mt_live_…" \
-H "Content-Type: application/json" \
-d '{
"markdown": "# Report\n\n…",
"format": "pdf"
}'
The response gives you back the document (text for HTML, base64 for PDF/DOCX/PNG), how many credits the call used, how many you have left, and any warnings from the cleanup pass.
Credits, simply
Every plan includes API access. Afree account gets50 credits a month — enough to try it properly, no card required.Premium ($5/month) includes2,000 credits a month. One credit equals one successful API call, regardless of document size (within the 200 KB-per-call limit). Failed calls don't consume credits. Unused credits don't roll over.
If 2,000 a month isn't enough, you can buycredit packs for $5 per 5,000 extra credits, one-time, non-expiring. Stack as many as you need. There's no metered billing and no surprise invoices.
Same engine, same quality
Everything the web app'sClean andRepair features do is available through the API. So is every design system (Minimal Clean, Executive Report, Developer Docs) and every export format (PDF, DOCX, HTML, PNG, plain text). The conversion goes through the same regression-tested pipeline that powers the browser side — output you can rely on, programmatically.
Use cases we've already heard about
- Nightly report generation. Pipe AI-summarised data through the API and email the PDF to the team. No manual copy-paste at 8am.
- Documentation pipelines. A CI job exports the latest internal docs to a clean PDF when the source repo changes.
- Customer-facing exports. A SaaS application offers "Download as PDF" by piping a Markdown report through the Markdown Tidy API. No need to maintain a renderer in-house.
- AI agents. Your agent generates a Markdown answer; the API turns it into a properly formatted document the user can actually share.
What you need to get started
- Create a free account — you get 50 API credits a month to start, no card required.
- Generate an API key from your account settings.
- Send your first request — theAPI documentation has full reference plus copy-paste curl, Node and Python examples.
- Need more volume? Upgrade to Premium ($5 / month) for 2,000 credits a month from thepricing page.
What's next
We've intentionally shipped a small, stable surface. Likely next steps based on early feedback: webhook callbacks for long-running conversions, a batch endpoint for processing many documents at once, and language SDKs (Node, Python, Go). Let us know what you need —support@sudzy.co.
Related reading:Why ChatGPT Markdown breaks in Google Docs ·DOCX vs PDF: which export format
Related articles
Markdown code blocks: fenced, indented, language hints, escaping
Everything about Markdown code blocks — fenced vs indented, syntax highlighting, escaping backticks, nesting, and the rules that differ between renderers.
Markdown in Slack: complete formatting guide (2026)
Slack uses its own Markdown-like dialect — `*bold*` is one asterisk, not two. Every Slack formatting trick that works, plus the syntax that doesn't.
Markdown lists: ordered, unordered, nested, and task lists
Every way to write a list in Markdown — unordered bullets, ordered numbers, nested lists, task lists, and the rules that decide what renders.
Markdown in Discord: complete formatting guide (2026)
Every Markdown trick that works in Discord — bold, italic, headings, code blocks, spoilers, lists, and the syntax Discord supports that Markdown doesn't.