Articles on: Forms

How to Collect Signatures and Automate Your Document Workflow

In this tutorial, we'll walk you through setting up a complete document signing workflow using PDF Generator API Forms and n8n. As a practical example, we'll use a consent form: a client fills in their details, reviews the generated document in the PDF Generator API Document Viewer, and signs it. Their details are stored in a Google Sheets spreadsheet, the signed PDF is emailed to the client, your team gets notified on Slack, and a permanent copy is saved to Google Drive.


The guide covers the following steps:



Step 1: Prepare Your Template


The template defines the layout and content of the PDF document your client will sign. Choose one of the three options below depending on your situation.


Option A: Build a template in the editor


  1. Go to Templates and click New template.
  2. Design your template using the editor's components. Add all static content you want to include in the document, such as the consent terms and your company details.
  3. Save the template.


💡 Tip: New to the editor? See How to Use the Editor before getting started.


Option B: Upload an existing static PDF


If you already have a static PDF, you can upload it directly as a template.


  1. Go to Templates, click the arrow next to New Template, and select Import from PDF.


Importing a PDF as a Template


  1. Your PDF will appear as the background of a new template. Use the editor to overlay dynamic components on top and position them wherever the client's data should appear.
  2. Save the template.


💡 Tip: For a full walkthrough of uploading and working with existing PDFs, see How to Upload Your Existing PDF Document as a Template.


Option C: Import an editable PDF directly from the Forms page


If your existing PDF is an editable form with fields already defined, you can skip the Templates page entirely.


  1. Go to Forms, click the arrow next to New Form, and select Import editable PDF.


Importing an Editable PDF


  1. PDF Generator API will automatically extract the editable fields and create both a form and a matching template in one step.


💡 Tip: For a detailed walkthrough of the import process, see the Create a Form Based on an Existing PDF Form section in the How to Create a Form guide.


Step 2: Create the Form and Configure Signing


2.1. Create the form


  1. Navigate to the Forms page and click New form.
  2. Give your form a Name for your own reference.
  3. Under Template, select the template you prepared in Step 1.
  4. Add a Title that the client will see, and an Introduction to give them context.


💡 Tip: For a full walkthrough of the form creation process, see How to Create a Form.


2.2. Configure Form Actions


  1. In the Form Actions section, check Store the Document first, and then check Sign the Document to activate the signing flow.


ℹ️ Note: Store the Document must be enabled before Sign the Document becomes available, since the document needs to exist in Document Storage before it can be signed.


  1. Enable Send data and document to third party service, which allows PDF Generator API to send the form submission data to n8n. In the Callback URL field, enter a placeholder to allow the form to be saved:


https://example.org/document-callback


You will replace this with the real n8n webhook URL in Step 3.


2.3. Add form fields and connect them to the template


Form fields define what the client fills in. Each field is also connected to a placeholder in your template, so the submitted data appears in the right place in the generated PDF.


ℹ️ Note: If you imported an editable PDF via Option C, your fields are already extracted and mapped to the template. Review them to make sure all names and labels are correct before proceeding.


  1. Add the fields you want the client to fill in.


Adding Form Fields


ℹ️ Note: There is no need to add a Signature field here. Since Sign the Document is enabled, signing happens entirely within the Document Viewer after submission.


  1. Save the form and reopen it.
  2. Click the arrow next to Save and select Save & Edit Template. This opens your template in the editor with your form fields available in the left sidebar.


Opening the Template Editor via Save & Edit Template


  1. Drag and drop each field into the correct position in the template so that the submitted data appears in the right place in the generated document.


Mapping Form Fields to the Template in the Editor

  1. Save the template.


💡 Tip: For a full list of available field types and how to configure them, see Forms – Field Types and Actions.


2.4. Save and share the form


Once everything is configured, click Save & Share to get a shareable link for your form. This is the link you'll send to your clients.


Consent Form View


What Happens After Submission


What the signer sees


