# EDI X12 856 Advance Ship Notice Skeleton Generator for Distributors

> Source: https://netray.co/tools/distributor-edi-x12-856-asn-skeleton-generator
> Publisher: Netray (netray.co), AI and integration engineering for ERP and manufacturing systems.
> Section: Free Tools

## Short answer

Fills an X12 856 skeleton with the segments a distributor typically sends: BSN, HL shipment, order and item loops.

## Category

supply-chain

## Industry

Wholesale Distribution

## Audience

- EDI analyst
- Distribution IT
- ERP integrator

## Tool

**Kind:** template

**Output:** code

**Language:** edi

**Fields:**

#### Sender ID

**Key:** sender_id

**Type:** text

**Default:** SENDERID

#### Receiver ID

**Key:** receiver_id

**Type:** text

**Default:** RECEIVERID

#### Shipment ID

**Key:** shipment_id

**Type:** text

**Default:** SH100234

#### Ship date (CCYYMMDD)

**Key:** ship_date

**Type:** text

**Default:** 20261020

#### Customer PO number

**Key:** po_number

**Type:** text

**Default:** PO778123

#### PO line number

**Key:** line_no

**Type:** text

**Default:** 1

#### Quantity shipped

**Key:** qty

**Type:** number

**Default:** 24

#### Buyer part number

**Key:** buyer_part

**Type:** text

**Default:** BP-4471

#### Carton count

**Key:** carton_count

**Type:** number

**Default:** 3

**Blocks:**

#### 856 skeleton

**Body:** ISA*00*          *00*          *ZZ*{{sender_id}}       *ZZ*{{receiver_id}}     *261020*0900*U*00401*000000101*0*P*>~
GS*SH*{{sender_id}}*{{receiver_id}}*20261020*0900*101*X*004010~
ST*856*0001~
BSN*00*{{shipment_id}}*{{ship_date}}*0900~
HL*1**S~
TD1*CTN*{{carton_count}}~
DTM*011*{{ship_date}}~
HL*2*1*O~
PRF*{{po_number}}~
HL*3*2*I~
LIN*{{line_no}}*BP*{{buyer_part}}~
SN1*{{line_no}}*{{qty}}*EA~
CTT*3~
SE*13*0001~
GE*1*101~
IEA*1*000000101~

**Notes:** This is a generic skeleton. Trading partners publish their own implementation guides that fix the version, required segments, qualifiers, carton (pack) loops and ID formats. Fix the ISA padding to the exact field widths of your partner, update the SE segment count, and test with the partner before production use.

## Content

**Intro:** An 856 advance ship notice tells a customer what is on the truck before it arrives. Distributors send it to retail, government and large contractor customers, and the first draft of a map often starts from a skeleton like this one.

**Sections:**

#### How to use it

**Body:** Fill in sender and receiver IDs, shipment ID, ship date, PO, part and quantity. Copy the output as the target structure for your EDI mapper or as a sample test file. Then compare it with the partner's implementation guide line by line. Their guide wins over any generic example.

**Bullets:**

- Use the partner's ISA qualifiers and widths
- Count segments and update the SE value
- Add pack loops if the partner requires them
- Test in the partner's sandbox first

#### The hierarchy

**Body:** The 856 uses HL segments to build a tree. Here HL 1 is the shipment level, HL 2 is the order level under it, and HL 3 is the item level under the order. Many partners require a pack level (P) between order and item, or tare and pack levels, so confirm the required hierarchy. Each HL carries an ID, a parent ID and a level code.

#### Reading the sample

**Body:** BSN carries the purpose, shipment ID and date. TD1 gives packaging, DTM gives the ship date, PRF references the purchase order, LIN identifies the buyer part with a qualifier, and SN1 gives the shipped quantity and unit. CTT counts the HL segments. SE counts all segments from ST to SE inclusive, so recount after you add loops.

#### Common mistakes

**Body:** Frequent errors are wrong segment counts, mismatched control numbers between ISA and IEA, dates in the wrong format, and sending quantities that do not match the invoice later. Another is sending an ASN before the shipment is confirmed in the ERP, which makes the customer receive data for goods not yet shipped.

**Cta:** If your ASN data is rebuilt by hand from ERP shipments, we can help review the mapping and automate the extract with approval before anything is sent.

**Faq:**

#### Is this skeleton ready to send to a customer?

**Answer:** No. It is a teaching and starting point. Customers define required segments, qualifiers and IDs in their guides, and most will reject a file that does not follow them. Treat it as a draft for your mapper.

#### What does the HL segment do?

**Answer:** HL builds the hierarchy of the document. Each one has its own ID, a parent ID and a level code such as S for shipment, O for order, P for pack and I for item. The tree tells the receiver what is inside what.

#### How do I count the SE value?

**Answer:** Count every segment from ST through SE, including both. In the sample that is 13. If you add or remove any segment, recount before you send.

#### Do I need an EDI provider?

**Answer:** Most distributors use a VAN or an EDI service or an ERP module to handle transport, acknowledgments and mapping. The skeleton helps you plan the map, not replace that connectivity.

## Search terms

x12 856 example, 856 advance ship notice template, edi 856 segments, asn edi skeleton, distributor edi asn, edi hl loop shipment order item, x12 856 sample file, edi 856 mapping

---
Talk to an engineer: https://netray.co/contact?intent=erp_ai | Machine catalog: https://netray.co/agent/catalog.json
