X12 EDI transaction sets, explained

What each document does, who sends it to whom, and what goes wrong on the dock and in accounts payable.

What is X12?

X12 is the standard most North American companies use to exchange business documents between computers. Each document type is a transaction set with a three-digit code: the 850 is a purchase order, the 856 a ship notice, the 810 an invoice. A file is a string of segments (ST, BEG, PO1 and so on) separated by delimiters and wrapped in an ISA and GS envelope. Versions are numbered by release. Retail and manufacturing mostly run 4010, and newer partners ask for 5010.

The standard sets the shape of each document. Every large trading partner then publishes an implementation guide that narrows it: which segments they require, which codes they accept, and how fast they want the document. Most of the work, and most of the chargebacks, live in the gap between that guide and what your ERP actually records.

How do the order-to-cash documents move?

BuyerSupplier850Purchase order855Acknowledgment856Ship notice810Invoice820RemittanceBuyerSupplier850 Purchase order855 Acknowledgment856 Ship notice810 Invoice820 Remittance
Each document is usually answered by a 997 functional acknowledgment, which only confirms it arrived and parsed.

Order to cash

The documents between a buyer and a supplier, from the purchase order to the payment, plus the acknowledgments that ride along.

CodeDocumentWhat it does
850Purchase OrderThe buyer's order: items, quantities, prices, ship-to and dates.
855Purchase Order AcknowledgmentThe supplier accepts, changes or rejects the order, line by line.
860Purchase Order Change Request (buyer initiated)The buyer changes an order it already sent.
865Purchase Order Change Acknowledgment (seller initiated)The supplier answers an 860, or proposes a change of its own.
856Ship Notice/Manifest (ASN)What is on the truck, carton by carton, sent before it arrives.
810InvoiceThe bill for what shipped, tied back to the purchase order.
820Payment Order/Remittance AdviceWhich invoices a payment covers, and what was deducted.
812Credit/Debit AdjustmentA deduction or charge outside the invoice, such as a shortage or pricing claim.
824Application AdviceThe partner's system read the document but rejected its business content.
864Text MessageFree-form text, often compliance notices or rule changes.
997Functional AcknowledgmentConfirms a group of documents arrived and parsed. It says nothing about whether the data was right.
999Implementation AcknowledgmentA 5010-era acknowledgment that also checks guide rules. Mostly used in healthcare.

Warehouse

The documents between the owner of the goods and a third-party warehouse that stores and ships them.

CodeDocumentWhat it does
940Warehouse Shipping OrderTells a 3PL warehouse to pick and ship an order.
945Warehouse Shipping AdviceThe warehouse reports what actually shipped.
943Warehouse Stock Transfer Shipment AdviceThe owner tells the warehouse that inbound stock is on the way.
944Warehouse Stock Transfer Receipt AdviceThe warehouse reports what it received.
947Warehouse Inventory Adjustment AdviceDamage, cycle-count corrections and other changes to stock on hand.

Transportation

The documents between a shipper and a carrier, from the load tender to the freight bill.

CodeDocumentWhat it does
204Motor Carrier Load TenderThe shipper offers a load to a carrier.
990Response to a Load TenderThe carrier accepts or declines the load.
214Transportation Carrier Shipment Status MessagePickup, in-transit and delivery events.
210Motor Carrier Freight Details and InvoiceThe carrier's freight bill, accessorials included.
753Request for Routing InstructionsThe supplier asks the buyer how a collect shipment should move.
754Routing InstructionsThe buyer answers with the carrier and pickup details.

Inventory and pricing

The documents that keep catalogs, stock positions and store lists in step between partners.

CodeDocumentWhat it does
846Inventory Inquiry/AdviceOn-hand and available quantities, usually sent daily.
852Product Activity DataA retailer's sales and stock by item and location.
832Price/Sales CatalogItems, descriptions, UPCs and prices.
816Organizational RelationshipsA partner's list of stores and distribution centers.
180Return Merchandise Authorization and NotificationReturns, requested and approved.

New trading partner sent you an implementation guide?

Send it to us. We will tell you which documents your ERP can already produce, what data is missing, and how long testing usually takes with a partner of that size.