Skip to main content

Zapier

Prerequisites

  • A PolyDoc account and API key — sign up for free, no credit card required. The free plan includes 150 PDF conversions per month.
  • A Zapier account — sign up for free (free plan limited to 5 Zaps).

Use Case 1: Generate PDFs from Google Sheets

Automatically generate an invoice PDF from each new Google Sheets row and email it as an attachment.
Google Sheets (new row) → Webhooks by Zapier (POST to PolyDoc) → Gmail (send email)

Create a new Zap

Log in to Zapier and click Create Zap. A Zap consists of a trigger ("when this happens") followed by one or more actions ("do this").

Screenshot placeholder: /img/guides/zapier/zapier-uc1-create-zap.png

Add a Google Sheets trigger

Add a worksheet with column headers that match your PolyDoc template. The example below uses an invoices tab and one sample row; you can import data via File → Import (CSV/XLSX).

invoice_numberinvoice_dateinvoice_due_dateinvoice_subtotalinvoice_tax_rateinvoice_tax_amountinvoice_totalcustomer_namecustomer_emailcustomer_streetcustomer_citycustomer_country
INV-2026-0012026-01-152026-02-1412000.11201320John Doejohn.doe@example.com456 Customer AvenueBeautiful CityUK

Set the trigger to Google Sheets → New Spreadsheet Row. Connect your Google account, select the spreadsheet and the invoices worksheet, then test the trigger to pull in a sample row.

Screenshot placeholder: /img/guides/zapier/zapier-uc1-sheets-trigger.png

Add a Webhooks by Zapier POST action

Add an action: Webhooks by Zapier → POST. Configure:

  • URL: https://api.polydoc.tech/pdf/convert
  • Payload Type: JSON
  • Headers: Authorization = Bearer YOUR_API_KEY (get from the Dashboard), Content-Type = application/json, X-Sandbox = true
  • Data: map Google Sheets columns to your PolyDoc template fields using Zapier's field picker.
Screenshot placeholder: /img/guides/zapier/zapier-uc1-webhooks-post.png

Add a Gmail action to send the PDF

Add another action: Gmail → Send Email. Map:

  • To: customer_email from Google Sheets
  • Subject: e.g. Invoice {{invoice_number}}
  • Attachment: use the response data from the Webhooks step
Screenshot placeholder: /img/guides/zapier/zapier-uc1-gmail-action.png

Test and turn on the Zap

Test each step individually using Zapier's step tester — verify the trigger pulls data, the webhook returns a PDF, and the email arrives. Once confirmed, click Turn on Zap.

Use Case 2: Catch Hook → PDF

Accept incoming data from any source via a Zapier webhook, generate a PDF, and deliver it by email.
Webhooks by Zapier (Catch Hook) → Webhooks by Zapier (POST to PolyDoc) → Email

Create a Catch Hook trigger

Create a new Zap. Set the trigger to Webhooks by Zapier → Catch Hook. Zapier generates a unique webhook URL — copy it.

Screenshot placeholder: /img/guides/zapier/zapier-uc2-catch-hook.png

Send test data to the webhook

Send a test POST request to the webhook URL with sample JSON data matching your PDF template fields. Zapier uses this to learn the data structure and make fields available in subsequent steps.

Screenshot placeholder: /img/guides/zapier/zapier-uc2-test-data.png

Add a POST action for PolyDoc

Add an action: Webhooks by Zapier → POST. Configure it the same way as Use Case 1 — URL, headers, and JSON body mapping the Catch Hook fields to your PolyDoc template.

Screenshot placeholder: /img/guides/zapier/zapier-uc2-post-polydoc.png

Deliver the PDF by email

Add an email action (Gmail, Outlook, or SMTP by Zapier). Attach the PDF from the previous step and set the recipient from the webhook data. Test the full Zap, then turn it on.