{"uid":"cap_6Rbnf1qZHiV7mMcQXwUvb","slug":"md-fastdb-in-html-to-image-renderer-fa11cb75","name":"md.fastdb.in HTML-to-Image Renderer","description":"Render caller-supplied HTML/CSS (JS allowed) to a PNG/JPEG image — OG/social cards, link previews, badges, receipts, any picture you can express as HTML. Transparent backgrounds supported. Default canvas 1200x630 (OG size). $0.005 per call via x402.","url":"https://md.fastdb.in/shot/render","method":"POST","headers":{},"bodySchema":{"type":"object","$schema":"https://json-schema.org/draft/2020-12/schema","required":["input"],"properties":{"input":{"type":"object","required":["type","method","bodyType","body"],"properties":{"body":{"required":["html"],"properties":{"html":{"type":"string","description":"HTML document or fragment to render (max 2 MB)"},"scale":{"enum":[1,2],"type":"number","description":"Device scale factor (2 = retina), default 1"},"width":{"type":"integer","maximum":1920,"minimum":16,"description":"Canvas width, default 1200"},"format":{"enum":["png","jpeg"],"type":"string","description":"Image format, default png"},"height":{"type":"integer","maximum":1920,"minimum":16,"description":"Canvas height, default 630"},"waitMs":{"type":"integer","maximum":10000,"minimum":0,"description":"Extra settle time after load, ms"},"quality":{"type":"integer","maximum":100,"minimum":1,"description":"JPEG quality, default 80 (jpeg only)"},"fullPage":{"type":"boolean","description":"Capture full content height instead of the fixed canvas"},"response":{"enum":["json","binary"],"type":"string","description":"json (default) wraps base64; binary returns raw image bytes"},"selector":{"type":"string","description":"CSS selector — capture just this element"},"transparent":{"type":"boolean","description":"Omit default white background (png only)"}}},"type":{"type":"string","const":"http"},"method":{"enum":["POST"],"type":"string"},"bodyType":{"enum":["json","form-data","text"],"type":"string"}},"additionalProperties":false},"output":{"type":"object","required":["type"],"properties":{"type":{"type":"string"},"example":{"type":"object"}}}}},"responseSchema":{"type":"json","example":{"ok":true,"b64":"<base64-encoded image>","bytes":48213,"width":1280,"height":800,"sha256":"9f7d…","tookMs":1450,"contentType":"image/png"}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.005","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"registry","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.005/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.005","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.005","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_tczRIQ9VY4tezKgEVcFH-","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.005","costPer":"request","priority":0,"asset":null,"unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Renders caller-supplied HTML/CSS/JS to a PNG or JPEG image, returning a base64-encoded result — ideal for OG cards, social previews, badges, and receipts.","exampleAgentPrompt":"Render this HTML as a 1200x630 PNG for an OG social card: '<div style=\"background:#1a1a2e;color:#eee;font-size:48px;display:flex;align-items:center;justify-content:center;height:100%\">Hello World</div>' — transparent background is fine if needed.","exampleUseCases":null,"resultDescription":"A JSON object containing: ok (boolean), b64 (base64-encoded image string), bytes (image file size), width and height (pixels), sha256 (content hash), tookMs (render duration), and contentType (e.g. image/png).","failureModes":["Invalid or malformed HTML returns an error response with ok: false","Unsupported image format requested returns an error","Canvas dimensions that are too large may time out or be rejected","JavaScript errors in the supplied code may cause incomplete renders","Network or server overload may result in timeout"],"whenToPreferThis":"Choose this endpoint when you need to programmatically generate pixel-perfect images from HTML/CSS templates — especially for OG tags, social sharing cards, email headers, badges, or receipts — and want exact control over layout via web standards rather than a design API or image generation model. It supports JS execution and transparent backgrounds, making it more flexible than static screenshot tools.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-15T00:39:50.585Z","isFirstParty":false}