Sync Conversion
The /v1/sync endpoint generates a PDF and returns a JSON response with a temporary download URL. By default, files stored in PDFBolt's temporary storage expire after 24 hours. Use it when your application needs a download URL instead of PDF bytes. You can also provide customS3PresignedUrl to upload the PDF directly to your own bucket.
Endpoint Details
Method: POST
https://api.pdfbolt.com/v1/sync
Success Example
- Request
- cURL
- Response
Example request body for converting a URL to PDF:
{
"url": "https://example.com"
}
Complete request with authentication:
curl 'https://api.pdfbolt.com/v1/sync' \
-H 'API-KEY: XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX' \
-H 'Content-Type: application/json' \
-d '{"url": "https://example.com"}'
To inspect response headers (rate limits, conversion cost), add -D -:
curl -D - 'https://api.pdfbolt.com/v1/sync' \
-H 'API-KEY: XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX' \
-H 'Content-Type: application/json' \
-d '{"url": "https://example.com"}'
{
"requestId": "db347fe5-7b72-45f6-92f9-a7b7755ab6c8",
"status": "SUCCESS",
"errorCode": null,
"errorMessage": null,
"documentUrl": "https://s3.pdfbolt.com/pdfbolt_ec2950a1-f835-4be6-bab2-69490b53b1f9_2026-04-30T10-44-09Z.pdf",
"expiresAt": "2026-05-01T10:44:09Z",
"isAsync": false,
"duration": 606,
"documentSizeMb": 0.02,
"isCustomS3Bucket": false
}
Failure Example
If the request fails (e.g., unauthorized, bad request, conversion timeout), the response is a JSON error object. See Error Handling for all error codes and recommended actions.
- Request
- Response
{
"url": "https://example.com",
"waitForFunction": "() => document.body.innerText.includes('Ready to Download')"
}
{
"timestamp": "2026-04-30T10:25:07Z",
"httpErrorCode": 408,
"errorCode": "CONVERSION_TIMEOUT",
"errorMessage": "Conversion process timed out. Please see https://pdfbolt.com/docs/parameters#timeout, https://pdfbolt.com/docs/parameters#waituntil and https://pdfbolt.com/docs/parameters#waitforfunction parameters."
}
Body Parameters
Below are only the parameters specific to the /sync endpoint. For common parameters shared across all endpoints, see Conversion Parameters.
customS3PresignedUrl
Type: string
Required: No
Details:
Specifies an HTTPS pre-signed URL for direct upload to your S3-compatible bucket. The URL must be no longer than 2048 characters. When provided, the response's documentUrl is null and isCustomS3Bucket: true (file goes directly to your bucket). If not provided, the document is stored in PDFBolt's S3 bucket for 24 hours.
See Uploading to Your S3 Bucket for setup details.
Usage:
{
"url": "https://example.com",
"customS3PresignedUrl": "https://your-bucket.s3.amazonaws.com/document.pdf?<presigned-query-params>"
}
customS3PresignedUrl is available on paid plans. Free plan users should omit this parameter and use PDFBolt's default temporary storage instead.
Response Parameters
Response fields for successful requests. For failure responses, see Error Response Format.
| Parameter | Type | Description | Possible Values | Example Value |
|---|---|---|---|---|
requestId | string (UUID) |
| Any valid UUID | db347fe5-7b72-45f6-92f9-a7b7755ab6c8 |
status | string (Enum) |
| SUCCESS | SUCCESS |
errorCode | string |
| null | null |
errorMessage | string |
| null | null |
documentUrl | string (URL) |
| Any valid URL or null | https://s3.pdfbolt.com/pdfbolt_ec2950a1-f835-4be6-bab2-69490b53b1f9_2026-04-30T10-44-09Z.pdf |
expiresAt | string (ISO 8601) |
| ISO 8601 datetime string in UTC or null | 2026-05-01T10:44:09Z |
isAsync | boolean |
| false | false |
duration | number |
| Any positive number | 606 |
documentSizeMb | number |
| Any positive number | 0.02 |
isCustomS3Bucket | boolean |
| truefalse | false |
For response headers, see API Response Headers.
Next Steps
📄️ Quick Start Guide
Code samples in Node.js, Python, Java, PHP, C#, Go, Rust
📄️ Conversion Parameters
Full reference for all PDF generation parameters
📄️ Uploading to Your S3 Bucket
Pre-signed URL setup with Node.js example