Automation Blog Pricing Contact

Convert PDF to XRechnung using REST-API

Convert a PDF invoice into a XRechnung-compliant XML document. Our engine reads your invoice data from a PDF, and generates a validated XRechnung XML automatically. XRechnung is Germany's national CIUS (Core Invoice Usage Specification) of the EN 16931 standard and is mandatory for all invoices sent to German federal, state, and municipal authorities.

POST /v1/convert/xrechnung

Request

Parameter Type Description
file * binary The PDF invoice file to convert.

Content-Type: multipart/form-data

Headers

Header Value
Authorization * Bearer YOUR_API_KEY
Content-Type multipart/form-data

Response

200 Returns the XRechnung XML document.
Content-Type: application/xml

Code Example

curl -X POST https://api.invoicexml.com/v1/convert/xrechnung \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -F "[email protected]"

Frequently Asked Questions

What is XRechnung?

XRechnung is the German implementation (CIUS) of EN 16931. It adds stricter validation rules on top of the European core standard and is mandatory for B2G invoicing with German government entities since November 2020.

Do I need a Leitweg-ID?

Yes. German government recipients require a Leitweg-ID (routing identifier) in the BuyerReference field. If the source PDF contains a Leitweg-ID, the API maps it automatically; otherwise, you can supply it as a parameter.

What is the difference between XRechnung and ZUGFeRD?

XRechnung produces a standalone XML file for B2G portals (e.g., ZRE, OZG-RE). ZUGFeRD produces a hybrid PDF with embedded XML, primarily for B2B exchange. Both can satisfy EN 16931 requirements.

Which XRechnung version is generated?

The API generates the latest XRechnung 3.0 specification, aligned with the current KoSIT validation rules.

Where do I submit XRechnung invoices?

XRechnung invoices are typically submitted via the Peppol network or uploaded directly to the ZRE (Zentrale Rechnungseingangsplattform) or OZG-RE portals.