Quick Start Guide
Generate your first PDF in under 5 minutes by following these 3 simple steps.
Step 1: Get Your API Key
Navigate to the API Keys page in the dashboard and generate your authentication key.
Free Tier
The free tier includes 300 PDF generations per month.
Your API key will look like this:
pdfsign_xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
Keep this key secure - you'll need it for all API requests.
Step 2: Create a Template with Variables
- Go to Templates in the dashboard
- Click "Create New Template"
- Design your template using the rich text editor
- Add variables using the Variables panel:
- Click "Add" in the Variables panel
- Set the variable name, type, and optional default value
- Click "Insert" to add the placeholder to your template
Example template HTML:
<h1>Invoice for {{clientName}}</h1>
<p>Invoice Number: {{invoiceNumber}}</p>
<p>Amount Due: ${{amount}}</p>
<p>Date: {{date}}</p>
Step 3: Make an API Request
Call the API with your template ID and variable values to generate a PDF.
POST
/functions/v1/generate-pdf-previewGenerate a PDF from a template
Example Request
curl -X POST https://api.pdf-sign.com/functions/v1/generate-pdf-preview \
-H "x-api-key: pdfsign_your_api_key" \
-H "Content-Type: application/json" \
-d '{
"templateId": "your-template-id",
"variables": {
"clientName": "John Doe",
"invoiceNumber": "INV-001",
"amount": "1000.00",
"date": "2024-01-15"
}
}'
Success Response
{
"success": true,
"pdf_url": "https://api.pdf-sign.com/storage/v1/object/public/pdfs/generated-pdf.pdf",
"generation_id": "660f9500-f39c-52e5-b827-557766551111",
"file_size": 45678
}
The pdf_url is a public URL where you can download your generated PDF.
What's Next?
- Learn more about Authentication
- Explore the full API Reference
- Understand Template Variables
- Check your Rate Limits