HL7 Version 2 to FHIR
1.0.0 - STU 1

HL7 Version 2 to FHIR - Downloaded Version 1.0.0 See the Directory of published versions

## ConceptMap: Segment MSH [Source] to Provenance Map (Experimental)

Official URL: http://hl7.org/fhir/uv/v2mappings/ConceptMap/segment-msh-source-to-provenance | Version: 1.0.0
Standards status: Informative | Computable Name: SegmentMSHSourceToProvenance
Copyright/Legal: Copyright (c) 2025, HL7 International, Inc., All Rights Reserved.

This ConceptMap represents a mapping from the HL7 V2 Segment MSH to the FHIR Provenance Resource.

This ConceptMap represents the mapping from the HL7 V2 MSH Segment to the FHIR Provenance Resource. See also the FHIR Shorthand or the CSV Source.

HL7 v2 | Condition (IF True, args) | HL7 FHIR | Comments
--- | --- | --- | ---
Sort Order | Identifier | Name | Data Type | Cardinality - Min | Cardinality - Max | Computable ANTLR | Computable FHIRPath | Narrative | FHIR Attribute | Extension | Data Type | Cardinality - Min | Cardinality - Max | Data Type Mapping | Vocabulary Mapping (IS, ID, CE, CEN, CWE) | Assignment
0 | MSH |  |  |  |  |  |  | when you hold on to/persist the v2 message in a data store | Provenance.entity.what(Provenance.DocumentReference.content.attachment.url) |  |  |  |  |  |  |  | If there is an interest in holding to the original message by the recipient
0 | MSH |  |  |  |  |  |  | when you do not hold on to/persist the v2 message in a data store | Provenance.entity.what(Provenance.DocumentReference.content.attachment.data) |  |  |  |  |  |  | /v2.txt or v2.xml into base 64/ | If there is an interest in holding to the original message by the recipient
0 | MSH |  |  |  |  |  |  | when you do not hold on to/persist the v2 message in a data store | Provenance.entity.what(Provenance.DocumentReference.status) |  |  |  |  |  |  | "current" | If there is an interest in holding to the original message by the recipient
0 | MSH |  |  |  |  |  |  |  | Provenance.entity.role |  |  |  |  |  |  | "source" |
1 | MSH-1 | Field Separator | ST | 1 | 1 |  |  |  |  |  |  |  |  |  |  |  |
2 | MSH-2 | Encoding Characters | ST | 1 | 1 |  |  |  |  |  |  |  |  |  |  |  |
3 | MSH-3 | Sending Application | HD | 0 | 1 | IF MSH-3 AND MSH-24 VALUED |  |  | Provenance.entity.what(Provenance.Device.identifier) |  | Reference(Provenance.Device) |  |  | HD[Identifier] |  |  |
3 | MSH-3 | Sending Application | HD | 0 | 1 | IF MSH-3 AND MSH-24 VALUED |  |  | Provenance.entity.role |  | code |  |  |  |  | "source" |
4 | MSH-4 | Sending Facility | HD | 0 | 1 | IF MSH-22 NOT VALUED |  |  | Provenance.agent.who(Provenance.Organization) |  | Reference(Provenance.Organization) | 1 | 1 | HD[Organization] |  |  |
4 | MSH-4 | Sending Facility | HD | 0 | 1 | IF MSH-22 NOT VALUED |  |  | Provenance.agent.type.coding.code |  | code | 0 | 1 |  |  | "author" |
4 | MSH-4 | Sending Facility | HD | 0 | 1 | IF MSH-22 NOT VALUED |  |  | Provenance.agent.type.coding.system |  | uri | 0 | 1 |  |  | "http://terminology.hl7.org/CodeSystem/provenance-participant-type" |
5 | MSH-5 | Receiving Application | HD | 0 | 1 |  |  |  |  |  |  |  |  |  |  |  |
6 | MSH-6 | Receiving Facility | HD | 0 | 1 |  |  |  |  |  |  |  |  |  |  |  |
7 | MSH-7 | Date/Time of Message | DTM | 1 | 1 |  |  |  | Provenance.recorded |  |  | 1 | 1 |  |  |  | We note that this could have been mapped to the Provenance.occurred[x] attribute, but since Provenance.recorded is required and these two times are virtually the same, we opted to map to Provenance.recorded.
7 | MSH-7 | Date/Time of Message | DTM | 1 | 1 |  |  |  | Provenance.occurred |  |  | 0 | 1 |  |  |  |
8 | MSH-8 | Security | ST | 0 | 1 |  |  |  |  |  |  |  |  |  |  |  |
9 | MSH-9 | Message Type | MSG | 1 | 1 |  |  |  | Provenance.activity.coding.display |  | string |  |  |  |  | "message - "+MSG.1+"^"+MSG.2+"^"+MSG.3 |
10 | MSH-10 | Message Control ID | ST | 1 | 1 |  |  |  |  |  |  |  |  |  |  |  |
11 | MSH-11 | Processing ID | PT | 1 | 1 |  |  |  |  |  |  |  |  |  |  |  |
12 | MSH-12 | Version ID | VID | 1 | 1 |  |  |  |  |  |  |  |  |  |  |  |
13 | MSH-13 | Sequence Number | NM | 0 | 1 |  |  |  |  |  |  |  |  |  |  |  |
14 | MSH-14 | Continuation Pointer | ST | 0 | 1 |  |  |  |  |  |  |  |  |  |  |  |
15 | MSH-15 | Accept Acknowledgment Type | ID | 0 | 1 |  |  |  |  |  |  |  |  |  |  |  |
16 | MSH-16 | Application Acknowledgment Type | ID | 0 | 1 |  |  |  |  |  |  |  |  |  |  |  |
17 | MSH-17 | Country Code | ID | 0 | 1 |  |  |  |  |  |  |  |  |  |  |  |
18 | MSH-18 | Character Set | ID | 0 | -1 |  |  |  |  |  |  |  |  |  |  |  |
19 | MSH-19 | Principal Language Of Message | CWE | 0 | 1 |  |  |  |  |  |  |  |  |  |  |  |
20 | MSH-20 | Alternate Character Set Handling Scheme | ID | 0 | 1 |  |  |  |  |  |  |  |  |  |  |  |
21 | MSH-21 | Message Profile Identifier | EI | 0 | -1 |  |  |  |  |  |  |  |  |  |  |  | If MSH-21 can be translated into a uri, it can be used to populate Provenance.policy
22 | MSH-22 | Sending Responsible Organization | XON | 0 | 1 |  |  |  | Provenance.agent.who(Provenance.Organization) |  | Reference(Provenance.Organization) | 1 | 1 | XON[Organization] |  |  |
22 | MSH-22 | Sending Responsible Organization | XON | 0 | 1 |  |  |  | Provenance.agent.type.coding.code |  | code | 0 | 1 |  |  | "author" |
22 | MSH-22 | Sending Responsible Organization | XON | 0 | 1 |  |  |  | Provenance.agent.type.coding.system |  | uri | 0 | 1 |  |  | "http://terminology.hl7.org/CodeSystem/provenance-participant-type" |
23 | MSH-23 | Receiving Responsible Organization | XON | 0 | 1 |  |  |  |  |  |  |  |  |  |  |  |
24 | MSH-24 | Sending Network Address | HD | 0 | 1 |  |  |  |  |  |  |  |  |  |  |  |
25 | MSH-25 | Receiving Network Address | HD | 0 | 1 |  |  |  |  |  |  |  |  |  |  |  |
26 | MSH-26 | Security Classification Tag | CWE | 0 | 1 |  |  |  |  |  |  |  |  |  |  |  |
27 | MSH-27 | Security Handling Instructions | CWE | 0 | -1 |  |  |  |  |  |  |  |  |  |  |  |
28 | MSH-28 | Special Access Restriction Instructions | ST | 0 | -1 |  |  |  |  |  |  |  |  |  |  |  |

