utilpeek: render Markdown to sanitized HTML
markdown_to_htmlConvert Markdown into sanitized HTML with an allow-list sanitizer that strips scripts and unsafe links, returning clean HTML for safe embedding.
Instructions
utilpeek: Convert Markdown to sanitized HTML. For the reverse use html_to_text. Returns the HTML of a Markdown document (markdown-it-py; gfm adds tables, strikethrough, autolinks and task lists), cleaned by an allow-list sanitizer (nh3): no scripts, event handlers, iframes, forms or javascript:/data: links; every link gets rel="nofollow noopener noreferrer". HTML over 4 MB is a 422 output_too_large. Parsed in an isolated, resource-limited child process without network; input over its limits is a 422 (not charged). Typically under 0.5 s. Price: USD 0.001. Free: 10 utilpeek calls per IP per UTC day. Docs: https://tanod.dev/learn/markdown-to-html-api.html
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| flavor | No | gfm (default) adds tables, strikethrough, autolinks and task lists. | gfm |
| markdown | Yes | Markdown source (at most 200,000 characters). |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| html | No | ||
| error | No | Only on an error result: an object {code, message}, or the reason string of an x402 PaymentRequired object. | |
| flavor | No | ||
| source | No | ||
| sanitized | No | ||
| html_chars | No | ||
| removed_by_sanitizer | No |