DRAFT - The specification is currently in development and subject to significant change. It is not ready for limited roll-out or production level use.

MessageHeader (CA:eReC)

Structure Definition: MessageHeader Profile

Canonical URL:http://fhir.infoway-inforoute.ca/io/CA-eReC/StructureDefinition/CA-eReC-MessageHeader

Simplifier project page: MessageHeader

Derived from: MessageHeader (R4)

Formal Views of Profile Content

Description of Profiles, Differentials, Snapshots and how the different presentations work

idS Σ1..1string
metaΣ0..1Meta
implicitRulesΣ ?!0..1uri
language0..1codeBinding
text0..1Narrative
contained0..*Resource
extensionI0..*Extension
modifierExtension?! I0..*Extension
eventCodingCoding
id0..1string
extensionI0..*Extension
modifierExtensionΣ ?! I0..*Extension
nameΣ0..1string
targetΣ I0..1Reference(Device)
endpointS Σ1..1url
id0..1string
extensionI0..*Extension
referenceS Σ I0..1string
typeΣ0..1uriBinding
id0..1string
extensionI0..*Extension
useΣ ?!0..1codeBinding
typeΣ0..1CodeableConceptBinding
systemS Σ1..1uri
valueS Σ1..1string
periodΣ I0..1Period
assignerΣ I0..1Reference(Organization)
displayΣ0..1string
id0..1string
extensionI0..*Extension
referenceS Σ I0..1string
typeΣ0..1uriBinding
id0..1string
extensionI0..*Extension
useΣ ?!0..1codeBinding
typeΣ0..1CodeableConceptBinding
systemS Σ1..1uri
valueS Σ1..1string
periodΣ I0..1Period
assignerΣ I0..1Reference(Organization)
displayΣ0..1string
id0..1string
extensionI0..*Extension
referenceS Σ I0..1string
typeΣ0..1uriBinding
id0..1string
extensionI0..*Extension
useΣ ?!0..1codeBinding
typeΣ0..1CodeableConceptBinding
systemS Σ1..1uri
valueS Σ1..1string
periodΣ I0..1Period
assignerΣ I0..1Reference(Organization)
displayΣ0..1string
id0..1string
extensionI0..*Extension
referenceS Σ I0..1string
typeΣ0..1uriBinding
id0..1string
extensionI0..*Extension
useΣ ?!0..1codeBinding
typeΣ0..1CodeableConceptBinding
systemS Σ1..1uri
valueS Σ1..1string
periodΣ I0..1Period
assignerΣ I0..1Reference(Organization)
displayΣ0..1string
id0..1string
extensionI0..*Extension
modifierExtensionΣ ?! I0..*Extension
nameΣ0..1string
softwareΣ0..1string
versionΣ0..1string
contactΣ I0..1ContactPoint
endpointS Σ1..1url
responsibleΣ I0..1Reference(Practitioner | PractitionerRole | Organization)
reasonS Σ0..1CodeableConcept
id0..1string
extensionI0..*Extension
modifierExtensionΣ ?! I0..*Extension
identifierS Σ1..1id
codeS Σ1..1codeBinding
detailsS Σ I0..1Reference(OperationOutcome)
focusS Σ I1..*Reference(ServiceRequest | Task | Appointment | Communication)
definitionΣ0..1canonical(MessageDefinition)
idS Σ1..1string
metaΣ0..1Meta
implicitRulesΣ ?!0..1uri
language0..1codeBinding
text0..1Narrative
contained0..*Resource
extensionI0..*Extension
modifierExtension?! I0..*Extension
eventCodingCoding
id0..1string
extensionI0..*Extension
modifierExtensionΣ ?! I0..*Extension
nameΣ0..1string
targetΣ I0..1Reference(Device)
endpointS Σ1..1url
id0..1string
extensionI0..*Extension
referenceS Σ I0..1string
typeΣ0..1uriBinding
id0..1string
extensionI0..*Extension
useΣ ?!0..1codeBinding
typeΣ0..1CodeableConceptBinding
systemS Σ1..1uri
valueS Σ1..1string
periodΣ I0..1Period
assignerΣ I0..1Reference(Organization)
displayΣ0..1string
id0..1string
extensionI0..*Extension
referenceS Σ I0..1string
typeΣ0..1uriBinding
id0..1string
extensionI0..*Extension
useΣ ?!0..1codeBinding
typeΣ0..1CodeableConceptBinding
systemS Σ1..1uri
valueS Σ1..1string
periodΣ I0..1Period
assignerΣ I0..1Reference(Organization)
displayΣ0..1string
id0..1string
extensionI0..*Extension
referenceS Σ I0..1string
typeΣ0..1uriBinding
id0..1string
extensionI0..*Extension
useΣ ?!0..1codeBinding
typeΣ0..1CodeableConceptBinding
systemS Σ1..1uri
valueS Σ1..1string
periodΣ I0..1Period
assignerΣ I0..1Reference(Organization)
displayΣ0..1string
id0..1string
extensionI0..*Extension
referenceS Σ I0..1string
typeΣ0..1uriBinding
id0..1string
extensionI0..*Extension
useΣ ?!0..1codeBinding
typeΣ0..1CodeableConceptBinding
systemS Σ1..1uri
valueS Σ1..1string
periodΣ I0..1Period
assignerΣ I0..1Reference(Organization)
displayΣ0..1string
id0..1string
extensionI0..*Extension
modifierExtensionΣ ?! I0..*Extension
nameΣ0..1string
softwareΣ0..1string
versionΣ0..1string
contactΣ I0..1ContactPoint
endpointS Σ1..1url
responsibleΣ I0..1Reference(Practitioner | PractitionerRole | Organization)
reasonS Σ0..1CodeableConcept
id0..1string
extensionI0..*Extension
modifierExtensionΣ ?! I0..*Extension
identifierS Σ1..1id
codeS Σ1..1codeBinding
detailsS Σ I0..1Reference(OperationOutcome)
focusS Σ I1..*Reference(ServiceRequest | Task | Appointment | Communication)
definitionΣ0..1canonical(MessageDefinition)
idS Σ1..1string
metaΣ0..1Meta
implicitRulesΣ ?!0..1uri
language0..1codeBinding
text0..1Narrative
contained0..*Resource
extensionI0..*Extension
modifierExtension?! I0..*Extension
eventCodingCoding
id0..1string
extensionI0..*Extension
modifierExtensionΣ ?! I0..*Extension
nameΣ0..1string
targetΣ I0..1Reference(Device)
endpointS Σ1..1url
id0..1string
extensionI0..*Extension
referenceS Σ I0..1string
typeΣ0..1uriBinding
id0..1string
extensionI0..*Extension
useΣ ?!0..1codeBinding
typeΣ0..1CodeableConceptBinding
systemS Σ1..1uri
valueS Σ1..1string
periodΣ I0..1Period
assignerΣ I0..1Reference(Organization)
displayΣ0..1string
id0..1string
extensionI0..*Extension
referenceS Σ I0..1string
typeΣ0..1uriBinding
id0..1string
extensionI0..*Extension
useΣ ?!0..1codeBinding
typeΣ0..1CodeableConceptBinding
systemS Σ1..1uri
valueS Σ1..1string
periodΣ I0..1Period
assignerΣ I0..1Reference(Organization)
displayΣ0..1string
id0..1string
extensionI0..*Extension
referenceS Σ I0..1string
typeΣ0..1uriBinding
id0..1string
extensionI0..*Extension
useΣ ?!0..1codeBinding
typeΣ0..1CodeableConceptBinding
systemS Σ1..1uri
valueS Σ1..1string
periodΣ I0..1Period
assignerΣ I0..1Reference(Organization)
displayΣ0..1string
id0..1string
extensionI0..*Extension
referenceS Σ I0..1string
typeΣ0..1uriBinding
id0..1string
extensionI0..*Extension
useΣ ?!0..1codeBinding
typeΣ0..1CodeableConceptBinding
systemS Σ1..1uri
valueS Σ1..1string
periodΣ I0..1Period
assignerΣ I0..1Reference(Organization)
displayΣ0..1string
id0..1string
extensionI0..*Extension
modifierExtensionΣ ?! I0..*Extension
nameΣ0..1string
softwareΣ0..1string
versionΣ0..1string
contactΣ I0..1ContactPoint
endpointS Σ1..1url
responsibleΣ I0..1Reference(Practitioner | PractitionerRole | Organization)
reasonS Σ0..1CodeableConcept
id0..1string
extensionI0..*Extension
modifierExtensionΣ ?! I0..*Extension
identifierS Σ1..1id
codeS Σ1..1codeBinding
detailsS Σ I0..1Reference(OperationOutcome)
focusS Σ I1..*Reference(ServiceRequest | Task | Appointment | Communication)
definitionΣ0..1canonical(MessageDefinition)
MessageHeader..
MessageHeader.id1..
MessageHeader.event[x]Coding..
MessageHeader.destination..
MessageHeader.destination.endpoint..
MessageHeader.destination.receiverReference(Practitioner | PractitionerRole | Organization)..
MessageHeader.destination.receiver.reference..
MessageHeader.destination.receiver.identifier..
MessageHeader.destination.receiver.identifier.system1..
MessageHeader.destination.receiver.identifier.value1..
MessageHeader.senderReference(Practitioner | PractitionerRole | Organization)..
MessageHeader.sender.reference..
MessageHeader.sender.identifier..
MessageHeader.sender.identifier.system1..
MessageHeader.sender.identifier.value1..
MessageHeader.entererReference(PractitionerRole | Practitioner)..
MessageHeader.enterer.reference..
MessageHeader.enterer.identifier..
MessageHeader.enterer.identifier.system1..
MessageHeader.enterer.identifier.value1..
MessageHeader.authorReference(PractitionerRole)1..
MessageHeader.author.reference..
MessageHeader.author.identifier..
MessageHeader.author.identifier.system1..
MessageHeader.author.identifier.value1..
MessageHeader.source..
MessageHeader.source.endpoint..
MessageHeader.reason..
MessageHeader.response..
MessageHeader.response.identifier..
MessageHeader.response.code..
MessageHeader.response.details..
MessageHeader.focusReference(ServiceRequest | Task | Appointment | Communication)1..

