v2MessageStructureDefinition
type: StructureDefinition
node role: treeRoot
id:
  v: v2MessageStructureDefinition
text:
  status:
    v: extensions
  div: Name Flags Card. Type Description & Constraints<img src="[binary]" alt="doco" style="background-color: inherit"/> v2MessageStructureDefinition 0..* Base Base for all types and resources Instances of this logical model are not marked to be the target of a Reference code Σ 1..1 code code name of this message structure, eg. ADT_A01 Binding: hl7VS-messageStructure (required): Message Structure Code title Σ 0..1 string human readable display name description 0..1 Narrative textual description of this message structure messageType 1..1 code Binding: http://terminology.hl7.org/ValueSet/v2plus-vs-message-type (required) steward 0..1 code Binding: steward (required): Steward for this Message Structure triggerEvents 0..* code Binding: event (extensible): What are the associated triggering events? structure 1..* BackboneElement detailed structure This repeating element order: The order of segmentEntry elements defines the structure of the HL7 V2 message. Order SHALL be preserved by all implementations. sequenceNumber 1..1 integer Slices for segment 1..* choice of segment group, segment, or choice Slice: Unordered, Open by value:system segment:SegmentGroup 1..1 group of segments name 1..1 string group of segments structure 1..1 BackboneElement Nested Structure segment:IndividualSegment 1..* individual segments code 1..1 string code for individual segment segment:ChoiceGroup 1..* choice of segments number 1..1 integer number to identify this individual group name 1..1 string groupname structure 1..1 BackboneElement Nested Structure implement 0..1 code This value indicates wheether this segment has to be implemented. The default value is empty, i.e. optional. Binding: v2plus-implement (required) minCardinality 0..1 integer maxCardinality 0..1 integer status 0..1 string <img src="[binary]" alt="doco" style="background-color: inherit"/> Documentation for this format
url:
  v: http://v2.hl7.org/fhir/StructureDefinition/v2MessageStructureDefinition
version:
  v: 1st draft
name:
  v: v2+ Message Structure Definition
title:
  v: v2+ Message Structure Definition
status:
  v: draft
date:
  v: 2023-10-23T14:45:10+02:00
description:
  v: Message Structure Definition
fhir version:
  v: 5.0.0
mapping:
  identity:
    v: rim
  uri:
    v: http://hl7.org/v3
  name:
    v: RIM Mapping
kind:
  v: logical
abstract:
  v: false
type:
  v: v2MessageStructureDefinition
base definition:
  v: http://hl7.org/fhir/StructureDefinition/Base
  link: http://hl7.org/fhir/StructureDefinition/Base
derivation:
  v: specialization
snapshot:
  element:
    id:
      v: v2MessageStructureDefinition
    path:
      v: v2MessageStructureDefinition
    short:
      v: Base for all types and resources
    definition:
      v: Base definition for all types defined in FHIR type system.
    min:
      v: 0
    max:
      v: *
    base:
      path:
        v: Base
      min:
        v: 0
      max:
        v: *
    is modifier:
      v: false
    mapping:
      identity:
        v: rim
      map:
        v: n/a
  element:
    id:
      v: v2MessageStructureDefinition.code
    path:
      v: v2MessageStructureDefinition.code
    short:
      v: code name of this message structure, eg. ADT_A01
    min:
      v: 1
    max:
      v: 1
    base:
      path:
        v: v2MessageStructureDefinition.code
      min:
        v: 1
      max:
        v: 1
    type:
      code:
        v: code
    is summary:
      v: true
    binding:
      strength:
        v: required
      description:
        v: Message Structure Code
      value set:
        v: http://terminology.hl7.org/ValueSet/v2-0354
        link: http://terminology.hl7.org/ValueSet/v2-0354
  element:
    id:
      v: v2MessageStructureDefinition.title
    path:
      v: v2MessageStructureDefinition.title
    short:
      v: human readable display name
    min:
      v: 0
    max:
      v: 1
    base:
      path:
        v: v2MessageStructureDefinition.title
      min:
        v: 0
      max:
        v: 1
    type:
      code:
        v: string
      profile:
        v: http://hl7.org/fhir/StructureDefinition/string
        link: http://hl7.org/fhir/StructureDefinition/string
    is summary:
      v: true
  element:
    short:
      v: textual description of this message structure
    min:
      v: 0
    max:
      v: 1
    base:
      min:
        v: 0
      max:
        v: 1
    type:
      code:
        v: Narrative
      profile:
        v: http://hl7.org/fhir/StructureDefinition/Narrative
        link: http://hl7.org/fhir/StructureDefinition/Narrative
  element:
    min:
      v: 1
    max:
      v: 1
    base:
      min:
        v: 1
      max:
        v: 1
    type:
      code:
        v: code
    binding:
      strength:
        v: required
      value set:
        v: http://terminology.hl7.org/ValueSet/v2plus-vs-message-type
        link: http://terminology.hl7.org/ValueSet/v2plus-vs-message-type
  element:
    id:
      v: v2MessageStructureDefinition.steward
    path:
      v: v2MessageStructureDefinition.steward
    min:
      v: 0
    max:
      v: 1
    base:
      path:
        v: v2MessageStructureDefinition.steward
      min:
        v: 0
      max:
        v: 1
    type:
      code:
        v: code
    binding:
      strength:
        v: required
      description:
        v: Steward for this Message Structure
      value set:
        v: steward
  element:
    min:
      v: 0
    max:
      v: *
    base:
      min:
        v: 0
      max:
        v: *
    type:
      code:
        v: code

strength:
  v: extensible
description:
  v: What are the associated triggering events?
value set:
  v: event

id:
  v: v2MessageStructureDefinition.structure
path:
  v: v2MessageStructureDefinition.structure
short:
  v: detailed structure
min:
  v: 1
max:
  v: *
base:
  path:
    v: v2MessageStructureDefinition.structure
  min:
    v: 1
  max:
    v: *
type:
  code:
    v: BackboneElement
order meaning:
  v: The order of segmentEntry elements defines the structure of the HL7 V2 message. Order SHALL be preserved by all implementations.
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element

representation:
  v: xmlAttr
short:
  v: Unique id for inter-element referencing
definition:
  v: Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Element.id
  min:
    v: 0
  max:
    v: 1
type:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
    value:
      v: id
  code:
    v: http://hl7.org/fhirpath/System.String
condition:
  v: ele-1
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

slicing:
  discriminator:
    type:
      v: value
    path:
      v: url
  description:
    v: Extensions are always sliced by (at least) url
  rules:
    v: open
short:
  v: Additional content defined by implementations
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
alias:
  v: extensions
alias:
  v: user content
min:
  v: 0
max:
  v: *
base:
  path:
    v: Element.extension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
constraint:
  key:
    v: ext-1
  severity:
    v: error
  human:
    v: Must have either extensions or value[x], not both
  expression:
    v: extension.exists() != value.exists()
  source:
    v: http://hl7.org/fhir/StructureDefinition/Extension
    link: http://hl7.org/fhir/StructureDefinition/Extension
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

short:
  v: Extensions that cannot be ignored even if unrecognized
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions. Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
requirements:
  v: Modifier extensions allow for extensions that *cannot* be safely ignored to be clearly distinguished from the vast majority of extensions which can be safely ignored. This promotes interoperability by eliminating the need for implementers to prohibit the presence of extensions. For further information, see the [definition of modifier extensions](http://hl7.org/fhir/R5/extensibility.html#modifierExtension).
alias:
  v: extensions
alias:
  v: user content
alias:
  v: modifiers
min:
  v: 0
max:
  v: *
base:
  path:
    v: BackboneElement.modifierExtension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
constraint:
  key:
    v: ext-1
  severity:
    v: error
  human:
    v: Must have either extensions or value[x], not both
  expression:
    v: extension.exists() != value.exists()
  source:
    v: http://hl7.org/fhir/StructureDefinition/Extension
    link: http://hl7.org/fhir/StructureDefinition/Extension
is modifier:
  v: true
is modifier reason:
  v: Modifier extensions are expected to modify the meaning or interpretation of the element that contains them
is summary:
  v: true
mapping:
  identity:
    v: rim
  map:
    v: N/A

min:
  v: 1
max:
  v: 1
base:
  min:
    v: 1
  max:
    v: 1
type:
  code:
    v: integer
  profile:
    v: http://hl7.org/fhir/StructureDefinition/integer
    link: http://hl7.org/fhir/StructureDefinition/integer

slice name:
  v: SegmentGroup
slicing:
  discriminator:
    type:
      v: value
    path:
      v: system
  rules:
    v: open
short:
  v: group of segments
min:
  v: 1
max:
  v: 1
base:
  min:
    v: 1
  max:
    v: 1

short:
  v: groupname
min:
  v: 1
max:
  v: 1
base:
  min:
    v: 1
  max:
    v: 1
type:
  code:
    v: string
  profile:
    v: http://hl7.org/fhir/StructureDefinition/string
    link: http://hl7.org/fhir/StructureDefinition/string

short:
  v: Nested Structure
min:
  v: 1
max:
  v: 1
base:
  min:
    v: 1
  max:
    v: 1
type:
  code:
    v: BackboneElement

slice name:
  v: IndividualSegment
short:
  v: individual segments
min:
  v: 1
max:
  v: *
base:
  min:
    v: 1
  max:
    v: *

short:
  v: code for individual segment
min:
  v: 1
max:
  v: 1
base:
  min:
    v: 1
  max:
    v: 1
type:
  code:
    v: code
  profile:
    v: http://hl7.org/fhir/StructureDefinition/string
    link: http://hl7.org/fhir/StructureDefinition/string

slice name:
  v: ChoiceGroup
short:
  v: choice of segments
min:
  v: 1
max:
  v: *
base:
  min:
    v: 1
  max:
    v: *

short:
  v: number to identify this individual group
min:
  v: 1
max:
  v: 1
base:
  min:
    v: 1
  max:
    v: 1
type:
  code:
    v: integer
  profile:
    v: http://hl7.org/fhir/StructureDefinition/integer
    link: http://hl7.org/fhir/StructureDefinition/integer

short:
  v: This value indicates wheether this segment has to be implemented. The default value is empty, i.e. optional.
min:
  v: 0
max:
  v: 1
base:
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: code
  profile:
    v: http://hl7.org/fhir/StructureDefinition/code
    link: http://hl7.org/fhir/StructureDefinition/code
binding:
  strength:
    v: required
  value set:
    v: v2plus-implement

min:
  v: 0
max:
  v: 1
base:
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: integer
  profile:
    v: http://hl7.org/fhir/StructureDefinition/integer
    link: http://hl7.org/fhir/StructureDefinition/integer

min:
  v: 0
max:
  v: 1
base:
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: integer
  profile:
    v: http://hl7.org/fhir/StructureDefinition/integer
    link: http://hl7.org/fhir/StructureDefinition/integer

definition:
  v: Specify the concept domain if it is a coded element
min:
  v: 0
max:
  v: 1
base:
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
  profile:
    v: http://hl7.org/fhir/StructureDefinition/string
    link: http://hl7.org/fhir/StructureDefinition/string

element:
  id:
    v: v2MessageStructureDefinition
  path:
    v: v2MessageStructureDefinition
  min:
    v: 0
  max:
    v: *
element:
  id:
    v: v2MessageStructureDefinition.code
  path:
    v: v2MessageStructureDefinition.code
  short:
    v: code name of this message structure, eg. ADT_A01
  min:
    v: 1
  max:
    v: 1
  type:
    code:
      v: code
  is summary:
    v: true
  binding:
    strength:
      v: required
    description:
      v: Message Structure Code
    value set:
      v: http://terminology.hl7.org/ValueSet/v2-0354
      link: http://terminology.hl7.org/ValueSet/v2-0354
element:
  id:
    v: v2MessageStructureDefinition.title
  path:
    v: v2MessageStructureDefinition.title
  short:
    v: human readable display name
  min:
    v: 0
  max:
    v: 1
  type:
    code:
      v: string
    profile:
      v: http://hl7.org/fhir/StructureDefinition/string
      link: http://hl7.org/fhir/StructureDefinition/string
  is summary:
    v: true
element:
  short:
    v: textual description of this message structure
  min:
    v: 0
  max:
    v: 1
  type:
    code:
      v: Narrative
    profile:
      v: http://hl7.org/fhir/StructureDefinition/Narrative
      link: http://hl7.org/fhir/StructureDefinition/Narrative
element:
  min:
    v: 1
  max:
    v: 1
  type:
    code:
      v: code
  binding:
    strength:
      v: required
    value set:
      v: http://terminology.hl7.org/ValueSet/v2plus-vs-message-type
      link: http://terminology.hl7.org/ValueSet/v2plus-vs-message-type
element:
  id:
    v: v2MessageStructureDefinition.steward
  path:
    v: v2MessageStructureDefinition.steward
  min:
    v: 0
  max:
    v: 1
  type:
    code:
      v: code
  binding:
    strength:
      v: required
    description:
      v: Steward for this Message Structure
    value set:
      v: steward
element:
  min:
    v: 0
  max:
    v: *
  type:
    code:
      v: code
  binding:
    strength:
      v: extensible
    description:
      v: What are the associated triggering events?
    value set:
      v: event
element:
  id:
    v: v2MessageStructureDefinition.structure
  path:
    v: v2MessageStructureDefinition.structure
  short:
    v: detailed structure
  min:
    v: 1
  max:
    v: *
  type:
    code:
      v: BackboneElement
  order meaning:
    v: The order of segmentEntry elements defines the structure of the HL7 V2 message. Order SHALL be preserved by all implementations.
element:
  min:
    v: 1
  max:
    v: 1
  type:
    code:
      v: integer
    profile:
      v: http://hl7.org/fhir/StructureDefinition/integer
      link: http://hl7.org/fhir/StructureDefinition/integer
element:
  slicing:
    discriminator:
      type:
        v: value
      path:
        v: system
    rules:
      v: open
  short:
    v: choice of segment group, segment, or choice
  min:
    v: 1
  max:
    v: *
element:
  slice name:
    v: SegmentGroup
  short:
    v: group of segments
  min:
    v: 1
  max:
    v: 1
element:
  short:
    v: group of segments
  min:
    v: 1
  max:
    v: 1
  type:
    code:
      v: string
    profile:
      v: http://hl7.org/fhir/StructureDefinition/string
      link: http://hl7.org/fhir/StructureDefinition/string
element:
  short:
    v: Nested Structure
  min:
    v: 1
  max:
    v: 1
  type:
    code:
      v: BackboneElement
element:
  slice name:
    v: IndividualSegment
  short:
    v: individual segments
  min:
    v: 1
  max:
    v: *
element:
  short:
    v: code for individual segment
  min:
    v: 1

v: 1

code:
  v: code
profile:
  v: http://hl7.org/fhir/StructureDefinition/string
  link: http://hl7.org/fhir/StructureDefinition/string

slice name:
  v: ChoiceGroup
short:
  v: choice of segments
min:
  v: 1
max:
  v: *

short:
  v: number to identify this individual group
min:
  v: 1
max:
  v: 1
type:
  code:
    v: integer
  profile:
    v: http://hl7.org/fhir/StructureDefinition/integer
    link: http://hl7.org/fhir/StructureDefinition/integer

short:
  v: groupname
min:
  v: 1
max:
  v: 1
type:
  code:
    v: string
  profile:
    v: http://hl7.org/fhir/StructureDefinition/string
    link: http://hl7.org/fhir/StructureDefinition/string

min:
  v: 1
max:
  v: 1
type:
  code:
    v: BackboneElement

short:
  v: This value indicates wheether this segment has to be implemented. The default value is empty, i.e. optional.
min:
  v: 0
max:
  v: 1
type:
  code:
    v: code
  profile:
    v: http://hl7.org/fhir/StructureDefinition/code
    link: http://hl7.org/fhir/StructureDefinition/code
binding:
  strength:
    v: required
  value set:
    v: v2plus-implement

min:
  v: 0
max:
  v: 1
type:
  code:
    v: integer
  profile:
    v: http://hl7.org/fhir/StructureDefinition/integer
    link: http://hl7.org/fhir/StructureDefinition/integer

min:
  v: 0
max:
  v: 1
type:
  code:
    v: integer
  profile:
    v: http://hl7.org/fhir/StructureDefinition/integer
    link: http://hl7.org/fhir/StructureDefinition/integer

definition:
  v: Specify the concept domain if it is a coded element
min:
  v: 0
max:
  v: 1
type:
  code:
    v: string
  profile:
    v: http://hl7.org/fhir/StructureDefinition/string
    link: http://hl7.org/fhir/StructureDefinition/string