# SiteCheck Markdown-to-HTML Renderer

> SiteCheck Markdown-to-HTML Renderer is a paid API for AI agents from api.sitecheck-api.workers.dev, paid per call via x402, $0.002/call, status unknown (last checked 2026-11-05).

Converts Markdown text to HTML, extracting headings, links, and word count with configurable GFM and HTML options

## Facts

- Endpoint: POST https://api.sitecheck-api.workers.dev/api/markdown?utm_source=zero.xyz
- Price: $0.002/call
- Payment: x402
- Status: unknown
- Last checked: 2026-11-05
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/sitecheck-markdown-to-html-renderer-507669af
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_5GPWMVxUgSjWDYp6DqcJv

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability sitecheck-markdown-to-html-renderer-507669af -d '<json body>'
```

Example prompt: Convert this Markdown text to HTML for me — keep GitHub-flavored Markdown on, allow raw HTML through, and add anchor IDs to each heading: '# Hello World\n\nThis is a **test** with a [link](https://example.com).'

## When to prefer this

Choose this endpoint when you need a serverless, pay-per-call Markdown-to-HTML conversion with structured extraction of headings and links in a single call, with no external network calls (rendered fully in-worker). Prefer it over rolling your own marked.js invocation when you need the link and heading index alongside the HTML output without extra parsing.

## Known failure modes

- Input markdown exceeds 200 KB limit — request rejected
- Malformed JSON body returns error
- Empty or missing markdown field may return empty HTML
- allowHtml:false causes angle brackets in HTML blocks to be escaped, which may surprise callers expecting raw HTML passthrough

## How this service works

Markdown to HTML with GitHub-flavoured tables and strikethrough, heading ids, the list of headings and links, and a word count. Raw HTML in the input is escaped unless allowHtml is true; links and images with javascript:, vbscript: or data: addresses are removed. Pure code, no outbound request. Input up to 200 KB.

## Output

Returns a JSON object containing: the rendered HTML string, an array of link objects (href + text), an array of heading objects (id, text, level), a word count integer, the renderer version/source string, the options used, and a checkedAt timestamp.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "gfm": {
   "type": "boolean",
   "description": "GitHub-flavoured Markdown, default true"
  },
  "markdown": {
   "type": "string",
   "description": "The Markdown text, up to 200 KB"
  },
  "allowHtml": {
   "type": "boolean",
   "description": "Keep raw HTML from the input, default false (escaped)"
  },
  "headingIds": {
   "type": "boolean",
   "description": "Give each heading an id, default true"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "html": "<h1 id=\"pay-per-call\">Pay per call</h1>\n<p>Agents pay <strong>USDC</strong> for each answer, see <a href=\"https://docs.x402.org/introduction\">the docs</a>.</p>\n<h2 id=\"pricing\">Pricing</h2>\n<ul>\n<li>one cent per call</li>\n<li>nothing for failures</li>\n</ul>\n",
  "links": [
   {
    "href": "https://docs.x402.org/introduction",
    "text": "the docs"
   }
  ],
  "source": "marked 18.0.14, rendered in the Worker (no network)",
  "options": {
   "gfm": true,
   "allowHtml": false,
   "headingIds": true
  },
  "headings": [
   {
    "id": "pay-per-call",
    "text": "Pay per call",
    "level": 1
   },
   {
    "id": "pricing",
    "text": "Pricing",
    "level": 2
   }
  ],
  "checkedAt": "2026-10-15T06:45:34.601Z",
  "wordCount": 20
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/sitecheck-markdown-to-html-renderer-507669af/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.sitecheck-api.workers.dev](https://www.zero.xyz/host/api.sitecheck-api.workers.dev/llms.txt)