{
    "resourceType": "StructureDefinition",
    "id": "CA-eReC-MessageHeader",
    "url": "http://fhir.infoway-inforoute.ca/io/CA-eReC/StructureDefinition/CA-eReC-MessageHeader",
    "version": "1.0.0",
    "name": "MessageHeader",
    "title": "MessageHeader",
    "status": "draft",
    "description": "The header for a message exchange that is either requesting or responding to an action. The reference(s) that are the subject of the action as well as other information related to the action are typically transmitted in a bundle in which the MessageHeader resource instance is the first resource in the bundle.",
    "fhirVersion": "4.0.1",
    "kind": "resource",
    "abstract": false,
    "type": "MessageHeader",
    "baseDefinition": "http://hl7.org/fhir/StructureDefinition/MessageHeader",
    "derivation": "constraint",
    "differential": {
        "element":  [
            {
                "id": "MessageHeader.id",
                "path": "MessageHeader.id",
                "min": 1,
                "mustSupport": true
            },
            {
                "id": "MessageHeader.event[x]",
                "path": "MessageHeader.event[x]",
                "mustSupport": true,
                "type":  [
                    {
                        "code": "Coding"
                    }
                ],
                "binding": {
                    "strength": "extensible",
                    "valueSet": "http://fhir.infoway-inforoute.ca/io/CA-eReC/ValueSet/message-event-code"
                }
            },
            {
                "id": "MessageHeader.destination",
                "path": "MessageHeader.destination",
                "mustSupport": true
            },
            {
                "id": "MessageHeader.destination.endpoint",
                "path": "MessageHeader.destination.endpoint",
                "mustSupport": true
            },
            {
                "id": "MessageHeader.destination.receiver",
                "path": "MessageHeader.destination.receiver",
                "type":  [
                    {
                        "code": "Reference",
                        "targetProfile":  [
                            "http://fhir.infoway-inforoute.ca/io/CA-eReC/StructureDefinition/CA-eReC-Practitioner",
                            "http://fhir.infoway-inforoute.ca/io/CA-eReC/StructureDefinition/CA-eReC-PractitionerRole",
                            "http://fhir.infoway-inforoute.ca/io/CA-eReC/StructureDefinition/CA-eReC-Organization"
                        ]
                    }
                ]
            },
            {
                "id": "MessageHeader.destination.receiver.reference",
                "path": "MessageHeader.destination.receiver.reference",
                "mustSupport": true
            },
            {
                "id": "MessageHeader.destination.receiver.identifier",
                "path": "MessageHeader.destination.receiver.identifier",
                "mustSupport": true
            },
            {
                "id": "MessageHeader.destination.receiver.identifier.system",
                "path": "MessageHeader.destination.receiver.identifier.system",
                "min": 1,
                "mustSupport": true
            },
            {
                "id": "MessageHeader.destination.receiver.identifier.value",
                "path": "MessageHeader.destination.receiver.identifier.value",
                "min": 1,
                "mustSupport": true
            },
            {
                "id": "MessageHeader.sender",
                "path": "MessageHeader.sender",
                "type":  [
                    {
                        "code": "Reference",
                        "targetProfile":  [
                            "http://fhir.infoway-inforoute.ca/io/CA-eReC/StructureDefinition/CA-eReC-Practitioner",
                            "http://fhir.infoway-inforoute.ca/io/CA-eReC/StructureDefinition/CA-eReC-PractitionerRole",
                            "http://fhir.infoway-inforoute.ca/io/CA-eReC/StructureDefinition/CA-eReC-Organization"
                        ]
                    }
                ]
            },
            {
                "id": "MessageHeader.sender.reference",
                "path": "MessageHeader.sender.reference",
                "mustSupport": true
            },
            {
                "id": "MessageHeader.sender.identifier",
                "path": "MessageHeader.sender.identifier",
                "mustSupport": true
            },
            {
                "id": "MessageHeader.sender.identifier.system",
                "path": "MessageHeader.sender.identifier.system",
                "min": 1,
                "mustSupport": true
            },
            {
                "id": "MessageHeader.sender.identifier.value",
                "path": "MessageHeader.sender.identifier.value",
                "min": 1,
                "mustSupport": true
            },
            {
                "id": "MessageHeader.enterer",
                "path": "MessageHeader.enterer",
                "type":  [
                    {
                        "code": "Reference",
                        "targetProfile":  [
                            "http://fhir.infoway-inforoute.ca/io/CA-eReC/StructureDefinition/CA-eReC-PractitionerRole",
                            "http://fhir.infoway-inforoute.ca/io/CA-eReC/StructureDefinition/CA-eReC-Practitioner"
                        ]
                    }
                ]
            },
            {
                "id": "MessageHeader.enterer.reference",
                "path": "MessageHeader.enterer.reference",
                "mustSupport": true
            },
            {
                "id": "MessageHeader.enterer.identifier",
                "path": "MessageHeader.enterer.identifier",
                "mustSupport": true
            },
            {
                "id": "MessageHeader.enterer.identifier.system",
                "path": "MessageHeader.enterer.identifier.system",
                "min": 1,
                "mustSupport": true
            },
            {
                "id": "MessageHeader.enterer.identifier.value",
                "path": "MessageHeader.enterer.identifier.value",
                "min": 1,
                "mustSupport": true
            },
            {
                "id": "MessageHeader.author",
                "path": "MessageHeader.author",
                "min": 1,
                "type":  [
                    {
                        "code": "Reference",
                        "targetProfile":  [
                            "http://fhir.infoway-inforoute.ca/io/CA-eReC/StructureDefinition/CA-eReC-PractitionerRole"
                        ],
                        "aggregation":  [
                            "referenced"
                        ]
                    }
                ],
                "mustSupport": true
            },
            {
                "id": "MessageHeader.author.reference",
                "path": "MessageHeader.author.reference",
                "mustSupport": true
            },
            {
                "id": "MessageHeader.author.identifier",
                "path": "MessageHeader.author.identifier",
                "mustSupport": true
            },
            {
                "id": "MessageHeader.author.identifier.system",
                "path": "MessageHeader.author.identifier.system",
                "min": 1,
                "mustSupport": true
            },
            {
                "id": "MessageHeader.author.identifier.value",
                "path": "MessageHeader.author.identifier.value",
                "min": 1,
                "mustSupport": true
            },
            {
                "id": "MessageHeader.source",
                "path": "MessageHeader.source",
                "mustSupport": true
            },
            {
                "id": "MessageHeader.source.endpoint",
                "path": "MessageHeader.source.endpoint",
                "mustSupport": true
            },
            {
                "id": "MessageHeader.reason",
                "path": "MessageHeader.reason",
                "mustSupport": true
            },
            {
                "id": "MessageHeader.response",
                "path": "MessageHeader.response",
                "mustSupport": true
            },
            {
                "id": "MessageHeader.response.identifier",
                "path": "MessageHeader.response.identifier",
                "mustSupport": true
            },
            {
                "id": "MessageHeader.response.code",
                "path": "MessageHeader.response.code",
                "mustSupport": true
            },
            {
                "id": "MessageHeader.response.details",
                "path": "MessageHeader.response.details",
                "mustSupport": true
            },
            {
                "id": "MessageHeader.focus",
                "path": "MessageHeader.focus",
                "min": 1,
                "type":  [
                    {
                        "code": "Reference",
                        "targetProfile":  [
                            "http://fhir.infoway-inforoute.ca/io/CA-eReC/StructureDefinition/CA-eReC-ServiceRequest",
                            "http://fhir.infoway-inforoute.ca/io/CA-eReC/StructureDefinition/CA-eReC-Task",
                            "http://fhir.infoway-inforoute.ca/io/CA-eReC/StructureDefinition/CA-eReC-Appointment",
                            "http://fhir.infoway-inforoute.ca/io/CA-eReC/StructureDefinition/CA-eReC-Communication"
                        ]
                    }
                ],
                "mustSupport": true
            }
        ]
    }
}

Usage

A MessageHeader resource with a unique id and appropriate eventCoding, source.endpoint, destination.endpoint and focus SHALL be the first entry in each message Bundle (CA:eReC).

The MessageHeader is used to convey the purpose of the message (i.e., eventCoding), to direct the receiver toward the information acted upon (i.e., focus) and to support message routing.

Notes

.id

  • Used to uniquely identify a message
  • Populate this element with a UUID each time a message is created
  • Note: a FHIR message contains two identifiers that are unique within the message stream, rules:
    • A MessageHeader.id (this element) SHALL be assigned when the message is created
    • A Bundle.id SHALL be assigned each time the message is sent

.eventCoding

  • Used to convey the business event that triggered the message from MessageEventCode

.destination

  • Used to enable message routing through an intermediary
  • .endpoint SHALL be populated with either:
    • A literal URL that identifies the addresses to which the message should be delivered, or
    • A logical URI (i.e. non-dereferenceable) known to the intermediary.

.sender

  • Identifies who the sending system is

.enterer

  • Identifies who the sending system and/or individual who entered the data to this message

.author

  • Identifies the person who initiated the event
  • SHALL either:
    • .reference a PractitionerRole resource included in the message as a Bundle.entry, or
    • include an .identifier previously known to both systems

.source.endpoint

  • used to enable message routing of responses through an intermediary
  • SHALL be populated with either:
    • A literal URL that identifies the addresses to which the message should be delivered, or
    • A logical URI (i.e. non-dereferenceable) known to the intermediary

.reason

  • Indicates the reason for the event that is the focus of this message, eg. RFI

.response

  • Indicates that a message is a response to a request message (with status)
  • If used:
    • .response.identifier SHALL be populated with the MessageHeader.id of the message to which this message is a response
    • .response.code SHALL be populated with a valid ResponseType
    • .response.details MAY be provided in a referenced OperationOutcome included in the Bundle

.focus

  • Identifies the information acted upon when the message was triggered
  • SHALL include a reference to a ServiceRequest, Task, Appointment, Communication which are included as a message Bundle.entry
  • A MessageHeader MAY include multiple instances of focus to communicate some events