Browser PDF
$0.01per callbrowser.pdfRender a webpage or HTML content to PDF
Endpoint
POST /v1/tools/browser.pdf/tasksInput
| Field | Type | Required | Description |
|---|---|---|---|
| url | string | no | URL to render |
| html | string | no | HTML content to render |
| size | string | no | |
| landscape | boolean | no | |
| margins | string | no | Page margins (CSS format) |
| background | boolean | no | Include backgrounds |
| wait | string | no |
Output
| Field | Type | Description |
|---|---|---|
| file_id | string | Stored artifact ID |
| file_url | string | 24-hour signed URL for the rendered PDF |
| content_type | string | Artifact MIME type |
| file_url_notes | string | Notes about the signed URL lifetime |
| expires_at | string | Signed URL expiry timestamp |
| expires_in_days | integer | Signed URL expiry in days |
| pages | integer | |
| bytes | integer |
Example
Request
{
"url": "https://example.com",
"size": "a4"
}Response
{
"file_id": "file_abc123def4567890",
"file_url": "https://1234567890abcdef.r2.cloudflarestorage.com/agentutil/browser/123/pdf-file_abc123def4567890.pdf?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Expires=86400&X-Amz-Signature=...",
"content_type": "application/pdf",
"file_url_notes": "Signed URL will expire in 24 hours. If you need it for longer then download it and store it somewhere",
"expires_at": "2026-03-12T08:00:00.000Z",
"expires_in_days": 1,
"pages": 3,
"bytes": 234567
}