Skip to main content

PDF Form and JSON in Dropbox? Power Automate Populates Them. Four Actions, That's It!

· 15 min read
SEO and Content Writer

You have a fillable PDF form and data in JSON. Manually typing into each field is slow and error prone. Power Automate plus PDF4me automates it: get the template and JSON from Dropbox (or SharePoint), run Fill a PDF Form, and create the filled file. No code. Works with Microsoft 365. Connect storage, map the files, and get a populated form.

In a nutshell: Get Template File (e.g. /blog data/fill a pdf/sample_fill_form.pdf) → Get JSON data file (e.g. /blog data/fill a pdf/sample_fill_form_data.json) → PDF4me – Fill a PDF Form (Template File Data from step 1, Form Data from step 2) → Create file. Output: filled PDF ready to store or send.

Why-Based Q&A

Why use JSON to fill PDF forms? JSON keys map directly to form field names (customerName, email, invoiceNumber, and so on). Your data lives in Excel, Dynamics, or databases; JSON is the common bridge. One template, many fills: reuse the same form with different JSON for bulk automation.

Why two Get file steps? One fetches the blank PDF form (template); the other fetches the JSON data. Both outputs go to Fill a PDF Form: Template File Data from the first step, Form Data (Data string) from the second. Template and data stay separate for flexible flows.

Why PDF4me Fill a PDF Form? The action accepts JSON directly. You provide the template PDF and the data; PDF4me matches keys to form fields and returns a filled PDF. Integrates with Dropbox, SharePoint, and Power Automate expressions.


What You'll Get

Input: A fillable PDF form and a JSON file (or JSON string) with matching field names. Output: A completed PDF with all fields populated, ready to save, email, or pass to the next action.


What You Need

  • Power AutomateOpen Power Automate. Create a new cloud flow (Instant or Automated).
  • PDF4me API keyGet your API key. Connect it when you add the Fill a PDF Form action. First time? See Connect PDF4me to Power Automate.
  • Dropbox or SharePoint — For the PDF template, JSON file, and output folder. Use the connector that matches your storage.

The Flow at a Glance

  1. Manually trigger a flow (or When a file is created for automation).
  2. Get Template File (Dropbox or SharePoint) — Gets the blank fillable PDF form.
  3. Get JSON data file (Dropbox or SharePoint) — Gets the JSON data to populate the form.
  4. PDF4me – Fill a PDF Form — Combines template and JSON. Template File Data from step 1, Form Data (Data string) from step 2.
  5. Create file (Dropbox or SharePoint) — Saves the filled PDF to your output folder.

Complete flow overview

Power Automate flow: Manually trigger a flow, Get Template File, Get JSON data file, Fill a PDF Form, Create file

Five steps: Trigger, Get Template File, Get JSON data file, Fill a PDF Form, Create file. Each action shows a green checkmark when configured. The PDF and JSON from the Get file steps are passed into PDF4me; the filled PDF goes to Create file.


Step 1: Get the Template File

Flow so far: Trigger and Get Template File only.

  1. Add Manually trigger a flow (or When a file is created in Dropbox or SharePoint for automation).
  2. Add Dropbox (or SharePoint) → Get file content using path (you can name it "Get Template File" in Settings).
  3. File Path — Enter the path to your fillable PDF form, e.g. /blog data/fill a pdf/sample_fill_form.pdf.
  4. Infer content typeYes (optional).
  5. Run the action. The output File Content will be passed to Fill a PDF Form as Template File Data.

Get Template File: Configuration

Get Template File: File Path /blog data/fill a pdf/sample_fill_form.pdf

Get Template File: File Path set to the PDF form. The output File Content is passed to Fill a PDF Form as Template File Data.


Step 2: Get the JSON Data File

Flow so far: Get Template File → Get JSON data file.

  1. Add Dropbox (or SharePoint) → Get file content using path (name it "Get JSON data file" in Settings).
  2. File Path — Enter the path to your JSON file, e.g. /blog data/fill a pdf/sample_fill_form_data.json.
  3. Infer content typeYes (optional).
  4. Run the action. The output File Content (or decoded text) will be passed to Fill a PDF Form as Form Data. Ensure JSON keys match the form field names (e.g. customerName, email, invoiceNumber).

Get JSON data file: Configuration

Get JSON data file: File Path /blog data/fill a pdf/sample_fill_form_data.json

Get JSON data file: File Path set to the JSON file. The file content is mapped into Fill a PDF Form as Form Data (Data string). If the connector returns base64, use base64ToString() in an expression to get the JSON text.


Step 3: Fill the PDF Form

