CNTCND Contractual Conditions (D01B)
This is the standard EANCOM D01B syntax 3 spec, with 22 loops and 47 segment positions, as OpenEDI JSON, an ediFabric C# template and an ediFabric Native model. To change it for a trading partner, customize it in the EDI Spec Builder.
Use the CNTCND spec in your code
ediFabric .NET
Add the C# template and its common files to your project, or reference the template NuGet package, and read CNTCND files into TSCNTCND objects. See ediFabric .NET.
ediFabric Native
Native supports X12 today, and EANCOM is coming. When it's available, map version D01B to this Native model with set_map to parse CNTCND files to JSON from Python, Java, C or C#. See ediFabric Native.
OpenEDI
Select Customize in Spec Builder to copy the spec under your own name, change it for your partner, and parse files against it in EdiNation, ediFabric Native or ediFabric Cloud. Read about OpenEDI.
Generate CNTCND classes in Python, Java, Node.js, Go, Rust or C
The OpenEDI file describes each CNTCND as JSON. To work with CNTCND data as typed objects, generate classes from the OpenEDI file in your language; the root class is TSCNTCND. The classes keep the loops, segments, lengths and code lists, but not the EDI data formats. Read more in Generate a class from OpenEDI.
Python: datamodel-code-generator. Node.js: openapi-typescript. Java, Go, Rust and C: OpenAPI Generator.
CNTCND structure
Loops and segments of the standard CNTCND, with their usage and maximum repeats.
| ID | Name | Usage | Max use |
|---|---|---|---|
| UNH | Message Header | Optional | 1 |
| BGM | BGM | Mandatory | 1 |
| DTM | DTM | Mandatory | 99 |
| PAI | PAI | Optional | 99 |
| TOD | Terms of delivery or transport | Optional | 99 |
| Loop RFF | RFF | Optional | 99 |
| RFF | RFF | Mandatory | 1 |
| DTM | DTM | Optional | 99 |
| Loop PRI | Price details | Optional | 99 |
| PRI | Price details | Mandatory | 1 |
| RNG | RNG | Optional | 99 |
| Loop QTY | QTY | Optional | 99 |
| QTY | QTY | Mandatory | 1 |
| DTM | DTM | Optional | 99 |
| Loop CUX | Currencies | Optional | 99 |
| CUX | Currencies | Mandatory | 1 |
| Loop TAX | TAX | Optional | 99 |
| TAX | TAX | Mandatory | 1 |
| Loop PAT | PAT | Optional | 99 |
| PAT | PAT | Mandatory | 1 |
| DTM | DTM | Optional | 99 |
| PCD | PCD | Optional | 99 |
| Loop SEQ | Sequence details | Mandatory | 99 |
| SEQ | Sequence details | Mandatory | 1 |
| NAD | NAD | Mandatory | 1 |
| Loop CTA | CTA | Optional | 99 |
| CTA | CTA | Mandatory | 1 |
| COM | Communication contact | Optional | 99 |
| Loop ALC | Allowance or charge | Optional | 99 |
| ALC | Allowance or charge | Mandatory | 1 |
| DTM | DTM | Optional | 99 |
| Loop PCD | PCD | Optional | 99 |
| PCD | PCD | Mandatory | 1 |
| RNG | RNG | Optional | 99 |
| Loop MOA | MOA | Optional | 99 |
| MOA | MOA | Mandatory | 1 |
| RNG | RNG | Optional | 99 |
| Loop LIN | Line item | Optional | 99 |
| LIN | Line item | Mandatory | 1 |
| PIA | PIA | Optional | 99 |
| IMD | IMD | Optional | 99 |
| Loop RFF | RFF | Optional | 99 |
| RFF | RFF | Mandatory | 1 |
| DTM | DTM | Optional | 99 |
| Loop TAX | TAX | Optional | 99 |
| TAX | TAX | Mandatory | 1 |
| Loop QTY | QTY | Optional | 99 |
| QTY | QTY | Mandatory | 1 |
| DTM | DTM | Optional | 99 |
| Loop ALC | Allowance or charge | Optional | 99 |
| ALC | Allowance or charge | Mandatory | 1 |
| DTM | DTM | Optional | 99 |
| Loop PCD | PCD | Optional | 99 |
| PCD | PCD | Mandatory | 1 |
| RNG | RNG | Optional | 99 |
| Loop MOA | MOA | Optional | 99 |
| MOA | MOA | Mandatory | 1 |
| RNG | RNG | Optional | 99 |
| Loop PRI | Price details | Optional | 99 |
| PRI | Price details | Mandatory | 1 |
| RNG | RNG | Optional | 99 |
| DTM | DTM | Optional | 99 |
| Loop TOD | Terms of delivery or transport | Optional | 99 |
| TOD | Terms of delivery or transport | Mandatory | 1 |
| Loop PAC | Package | Optional | 99 |
| PAC | Package | Mandatory | 1 |
| Loop NAD | NAD | Optional | 99 |
| NAD | NAD | Mandatory | 1 |
| UNT | Message Trailer | Optional | 1 |