After submitting the form, the client is automatically taken into the Document Viewer, a hosted, browser-based experience that requires nothing to install or download. The viewer guides the signer step by step through reviewing the pre-filled document, confirming their details, and drawing their signature, all within the same browser session immediately after they submit the form.


Reviewed and Signed Document in the Document Viewer


Where signed documents go


Once a document is signed, it is saved automatically to Document Storage. From there you can:


  • View the document and its full version history.
  • See every action taken on it, such as when it was reviewed and when it was signed.
  • Download the final signed version.


⚠️ Important: Documents in Document Storage are kept for 30 days and then permanently deleted. The n8n workflow in Step 3 saves a permanent copy to Google Drive automatically so you always have a long-term record.


Step 3: Set Up the n8n Workflow


To automate what happens after signing, we'll use n8n to connect PDF Generator API with Google Sheets, Gmail, Slack, and Google Drive. We've published this workflow as an official n8n template here, where you can click Use for free to import it directly into your own n8n account.


n8n Document Signing Workflow


Before activating the workflow


  1. Connect your credentials for PDF Generator API, Gmail, Slack, Google Sheets, and Google Drive in the respective nodes. Without credentials, the nodes cannot communicate with the external services.


💡 Tip: New to the PDF Generator API node in n8n? See How to Integrate PDF Generator API with n8n for how to install the node and find your API credentials.


  1. Create a Google Sheets spreadsheet to store your client submissions. Add column headers matching the fields in your form, plus Public ID, which the workflow uses to link each submission to its signed document. We also added Signed and Signed At to keep a record of the signature status.


Consent Form Submissions Spreadsheet


ℹ️ Note: Make sure the spreadsheet name and sheet name in the Google Sheets nodes match what you created.


  1. Set the Webhook URL. The Webhook node in n8n generates a URL that PDF Generator API will call whenever a relevant event occurs, such as form submission or document signing. Open the Webhook node, copy the production URL, and paste it in two places:


    • Callback URL field in your form (replace the placeholder from Step 2)
    • Settings -> Documents -> Document Webhook in PDF Generator API.


Setting the Document Webhook URL


⚠️ Important: The Webhook node generates two URLs. Make sure to use the production URL in both places, otherwise the workflow will only trigger when the workflow is open in the editor.


Once everything is configured, activate the workflow and the automation is ready to go.


What each node does


  • Webhook: receives callback notifications from PDF Generator API on form submission and on document signing.
  • Route by Action: routes the flow based on the event type: form submission goes to Save Form Submission, signed document goes to Update Submission Record, and any other action is ignored.
  • Save Form Submission: saves the client's details as a new row in your Google Sheets spreadsheet, using the document Public ID as a unique identifier.
  • Update Submission Record: finds the matching row by Public ID and updates it with the signature status and timestamp.
  • Optimize & Download Signed PDF: optimizes and downloads the signed PDF via the PDF Generator API node.
  • Email Signed Document to Client: sends the signed document to the client.
  • Notify Team: sends a notification to your team channel with the client's name, email, and a link to the document.
  • Save Signed Document: saves the signed PDF to a dedicated folder in Google Drive for long-term storage.


How It All Comes Together


Once everything is set up, the complete flow looks like this:


  1. The client opens your form link, fills in their details, and submits.
  2. PDF Generator API sends the form data to n8n, and the workflow saves the client's details to Google Sheets.
  3. The consent form is generated with the client's data and opens in the Document Viewer.
  4. The client reviews the document, draws their signature, and confirms.
  5. The signed document is saved to Document Storage.
  6. PDF Generator API notifies n8n that the document was signed.
  7. The workflow updates the client's row in Google Sheets, retrieves and optimizes the signed PDF via PDF Generator API, emails it to the client via Gmail, notifies your team via Slack, and saves the file to Google Drive.


Updated on: 23/07/2026

Was this article helpful?

Share your feedback

Cancel

Thank you!