Skip to main content

Create ZUGFeRD Invoice in n8n

What this node does

PDF4me — Create Zugferd Invoice generates fully compliant ZUGFeRD hybrid e-invoices — a PDF/A-3 document with structured XML invoice data embedded inside — directly inside your n8n workflow. Convert XML, JSON, or CSV invoice data into a single hybrid file ready for the German B2B e-invoicing mandate, EU-wide EN 16931 compliance, or the German XRECHNUNG public-sector profile. Supports every ZUGFeRD version from 1.0 to 2.4 and all six conformance levels in one node.

Authenticating Your API Request

Every PDF4me node in n8n requires a valid Credential to connect with. Create or select one that holds your PDF4me API key so the workflow can authenticate ZUGFeRD invoice generation requests securely.

Important Facts You Should Not Miss

ZUGFeRD is a hybrid PDF/A-3 + XML format — not a pure XML standard
The output is a single PDF/A-3 archival-grade PDF with the structured XML invoice attached inside it. Humans read the PDF, machines parse the XML — no separate files to send. To generate pure XML without the PDF wrapper, set Output Mode to XML Only; to generate the hybrid file, set it to XML With PDF (the default).
ZUGFeRD 2.0+ is required for the 2025–2028 German B2B mandate
The German Wachstumschancengesetz (Growth Opportunities Act) made e-invoice receipt mandatory for all B2B transactions from 1 January 2025, with full sending obligations phased in by 2028. ZUGFeRD version 2.0 or higher with EN16931 or XRECHNUNG conformance satisfies the mandate. Legacy ZUGFeRD 1.0 does not comply.
Conformance Level controls compliance — EN16931 is the safe default
Pick EN16931 for general B2B invoicing across the EU (the European Standard), XRECHNUNG when invoicing German public-sector entities, and EXTENDED for industry-specific fields beyond the EN 16931 baseline. MINIMUM and BASICWL omit line items and cannot be used for full invoicing — only for internal accounting drop-offs.

Parameters

Required in the n8n UI: Credential to connect with, Input Data Type, Document Name (always required — even when Input Data Type is None, used as document name fallback), Output Mode, Zugferd Version, Render Invoice On PDF, Language, Input Format, and Invoice Data Input Type. Conformance Level is shown and required based on the Zugferd Version branch — different field name and option set for 1.0 vs 2.0/2.1/2.2/2.4 vs Custom. The matching invoice data field (Invoice XML/JSON/CSV Data, Binary Property, Base64 Content, or Data URL) is required based on Invoice Data Input Type. Runtime validation enforces non-empty content on the chosen path with errors like "Invoice … data is required" or "Invoice base64 content is required".

Create Zugferd Invoice n8n node showing complete parameter panel with Credential to connect with PDF4ME account dev, Resource Invoice, Invoice Operations Create Zugferd Invoice, Input Data Type Binary Data, Binary Property data, Document Name invoice.pdf, Output Mode XML With PDF, Zugferd Version 2.0, Conformance Level EN16931, Language German, Render Invoice On PDF enabled, Input Format JSON, Invoice Data Input Type Direct Text, Output File Name zugferd_invoice.pdf, Output Binary Field Name data

Full Parameters view — use with the table below to locate each field in the node.