Flow so far: Get Template File → Get JSON data file → Fill a PDF Form.

  1. Add PDF4meFill a PDF Form.
  2. Template File Data — Map File Content from the Get Template File action.
  3. Template File Name — e.g. sample_fill_form.pdf (must include .pdf).
  4. Form Data (Data string) — Map the JSON content. Use File Content from Get JSON data file. If it returns binary or base64, use an expression like base64ToString(body('Get_JSON_data_file')?['$content']) to get the JSON text.
  5. Keep Pdf template EditableNo for a flattened PDF; Yes to keep fields editable.
  6. Run the action. PDF4me returns Output Documents with File Content (the filled PDF).

PDF4me – Fill a PDF Form: Template, Form Data, and options

Fill a PDF Form: Template File Data from Get Template File, Template File Name, Form Data from Get JSON data file, Keep Pdf template Editable No

Fill a PDF Form: Template File Data from Get Template File, Template File Name, Form Data (Data string) from Get JSON data file. Keep Pdf template Editable set to No for a flattened output. Output Documents contain the filled PDF.


Step 4: Create the File (Save the Filled PDF)

Flow so far: Get Template File → Get JSON data file → Fill a PDF Form → Create file.

  1. Add Dropbox (or SharePoint) → Create file.
  2. Folder Path — e.g. /blog data/fill a pdf/output.
  3. File Name — e.g. Fill_PDF_PA.pdf.
  4. File Content — Map File Content from the first item in Output Documents of the Fill a PDF Form action (e.g. body('Fill_a_PDF_Form')?['OutputDocuments']?[0]?['FileContent'] or the dynamic content picker).
  5. Run the flow. The filled PDF is saved to your folder.

Create file: Save filled PDF to output folder

Create file: Folder Path /blog data/fill a pdf/output, File Name Fill_PDF_PA.pdf, File Content from Fill a PDF Form

Create file: Folder Path, File Name Fill_PDF_PA.pdf, File Content mapped from Fill a PDF Form Output Documents.


Input and Output: What Goes In, What Comes Out

Here is the JSON, the blank form, and the filled result.

Example JSON input

Example JSON data for PDF form filling: customerName, email, phone, invoiceNumber, invoiceDate, address, amount

Sample JSON: keys (customerName, email, phone, invoiceNumber, invoiceDate, address, amount) match the fillable form fields. Get JSON data file fetches this; Form Data passes it to Fill a PDF Form.

Blank fillable form (input)

Demo Invoice Form (Fillable): blank form with fields for Customer Name, Email, Phone, Invoice Number, Invoice Date, Address, Amount

Blank fillable invoice form: fields correspond to the JSON keys. PDF4me populates each field from the JSON value.

Filled form (output)

Demo Invoice Form filled with John Doe, john.doe@email.com, INV-2026-001, 221B Baker Street, 1250 USD

Filled invoice form: all fields populated from JSON. Output is saved via Create file or passed to the next flow action.


Use Cases: When to Fill PDF Forms in Power Automate

Invoices and quotes: Pull data from Excel, Dynamics, or SharePoint lists. Generate JSON, then fill the template. Save to a folder or email automatically.

Contracts and agreements: CRM or form responses produce JSON. Map to a contract template and generate filled PDFs for each party.

Certificates and badges: Event or training data in JSON. Fill certificate forms in bulk and save to SharePoint or send via Outlook.


Quick Reference: Key Settings

ActionSettingExample
1. Get Template FileFile Path/blog data/fill a pdf/sample_fill_form.pdf
2. Get JSON data fileFile Path/blog data/fill a pdf/sample_fill_form_data.json
3. Fill a PDF FormTemplate File DataFrom Get Template File
3. Fill a PDF FormForm DataFrom Get JSON data file (JSON text)
4. Create fileFile ContentOutput Documents [0] from Fill a PDF Form

For full parameter details, see Fill a PDF Form — Power Automate.


Troubleshooting

Form fields not filled or wrong values

JSON keys must match PDF form field names exactly (case sensitive). Check field names in Acrobat or a PDF editor.

Form Data: invalid or empty

Form Data expects JSON text. If Get file content returns base64, use base64ToString(body('Get_JSON_data_file')?['$content']) in an expression.

Create file: map File Content from Fill a PDF Form

Map from Output Documents of Fill a PDF Form, not from Get Template File. Use the first item in the array: body('Fill_a_PDF_Form')?['OutputDocuments']?[0]?['FileContent'].

401, 402, or other API errors

PDF4me Troubleshooting covers 401 (API key), 402 (credits), and more.


What's Next?

  • Replace the manual trigger with When a file is created in Dropbox or SharePoint to process new template and JSON pairs automatically.
  • Generate JSON from Excel or a SharePoint list (e.g. Apply to each) to fill multiple forms in one run.
  • Add Send an email after Create file to email the filled PDF to recipients.
  • Same flow pattern in Make if you prefer that platform.