Invoices in Odoo as xml file
The standard Invoice-X
26 January, 2023 by
Invoices in Odoo as xml file
manaTec GmbH, Lisa-Marie Pirnke
 

The introduction of e-billing, which was put into effect by the German government's e-billing ordinance in November 2018, has made it possible to further advance the digitization of business processes to date. It offers the possibility to electronize invoices so that they can be processed further in an automated manner. To create e-invoices, a data standard is used to standardize electronic invoices, the XInvoice, which is a purely digital format based on XML code. Another efficient way to create e-invoices is represented by the Factur-X standard, which is examined in more detail in this article.

The ZUGFeRD data format for electronic invoices (Central User Guide of the Forum Electronic Invoices Germany) makes it possible to make the PDF format readable and also contains a structured XML file in this file. Initially, the Federal Ministry for Economic Affairs and Energy developed ZUGFeRD for the business sector, but in the meantime requirements of administrations and public authorities can also be implemented, as XInvoice is also supported with version 2.1.1. The different requirements for electronic invoices can be controlled with ZUGFeRD via different profiles, such as with low requirement level (BASIC) or higher requirement level (EXTENDED). Due to this field of application, the hybrid format is mainly used in B2B and B2C.

What is Factur-X?

The Factur-X standard is an e-invoicing standard for France and Germany, which makes it possible to implement e-invoicing for companies of all types. The standard is fully compatible and identical to the German version ZUGFeRD 2.0, but the name Factur-X is used internationally. This hybrid format for electronic invoices combines the most common invoice formats PDF and XML. For this purpose, a structured invoice (XML) and a visual invoice (PDF) are embedded in a PDF document for easier further processing.
If we open the Factur-X compliant PDF file as usual via the form view of a customer invoice, the embedded XML code is not directly visible. It can be read by an editor, for example, but the XML code can be read directly by machines when the file is sent.

Faktur-X
Factur-X

The aim of this is to generate a maximum of structured information in this format, which provides added value for suppliers and invoicing parties. Factur- X therefore supports multiple application profiles, as it complies with all the invoice information contained in the European standard EN16931, as well as the required minimum invoice information.

XInvoice vs. Factur-X

Both XInvoice and Factur-X are based on the European standard EN16931, which defines UBL (Universal Business Language) and CII (Cross Industry Invoice) as permissible syntaxes. The XInvoice can be implemented in both syntaxes, but ZUGFeRD and thus Factur-X can only be implemented as CII. In addition, the XInvoice format supports 21 other national business rules and therefore also meets the special requirements of German authorities and administrations. For example, it is mandatory for XInvoice- to specify the routing ID, also known as buyer reference. Compared to Factur-X, the XInvoice is a purely digital format based only on XML code. Therefore, unlike the embedded XML in the PDF file of the Factur-X format, a quick view in the form of a PDF is not possible with the XInvoice. As a sustainable standard, the XInvoice format can be used within Germany, but Factur-X even goes beyond the German national borders and therefore enjoys international acceptance.

Supported application profiles of Factur-X

Due to its wide range of applications, Factur-X supports different profiles that can be accessed. The MINIMUM profile represents the basis, so to speak, in which it provides only essential information about the seller and buyer, as well as the total sales tax and the total invoice amount as an accounting aid. In the BASIC profile, it is already possible to create invoices that comply with the VAT Act. On the other hand, the COMFORT profile (EN 16931) contains all the content required for electronic invoices, which comply with the European standard EN 16931. With the profile EXTENDED Factur-X manages to support different business processes with an extension of EN 16931.

Configuration Factur-X in Odoo

To configure Factur-X in Odoo, we select the "Journals" in the Accounting module under "Configuration". Factur-X can now be set in the "Advanced Settings". However, this setting is usually already given, so no separate configuration is necessary for XFactur.

Konfiguration Faktur-X
Configuration Factur-X

Export of XML files

Factur-X enables an automatic generation of XML files when creating new invoices in the journal. Thus, all XML files can be visualized and extracted, as they are not visible in the PDF view first of all. For this, the debug mode must be enabled. In the Accounting module we open an invoice (under Customers and then Invoices). To open the Factur-X attachment, we click on "Print", then the PDF view of the selected invoice opens and we can extract the Factur-XML file in the attachment.

Export von xml-Dateien
Export of XML files

Extended Tip

Another way to use the XFactur data format in Odoo: Under Settings we open Technical, select Database Structure and Attachments, there all attachments of the whole database can be listed, including the XML files linked to the invoices. To view and extract the XML files of the invoices, we switch to the list view and filter by the resource model: "account.move". The XML files can be extracted directly by using the "File Content (base64)" field in the invoice to download or all invoices can be exported to Excel.

Extended Tip
Extended Tip
Extended Tip
Extended Tip
Extended Tip


With Factur-X you don't have to change your habits, you can send your invoices by e-mail as usual. If one already has a modern accounting software, the Factur-X invoices can be automatically imported as supplier invoices, because they can take advantage of all the benefits of the integrated XML file. Even if one does not yet have modern accounting software, the Factur-X file can be easily opened with a reader, so that the document can also be manually entered as a supplier invoice. 
The advantage of XFactur is that the hybrid format complies with tax regulations and does not incur any additional costs (such as postage costs for sending invoices). This makes data exchange not only faster, but also more secure, which can improve workflow through the optimal process of invoice processing.
On the whole, the electronic exchange of invoices between companies and public authorities and administrations has become even more convenient with the uniform XFactur standard, which means that they are well equipped for future developments in digitalization. 

Are you looking for an ERP system that provides the ideal basis for integrating e-invoices into modern business processes?
Contact us now
, we will be happy to help you!



Sources: www.symtrax.comwww.odoo.comwww.afi-solutions.comwww.awv.net

 
How Odoo 16 and the notes module help with New Year's resolutions
Productive implementation or more appearance than reality?