ParameterRequiredWhat it doesExample
Input Data TypeYesHow the background PDF (the visual layer of the hybrid invoice) is supplied. None creates the PDF from invoice data alone. Binary Data reads from a previous n8n node. Base64 String accepts encoded content. URL downloads from a public link.Binary Data
Binary Property NameConditionalName of the binary field from the previous node. Required when Input Data Type is Binary Data.data
Base64 ContentConditionalBase64-encoded PDF string. Required when Input Data Type is Base64 String.JVBERi0xLjQK...
File URLConditionalPublic URL to the source PDF. Required when Input Data Type is URL.https://example.com/invoice.pdf
Document NameYesFilename of the source PDF document. Always required in the UI — including when Input Data Type is None (used as document name fallback in the payload). Include the .pdf extension.invoice.pdf
Output ModeYesXML Only generates a pure XML file. XML With PDF generates the full hybrid ZUGFeRD file — a PDF/A-3 document with structured XML embedded inside. XML With PDF is the canonical ZUGFeRD output.XML With PDF
Zugferd VersionYesZUGFeRD specification version. 1.0 is legacy and does not satisfy the German B2B mandate. 2.0 through 2.4 all support EN 16931. 2.2 and 2.4 add the latest XRECHNUNG profile updates. Custom enables advanced version handling.2.0
Zugferd Version CustomConditionalCustom ZUGFeRD version identifier. Shown and required only when Zugferd Version is Custom (the execute step throws if empty).2.3.1
Custom Conformance RulesConditionalRule set used to validate custom versions. Shown and required when Zugferd Version is Custom. Choose legacy (for v1.0-style rules) or v21plus (for v2.1+ rules).v21plus
Conformance LevelConditionalProfile controlling which invoice fields are required. Shown when Zugferd Version is 1.0 (legacy options). Switches to Conformance Level (Above 2) for versions 2.0/2.1/2.2/2.4 (MINIMUM, BASICWL, BASIC, EN16931, EXTENDED, XRECHNUNG). Two further variants exist for Custom version branches.EN16931
LanguageYesDisplay language for invoice labels in the rendered PDF. Options: German, French, Italian, English, Spanish, Dutch, Polish, Portuguese. The XML data itself remains language-neutral.German
Render Invoice On PDFYesToggle (ON/OFF). When enabled, PDF4me visually renders the invoice content on the PDF using your invoice data. When disabled, only the structured XML is generated and embedded — useful when you supply a pre-designed background PDF.true
Input FormatYesFormat of the invoice data you are providing. XML for pre-built ZUGFeRD XML or UBL data. JSON for structured invoice objects. CSV for tabular batch exports.XML sampleJSON sampleCSV sample
Invoice Data Input TypeYesHow the invoice data reaches the node. Direct Text accepts pasted or mapped data inline. Binary Data reads from a previous file node. Base64 String for encoded payloads. URL downloads from a public link.Direct Text
Invoice XML / JSON / CSV DataConditionalThe actual invoice content. Appears as Invoice XML Data, Invoice JSON Data, or Invoice CSV Data — matching the chosen Input Format. Required when Invoice Data Input Type is Direct Text. Runtime also throws "Invoice … data is required" if empty.XML sampleJSON sampleCSV samplePaste, map, or load via Binary / Base64 / URL — match the format you chose above.
Invoice Binary Property NameConditionalName of the binary field holding the invoice data file. Required when Invoice Data Input Type is Binary Data.data
Invoice Base64 ContentConditionalBase64-encoded invoice data. Required when Invoice Data Input Type is Base64 String. Runtime also throws "Invoice base64 content is required" if empty.PGludm9pY2U+...
Invoice Data URLConditionalPublic URL to the invoice data file. Required when Invoice Data Input Type is URL.https://example.com/invoice.json
Output File NameNoFilename for the generated ZUGFeRD invoice. Default provided and normalized in execute (e.g. extension matched to Output Mode). Use .pdf for XML With PDF and .xml for XML Only.zugferd_invoice.pdf
Output Binary Field NameNoName of the binary field holding the generated ZUGFeRD file. Defaults to data. Used to reference the file in subsequent workflow nodes.data

Advanced Options

All fields inside the Advanced Options collection are optional. Add them via Add Option in the node UI.

profiles
Custom PDF4me processing profiles. Apply pre-configured option sets for advanced or specialized ZUGFeRD invoice generation (for example custom validation rules, alternative schema mappings, or sector-specific output tuning).

Input Data Type Options

Controls how the background PDF document (the visual layer of the hybrid invoice) is supplied to the node.

Input Data Type dropdown in n8n PDF4me Create Zugferd Invoice node showing four options: None with description No document input required (XML/JSON/CSV only), Binary Data highlighted with description Use file from previous node, Base64 String with description Provide file content as base64 encoded string, and URL with description Provide URL to file

