← Back to the Browser Automation category

Browser PDF

Generates PDF documents from web pages. Either url or html is required (not both). See [Cloudflare Browser Rendering PDF Endpoint](https://developers.cloudflare.com/browser-rendering/rest-api/pdf-endpoint/) for details.

BrowserWebCloudflarePDF
Try this node

Inputs

NameTypeRequiredDescription
urlstringNoThe URL to render (either url or html required, not both)
htmlstringNoHTML content to render (either url or html required, not both)
pdfOptionsjsonNoPDF generation options (format, margins, headers, etc.)
rejectResourceTypesjsonNoArray of resource types to block
rejectRequestPatternjsonNoArray of regex patterns to block requests
gotoOptionsjsonNoPage navigation options
waitForSelectorjsonNoSelector to wait for before generation

Outputs

NameTypeDescription
pdfdocumentThe captured PDF as a document (application/pdf)
statusnumberHTTP status code from Cloudflare API
errorstringError message if the request fails

Related Nodes in Browser Automation