EN16931 defines a common part (Core Invoice) and allows for national extensions, so-called Core Invoice Usage Specifications, CIUS. XRechnung is the CIUS for invoices to the german authorities. The version 1.2.2 will be replaced as of 2021-01-01 by XRechnung Version 2.
Example: The Core Invoice requires country and email address of the recipient, but according to german §19 UstG an invoice has to bear the street address of the recipient. So the street address is among the attributes which XRechnung there are also additional optional attributes, e.g. the german Skonto (cash discount), despite being usual in Germany, is unusual in the rest of Europe, that’s why it didn’t make it into the Core Invoice.
The XRechnung requirements can be expressed in either UBL or UN/CEFACT XML. A UN/CEFACT XRechnung (like this one) is based on the same schema files, thus identical similar to the file embedded in a ZUGFeRD 2.0 PDF in the EN16931 profile.
|Name||Release date||File format||Hybrid||B2G||B2B with agreements||B2B without agreements||B2C||XML dialect|
|XRechnung 1.0||2017-05-10||.xml||n||y||y||n||n||UBL, UN/CEFACT CII|
|XRechnung 1.1||2017-11-30||.xml||n||y||y||n||n||UBL, UN/CEFACT CII|
|XRechnung 1.2||2018-12-18||.xml||n||y||y||n||n||UBL, UN/CEFACT CII|
|XRechnung 2.0||2020-06-30||.xml||n||y||y||n||n||UBL, UN/CEFACT CII|
|ZUGFeRD 1.0||2014-06-25||y||n||y||y||y||UN/CEFACT CII|
|ZUGFeRD 2.0||2019-03-11||y||y||y||y||y||UN/CEFACT CII|
You can also refer to a german ZUGFeRD/XRechnung comparison.
XRechnung has published open source XSLT style sheets to convert EN16931 XML to HTML, which also work on ZUGFeRD 2 and Factur-X files.
There are Online-Tools to create a UBL-XRechnung data structure.
The idea is that invoices to national authorities are uploaded to central platforms, Chorus in France, ZRE in Germany. The ZRE has a environment for uploads of productive and test invoices and almost certainly runs the open source Kosit validator on the incoming invoices. The same validator is probably used on the OZG-RE, the invoice upload portal for several german states.
For this reason (the central upload) one concept is that the recipient is encoded as a so-called “Leitweg-ID” in the BuyerReference field. There is a specification for a Leitweg ID 2.0 with a checksum, unfortunately previous versions (with no or an unknown checksum) are still wide-spread. The sample mentioned in the 2.0 spec is not a live Leitweg-ID and although the need has been documented there is currently not yet a public complete list or online validator. If you need a Leitweg ID to test, e.g. against the ZRE test portal you may have to use a live one, like the one of the German Weather Service DWD, mentioned by Mr. Dedus in his slides.
On a (german) federal level, Mr. Hauschild summarized in a german speech the situation in german non-federal administration in early 2018: (slides). He recommended a german handbook for the authorities.
Since 2019 Kosit has published a detailed description of the implementation of the states and additionally the VER has a map with information by state.
The XRechnung 2.0 was released June 30th, 2020 and will become mandatory as of January 1st, 2021.
It now has two profiles (standard and extension) and after the release of the specification, the sample files as well as the
schematron validation as well as the Kosit validator configuration
have been updated. Currently, only UBL samples are available for the extension profile.
- A UNCEFACT/XRechnung example is mentioned in the XRechnung page,
- the same invoice also exists as UBL
- Kosit has 26 more UNCEFACT.xml (and according UBL) test instances
- and CenPC434 also published many UN/CEFACT as well as UBL EN16931 examples.
- Schütze Consulting has a XRechnungs generator GUI and offers 50 ZF 1.2 sample files in UBL und UN/CEFACT on a free registration
The permitted attribute values are listed in the Full listing of the code lists as used in EN16931 – version 4.0.