X12 transaction code
EDI 864 Text Message (X12 864)
EDI 864 is the X12 Text Message transaction set, used when a trading partner sends information intended for a recipient. Either party can send an 864, but in practice the retailer, buyer, or 3PL usually sends it to the supplier's EDI or accounting team.
- Standard
- X12
- Code
- 864
- Partner references
- 15
At a glance
EDI 864 at a glance
What the 864 carries, who sends it to whom, when it goes out, and the segments trading partners list for it.
| Document | X12 864 Text Message |
|---|---|
| Business record | Business message |
| Who sends it to whom | Either party can send an 864, but in practice the retailer, buyer, or 3PL usually sends it to the supplier's EDI or accounting team. |
| When it is sent | A buyer's system rejects a supplier document, for example an invoice that fails validation rules, and issues an 864 explaining the errors and requesting a corrected retransmission. |
| Match on | Message reference, subject and related business document |
| Partner references | 15 trading partners in this directory |
| Related documents | X12 850 Purchase Order, X12 824 Application Advice |
Key segments in an EDI 864
The business segments that appear in at least half of the 25 partner document references listed below, most common first. The table leaves out envelope segments (ISA, GS, ST, SE, GE, IEA). Your partner guide sets which segments and elements your account must send.
| Segment | Name | Purpose | Partner references |
|---|---|---|---|
| BMG | Beginning Segment For Text Message | To indicate the beginning of a Text Message Transaction Set. | 25 of 25 |
| MIT | Message Identification | To identify the beginning of a specific message and to allow the identification of a subject for the message. | 25 of 25 |
| MSG | Message Text | To provide a free-form format that allows the transmission of text information. | 25 of 25 |
| N1 | Party Identification | To identify a party by type of organization, name, and code. | 17 of 25 |
| DTM | Date/Time Reference | To specify pertinent dates and times. | 13 of 25 |
Stacksync connects EDI documents such as the X12 864 to your ERP, CRM and databases with two-way sync. Read the EDI overview, check pricing and security, or book a demo to walk through your partner guide.
Implementation guide
X12 864 mapping and validation
X12 864 Text Message is used when a trading partner sends information intended for a recipient. Preserve message reference, subject and related business document so the business message in your business system stays connected to the original document.
Use the version and implementation guide agreed with your trading partner to confirm required fields and responses.
| Document or decision | Record and matching IDs | What to test |
|---|---|---|
| Match the business record | business message message reference, subject and related business document |
|
| Update the receiving system | Processing the business message ID assigned by the receiving system and processing result |
|
| Check the processing result | Processing status for the business message Original document reference and matching response |
|
How the related documents differ
Each message represents a different business event. Use shared references to connect the records while tracking each message’s outcome separately.
- X12 850 Purchase Order
purchase order or sales order: a buyer places an order.
- X12 824 Application Advice
application validation result: a receiving application reports processing results.
Implementation steps
-
Choose the starting event and owner
Decide which application acts when a trading partner sends information intended for a recipient. Name the operational owner of the business message and the team that resolves rejected or ambiguous messages.
-
Keep record IDs connected
Map message reference, subject and related business document. Confirm qualifiers, code lists, units and date/time meaning against the agreed X12 version and partner guide. Preserve the source reference alongside any new destination identifier.
-
Test failures before launch
Run the failure cases in the mapping table against realistic business message data. Check how the receiving system reports a rejection and how your team corrects it without creating a duplicate.
-
Track every document to completion
Record transport delivery and document validation separately from successful business message processing. Give unresolved errors an owner and check the receiving system before approving retries.
Go-live checklist
- An approved 864 sample and the agreed version and partner guide are available.
- The mapping tests pass with realistic business message data.
- Each submitted document can be traced through delivery, validation and processing in the receiving system.
- Your team knows how to investigate and recover a rejected or timed-out business message without processing it twice.
Document structure
X12 864 Text Message at the element level
The X12 864 reference contains 16 segment entries and 52 data elements; 35 are marked mandatory in this reference. Use the version and partner guide agreed for your account to confirm required fields.
- Segments
- 16
- Data elements
- 52
- Mandatory elements
- 35
| Segment | Elements | Mandatory |
|---|---|---|
| BMG | 3 | 1 |
| N1 | 4 | 1 |
| MIT | 1 | 1 |
| N3 | 2 | 1 |
| REF | 2 | 1 |
| PER | 4 | 1 |
| MSG | 1 | 1 |
- Transaction Set Purpose Code
- Entity Identifier Code
- Reference Identification
- Address Information
- Reference Identification Qualifier
- Contact Function Code
- Free-Form Message Text
Find your trading partner for X12 864
15 partners, 25 channels. Choose a channel to inspect its listed document reference and implementation context.
Catalog breakdown
Where X12 864 Text Message appears in this catalog
The largest groups of classified 864 catalog entries are in building & hardware, grocery & food and retail.
By industry
- building & hardware 7 channels
- grocery & food 6 channels
- retail 6 channels
- apparel & footwear 6 channels
By network
- ecUtopia 2 channels
- InterTrade 1 channel
FAQ
EDI 864 questions
What is an EDI 864?
EDI 864 is the X12 Text Message transaction set. Trading partners use it when a trading partner sends information intended for a recipient. It carries the data for the business message, and your system matches it on message reference, subject and related business document.
Who sends an EDI 864 and who receives it?
Either party can send an 864, but in practice the retailer, buyer, or 3PL usually sends it to the supplier's EDI or accounting team. Your trading partner agreement confirms the direction and version for your account.
When is an EDI 864 sent?
A buyer's system rejects a supplier document, for example an invoice that fails validation rules, and issues an 864 explaining the errors and requesting a corrected retransmission. Your partner guide sets any deadline or schedule for the document.
What are the key segments in an EDI 864?
Across 25 partner document references listed here, the business segments that appear most often include BMG (Beginning Segment For Text Message), MIT (Message Identification), MSG (Message Text), N1 (Party Identification), DTM (Date/Time Reference). Each partner guide sets which segments and elements your account must send.
What is the difference between EDI 864 and EDI 850?
The 864 carries the business message and is used when a trading partner sends information intended for a recipient. The 850 carries the purchase order or sales order and is used when a buyer places an order.
What should I map for X12 864?
Start with message reference, subject and related business document and the target business message. Define duplicate detection, allowed updates and response correlation before mapping individual fields. Use the partner guide to check required fields and their formats.
How should I test 864 error handling?
Preserve line breaks and readable content in the receiving work queue. Test an urgent message linked to an order and assign a human owner instead of silently filing it. Also test a lost response after destination processing so that a retry cannot create an unintended duplicate or repeated adjustment.
Which partners list X12 864?
The directory on this page links 15 partner entries that list this message. Choose your partner and channel, then confirm which messages and versions your account requires.
Connect EDI to your business systems
See how Stacksync can fit your enterprise EDI workflow. Bring one partner guide and a sample exchange to plan the system mapping, exception handling and production rollout.




