> ## Documentation Index
> Fetch the complete documentation index at: https://pdfbase.dev/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Generate thumbnail

> Generate a PNG thumbnail from a single page of a PDF.

## Phase

**Phase 2** — Useful for thumbnails, previews, and social sharing images.

## Request

<ParamField body="source" type="object" required>
  The PDF to convert.

  * `{ "pdf_id": "pdf_abc123" }`
  * `{ "url": "https://example.com/doc.pdf" }`
  * `{ "base64": "JVBERi0x..." }`
</ParamField>

<ParamField body="page" type="integer" default="1">
  The page number to render as a thumbnail.
</ParamField>

<ParamField body="output" type="string" default="url">
  `url` or `base64`.
</ParamField>

## Response

```json theme={null}
{
  "id": "conv_img1",
  "object": "conversion",
  "status": "completed",
  "image": {
    "page": 1,
    "url": "https://files.pdfbase.dev/conv_img1_p1.png?token=sig_a",
    "width": 1240,
    "height": 1754,
    "bytes": 180000
  },
  "created_at": "2026-05-19T13:25:00Z",
  "expires_at": "2026-05-20T13:25:00Z"
}
```

## Example

```bash theme={null}
curl -X POST https://api.pdfbase.dev/v1/convert/image \
  -H "Authorization: Bearer pk_live_xxx" \
  -H "Content-Type: application/json" \
  -d '{
    "source": { "pdf_id": "pdf_report" },
    "page": 3,
    "output": "url"
  }'
```
