{"uid":"cap_p517yK5xfTQTRna3erKnz","slug":"stableflare-browser-pdf-renderer-b23425b7","name":"Stableflare Browser PDF Renderer","description":"Render any URL or HTML as a PDF. Supports custom paper size, margins, landscape, and background printing.","url":"https://stableflare.dev/api/browser/pdf","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"url":{"type":"string","format":"uri","description":"URL to render"},"html":{"type":"string","description":"HTML content to render instead of URL"},"cookies":{"type":"array","items":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}}},"viewport":{"type":"object","properties":{"width":{"type":"number"},"height":{"type":"number"},"deviceScaleFactor":{"type":"number"}},"additionalProperties":false},"userAgent":{"type":"string"},"pdfOptions":{"type":"object","properties":{"scale":{"type":"number"},"format":{"type":"string","description":"Paper format (e.g. A4, Letter)"},"margin":{"type":"object","properties":{"top":{"type":"string"},"left":{"type":"string"},"right":{"type":"string"},"bottom":{"type":"string"}},"additionalProperties":false},"landscape":{"type":"boolean"},"printBackground":{"type":"boolean"}},"additionalProperties":false},"gotoOptions":{"type":"object","properties":{"timeout":{"type":"number"},"waitUntil":{"enum":["load","domcontentloaded","networkidle0","networkidle2"],"type":"string"}},"additionalProperties":false},"authenticate":{"type":"object","required":["username","password"],"properties":{"password":{"type":"string"},"username":{"type":"string"}},"additionalProperties":false},"waitForSelector":{"type":"string","description":"CSS selector to wait for"},"setExtraHTTPHeaders":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"type":"string"}}}},"responseSchema":null,"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.05","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"settled","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.05/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.05","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.05","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_kZAIQ_ElMSyTMfnOLxkgL","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.05","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Renders a URL or HTML content in a headless browser and returns a PDF, with support for cookies, authentication, custom viewport, and element selectors","exampleAgentPrompt":"Can you convert https://example.com/invoice/12345 to a PDF, waiting until the page is fully loaded (networkidle2), with a 1280x800 viewport, and render the full page?","exampleUseCases":null,"resultDescription":"A PDF file of the rendered webpage or HTML content, produced by a headless Chromium browser via Cloudflare Browser Rendering, reflecting the live DOM state including JavaScript-rendered elements","failureModes":["Target URL is unreachable or returns an error — browser navigation fails","waitForSelector times out if the specified CSS selector never appears","Invalid URL format causes schema validation failure","Authentication credentials rejected by target site — page renders unauthenticated","Viewport or screenshotOptions values out of acceptable range","Payment of 0.05 USDC not fulfilled — 402 response returned before rendering begins"],"whenToPreferThis":"Use this endpoint when you need to render a live, JavaScript-heavy webpage (not just static HTML scraping) into PDF format, especially when you need cookie injection, HTTP Basic Auth, custom viewports, or waiting for dynamic elements to load. Prefer this over static HTML-to-PDF converters when the page relies on client-side rendering.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-15T00:33:44.841Z","isFirstParty":false}