EDI for Suppliers: Sending EDIFACT Orders and Invoices — Odoo & ERP article by Rui Codex

Suppliers receive EDIFACT ORDERS messages from a buyer through a network or direct connection, convert them into ERP sales orders, and return INVOICE messages built from the same ERP data. The hard work is mapping codes, handling acknowledgements and testing with each buyer, not the message syntax itself.

Key takeaways

  • EDIFACT orders and invoices are structured messages, so the ERP data behind them must be complete and consistent before any mapping starts.
  • Most failures come from item codes, unit of measure, price and tax mismatches, not from the EDI transport itself.
  • Each buyer usually has its own implementation guideline, so every new trading partner needs its own mapping and test cycle.
  • Acknowledgements and error handling must be built as deliberately as the happy path.
  • E-invoicing rules differ by country and by buyer, so the legal requirements should be checked with qualified advisers.

What EDIFACT messages matter for suppliers?

For most suppliers, two messages carry the daily workload: ORDERS, which the buyer sends to request goods, and INVOICE, which the supplier sends to request payment. EDIFACT is the syntax defined under the UN/EDIFACT standard, maintained through the UNECE UN/CEFACT programme. Around these two, expect order responses, dispatch advice and remittance messages, depending on the buyer.

EDIFACT is strict about segment order, qualifiers and code lists. A field that is optional in your ERP may be mandatory in the buyer's implementation guideline. Read that guideline before you write any mapping, because it defines which segments the buyer actually processes.

How does an order get from the buyer into your ERP?

An incoming ORDERS message is received over a value-added network or a direct AS2 connection, parsed, validated against the buyer's rules, and then turned into a sales order in your ERP. Each step can fail independently, so each needs its own log entry and its own alert.

  • Receive and store the raw file before any transformation, so you can prove what arrived.
  • Validate the envelope and message structure against the agreed guideline.
  • Map buyer item identifiers, such as GTIN or the buyer's article number, to your product records.
  • Check quantities, units of measure, prices and delivery dates against your rules and agreed terms.
  • Create the sales order and return a functional acknowledgement or order response.

The mapping table is where most of the effort goes. A single buyer may use one identifier for the product and another for the packaging unit, and the ERP has to know which one drives stock. Keep these mappings in data tables rather than hard-coded logic, so that a new buyer does not require a new code release.

Tip: Reject an order with a clear error reason rather than guessing a missing value. A wrong guess ships the wrong goods, and the correction costs more than the rejection.

How do you send invoices back to the buyer?

An outgoing INVOICE message should be generated from the posted invoice in your ERP, never from a separate spreadsheet. The EDI file then references the order number, the delivery reference and each line the buyer expects to match.

Matching fails most often on price and tax. If the invoice line uses a different unit price or VAT category than the order, the buyer's accounts payable system will typically hold or reject the invoice. Compare every invoice line with the original order line before the file is sent, and log any difference.

Handling credit notes and corrections

Credit notes and corrected invoices should reference the original invoice number explicitly. Avoid reusing invoice numbers, even for corrections, because most buyer systems treat a repeated number as a duplicate.

Does e-invoicing law change what you send?

Yes, in some cases. Directive 2014/55/EU requires contracting authorities in the EU to accept electronic invoices that follow a European standard, and its text is published on EUR-Lex. Whether a given private buyer or public body imposes further requirements is a question for the buyer and for national rules.

This article is general information and not legal or tax advice. Rui Codex provides technical implementation support for EDI and ERP connections, but does not give legal, tax or compliance advice, audits or certification.

Plan for the format first and the legal question second. Ask each buyer which syntax, transport and identifier scheme they accept, and record the answer in the trading partner profile.

Hypothetical examples of a supplier onboarding

Here are two hypothetical scenarios:

  • Scenario one: a supplier of industrial fasteners receives its first ORDERS file from a large retailer. The buyer uses a GTIN for the consumer pack and a separate code for the case. The supplier maps both codes in a table, and the first orders are rejected until the case quantity is converted into single units.
  • Scenario two: a food packaging supplier sends invoices that reference delivery numbers from a warehouse system rather than the buyer's purchase order. Every invoice is rejected by the buyer's payables team until the reference is changed to the order number.

Neither scenario describes a real organisation. They show where the effort usually sits: in identifiers and references, not in the transport.

Where does supplier EDI usually fail?

Supplier EDI usually fails at the boundary between systems, where data is valid in one place and meaningless in another. The transport rarely causes the problem.

  • Master data drift, where a product is renamed or discontinued in the ERP but still active in the buyer's catalogue.
  • Silent acknowledgement gaps, where a message is sent but no functional acknowledgement is checked.
  • Date and time zone errors in delivery windows.
  • Character set problems with names and addresses containing accents.
  • Changes in the buyer's guideline that are never communicated to the supplier.

Integration platforms can help by monitoring these points, but they do not remove the need for clean master data. Our ERP and CRM integration service page describes how these connections are typically built, and the system integration services cover the wider picture.

What should you test before going live?

Testing should follow the message flow, not only the happy path. For each trading partner, a short checklist keeps the work visible.

  1. Send a test ORDERS file with every product type and unit of measure the buyer uses.
  2. Confirm that rejected orders produce a readable error and no sales order.
  3. Check that every invoice line matches its order line in quantity, price and tax.
  4. Test credit notes and corrections against the original invoice number.
  5. Run a full day of traffic in parallel with the existing process before switching off manual steps.
Tip: Keep a test log per buyer with the guideline version used. When a buyer changes its rules, you can see exactly which assumptions to retest.

For a broader view of how supplier connections fit into your integration landscape, the integration and API engineering articles on the Rui Codex blog cover the underlying patterns. If you want help designing the mapping and testing approach for your own ERP, you can request a project consultation, or email info@ruicodex.com to discuss your project.

Frequently Asked Questions

Do I need a value-added network to receive EDIFACT orders?

Not always. Some buyers accept direct AS2 connections, while others require a value-added network or a platform provider. Ask each buyer which transport and onboarding process they use, because the choice affects cost, setup time and support.

What is the difference between ORDERS and INVOICE messages?

ORDERS is sent by the buyer to request goods, and INVOICE is sent by the supplier to request payment. Both reference shared data such as product identifiers, quantities and prices, so mismatches between them are the most common source of rejections.

Can an ERP send EDIFACT files without a middleware layer?

Some ERP systems have native EDI modules, but many require a middleware or integration layer for mapping, transport and monitoring. The right choice depends on the number of trading partners, the complexity of their guidelines and the in-house skills available.

How long does it take to onboard a new buyer?

The timeline depends on the buyer's guideline, the number of document types and the testing they require. Plan for a dedicated test cycle with each buyer, and avoid promising a fixed timeline before the guideline has been reviewed.

Sources

Tags: EDI EDIFACT ERP integration API Integration Workflow Automation Business Process Automation Supplier Management E-invoicing

Need Help Implementing This?

Our team can help you put these insights into practice. From AI automation to custom software development, we build solutions that deliver real results.

Send a project request