OdooWiki OCA HUB

Base EDIFACT

base_edifact folder_open OCA/edi open_in_new
Tools License: AGPL-3

This module contains methods to generate and parse EDIFACT/D96A files

auto_awesome What this module does

AI-generated from the code · Odoo 16.0

Provides technical building blocks to read and write UN/EDIFACT D96A electronic business documents (orders, invoices, etc.) inside Odoo, converting EDI segments into Odoo-friendly values such as partners, addresses, products, quantities and prices.

This is a technical foundation module, not a screen-based feature. It adds an abstract model base.edifact that other modules can use to generate and parse EDIFACT/D96A files.

What it does: - Reads an EDIFACT file and turns it into a structured Python object, exposing the interchange header and each message with its segments. - Identifies the message type from the UNH segment. - Converts EDI values into Odoo values: dates, partners, delivery/invoice addresses, currencies, products, quantities, unit prices and descriptions. - Builds new EDIFACT segments and interchanges (UNB/UNZ) from Odoo data, with sender, recipient, control reference and syntax identifier.

Business rules visible in the code: - Partner and address mapping recognises GLN identifiers and the agency code 9. - Address mapping only handles delivery (DP) and invoice (IV) parties; other codes return nothing. - Product mapping distinguishes EAN/UPC barcodes from GTIN/SRV codes and can use a supplier article number. - Unit price mapping accepts calculation net (AAA) and calculation gross (AAB) qualifiers, otherwise returns 0.0. - Creating an interchange raises an error if sender, recipient, control reference or syntax identifier is missing.

It depends on account, partner_identification and partner_identification_gln, and requires the external Python library pydifact. No menus or reports are added by this module.

Models and fields (1)
  • base.edifact · new model

Text generated by AI (DeepSeek) from reading the Odoo 16.0 code on GitHub; it may contain mistakes, so check the code before deciding. View the code on GitHub

Availability by version

Reviewed: 2026-11-03
Confirmed (verified in repository and branch) Estimated (unverified) No information

Confirmation status: 1 confirmed, 8 with no information of 9 versions.

terminal Installation and usage

OCA documentation · Odoo 16.0

This module requires 'pydifact' python library.

Requires partner_identification_gln module to store GLN identifiers.

Partner identification code assigned by the European Article Numbering Association.

Use two identification categories:

  • "GLN Identificatin Number". Partner identification like invoice or delivery address.
  • "GCP Identification Number". Global Company Prefix.

If GCP codes are needed in UNB interchange header.

If you need group partners, consider oca/partner-contact/partner_company_group module.

This module doesn't do anything useful by itself, but it is used by several other modules:

  • sale_order_import_edifact that imports EDIFACT/D96A sale orders.
info

Data imported from GitHub: this sheet reflects the latest catalog review, not a live lookup. Always check the module documentation and staging before installing in production.