Skip to main content
Version: v0.0.2

Interface: TransactionSetSpec

A single ST..SE transaction set. The builder emits ST{idCode}{control}, then each body SegmentSpec, then SE{count}{control} with the segment count (ST..SE inclusive) computed for you.

Example

const tx: TransactionSetSpec = {
transactionSetIdCode: "837",
transactionSetControlNumber: "0001",
implementationConventionReference: "005010X222A2",
segments: [["BHT", "0019", "00", "REF", "20250101", "1200", "CH"]],
};

Properties

implementationConventionReference?

readonly optional implementationConventionReference?: string

ST-03 - implementation convention reference (optional, e.g. "005010X222A2").


segments

readonly segments: readonly SegmentSpec[]

Body segments between ST and SE (excludes ST and SE themselves).


transactionSetControlNumber

readonly transactionSetControlNumber: string

ST-02 / SE-02 - transaction set control number (echoed on SE-02).


transactionSetIdCode

readonly transactionSetIdCode: string

ST-01 - transaction set ID code (e.g. "837", "835", "271").