Skip to content
X12 EDI

Canadian Pacific Railway X12 417 Rail Carrier Waybill Interchange

Plan X12 417 Rail Carrier Waybill Interchange for Canadian Pacific Railway. Connect document identifiers to your business records, test exception handling and track each exchange to completion.

Segments
43
Loops
7
X12 417
Partner references ↗

Implementation guide

Canadian Pacific Railway: 417 mapping and validation

X12 417 Rail Carrier Waybill Interchange is used when rail shipment information passes between carriers. Preserve waybill, originating carrier and equipment so the rail waybill interchange in your business system stays connected to the original document.

This document is listed for Canadian Pacific Railway. Confirm the version, required fields and responses that apply to your account.

Map records and test the business result
Document or decisionRecord and matching IDsWhat to test
Match the business record rail waybill interchange

waybill, originating carrier and equipment

  • Define which combination of waybill, originating carrier and equipment identifies one business record, its lines and any later revision.
Update the receiving system Processing the rail waybill interchange

ID assigned by the receiving system and processing result

  • Preserve originating references when a connecting carrier assigns its own number.
  • Test a waybill correction after interchange and identify which record it supersedes.
Check the processing result Processing status for the rail waybill interchange

Original document reference and matching response

  • Reconcile the rail waybill interchange with the source after a timeout before sending it again. A lost response can occur after the destination has already processed the document.

The document reference includes 43 segments. Use the segment reference below to locate the relevant parts of the message. Check required fields and repetition limits in the partner guide.

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.

Implementation steps

  1. Choose the starting event and owner

    Decide which application acts when rail shipment information passes between carriers. Name the operational owner of the rail waybill interchange and the team that resolves rejected or ambiguous messages.

  2. Keep record IDs connected

    Map waybill, originating carrier and equipment. Confirm qualifiers, code lists, units and date/time meaning against the agreed X12 version and Canadian Pacific Railway guide. Preserve the source reference alongside any new destination identifier.

  3. Test failures before launch

    Run the failure cases in the mapping table against realistic rail waybill interchange data. Check how the receiving system reports a rejection and how your team corrects it without creating a duplicate.

  4. Track every document to completion

    Record transport delivery and document validation separately from successful rail waybill interchange processing. Give unresolved errors an owner and check the receiving system before approving retries.

Go-live checklist

  • An approved 417 sample and the agreed version and partner guide are available.
  • The mapping tests pass with realistic rail waybill interchange 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 rail waybill interchange without processing it twice.

Transaction context

Where 417 Rail Carrier Waybill Interchange fits on Canadian Pacific Railway

Canadian Pacific Railway channels
1 of 1

1 of Canadian Pacific Railway's 1 channel list 417

Trading partners
2

partner references list 417

Channels
2

channel entries list 417

Document structure

X12 417 Rail Carrier Waybill Interchange at the element level

The X12 417 reference contains 63 segment entries and 291 data elements; 76 are marked mandatory in this reference. Use the version and partner guide agreed for your account to confirm required fields.

Segments
63
Data elements
291
Mandatory elements
76
Segments with elements marked mandatory in this reference
Segment Elements Mandatory
ZC1 9 6
BX 9 3
N9 6 1
DTM 4 1
N7 5 1
VC 4 1
N1 4 1
N3 2 1
M12 7 1
M7 4 1
N8 2 2
F9 4 2
Key identifiers in 417
  • Equipment Number
  • Transaction Reference Number
  • Transaction Reference Date
  • Correction Indicator
  • Standard Carrier Alpha Code
  • Transportation Method/Type Code
  • Transaction Set Purpose Code
  • Shipment Method of Payment
Segment reference — 43 segments 7 loops · X12 417 Rail Carrier Waybill Interchange
ISA Interchange Control Header 16 elements

To start and identify an interchange of zero or more functional groups and interchange-related control segments

GS Functional Group Header 8 elements

To indicate the beginning of a functional group and to provide control information

ST Transaction Set Header 2 elements

To indicate the start of a transaction set and to assign a control number

ZC1 Beginning Segment for Data Correction or Change 9 elements

To transmit identifying numbers, dates, and other basic data relating to the transaction set

BX General Shipment Information 9 elements

To transmit identification numbers and other basic shipment data

BNX Rail Shipment Information 2 elements

To transmit rail-specific shipment data

N9 Reference Identification 6 elements

To transmit identifying information as specified by the Reference Identification Qualifier

CM Cargo Manifest 15 elements

To identify specific flight or voyage information for multimodal shipments

DTM Date/Time Reference 4 elements

To specify pertinent dates and times

N7 Loop Repeat: 500
N7 Equipment Details 5 elements

To identify the equipment

VC Loop Repeat: 36
VC Motor Vehicle Control 4 elements

To define motor vehicle identification and logistics