Input Data Type dropdown — controls how the background PDF reaches the node

NoneXML/JSON/CSV only — no background PDF
No document input is required. PDF4me generates both the visual PDF layer and the structured XML from the invoice data alone. Use this when only the invoice data exists and you want PDF4me to render the full hybrid file.
Binary DataFile from previous node — most common
Reads the background PDF binary directly from the output of a prior n8n node — Google Drive Download, HTTP Request, Read Binary File. The Binary Property field specifies which output field to read (default data).
Base64 StringBase64-encoded file content
Accepts the background PDF as a base64-encoded string. Use this when the file arrives from an API response, webhook payload, or a database column that stores documents as base64.
URLDownload from a public link
Provide a publicly accessible URL to the background PDF. PDF4me downloads the file directly before generating the hybrid invoice. The URL must not require authentication.

Output Mode Options

Controls whether the node produces a pure XML file or the full ZUGFeRD hybrid (PDF/A-3 + embedded XML).

Output Mode dropdown in n8n PDF4me Create Zugferd Invoice node showing two options: XML Only with description Generate only the XML file, and XML With PDF highlighted with description Generate XML embedded in PDF

Output Mode dropdown — two options: pure XML or hybrid PDF/A-3 with XML embedded

XML OnlyPure XML — no PDF wrapper
Outputs only the structured XML invoice data. Use when the receiving system processes the XML directly and discards visual content, for XRechnung pure-XML submissions, or for testing the data layer in isolation. Set Output File Name extension to .xml.
XML With PDFDefault — full ZUGFeRD hybrid file
Generates the standard ZUGFeRD hybrid invoice — a PDF/A-3 archival-grade PDF with the structured XML invoice data embedded inside as an attachment. Humans read the PDF, machines parse the XML. This is the canonical ZUGFeRD output for production B2B e-invoicing.

ZUGFeRD Version Options

The ZUGFeRD specification version embedded in the generated invoice.

Zugferd Version dropdown in n8n PDF4me Create Zugferd Invoice node showing options: 1.0, 2.0 highlighted, 2.1, 2.2, 2.4, and Custom, with tooltip showing Parameter: zugferdVersion

ZUGFeRD Version dropdown — six version options including legacy 1.0 and the latest 2.4

1.0Legacy — does not satisfy 2025 mandate
Original 2014 specification. Compatible with legacy receiving systems only. Does not meet the German B2B e-invoicing mandate effective from 2025. Avoid for new workflows.
2.0Default — broad compatibility
The first EN 16931–aligned version (2019). Satisfies the German B2B mandate and is the safe default for general B2B invoicing. Fully compatible with Factur-X 1.0.
2.1Minor refinements
Adds minor schema refinements and clarifications over 2.0. Use when your receiving system specifically requires 2.1.
2.2Updated XRECHNUNG profile
Aligns with the updated XRECHNUNG profile version 2.x. Choose when invoicing German public-sector entities that require the newer profile.
2.4Latest — newest XRECHNUNG support
Latest released specification. Includes support for the most recent XRECHNUNG profile and schema enhancements. Pick when the receiving party requires the latest version.
CustomAdvanced version handling
Enables custom version handling when a non-standard version identifier is required by a specific receiving system. Use only when explicitly instructed by your invoicing counterparty.

Conformance Level Options

The conformance profile controls which invoice fields are required and validated — the most critical choice for compliance.

Conformance Level dropdown in n8n PDF4me Create Zugferd Invoice node showing six options: MINIMUM, BASICWL, BASIC, EN16931 highlighted, EXTENDED, and XRECHNUNG

Conformance Level dropdown — six profiles from MINIMUM to XRECHNUNG, controlling field requirements and compliance scope

