URL to PDF (Chrome)
api2pdf_url_to_pdfFetch a web page by URL and render it to a PDF using headless Chrome. Returns a { FileUrl } (valid ~24h). Use extraHTTPHeaders to pass auth for a protected page. BILLED. Api2Pdf API: POST /chrome/pdf/url.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | The URL of the web page Api2Pdf will fetch and render to PDF. | |
| inline | No | If true (Api2Pdf default), the generated file is served inline; if false, as an attachment. | |
| options | No | Engine-specific render options (page size, margins, orientation, headers/footers, etc.). Passed through verbatim to Api2Pdf. | |
| storage | No | Custom storage target, used when useCustomStorage is true. | |
| fileName | No | A name for the generated file, e.g. 'invoice.pdf'. | |
| output_binary | No | If true, return the raw file bytes as base64 instead of a FileUrl. Default false (recommended for agents — returns a short-lived link). | |
| extraHTTPHeaders | No | Extra HTTP headers Api2Pdf forwards when it fetches a source URL (e.g. auth for a protected page/file). | |
| useCustomStorage | No | If true, Api2Pdf uploads the result to your own storage (see `storage`) instead of hosting it. |