C-CDA on FHIR, published by HL7 International / Cross-Group Projects. This guide is not an authorized publication; it is the continuous build for version 2.0.0-ballot built by the FHIR (HL7® FHIR® Standard) CI Build. This version is based on the current content of https://github.com/HL7/ccda-on-fhir/ and changes regularly. See the Directory of published versions
This page provides a mapping from CDA to FHIR. For guidance on how to read the table below, see Reading the C-CDA ↔ FHIR Mapping Pages.
Social History is a category of several templates in C-CDA and several profiles in US Core. At a high-level, mappings between CDA <observation>
acts and FHIR Observation resources are similar and are represented by the top table. Differences are documented on the proceeding tables.
Note that some observations in C-CDA map to extensions on the patient or elsewhere in FHIR. In these cases, a FHIR Observation should not be created; instead, the corresponding extension should be used.
This maps to US Core version 6's Simple Observation. Previous versions of US Core did not define a generic observation, but the following guidance can still be used to create a generic FHIR observation regardless of the version of US Core being targeted.
C-CDA Social History Observation |
FHIR Simple Observation |
Transform Steps |
---|---|---|
/id | .identifier | CDA id ↔ FHIR identifier |
.category | Set to social-history from Observation Category CodesAdditional SDOH categories may be set as well, depending on the code of the observation. |
|
/code | .code | CDA coding ↔ FHIR CodeableConcept |
/statusCode | .status | CDA Result Status → FHIR Observation Status |
/effectiveTime | .effectiveDateTime or .effectivePeriod |
Prefer effectiveDateTime CDA ↔ FHIR Time/Dates |
/value[xsi:type=PQ] | .valueQuantity | CDA ↔ FHIR Quantity |
/value[xsi:type=IVL_PQ] | .valueQuantity or .valueRange |
Ranges of Physical Quantities |
/value[xsi:type=CD] (or CE, CV, CO, CS) |
.valueCodeableConcept | CDA coding ↔ FHIR CodeableConcept |
/value[xsi:type=INT] | .valueInteger | |
/value[xsi:type=REAL] | .valueQuantity | Leave unit fields empty |
/value[xsi:type=ST] | .valueString |
Additional fields, such as .interpretationCode
, .referenceRange
, .performer
are not documented in C-CDA but can be mapped in the same manner as Results.
In C-CDA 3.0, the Smoking Status - MU and Tobacco Use templates were merged into a single template to better match the US Core V7 Smoking Status template. In general, the mapping follows the standard Social History mapping above, but additional caveats are noted below.
C-CDA Smoking Status - MU (Deprecated) Tobacco Use (Decprecated) Smoking Status (C-CDA 3.0)² |
FHIR Smoking Status Observation (US Core 4) |
Transform Steps |
---|---|---|
/code | .code | Prior to US Core 7, the code in FHIR should be 72166-2 (Tobacco smoking status NCIS) , but this is an extensible value set, so other codes used in the older C-CDA templates may be used.In US Core 7, the value set remains extensible, but contains the same 4 concepts allowed in the C-CDA R3.0's Smoking Status value set. |
/effectiveTime | .effectiveDateTime or .effectivePeriod |
Smoking Status - MU required a timestamp; Tobacco Use required a time range; Smoking Status (3.0) combines the two templates into one and allows for either. When mapping to US Core be aware of the requirements around effectiveTime. In v7, time can be either a period or a single value. Prior to v7, the Smoking Status Observation only allowed a single timestamp. If Mapping a C-CDA Tobacco Use template that contains a date range, use one of the following approaches: - Map to the US Core 7 version of the Smoking Status Observation - Map to a generic FHIR observation (i.e. do not assert conformance with US Core) - Omit the effectiveTime high value or create a non-conformant US Core Smoking Status Observation |
In US Core, Pregnancy Observation was first defined in version 6.
C-CDA Pregnancy Observation |
FHIR Pregnancy Status |
Transform Steps |
---|---|---|
.moodCode | The C-CDA moodCode is EVN which is why this maps to FHIR's Pregnancy Status rather than Pregnancy Intent. |
|
.code | 82810-3 (Pregnancy Status) - C-CDA uses ASSERTION , but FHIR clarifies the code to be used. |
|
/effectiveTime/@value or /effectiveTime/low/@value or /effectiveTime/high/@value or /author/time |
.effectiveDateTime | FHIR only allows a single timestamp. Send the first element from the first column with a populated timestamp. CDA ↔ FHIR Time/Dates |
/value | .valueCodeableConcept | Value sets are the same CDA coding ↔ FHIR CodeableConcept |
/value/@nullFlavor=UNK | .valueCodeableConcept | Unknown becomes an actual value with system = http://terminology.hl7.org/CodeSystem/v3-NullFlavor . Any other nullFlavors should use a data-absent-reason extension. |
Estimated Date of Delivery /entryRelationship/observation[code/@code="11778-8"]/value |
.component.code .component.valueDateTime |
Set code to 11778-8 and map value to .valueDateTime .Note that while C-CDA hard-codes this to a single value ( 11778-8 ), there are other, more specific, EDD LOINC codes that could be used as well (see EDD Including Method). These might be communicated as translations on the entryRelationship/observation/code, as the methodCode, or sent as entirely custom observations. Any of these codes can also reasonably be included as a component to a Pregnancy Observation to represent the estimated date of delivery. |
In US Core, Pregnancy Intent was first defined in version 6.
C-CDA Pregnancy Intention |
FHIR Pregnancy Intent |
Transform Steps |
---|---|---|
.moodCode | The C-CDA moodCode is INT which is why this maps to FHIR's Pregnancy Status rather than Pregnancy Intent. |
|
/code | .code | In both standards, the code is 86645-9 |
/effectiveTime/low/@value | .effectiveDateTime | FHIR only allows a single timestamp which corresponds to C-CDA's "low" |
/value | .valueCodeableConcept | Value sets are the same CDA coding ↔ FHIR CodeableConcept |
/value/@nullFlavor=UNK | .valueCodeableConcept | Unknown becomes an actual value with system = http://terminology.hl7.org/CodeSystem/v3-NullFlavor . Any other nullFlavors should use a data-absent-reason extension. |
The following is a comparison between C-CDA and FHIR Smoking Status Observations
CDA Example | FHIR Resource |
---|---|
<observation classCode="OBS" moodCode="EVN">
<templateId root="2.16.840.1.113883.10.20.22.4.78"/>
<templateId root="2.16.840.1.113883.10.20.22.4.78"
extension="2014-06-09"/>
<id
extension="123456789"
root="2.16.840.1.113883.19" />
<code
code="72166-2"
codeSystem="2.16.840.1.113883.6.1"
displayName="Tobacco smoking status NHIS"/>
<statusCode code="completed"/>
<effectiveTime value="20140606153200+0000"/>
<value xsi:type="CD"
code="449868002"
codeSystem="2.16.840.1.113883.6.96"
codeSystemName="SNOMED CT"
displayName="Current every day smoker"/>
</observation>
|
{
"resourceType": "Observation",
"id": "62f17e2aa2392d0008fbb23a",
"identifier": [{
"system": "urn:oid:2.16.840.1.113883.19",
"value": "123456789"
}],
"status": "final",
"category": [{
"coding": [{
"system": "http://terminology.hl7.org/CodeSystem/observation-category",
"code": "social-history",
"display": "Social History"
}]
}],
"code": {
"coding": [{
"system": "http://loinc.org",
"code": "72166-2",
"display": "Tobacco smoking status NHIS"
}]
},
"subject": {
"reference": "Patient/62f17e29b7532c0009e217b7"
},
"effectiveDateTime": "2014-06-06T15:32:00.000Z",
"valueCodeableConcept": {
"coding": [{
"system": "http://www.snomed.org/",
"code": "449868002",
"display": "Current every day smoker"
}]
}
}
|
CDA Example | FHIR Resource |
---|---|
<observation classCode="OBS" moodCode="EVN">
<templateId root="2.16.840.1.113883.10.20.15.3.8"/>
<id extension="123456789" root="2.16.840.1.113883.19"/>
<!-- ASSERTION maps to: 82810-3 -->
<code code="ASSERTION" codeSystem="2.16.840.1.113883.5.4"/>
<statusCode code="completed"/>
<effectiveTime>
<low value="20220824103952+0000"/>
</effectiveTime>
<value xsi:type="CD" code="77386006"
displayName="pregnant"
codeSystem="2.16.840.1.113883.6.96"/>
<entryRelationship typeCode="REFR">
<observation classCode="OBS" moodCode="EVN">
<templateId root="2.16.840.1.113883.10.20.15.3.1"/>
<code
code="11778-8"
codeSystem="2.16.840.1.113883.6.1"
displayName="Estimated date of delivery"/>
<text>
<reference value="#dod" />
</text>
<statusCode code="completed"/>
<value xsi:type="TS" value="2023-02-14" />
</observation>
</entryRelationship>
</observation>
|
{
"resourceType": "Observation",
"id": "pregnancy-status",
"identifier": [{
"system": "urn:oid:2.16.840.1.113883.19",
"value": "123456789"
}],
"status": "final",
"category": [{
"coding": [{
"system": "http://terminology.hl7.org/CodeSystem/observation-category",
"code": "social-history",
"display": "Social History"
}]
}],
"code": {
"coding": [{
"system": "http://loinc.org",
"code": "82810-3",
"display": "Pregnancy status"
}]
},
"subject": { "reference": "Patient/example" },
"effectiveDateTime": "2022-08-24T10:39:52Z",
"valueCodeableConcept": {
"coding": [{
"system": "http://snomed.info/sct",
"code": "77386006",
"display": "Pregnant"
}]
},
"component": [{
"code": {
"coding": [{
"system": "http://loinc.org",
"code": "11778-8",
"display": "Delivery date Estimated"
}]
},
"valueDateTime": "2023-02-14"
}]
}
|