MINIMUMHeader only — not a valid invoice
Only header data — parties, totals, document references. No line items. Cannot be used as a legal invoice — only for internal accounting drop-offs or status notifications.
BASICWLBasic Without Lines — VAT only
Adds VAT/tax breakdowns on top of MINIMUM. Still no line items. Used for booking-only scenarios where invoices are reconciled against orders, not as standalone legal invoices.
BASICMinimum legal invoice
Adds line items on top of BASICWL. Meets the absolute minimum of the EU e-invoicing directive. Acceptable for simple invoices, but EN16931 is the safer default for full B2B compliance.
EN16931Default — European Standard
European Standard EN 16931 full profile. The recommended default for B2B invoicing across the EU and the conformance level the German 2025 mandate references. Includes all fields needed for compliant business invoicing.
EXTENDEDIndustry-specific extras
Adds industry-specific fields beyond EN 16931 — for example, additional logistics, freight, or sector-specific references. Use when your industry agreement or trading partner requires the EXTENDED fields.
XRECHNUNGGerman public-sector mandatory
The German XRechnung CIUS profile, mandatory for invoices to German federal, state, and municipal authorities. Stricter validation than EN16931. Use whenever the receiver is a German public-sector entity.

Language Options

Display language for invoice labels in the rendered PDF layer. The XML data itself is language-neutral.

Language dropdown in n8n Create Zugferd Invoice showing German, French, Italian, English, Spanish, Dutch, Polish, and Portuguese

Language — localized labels for the rendered PDF (German is typical for DE B2B and B2G).

German— Default, German B2B/B2G
English— International invoicing
French— Factur-X workflows
Italian— Italian B2B
Spanish— Spanish B2B
Dutch— Netherlands/Belgium
Polish— Poland B2B
Portuguese— Portugal/Brazil

Input Format Options

Format of the invoice data you supply to the node.

Input Format dropdown in n8n Create Zugferd Invoice showing XML, JSON, and CSV options with JSON selected

Input Format — choose XML, JSON, or CSV to match your invoice payload.

XMLPre-built XML invoice
Supply already-formatted ZUGFeRD-compliant XML or UBL XML data. Use when your ERP already produces standard XML invoices that just need wrapping in the hybrid PDF.
JSONDefault — modern API source
Supply invoice data as a structured JSON object. The most common choice when invoice data arrives from a webhook, REST API, or modern accounting software. PDF4me maps JSON fields to the ZUGFeRD XML schema automatically.
CSVTabular batch invoice data
Supply invoice data as CSV — useful for batch invoice exports from spreadsheets, legacy systems, or bulk billing scenarios. PDF4me maps CSV columns to the ZUGFeRD schema.

Invoice Data Input Type Options

Controls how the invoice data (the XML, JSON, or CSV content) reaches the node.

Invoice Data Input Type dropdown in n8n Create Zugferd Invoice showing Direct Text, Binary Data, Base64 String, and URL options

Invoice Data Input Type — how the XML, JSON, or CSV payload is supplied (inline, binary from a prior node, base64, or URL).

Direct TextDefault — paste or map inline
Paste or map the invoice data directly into the Invoice Data field. Best for JSON or smaller CSV payloads from upstream nodes. Use n8n expression syntax to dynamically construct the data.
Binary DataFile from previous node
Reads the invoice data file (XML, JSON, or CSV) directly from the binary output of a previous n8n node — Google Drive Download, Read Binary File, HTTP Request. Best for large XML files.
Base64 StringBase64-encoded data
Accepts the invoice data as a base64-encoded string. Use when invoice content arrives from an API response or database field that stores files as base64.
URLDownload from a public link
Provide a publicly accessible URL to the invoice data file. PDF4me downloads the file and parses the content according to the selected Input Format.

Output Fields

FieldTypeWhat it contains
fileNameStringFilename of the generated ZUGFeRD invoice, for example zugferd_invoice.pdf for XML With PDF output or zugferd_invoice.xml for XML Only output.
mimeTypeStringMIME type of the output file — application/pdf for hybrid output, application/xml for XML Only. Useful for content type validation in downstream HTTP or storage nodes.
fileSizeNumberSize of the generated ZUGFeRD file in bytes. Useful for storage planning, bandwidth monitoring, and conditional routing in the workflow.
successBooleanTrue when the ZUGFeRD invoice was generated successfully. False if validation failed or input data was malformed. Use this field to route error handling branches.
messageStringHuman-readable status message confirming success or describing the validation/parsing error encountered. Useful for logging and error notification steps.

