Business

Invoice PDF Template

Generate professional, pixel-perfect invoices via API. Dynamic tables, client logos, tax calculations. Perfect for e-commerce, SaaS billing, and accounting automation.

35 customizable variables
Invoice PDF Template Preview
Preview

How It Works

1. Get Your API Key

Sign up and generate an API key from your dashboard.

2. Send JSON Payload

Make a POST request with your template variables as JSON.

3. Receive PDF URL

Get a direct URL to your generated PDF document.

Template Variables

Customize your PDF by providing values for these variables in your API request.

Variable NameTypeDefault Value
{{company_logo_url}}texthttps://api.pdf-sign.com/storage/v1/object/public/images/Your-Logo-here.png
{{company_email}}textbilling@company.com
{{company_phone}}text+1 (555) 000-0000
{{due_date}}date-
{{client_email}}textclient@example.com
{{payment_status}}textPAID
{{item1_description}}textWeb Development Services
{{item1_qty}}number1
{{item1_price}}text€500.00
{{item1_total}}text€500.00
{{item2_description}}textUI/UX Design
{{item2_qty}}number2
{{item2_price}}text€150.00
{{item2_total}}text€300.00
{{item3_description}}textHosting (Annual)
{{item3_qty}}number1
{{item3_price}}text€120.00
{{item3_total}}text€120.00
{{subtotal}}text€920.00
{{tax_rate}}text20%
{{tax_amount}}text€184.00
{{bank_name}}textYour Bank
{{iban}}textFR76 XXXX XXXX XXXX
{{bic}}textXXXXXXXX
{{invoice_number}}textINV-2024-0042
{{date}}date-
{{company_name}}textAcme Corporation
{{company_address}}text123 Business Avenue, Suite 100, Paris 75001
{{client_name}}textTechStart Inc.
{{client_address}}text456 Innovation Drive, London EC2A 4BX
{{item_description}}textService
{{item_qty}}number1
{{item_price}}text$100
{{item_total}}text$100
{{total}}text€1,104.00

Code Examples

Copy and paste these examples to start generating PDFs with this template.

curl -X POST 'https://api.pdf-sign.com/functions/v1/generate-pdf-preview' \
  -H 'Content-Type: application/json' \
  -H 'x-api-key: pdfsign_YOUR_API_KEY' \
  -d '{
    "templateId": "f86e0233-39bd-4884-80ca-c5da4774a3db",
    "variables": {
      "company_logo_url": "https://api.pdf-sign.com/storage/v1/object/public/images/Your-Logo-here.png",
      "company_email": "billing@company.com",
      "company_phone": "+1 (555) 000-0000",
      "due_date": "your_due_date",
      "client_email": "client@example.com",
      "payment_status": "PAID",
      "item1_description": "Web Development Services",
      "item1_qty": "1",
      "item1_price": "€500.00",
      "item1_total": "€500.00",
      "item2_description": "UI/UX Design",
      "item2_qty": "2",
      "item2_price": "€150.00",
      "item2_total": "€300.00",
      "item3_description": "Hosting (Annual)",
      "item3_qty": "1",
      "item3_price": "€120.00",
      "item3_total": "€120.00",
      "subtotal": "€920.00",
      "tax_rate": "20%",
      "tax_amount": "€184.00",
      "bank_name": "Your Bank",
      "iban": "FR76 XXXX XXXX XXXX",
      "bic": "XXXXXXXX",
      "invoice_number": "INV-2024-0042",
      "date": "your_date",
      "company_name": "Acme Corporation",
      "company_address": "123 Business Avenue, Suite 100, Paris 75001",
      "client_name": "TechStart Inc.",
      "client_address": "456 Innovation Drive, London EC2A 4BX",
      "item_description": "Service",
      "item_qty": "1",
      "item_price": "$100",
      "item_total": "$100",
      "total": "€1,104.00"
    }
  }'

Example JSON Payload

Here's a complete example of the variables object you'll send in your API request.

{
  "templateId": "f86e0233-39bd-4884-80ca-c5da4774a3db",
  "variables": {
    "company_logo_url": "https://api.pdf-sign.com/storage/v1/object/public/images/Your-Logo-here.png",
    "company_email": "billing@company.com",
    "company_phone": "+1 (555) 000-0000",
    "due_date": "your_due_date",
    "client_email": "client@example.com",
    "payment_status": "PAID",
    "item1_description": "Web Development Services",
    "item1_qty": "1",
    "item1_price": "€500.00",
    "item1_total": "€500.00",
    "item2_description": "UI/UX Design",
    "item2_qty": "2",
    "item2_price": "€150.00",
    "item2_total": "€300.00",
    "item3_description": "Hosting (Annual)",
    "item3_qty": "1",
    "item3_price": "€120.00",
    "item3_total": "€120.00",
    "subtotal": "€920.00",
    "tax_rate": "20%",
    "tax_amount": "€184.00",
    "bank_name": "Your Bank",
    "iban": "FR76 XXXX XXXX XXXX",
    "bic": "XXXXXXXX",
    "invoice_number": "INV-2024-0042",
    "date": "your_date",
    "company_name": "Acme Corporation",
    "company_address": "123 Business Avenue, Suite 100, Paris 75001",
    "client_name": "TechStart Inc.",
    "client_address": "456 Innovation Drive, London EC2A 4BX",
    "item_description": "Service",
    "item_qty": "1",
    "item_price": "$100",
    "item_total": "$100",
    "total": "€1,104.00"
  }
}

Other Templates

Ready to Generate Invoices?

Sign up and start generating professional PDF documents in minutes. Start at just €9/month.