E-invoice API
E-invoice API for XRechnung, Factur‑X and ZUGFeRD
Send JSON, get a compliant XRechnung or Factur‑X file back. The API handles the XML schemas and the hybrid PDF, so you skip a custom build for each country.
14 day Sandbox with the full API. No credit card.
POST /einvoice/facturx
{
"template": { "id": 1234567,
"data": { "...": "..." } },
"profile": "en16931",
"output": "base64"
}
factur-x.xml insidePOST /einvoice/xrechnung
{
"data": { "...": "..." },
"type": "UBL",
"output": "base64"
}
<ubl:Invoice>
<cbc:CustomizationID>
urn:cen.eu:en16931:2017
#compliant#urn:xeinkauf.de:
kosit:xrechnung_3.0
</cbc:CustomizationID>
<cbc:ID>RE-2026-114</cbc:ID>
<cac:LegalMonetaryTotal>
<cbc:PayableAmount>
5106.20
...
</ubl:Invoice>
POST /einvoice
{
"data": { "...": "..." },
"type": "CII",
"output": "file"
}
<rsm:CrossIndustryInvoice>
<ram:GuidelineSpecified
DocumentContextParameter>
<ram:ID>
urn:cen.eu:en16931:2017
</ram:ID>
...
<ram:ID>RE-2026-114</ram:ID>
...
</rsm:CrossIndustryInvoice>
You send JSON, the API returns the file. The visible invoice is an example from our free template library.
The basics
What e-invoices are and why your business needs them
Electronic invoicing is the exchange of a structured invoice document in an integrated electronic format.
Unlike a standard PDF or a scanned paper invoice, a true e-invoice carries structured data, usually XML, that accounting and ERP systems process automatically, with no manual data entry.
As governments across Europe move toward mandatory digital reporting, compliant e-invoicing has shifted from a technical convenience to a legal requirement for B2G and B2B. For country details, see our guides for France and Germany.
Mandates, as of November 2026
- GermanyAll companies must be able to receive e-invoices
- BelgiumStructured B2B e-invoices are mandatory
- FranceAll companies receive. Large and mid sized companies issue
- GermanyCompanies with turnover above €800,000 issue
- FranceSmall and micro companies issue
- GermanyAll companies issue
How it works
How the e-invoice API turns JSON into XRechnung or Factur‑X
You do not build an XML engine. Map your fields once, call the endpoint, and receive a validated, compliant file.
Send your JSON
Post the invoice data you already have. The payload follows the Peppol BIS Billing 3.0 invoice model, and GET /einvoice/schema returns the exact structure.
No XML knowledge neededYou map your fields once. The API writes the XML.
{
"data": {
"invoice_number": "...",
"seller": { "...": "..." },
"lines": [ ... ]
}
}
// shape: GET /einvoice/schema
Pick a format
Choose UBL or CII, XRechnung, or a Factur‑X profile in one parameter. For Factur‑X you also send the id of the template that draws the visible invoice.
Get a compliant file
The API returns the file as base64 or as a download, for example a Factur‑X PDF with the XML embedded, ready to send or archive.
Validated on the way outEvery file is checked against the EN 16931 schema before it is returned.
RE-2026-114.pdfFormats
E-invoice formats the API generates
XRechnung, ZUGFeRD, Factur‑X, UBL and CII all implement the European EN 16931 model, so you map your data once.
| Format | Type | Used in | What it is |
|---|---|---|---|
| Factur‑X | Hybrid PDF | France and Germany | A PDF/A-3 invoice your customer reads, with the EN 16931 XML embedded. Try the Factur‑X API |
| ZUGFeRD | Hybrid PDF | Germany | The German hybrid standard, compatible with Factur‑X from version 2.1. |
| XRechnung | XML | Germany, B2G and B2B | Pure XML with no PDF layer, the format German public authorities require. Try the XRechnung API |
| UBL | XML | Across Europe, Peppol | Universal Business Language, carried over the Peppol network. |
| CII | XML | EDI flows | UN/CEFACT Cross Industry Invoice, the syntax inside Factur‑X and ZUGFeRD. |
| EN 16931 | Model | The whole EU | The semantic model behind every format. Map your data once, output any of them. |
No code
E-invoices without code in n8n
Connect your ERP or billing tool to the E-Invoice API with our n8n integration and generate compliant e-invoices from a webhook.
- Trigger on a new invoice in your ERP or billing tool
- Map the fields to the e-invoice JSON once
- Call the E-Invoice API node and store or send the file
Watch the two minute walkthrough, then read the full n8n guide. Building it into your own ERP? See e-invoice infrastructure for ERPs.
Partner program
PDF API partner program for platforms, ISVs and agencies
Partner through a revenue share, partner pricing or a white label deployment. We built the integrations below ourselves, and each one has its own page and tutorial.
Logos belong to their owners and show platforms with a PDF Generator API integration, not members of the partner program. SaaS and ERP vendors can also embed the white label editor with a workspace per customer.
Features
E-invoice API features
What the E-Invoice API includes on every plan.
- EN 16931 standard compliance
- XRechnung XML generation
- Factur‑X hybrid PDF/A-3
- JSON to XML mapping
- Automatic schema validation
- Secure data processing
- Universal UBL and CII support
- Embedded metadata and archiving
- Developer friendly API v4
Questions about the E-Invoice API?
I will walk you through the endpoints, the formats and your compliance timeline in a quick call, or point you to the right guide for your country.
Michal Líška, COO, PDF Generator API
Questions
E-Invoice API FAQ
Formats, EN 16931, the country mandates and the no code route.
Which formats does the E-Invoice API support?
What is EN 16931?
What is the difference between XRechnung, ZUGFeRD and Factur‑X?
Does the API cover the French, Belgian and German mandates?
Do I need to know XML?
Can I generate e-invoices without code?
More services
More PDF services on the same account
Add signing, forms, conversion and accessibility on the same API and account.
Sandbox
Generate your first e-invoice today
The Sandbox gives you the full API, including the e-invoice endpoints, for 14 days with no credit card. Plans are on the pricing page.