Quick Setup

  1. Add PDF4me to your n8n workflow. Set Resource to Invoice and Invoice Operations to Create Zugferd Invoice.
  2. In Credential to connect with, select your PDF4me credential or click Create New Credential and paste your API key.
  3. Set Input Data Type — connect a previous node (Binary Data), provide a Base64 string or URL for the background PDF, or select None when PDF4me should render the PDF from invoice data alone.
  4. Enter Document Name (for example invoice.pdf).
  5. Set Output ModeXML With PDF for the standard hybrid ZUGFeRD output, or XML Only for pure XML.
  6. Choose Zugferd Version (use 2.0 as the safe default; 2.4 for the latest XRECHNUNG profile).
  7. Choose Conformance LevelEN16931 for general B2B, XRECHNUNG for German public-sector invoicing, EXTENDED for industry-specific fields.
  8. Set Language for the rendered PDF labels (German by default).
  9. Enable Render Invoice On PDF if you want PDF4me to render invoice content visually; disable when supplying a pre-designed background PDF.
  10. Choose Input Format (JSON, XML, or CSV) and Invoice Data Input Type (Direct Text, Binary Data, Base64 String, or URL). Paste or map the invoice data into the Invoice Data field.
  11. Set Output File Name to zugferd_invoice.pdf and Output Binary Field Name to data.
  12. Connect the output to your next node — email sender, cloud storage upload, government portal HTTP POST — and execute the workflow.

Workflow Examples

Workflow ExamplesCommon n8n workflow patterns using Create Zugferd Invoice.
Accounting software → ZUGFeRD 2.0 EN16931 invoice → email customer
  1. A Webhook Trigger fires when an invoice is finalized in the accounting platform (DATEV, sevDesk, lexoffice).
  2. The webhook payload contains invoice data as a structured JSON object.
  3. PDF4me Create Zugferd Invoice generates the hybrid invoice. Input Data Type is None (PDF4me renders the PDF from the JSON). Output Mode is XML With PDF, Zugferd Version is 2.0, Conformance Level is EN16931, Language is German, Input Format is JSON, Invoice Data Input Type is Direct Text mapped from the webhook payload.
  4. A Gmail node emails the ZUGFeRD PDF to the customer's accounts-payable address, satisfying the German B2B receive-mandate requirement.
  5. A PostgreSQL node logs the invoice number, ZUGFeRD version, and conformance level for audit and compliance reporting.
ERP XML invoice → ZUGFeRD XRECHNUNG → upload to public-sector portal
  1. A Schedule Trigger fires every weekday at 16:00 to process public-sector invoices.
  2. An SFTP node pulls newly generated ERP XML invoice files from the export folder.
  3. PDF4me Create Zugferd Invoice generates a compliant XRECHNUNG invoice. Input Data Type is None, Output Mode is XML With PDF, Zugferd Version is 2.4 (latest XRECHNUNG profile), Conformance Level is XRECHNUNG, Language is German, Input Format is XML, Invoice Data Input Type is Binary Data mapped from the SFTP file content.
  4. An HTTP Request node uploads the XRECHNUNG invoice to the federal ZRE (Zentrale Rechnungseingangsplattform des Bundes) or the relevant state portal.
  5. A Microsoft Outlook node sends a confirmation to the procurement team and a PostgreSQL node logs the submission reference.
Monthly CSV billing batch → ZUGFeRD invoices → archive to SharePoint
  1. A Schedule Trigger fires on the 1st of every month to process the monthly billing run.
  2. A Google Drive node downloads the consolidated CSV billing export — one row per customer invoice.
  3. A Split In Batches node iterates over each CSV row. PDF4me Create Zugferd Invoice generates one ZUGFeRD invoice per customer. Input Data Type is None, Output Mode is XML With PDF, Zugferd Version is 2.0, Conformance Level is EN16931, Language varies per customer locale, Input Format is CSV, Invoice Data Input Type is Direct Text with the per-row CSV content.
  4. A Microsoft SharePoint node uploads each ZUGFeRD PDF to the customer's billing archive folder.
  5. A Gmail node sends each customer their hybrid invoice; a final PostgreSQL summary row records the batch run with invoice count and total amount.

Frequently Asked Questions

What is ZUGFeRD and how does it differ from XRechnung and Factur-X?+
ZUGFeRD is the German hybrid e-invoicing standard — a PDF/A-3 archival-grade PDF with structured XML invoice data embedded inside as an attachment. Humans read the visual PDF and machines parse the embedded XML, so a single file serves both audiences. XRechnung is the German public-sector profile, mandatory when invoicing federal, state, or municipal authorities — it can be issued as pure XML or as a ZUGFeRD conformance level. Factur-X is the French sister format that uses the identical hybrid PDF/A-3 + XML structure as ZUGFeRD 2.x and is fully interoperable. Use ZUGFeRD 2.x with EN16931 for general B2B, XRECHNUNG conformance for German public sector, and ZUGFeRD/Factur-X for cross-border French-German invoicing.
Which ZUGFeRD version should I use in 2025 for the German B2B e-invoicing mandate?+
ZUGFeRD 2.0 or higher is required to comply with the German B2B e-invoicing mandate. The mandate, enacted under the Wachstumschancengesetz (Growth Opportunities Act), made e-invoice receipt mandatory from 1 January 2025 and phases in full sending obligations by 2028. Versions 2.0 through 2.4 all comply with EN 16931 — the European standard the mandate references. ZUGFeRD 2.2 and 2.4 add support for the newer XRECHNUNG profile updates. Legacy ZUGFeRD 1.0 does not satisfy the mandate. Default to 2.0 for broad compatibility across receiving systems, or 2.4 when the latest XRECHNUNG profile is required.
What is the difference between MINIMUM, BASICWL, BASIC, EN16931, EXTENDED, and XRECHNUNG conformance levels?+
MINIMUM contains only the absolute minimum invoice header data — totals and parties — and cannot serve as a legal invoice; it is for internal accounting drop-offs only. BASICWL (Basic Without Lines) adds VAT and tax breakdowns but still has no line items. BASIC adds line items and meets the absolute minimum of the EU e-invoicing directive. EN16931 is the European Standard EN 16931 profile, recommended as the default for B2B invoicing across the EU and the level the German mandate references. EXTENDED adds industry-specific fields beyond EN 16931. XRECHNUNG is the German public-sector mandatory profile, required when invoicing federal, state, or municipal authorities. Use EN16931 for general B2B, XRECHNUNG for public sector, EXTENDED for industry-specific scenarios.
What is the difference between XML Only and XML With PDF output modes?+
XML Only generates a pure XML file containing the structured invoice data — useful when the receiving system processes only the XML and discards visual content, for XRechnung pure-XML submissions, or for testing the data layer in isolation. XML With PDF generates the full ZUGFeRD hybrid invoice: a PDF/A-3 archival document with the XML embedded as an attachment inside the PDF. The hybrid format is the canonical ZUGFeRD output and is required when both human readability and machine processing must be supported by a single file. Choose XML With PDF for production e-invoicing workflows and XML Only for data-layer integration testing or pure-XML public-sector submissions.
Can I generate ZUGFeRD invoices from CSV data, and what does Invoice Data Input Type control?+
Yes. The Input Format parameter supports XML, JSON, and CSV — pick the format matching your data source. Invoice Data Input Type then controls how the data reaches the node: Direct Text lets you paste or map the data inline (best for JSON or small CSV from upstream nodes), Binary Data reads from a previous file node (best for large XML files), Base64 String accepts encoded content (best for API payloads), and URL downloads the data file from a public link. CSV input is automatically mapped to the ZUGFeRD XML schema by PDF4me before being embedded in the output PDF — no manual XML construction is required.

Same Task on Other Platforms

Get Help