DevToolCase
Sign in Sign in

EDIFACT DESADV: the despatch advice message

The EDIFACT DESADV despatch advice (ASN): its packing hierarchy (CPS, PAC, GIN with SSCC), segments, codes and an annotated EANCOM D96A example.

Where DESADV fits in the exchanges

What is the DESADV message for?

DESADV, the despatch advice, is sent by the supplier when the goods leave: what is shipped, in which packages, for which order, and when it should arrive. It is also called ASN (advance shipping notice). The buyer prepares the receipt with it, and in retail scans the SSCC labels of the pallets against it.

It describes the shipment as a tree: CPS segments give the packing levels (the shipment, then each pallet, then each carton), each level its packages (PAC), their SSCC (GIN) and the items they hold (LIN). The buyer may confirm what arrived with a receiving advice (RECADV). Note that D.96A DESADV has no UNS segment.

Sender: Supplier. Recipient: Buyer.

Structure of the DESADV message

Its main segments, in the order of the D.96A directory. M means mandatory and C conditional, followed by the maximum number of repetitions; for the first segment of a segment group (SG), they apply to the whole group. Rarely used segments are left out.

SegmentGroupStatusWhat it carries
UNH Message header—M 1Message header: the message reference and its type, DESADV:D:96A:UN:EAN005.
BGM Beginning of message—M 1Document type (351 despatch advice) and despatch advice number.
DTM Date/time/period—C 10Document date, despatch date, estimated delivery date.
RFF ReferenceSG1C 10References: order, delivery note.
NAD Name and addressSG2C 10Parties: buyer, supplier, delivery point, shipper.
TDT Details of transportSG6C 10Transport: mode, carrier, vehicle.
CPS Consignment packing sequenceSG10C 9999Packing level: its number and the number of its parent level (the shipment, a pallet…).
PAC PackageSG10 › SG11C 9999Number and type of packages at this level.
PCI Package identificationSG10 › SG11 › SG13C 1000Marking of the packages: an SSCC label (33E).
GIN Goods identity numberSG10 › SG11 › SG13 › SG14C 99SSCC of the package.
LIN Line itemSG10 › SG15C 9999Item packed at this level: line number and GTIN.
PIA Additional product idSG10 › SG15C 10Other item numbers.
QTY QuantitySG10 › SG15C 10Quantity despatched.
DTM Date/time/periodSG10 › SG15C 5Dates of the item, such as its best-before date.
RFF ReferenceSG10 › SG15 › SG16C 10Order and order line the item belongs to.
CNT Control total—C 5Control totals, such as the number of lines.
UNT Message trailer—M 1Message trailer: number of segments and message reference.

Codes worth knowing

SegmentData elementCodeMeaning
BGM1001351Despatch advice
DTM200511Despatch date
DTM200517Estimated delivery date
RFF1153ONOrder number (purchase)
NAD3035DPDelivery party: where the goods go
PCI423333EMarked with an SSCC (EANCOM code)
PCI423330Mark the SSCC (UN code, outside EANCOM)
GIN7405BJSerial shipping container code (SSCC)
QTY606312Despatch quantity
TDT805120Main-carriage transport

Example of DESADV message

UNA:+.? '
UNB+UNOC:3+8712345000011:14+5412345000013:14+261126:0800+DES0001'
UNH+1+DESADV:D:96A:UN:EAN005'
BGM+351+DES5678+9'
DTM+137:20261126:102'
DTM+11:20261126:102'
DTM+17:20261127:102'
RFF+ON:PO12345'
NAD+BY+5412345000013::9'
NAD+SU+8712345000011::9'
NAD+DP+5412345000020::9'
TDT+20++30'
CPS+1'
PAC+1++PX'
CPS+2+1'
PAC+1++PX'
PCI+33E'
GIN+BJ+387123450000000012'
LIN+1++8712345100018:EN'
QTY+12:48'
RFF+ON:PO12345:1'
LIN+2++8712345100025:EN'
QTY+12:10'
RFF+ON:PO12345:2'
CNT+2:2'
UNT+24+1'
UNZ+1+DES0001'
Convert it to JSON

The example, segment by segment

SegmentMeaning
BGM+351+DES5678+9Despatch advice DES5678, original.
DTM+17:20261127:102Delivery expected on 27 November 2026.
TDT+20++30Main carriage (20) by road (30).
CPS+1Level 1: the whole shipment, here one pallet (PAC).
CPS+2+1Level 2, inside level 1: the pallet itself, described by the segments that follow.
PCI+33EThe pallet bears an SSCC label…
GIN+BJ+387123450000000012…with this SSCC (BJ), the number scanned at the receipt.
QTY+12:4848 units of line 1 despatched on this pallet.
RFF+ON:PO12345:2Line 2 of order PO12345.
UNT+24+1End of the message: the number of segments from UNH to UNT included, then the reference given in UNH.

Related messages

In the ANSI X12 standard, used mostly in North America, the equivalent of DESADV is the 856 transaction set (Ship Notice/Manifest), which you can read with the X12 viewer.

Add this browser’s favorites to your account?

This browser has 0 favorites that your account does not have:

Either way, this browser keeps its favorites: you find them again after signing out.