{"product_id":"fill-pdfs-from-json-in-n8n-justfill-gemini-vision-workflow","title":"Fill PDFs from JSON in n8n: JustFill + Gemini Vision Workflow","description":"\u003ch3\u003eFill PDFs from JSON in n8n—with JustFill field detection and Google Gemini Vision review\u003c\/h3\u003e\n\u003cp\u003eThis workflow takes an uploaded PDF and a \u003cstrong\u003eData JSON\u003c\/strong\u003e payload in an n8n form, automatically maps your JSON values to the correct PDF fields using \u003cstrong\u003eJustFill\u003c\/strong\u003e, and then uses \u003cstrong\u003eGoogle Gemini Vision\u003c\/strong\u003e to visually verify the filled result before generating a downloadable PDF.\u003c\/p\u003e\n\n\u003ch3\u003eWhat this workflow does\u003c\/h3\u003e\n\u003cul\u003e\n  \u003cli\u003e\n\u003cstrong\u003eCollects inputs via an n8n form:\u003c\/strong\u003e users upload a PDF and submit a “Data JSON” object.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eRequests a JustFill upload slot:\u003c\/strong\u003e the workflow uploads the PDF to JustFill, opens it, and detects fillable fields to create a workspace.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eGenerates labelled previews:\u003c\/strong\u003e it renders labelled page previews for all pages containing detected fields.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eMaps JSON keys to JustFill field IDs:\u003c\/strong\u003e the workflow sends the labelled previews plus the user’s JSON keys to \u003cstrong\u003eGoogle Gemini Vision\u003c\/strong\u003e, which maps each data key to the appropriate field ID.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eVisually validates placement and readability:\u003c\/strong\u003e it renders filled previews with the proposed values and asks Gemini to review across pages.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eFills and returns a download link:\u003c\/strong\u003e if Gemini approves with no issues, the workflow fills the PDF in JustFill and returns a redirect link to download the completed document.\u003c\/li\u003e\n\u003c\/ul\u003e\n\n\u003ch3\u003eUse cases\u003c\/h3\u003e\n\u003cul\u003e\n  \u003cli\u003e\n\u003cstrong\u003eContract or application automation:\u003c\/strong\u003e fill multi-page PDFs from structured JSON data while ensuring the output is readable.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eOperations and SaaS workflows:\u003c\/strong\u003e reduce manual data entry for forms by validating field placement before final PDF generation.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eWorkflow prototyping for automation engineers:\u003c\/strong\u003e create a reliable “PDF + JSON → approved filled PDF” pipeline with visual review.\u003c\/li\u003e\n\u003c\/ul\u003e\n\n\u003ch3\u003eTechnical details\u003c\/h3\u003e\n\u003cul\u003e\n  \u003cli\u003e\n\u003cstrong\u003eIntegrations:\u003c\/strong\u003e \u003cstrong\u003eJustFill\u003c\/strong\u003e (request_file_upload, open_pdf, render_preview, render_filled_preview, fill_pdf) and \u003cstrong\u003eGoogle Gemini Vision\u003c\/strong\u003e (field mapping + visual approval).\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003en8n nodes \/ building blocks:\u003c\/strong\u003e Set, Code, Form, Sticky Note, Form Trigger, HTTP Request.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eSetup requirements:\u003c\/strong\u003e add a \u003cstrong\u003eJustFill API key\u003c\/strong\u003e and \u003cstrong\u003eGoogle Gemini API key\u003c\/strong\u003e in the Config step (optionally adjust the model name), confirm your JustFill MCP tools are accessible, then customize the n8n form fields and sample JSON.\u003c\/li\u003e\n\u003c\/ul\u003e","brand":"N8N Commerce","offers":[{"title":"Default Title","offer_id":45876841840819,"sku":"N8N-18525","price":51.99,"currency_code":"GBP","in_stock":true}],"thumbnail_url":"\/\/cdn.shopify.com\/s\/files\/1\/0749\/6279\/6723\/files\/2L8QaUHB0JoOGBHymCOK1_DbpqgQQj.png?v=1787303147","url":"https:\/\/buyflowscripts.com\/products\/fill-pdfs-from-json-in-n8n-justfill-gemini-vision-workflow","provider":"N8N Commerce","version":"1.0","type":"link"}