Mapping from (not specified) to (not specified)

Group 1 Mapping from `unspecified code system` to `unspecified code system`

Source Concept Details | Relationship | Target Concept Details | Comment
Codes from | NarrativeCondition | ComputableANTLR |  | Codes from |
MSH |  | when you hold on to/persist the v2 message in a data store |  | is equivalent to | entity[1].what(DocumentReference.content.attachment.url) | entity[1].what(DocumentReference.content.attachment.url) | If there is an interest in holding to the original message by the recipient
MSH |  | when you do not hold on to/persist the v2 message in a data store |  | is equivalent to | entity[1].what(DocumentReference.content.attachment.data) | entity[1].what(DocumentReference.content.attachment.data) | If there is an interest in holding to the original message by the recipient
MSH |  | when you do not hold on to/persist the v2 message in a data store |  | is equivalent to | entity[1].what(DocumentReference.status) | entity[1].what(DocumentReference.status) | If there is an interest in holding to the original message by the recipient
MSH |  |  |  | is equivalent to | entity[1].role | entity[1].role |
MSH-3 | Sending Application |  | IF MSH-3 AND MSH-24 VALUED | is equivalent to | entity[2].what(Device.identifier) | entity[2].what(Device.identifier) |
MSH-3 | Sending Application |  | IF MSH-3 AND MSH-24 VALUED | is equivalent to | entity[2].role | entity[2].role |
MSH-4 | Sending Facility |  | IF MSH-22 NOT VALUED | is equivalent to | agent[1].who(Organization) | agent[1].who(Organization) |
MSH-4 | Sending Facility |  | IF MSH-22 NOT VALUED | is equivalent to | agent[1].type.coding.code | agent[1].type.coding.code |
MSH-4 | Sending Facility |  | IF MSH-22 NOT VALUED | is equivalent to | agent[1].type.coding.system | agent[1].type.coding.system |
MSH-7 | Date/Time of Message |  |  | is equivalent to | recorded | recorded | We note that this could have been mapped to the Provenance.occurred[x] attribute, but since Provenance.recorded is required and these two times are virtually the same, we opted to map to Provenance.recorded.
MSH-7 | Date/Time of Message |  |  | is equivalent to | occurred | occurred |
MSH-9 | Message Type |  |  | is equivalent to | activity.coding.display | activity.coding.display |
MSH-22 | Sending Responsible Organization |  |  | is equivalent to | agent[2].who(Organization) | agent[2].who(Organization) |
MSH-22 | Sending Responsible Organization |  |  | is equivalent to | agent[2].type.coding.code | agent[2].type.coding.code |
MSH-22 | Sending Responsible Organization |  |  | is equivalent to | agent[2].type.coding.system | agent[2].type.coding.system |

### Notes: