Getting Started

Authenticate and send your first request

Every FastPDF request requires an API key in the X-API-Key header. Follow the steps below to get a key and make your first conversion.

  1. 1
    key

    Create an API key

    Go to your Dashboard → API Keys page and click New API Key. Copy and save the key — it's only shown once.

  2. 2
    lock

    Include it in every request

    Pass the key as the X-API-Key HTTP header on all conversion requests. There is no Bearer prefix or OAuth flow — just the raw key value.

  3. 3
    arrow_forward

    Continue with an endpoint

    For endpoint-specific request bodies, continue with Convert HTML to PDF or Convert URL to PDF.

lightbulb

Keep your API key out of version control. Store it in an environment variable — FASTPDF_API_KEY is a good name.

Verify connectivity

Before sending your first conversion, confirm the API is reachable with a single GET /health request. No API key required.

GET/health
No auth
curl https://api.fastpdfhq.com/health
200 Healthy
{
  "status": "healthy",
  "message": "All systems operational",
  "timestamp": "2026-04-05T10:30:00Z"
}
info

See the Health Check reference for the full response schema and use cases for uptime monitoring and CI pre-flight checks.

Quick start

POST/v1/convert/html
cURL
curl -X POST https://api.fastpdfhq.com/v1/convert/html \  -H "X-API-Key: YOUR_API_KEY" \  -H "Content-Type: application/json" \  -d '{  "html": "<h1>Hello, World!</h1>",  "config": {    "paper": { "width": "8.5in", "height": "11in" },    "margin": { "top": "1in", "bottom": "1in" },    "print_background": true  }}' \  --output document.pdf
API Playground
POST/v1/convert/html
curl -X POST https://api.fastpdfhq.com/v1/convert/html \ -H "X-API-Key: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "html": "<h1>Hello, World!</h1>", "config": { "paper": { "width": "8.5in", "height": "11in" }, "margin": { "top": "1in", "bottom": "1in" }, "print_background": true }}' \ --output document.pdf
{ "content": "JVBERi0xLjQKJeLjz9MKMyAwIG9iago..."}