N1 Loop Repeat: 2
N1 Name 4 elements

To identify a party by type of organization, name, and code

N8 Waybill Reference 2 elements

To identify the waybill and to specify the equipment used and the destination details

F9 Origin Station 4 elements

To identify the rail origin of the shipment

D9 Destination Station 4 elements

To identify the rail destination of the shipment

N3 Address Information 1 element

To specify the location of the named party

N4 Geographic Location 4 elements

To specify the geographic place of the named party

BL Billing Information 11 elements

To identify the individual billing segments within a movement when joint rail rates have been established between carriers but do not cover the entire movement

R2 Route Information 5 elements

To specify carrier and routing sequences and details

H3 Special Handling Instructions 1 element

To specify special handling instructions in coded or free-form format

PS Protective Service Instructions 5 elements

To specify mechanical protective service and ventilation instructions

LX Loop Repeat: 25
LX Assigned Number 1 element

To reference a line number in a transaction set

L5 Description, Marks and Numbers 5 elements

To specify the line item in terms of description, quantity, packaging, and marks and numbers

L0 Loop Repeat: 25
L0 Line Item - Quantity and Weight 8 elements

To specify quantity, weight, volume, and type of service for a line item including applicable \"quantity/rate-as\" data

PI Price Authority Identification 11 elements

To communicate basis of pricing, such as contract number, quote number, or tariff number

LS Loop Repeat: 1
LS Loop Header 1 element

To indicate that the next segment begins a loop

LH1 Loop Repeat: 1,000
LH1 Hazardous Identification Information 8 elements

To specify the hazardous commodity identification reference number and quantity

LH2 Hazardous Classification Information 13 elements

To specify the hazardous notation and endorsement information

LH3 Hazardous Material Shipping Name 2 elements

To specify the hazardous material shipping name and additional descriptive requirements

PER Administrative Communications Contact 4 elements

To identify a person or office to whom administrative communications should be directed

LHR Hazardous Material Identifying Reference Numbers 3 elements

To transmit specific hazardous material reference numbers

XH Pro Forma - B13 Information 7 elements

This segment is used to specify a pro forma invoice and B13 Canadian Customs Export Declaration information, required by U.S. and Canadian customs

X7 Customs Information 2 elements

To indicate customs information

SE Transaction Set Trailer 2 elements

To indicate the end of the transaction set and provide the count of the transmitted segments (including the beginning (ST) and ending (SE) segments)

M12 In-bond Identifying Information 7 elements

To transmit in-bond information

M7 Seal Numbers 4 elements

To record seal numbers used and the organization that applied the seals

GA Canadian Grain Information 16 elements

To transmit the transportation and distribution requirements of grain at Canadian ports

X1 Export License 17 elements

To transmit information contained on an export license

LFH Freeform Hazardous Material Information 7 elements

To uniquely identify the variable information required by government regulation covering the transportation of hazardous material shipments

LEP EPA Required Data 1 element

To specify the Environmental Protection Agency (EPA) information relating to shipments of hazardous material

LH4 Canadian Dangerous Requirements 2 elements

To specify additional Transport Canada requirements covering transportation of dangerous goods in Canada

LHT Transborder Hazardous Requirements 1 element

To specify the placard information required by the second government agency when shipment is to cross into another country

LE Loop Trailer 1 element

To indicate that the loop immediately preceding this segment is complete

Related references

Other transactions in Canadian Pacific Railway

Other EDI documents listed on this channel.

Canadian Pacific Railway EDI 417 questions

Common questions about 417 Rail Carrier Waybill Interchange on the Canadian Pacific Railway channel.

What is X12 417 Rail Carrier Waybill Interchange used for?

417 is used when rail shipment information passes between carriers. It carries information for the rail waybill interchange. Match it to your business system using waybill, originating carrier and equipment.

Is 417 required for Canadian Pacific Railway?

417 is listed for Canadian Pacific Railway. Confirm the required version and direction for your business unit and account with the partner.

What should I map for X12 417?

Start with waybill, originating carrier and equipment and the target rail waybill interchange. 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 417 error handling?

Preserve originating references when a connecting carrier assigns its own number. Test a waybill correction after interchange and identify which record it supersedes. Also test a lost response after destination processing so that a retry cannot create an unintended duplicate or repeated adjustment.

How does 417 relate to other EDI messages?

X12 404 Rail Carrier Shipment Information is a related document also listed on Canadian Pacific Railway. Match these documents through their order, shipment or invoice references. Agree which response marks each business step as complete.

What is the difference between 417 and 404?

417 is used when rail shipment information passes between carriers. 404 is used when rail movement instructions are ready for carrier use. Each message represents a different business step. Keep their record references connected and track the processing result for each message.

Connect Canadian Pacific Railway 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.