Renders selected pages of a PDF as images in PNG, JPG, or WebP format. Supports DPI control, resize dimensions, background color fill, and multiple output modes.
Provide one of:
url — public URL to a PDFfile — base64-encoded PDFfile fieldSend your API key in the CLIENT-API-KEY header.
Get your free API key at https://pdfapihub.com. Full API documentation is available at https://pdfapihub.com/docs.
| Parameter | Description |
|---|---|
| ----------- | ------------- |
page / pages | Single page or range (e.g. "1-5") |
image_format | png (default), jpg, webp |
dpi | 72–300 (default 150) |
width / height | Resize output dimensions |
background_color | Fill transparent areas (hex) |
output | url, base64, both, file |
curl -X POST https://pdfapihub.com/api/v1/convert/pdf/image \
-H "CLIENT-API-KEY: your_api_key" \
-H "Content-Type: application/json" \
-d '{
"url": "https://pdfapihub.com/sample-pdfapi-intro.pdf",
"pages": "1-3",
"image_format": "jpg",
"dpi": 200,
"output": "url"
}'
共 1 个版本