Interface: X12Interchange
The top-level X12 interchange returned by parseX12. isa carries the
envelope header verbatim; delimiters is the four-class delimiter set
detected from fixed positions inside isa.raw; groups is the ordered
GS..GE list; warnings accumulates every Tier-2 deviation observed
during the parse (lenient mode); trailingBytes (when present) is any
non-empty content after IEA - preserved verbatim so a consumer can
inspect or re-emit it.
Example
import { parseX12 } from "@cosyte/x12";
const ix = parseX12(raw);
for (const w of ix.warnings) console.warn(w.code, w.position);
Properties
delimiters
readonlydelimiters:Delimiters
groups
readonlygroups: readonlyX12FunctionalGroup[]
iea
readonlyiea:IeaSegment|undefined
isa
readonlyisa:IsaSegment
profile?
readonlyoptionalprofile?:X12Profile
The trading-partner X12Profile in effect for this parse, if any -
either passed explicitly via options.profile or resolved from the
process-scoped default. Present only when a profile applied; used for
attribution and as the partition basis for partitionWarnings.
ta1Segments
readonlyta1Segments: readonlyTa1Segment[]
trailingBytes?
readonlyoptionaltrailingBytes?:string
warnings
readonlywarnings: readonlyX12ParseWarning[]