WHO Digital Documentation of COVID-19 Certificates (DDCC)
1.0.1 - release
This page is part of the WHO Digital Documentation of COVID-19 Certificates (DDCC) (v1.0.1: releases Draft) based on FHIR (HL7® FHIR® Standard) R4. This is the current published version. For a full list of available versions, see the Directory of published versions
Draft as of 2024-12-18 |
<StructureMap xmlns="http://hl7.org/fhir">
<id value="CertDCCtoCoreDataSet"/>
<text>
<status value="generated"/>
<div xmlns="http://www.w3.org/1999/xhtml"><p class="res-header-id"><b>Generated Narrative: StructureMap CertDCCtoCoreDataSet</b></p><a name="CertDCCtoCoreDataSet"> </a><a name="hcCertDCCtoCoreDataSet"> </a><a name="CertDCCtoCoreDataSet-en-US"> </a><pre class="fml">
<b>map</b><span style="color: navy"> "</span>http://smart.who.int/ddcc/StructureMap/CertDCCtoCoreDataSet<span style="color: navy">" = "</span>CertDCCtoCoreDataSet<span style="color: navy">"
</span><span style="color: navy">// </span><span style="color: green">Structure map transforming CertDCC logical model to bundle of Core Data Set logical model</span>
<b>uses</b><span style="color: navy"> "</span>http://smart.who.int/ddcc/StructureDefinition/CertDCC<span style="color: navy">" </span><b>alias </b>CWTPayload <b>as </b><b>source</b>
<b>uses</b><span style="color: navy"> "</span><a href="http://hl7.org/fhir/R4/bundle.html" title="Bundle">http://hl7.org/fhir/StructureDefinition/Bundle</a><span style="color: navy">" </span><b>alias </b>DDCCBundle <b>as </b><b>target</b>
<b>uses</b><span style="color: navy"> "</span><a href="StructureDefinition-DDCCCoreDataSet.html" title="DDCC Core Data Set Logical Model">http://smart.who.int/ddcc/StructureDefinition/DDCCCoreDataSet</a><span style="color: navy">" </span><b>alias </b>DDCC <b>as </b><b>target</b>
<b>uses</b><span style="color: navy"> "</span><a href="StructureDefinition-DDCCCoreDataSetVS.html" title="DDCC Core Data Set Logical Model for Vaccination Status">http://smart.who.int/ddcc/StructureDefinition/DDCCCoreDataSetVS</a><span style="color: navy">" </span><b>alias </b>DDCCVS <b>as </b><b>target</b>
<b>uses</b><span style="color: navy"> "</span><a href="StructureDefinition-DDCCCoreDataSetTR.html" title="DDCC Core Data Set Logical Model for Test Result">http://smart.who.int/ddcc/StructureDefinition/DDCCCoreDataSetTR</a><span style="color: navy">" </span><b>alias </b>DDCCTR <b>as </b><b>target</b>
<b>group </b>CertDCCtoCoreDataSet<span style="color: navy">(</span><b>source</b> <span style="color: maroon">src</span><span style="color: navy"> : </span>CWTPayload, <b>target</b> <span style="color: maroon">ddccBundle</span><span style="color: navy"> : </span>DDCCBundle<span style="color: navy">)</span><span style="color: navy"> {
</span> src.-260<b> as </b><span style="color: maroon">hcert</span><b> then</b><span style="color: navy"> {
</span> hcert.1<b> as </b><span style="color: maroon">dcc</span><b> then</b><span style="color: navy"> {
</span> dcc.v<b> as </b><span style="color: maroon">v</span><span style="color: navy"><b> -> </b></span> ddccBundle.entry<b> as </b><span style="color: maroon">outentry</span><span style="color: navy">, </span> <b>create</b><span style="color: navy">(</span><span style="color: blue">'http://smart.who.int/ddcc/StructureDefinition/DDCCCoreDataSetVS'</span><span style="color: navy">)</span><b> as </b><span style="color: maroon">ddcc</span><b> then</b><span style="color: navy"> {
</span> v<b> then </b>DCCtoCoreDataSet<span style="color: navy">(</span><span style="color: maroon">dcc</span><span style="color: navy">, </span><span style="color: maroon">ddcc</span><span style="color: navy">)</span> <i>"set DDCC"</i><span style="color: navy">;</span>
v<span style="color: navy"><b> -> </b></span>ddcc.certificate<b> as </b><span style="color: maroon">certificate</span><b> then </b>CertDCCtoCoreDataSetCertificate<span style="color: navy">(</span><span style="color: maroon">src</span><span style="color: navy">, </span><span style="color: maroon">dcc</span><span style="color: navy">, </span><span style="color: maroon">v</span><span style="color: navy">, </span><span style="color: maroon">certificate</span><span style="color: navy">)</span> <i>"set certificate"</i><span style="color: navy">;</span>
v<span style="color: navy"><b> -> </b></span>ddcc.vaccination<b> as </b><span style="color: maroon">vaccination</span><b> then </b>VtoCoreDataSetVS<span style="color: navy">(</span><span style="color: maroon">v</span><span style="color: navy">, </span><span style="color: maroon">vaccination</span><span style="color: navy">)</span> <i>"set vaccination"</i><span style="color: navy">;</span>
v<span style="color: navy"><b> -> </b></span>outentry.resource = <span style="color: maroon">ddcc</span> <i>"set outentry"</i><span style="color: navy">;</span>
<span style="color: navy">}</span><span style="color: navy">;</span>
dcc.t<b> as </b><span style="color: maroon">t</span><span style="color: navy"><b> -> </b></span> ddccBundle.entry<b> as </b><span style="color: maroon">outentry</span><span style="color: navy">, </span> <b>create</b><span style="color: navy">(</span><span style="color: blue">'http://smart.who.int/ddcc/StructureDefinition/DDCCCoreDataSetTR'</span><span style="color: navy">)</span><b> as </b><span style="color: maroon">ddcc</span><b> then</b><span style="color: navy"> {
</span> t<b> then </b>DCCtoCoreDataSet<span style="color: navy">(</span><span style="color: maroon">dcc</span><span style="color: navy">, </span><span style="color: maroon">ddcc</span><span style="color: navy">)</span> <i>"set DDCC"</i><span style="color: navy">;</span>
t<span style="color: navy"><b> -> </b></span>ddcc.certificate<b> as </b><span style="color: maroon">certificate</span><b> then </b>CertDCCtoCoreDataSetCertificate<span style="color: navy">(</span><span style="color: maroon">src</span><span style="color: navy">, </span><span style="color: maroon">dcc</span><span style="color: navy">, </span><span style="color: maroon">t</span><span style="color: navy">, </span><span style="color: maroon">certificate</span><span style="color: navy">)</span> <i>"set certificate"</i><span style="color: navy">;</span>
t<span style="color: navy"><b> -> </b></span>ddcc.test<b> as </b><span style="color: maroon">test</span><b> then </b>TtoCoreDataSetTR<span style="color: navy">(</span><span style="color: maroon">t</span><span style="color: navy">, </span><span style="color: maroon">test</span><span style="color: navy">)</span> <i>"set test"</i><span style="color: navy">;</span>
t<span style="color: navy"><b> -> </b></span>outentry.resource = <span style="color: maroon">ddcc</span> <i>"set outentry"</i><span style="color: navy">;</span>
<span style="color: navy">}</span><span style="color: navy">;</span>
<span style="color: navy">}</span> <i>"eu_DCC_v1"</i><span style="color: navy">;</span>
<span style="color: navy">}</span> <i>"hcert"</i><span style="color: navy">;</span>
<span style="color: navy">}
</span><b>group </b>DCCtoCoreDataSet<span style="color: navy">(</span><b>source</b> <span style="color: maroon">dcc</span>, <b>target</b> <span style="color: maroon">ddcc</span><span style="color: navy"> : </span>DDCC<span style="color: navy">)</span><span style="color: navy"> {
</span> dcc.dob<b> as </b><span style="color: maroon">birthDate</span><span style="color: navy"><b> -> </b></span>ddcc.birthDate = <span style="color: maroon">birthDate</span> <i>"set birthDate"</i><span style="color: navy">;</span>
dcc.nam<b> as </b><span style="color: maroon">nam</span><b> then</b><span style="color: navy"> {
</span> nam.gn<b> as </b><span style="color: maroon">given</span><span style="color: navy"><b> -> </b></span>ddcc.name = <span style="color: navy">(</span>given.replaceMatches('$', ' ')<span style="color: navy">)</span> <i>"set given name"</i><span style="color: navy">;</span>
nam.fn<b> as </b><span style="color: maroon">family</span><span style="color: navy"><b> -> </b></span> ddcc.name<b> as </b><span style="color: maroon">tName</span><span style="color: navy">, </span> ddcc.name = <b>append</b><span style="color: navy">(</span><span style="color: maroon">tName</span><span style="color: navy">, </span><span style="color: maroon">family</span><span style="color: navy">)</span> <i>"add family name"</i><span style="color: navy">;</span>
<span style="color: navy">}</span><span style="color: navy">;</span>
<span style="color: navy">}
</span><b>group </b>CertDCCtoCoreDataSetCertificate<span style="color: navy">(</span><b>source</b> <span style="color: maroon">src</span><span style="color: navy"> : </span>CWTPayload, <b>source</b> <span style="color: maroon">dcc</span>, <b>source</b> <span style="color: maroon">g</span>, <b>target</b> <span style="color: maroon">certificate</span><span style="color: navy">)</span><span style="color: navy"> {
</span> src<span style="color: navy"><b> -> </b></span>certificate.period = <b>create</b><span style="color: navy">(</span><span style="color: blue">'Period'</span><span style="color: navy">)</span><b> as </b><span style="color: maroon">period</span><b> then </b>CwtToPeriod<span style="color: navy">(</span><span style="color: maroon">src</span><span style="color: navy">, </span><span style="color: maroon">period</span><span style="color: navy">)</span> <i>"set period"</i><span style="color: navy">;</span>
dcc.ver<b> as </b><span style="color: maroon">ver</span><span style="color: navy"><b> -> </b></span>certificate.version = <span style="color: maroon">ver</span> <i>"set version"</i><span style="color: navy">;</span>
g.ci<b> as </b><span style="color: maroon">ci</span><span style="color: navy"><b> -> </b></span> certificate.hcid<b> as </b><span style="color: maroon">hcid</span><span style="color: navy">, </span> hcid.value = <span style="color: maroon">ci</span> <i>"set hcid"</i><span style="color: navy">;</span>
g.is<b> as </b><span style="color: maroon">is</span><span style="color: navy"><b> -> </b></span> certificate.issuer = <b>create</b><span style="color: navy">(</span><span style="color: blue">'Reference'</span><span style="color: navy">)</span><b> as </b><span style="color: maroon">issuer</span><span style="color: navy">, </span> issuer.display = <span style="color: maroon">is</span> <i>"set issuer"</i><span style="color: navy">;</span>
<span style="color: navy">}
</span><b>group </b>CwtToPeriod<span style="color: navy">(</span><b>source</b> <span style="color: maroon">src</span><span style="color: navy"> : </span>CWTPayload, <b>target</b> <span style="color: maroon">tgt</span><span style="color: navy"> : </span>Period<span style="color: navy">)</span><span style="color: navy"> {
</span> src.6<b> as </b><span style="color: maroon">iat</span><span style="color: navy"><b> -> </b></span> <b>append</b><span style="color: navy">(</span><span style="color: maroon">iat</span><span style="color: navy">, </span><span style="color: blue">' seconds'</span><span style="color: navy">)</span><b> as </b><span style="color: maroon">epoch</span><span style="color: navy">, </span> tgt.start = <span style="color: navy">(</span>@1970-01-01T00:00:00.000+00:00 + epoch.toQuantity()<span style="color: navy">)</span> <i>"set period start"</i><span style="color: navy">;</span>
src.4<b> as </b><span style="color: maroon">exp</span><span style="color: navy"><b> -> </b></span> <b>append</b><span style="color: navy">(</span><span style="color: maroon">exp</span><span style="color: navy">, </span><span style="color: blue">' seconds'</span><span style="color: navy">)</span><b> as </b><span style="color: maroon">epoch</span><span style="color: navy">, </span> tgt.end = <span style="color: navy">(</span>@1970-01-01T00:00:00.000+00:00 + epoch.toQuantity()<span style="color: navy">)</span> <i>"set period end"</i><span style="color: navy">;</span>
<span style="color: navy">}
</span><b>group </b>VtoCoreDataSetVS<span style="color: navy">(</span><b>source</b> <span style="color: maroon">v</span>, <b>target</b> <span style="color: maroon">vaccination</span><span style="color: navy">)</span><span style="color: navy"> {
</span> v.tg<b> as </b><span style="color: maroon">tg</span><span style="color: navy"><b> -> </b></span> vaccination.disease<b> as </b><span style="color: maroon">coding</span><span style="color: navy">, </span> coding.system = <span style="color: blue">'http://snomed.info/sct'</span><span style="color: navy">, </span> coding.code = <span style="color: maroon">tg</span> <i>"set target disease"</i><span style="color: navy">;</span>
v.vp<b> as </b><span style="color: maroon">vp</span><span style="color: navy"><b> -> </b></span> vaccination.vaccine<b> as </b><span style="color: maroon">coding</span><span style="color: navy">, </span> coding.system = <span style="color: blue">'https://ec.europa.eu/health/documents/community-register/html/'</span><span style="color: navy">, </span> coding.code = <span style="color: maroon">vp</span> <i>"set vaccine"</i><span style="color: navy">;</span>
v.mp<b> as </b><span style="color: maroon">mp</span><b> then</b><span style="color: navy"> {
</span> mp<span style="color: navy"><b> -> </b></span> vaccination.brand<b> as </b><span style="color: maroon">coding</span><span style="color: navy">, </span> coding.system = <span style="color: blue">'https://id.uvci.eu/valuesets/vaccine-medicinal-product.json'</span><span style="color: navy">, </span> coding.code = <span style="color: maroon">mp</span> <i>"set default brand"</i><span style="color: navy">;</span>
mp<span style="color: navy"><b> -> </b></span><b>c</b><span style="color: navy">(</span><span style="color: blue">'https://ec.europa.eu/health/documents/community-register/html/'</span><span style="color: navy">, </span><span style="color: maroon">mp</span><span style="color: navy">)</span><b> as </b><span style="color: maroon">coded</span><b> then</b><span style="color: navy"> {
</span> mp<b> where </b>coded.memberOf('http://smart.who.int/ddcc/ValueSet/vaccine-covid19-euur')<span style="color: navy"><b> -> </b></span>vaccination.brand = <b>translate</b><span style="color: navy">(</span><span style="color: maroon">coded</span><span style="color: navy">, </span><span style="color: blue">'http://smart.who.int/ddcc/ConceptMap/vaccine-covid19-euur-to-icd11'</span><span style="color: navy">, </span><span style="color: blue">'Coding'</span><span style="color: navy">)</span> <i>"translate COVID19 brand"</i><span style="color: navy">;</span>
<span style="color: navy">}</span> <i>"coding"</i><span style="color: navy">;</span>
<span style="color: navy">}</span><span style="color: navy">;</span>
v.ma<b> as </b><span style="color: maroon">ma</span><span style="color: navy"><b> -> </b></span> vaccination.maholder<b> as </b><span style="color: maroon">coding</span><span style="color: navy">, </span> coding.system = <span style="color: blue">'https://id.uvci.eu/valuesets/vaccine-mah-manf.json'</span><span style="color: navy">, </span> coding.code = <span style="color: maroon">ma</span> <i>"set maholder"</i><span style="color: navy">;</span>
v.dt<b> as </b><span style="color: maroon">date</span><span style="color: navy"><b> -> </b></span>vaccination.date = <span style="color: maroon">date</span> <i>"set date"</i><span style="color: navy">;</span>
v.dn<b> as </b><span style="color: maroon">dose</span><span style="color: navy"><b> -> </b></span>vaccination.dose = <span style="color: maroon">dose</span> <i>"set dose"</i><span style="color: navy">;</span>
v.sd<b> as </b><span style="color: maroon">totalDoses</span><span style="color: navy"><b> -> </b></span>vaccination.totalDoses = <span style="color: maroon">totalDoses</span> <i>"set totalDoses"</i><span style="color: navy">;</span>
v.co<b> as </b><span style="color: maroon">co</span><span style="color: navy"><b> -> </b></span> vaccination.country<b> as </b><span style="color: maroon">coding</span><span style="color: navy">, </span> coding.code = <span style="color: maroon">co</span><span style="color: navy">, </span> coding.system = <span style="color: blue">'urn:iso:std:iso:3166'</span> <i>"set country"</i><span style="color: navy">;</span>
<span style="color: navy">}
</span><b>group </b>TtoCoreDataSetTR<span style="color: navy">(</span><b>source</b> <span style="color: maroon">t</span>, <b>target</b> <span style="color: maroon">test</span><span style="color: navy">)</span><span style="color: navy"> {
</span> t.tg<b> as </b><span style="color: maroon">tg</span><b> then</b><span style="color: navy"> {
</span> tg<span style="color: navy"><b> -> </b></span> test.pathogen<b> as </b><span style="color: maroon">coding</span><span style="color: navy">, </span> coding.system = <span style="color: blue">'http://snomed.info/sct'</span><span style="color: navy">, </span> coding.code = <span style="color: maroon">tg</span> <i>"set default pathogen"</i><span style="color: navy">;</span>
tg<span style="color: navy"><b> -> </b></span><b>c</b><span style="color: navy">(</span><span style="color: blue">'http://snomed.info/sct'</span><span style="color: navy">, </span><span style="color: maroon">tg</span><span style="color: navy">)</span><b> as </b><span style="color: maroon">coded</span><b> then</b><span style="color: navy"> {
</span> tg<b> where </b>coded.memberOf('http://smart.who.int/ddcc/ValueSet/lab-test-pathogen-covid19-snomed')<span style="color: navy"><b> -> </b></span>test.pathogen = <b>translate</b><span style="color: navy">(</span><span style="color: maroon">coded</span><span style="color: navy">, </span><span style="color: blue">'http://smart.who.int/ddcc/ConceptMap/lab-test-pathogen-snomed-to-icd11'</span><span style="color: navy">, </span><span style="color: blue">'Coding'</span><span style="color: navy">)</span> <i>"translate COVID19 pathogen"</i><span style="color: navy">;</span>
<span style="color: navy">}</span> <i>"coding"</i><span style="color: navy">;</span>
<span style="color: navy">}</span><span style="color: navy">;</span>
t.tt<b> as </b><span style="color: maroon">tt</span><b> then</b><span style="color: navy"> {
</span> tt<span style="color: navy"><b> -> </b></span> test.type<b> as </b><span style="color: maroon">coding</span><span style="color: navy">, </span> coding.system = <span style="color: blue">'http://loinc.org'</span><span style="color: navy">, </span> coding.code = <span style="color: maroon">tt</span> <i>"set default type"</i><span style="color: navy">;</span>
tt<span style="color: navy"><b> -> </b></span><b>c</b><span style="color: navy">(</span><span style="color: blue">'http://loinc.org'</span><span style="color: navy">, </span><span style="color: maroon">tt</span><span style="color: navy">)</span><b> as </b><span style="color: maroon">coded</span><b> then</b><span style="color: navy"> {
</span> tt<b> where </b>coded.memberOf('http://smart.who.int/ddcc/ValueSet/lab-test-type-covid19-loinc')<span style="color: navy"><b> -> </b></span>test.type = <b>translate</b><span style="color: navy">(</span><span style="color: maroon">coded</span><span style="color: navy">, </span><span style="color: blue">'http://smart.who.int/ddcc/ConceptMap/lab-test-type-covid19-loinc-to-icd11'</span><span style="color: navy">, </span><span style="color: blue">'Coding'</span><span style="color: navy">)</span> <i>"translate COVID19 type"</i><span style="color: navy">;</span>
<span style="color: navy">}</span> <i>"coding"</i><span style="color: navy">;</span>
<span style="color: navy">}</span><span style="color: navy">;</span>
t.nm<b> as </b><span style="color: maroon">nm</span><span style="color: navy"><b> -> </b></span> test.brand<b> as </b><span style="color: maroon">coding</span><span style="color: navy">, </span> coding.system = <span style="color: blue">'https://id.uvci.eu/valuesets/test-manf.json'</span><span style="color: navy">, </span> coding.code = <span style="color: maroon">nm</span> <i>"set brand"</i><span style="color: navy">;</span>
t.ma<b> as </b><span style="color: maroon">ma</span><span style="color: navy"><b> -> </b></span> test.manufacturer<b> as </b><span style="color: maroon">coding</span><span style="color: navy">, </span> coding.system = <span style="color: blue">'https://covid-19-diagnostics.jrc.ec.europa.eu/devices'</span><span style="color: navy">, </span> coding.code = <span style="color: maroon">ma</span> <i>"set manufacturer"</i><span style="color: navy">;</span>
t.sc<b> as </b><span style="color: maroon">date</span><span style="color: navy"><b> -> </b></span>test.date = <span style="color: maroon">date</span> <i>"set date"</i><span style="color: navy">;</span>
t.tr<b> as </b><span style="color: maroon">tr</span><b> then</b><span style="color: navy"> {
</span> tr<span style="color: navy"><b> -> </b></span> test.result<b> as </b><span style="color: maroon">coding</span><span style="color: navy">, </span> coding.system = <span style="color: blue">'http://snomed.info/sct'</span><span style="color: navy">, </span> coding.code = <span style="color: maroon">tr</span> <i>"set default result"</i><span style="color: navy">;</span>
tr<span style="color: navy"><b> -> </b></span><b>c</b><span style="color: navy">(</span><span style="color: blue">'http://snomed.info/sct'</span><span style="color: navy">, </span><span style="color: maroon">tr</span><span style="color: navy">)</span><b> as </b><span style="color: maroon">coded</span><b> then</b><span style="color: navy"> {
</span> tr<b> where </b>coded.memberOf('http://smart.who.int/ddcc/ValueSet/lab-test-qual-result-snomed')<span style="color: navy"><b> -> </b></span>test.result = <b>translate</b><span style="color: navy">(</span><span style="color: maroon">coded</span><span style="color: navy">, </span><span style="color: blue">'http://smart.who.int/ddcc/ConceptMap/lab-test-qual-result-snomed-to-icd11'</span><span style="color: navy">, </span><span style="color: blue">'Coding'</span><span style="color: navy">)</span> <i>"translate COVID19 result"</i><span style="color: navy">;</span>
<span style="color: navy">}</span> <i>"coding"</i><span style="color: navy">;</span>
<span style="color: navy">}</span><span style="color: navy">;</span>
t.tc<b> as </b><span style="color: maroon">tc</span><span style="color: navy"><b> -> </b></span> test.centre<b> as </b><span style="color: maroon">coding</span><span style="color: navy">, </span> coding.code = <span style="color: maroon">tc</span> <i>"set centre"</i><span style="color: navy">;</span>
t.co<b> as </b><span style="color: maroon">co</span><span style="color: navy"><b> -> </b></span> test.country<b> as </b><span style="color: maroon">coding</span><span style="color: navy">, </span> coding.code = <span style="color: maroon">co</span><span style="color: navy">, </span> coding.system = <span style="color: blue">'urn:iso:std:iso:3166'</span> <i>"set country"</i><span style="color: navy">;</span>
<span style="color: navy">}
</span></pre></div>
</text>
<url value="http://smart.who.int/ddcc/StructureMap/CertDCCtoCoreDataSet"/>
<version value="1.0.1"/>
<name value="CertDCCtoCoreDataSet"/>
<status value="draft"/>
<date value="2024-12-18T16:46:48+01:00"/>
<publisher value="WHO"/>
<contact>
<name value="WHO"/>
<telecom>
<system value="url"/>
<value value="http://who.int"/>
</telecom>
</contact>
<description
value="Structure map transforming CertDCC logical model to bundle of Core Data Set logical model"/>
<jurisdiction>
<coding>
<system value="http://unstats.un.org/unsd/methods/m49/m49.htm"/>
<code value="001"/>
</coding>
</jurisdiction>
<structure>
<url value="http://smart.who.int/ddcc/StructureDefinition/CertDCC"/>
<mode value="source"/>
<alias value="CWTPayload"/>
</structure>
<structure>
<url value="http://hl7.org/fhir/StructureDefinition/Bundle"/>
<mode value="target"/>
<alias value="DDCCBundle"/>
</structure>
<structure>
<url
value="http://smart.who.int/ddcc/StructureDefinition/DDCCCoreDataSet"/>
<mode value="target"/>
<alias value="DDCC"/>
</structure>
<structure>
<url
value="http://smart.who.int/ddcc/StructureDefinition/DDCCCoreDataSetVS"/>
<mode value="target"/>
<alias value="DDCCVS"/>
</structure>
<structure>
<url
value="http://smart.who.int/ddcc/StructureDefinition/DDCCCoreDataSetTR"/>
<mode value="target"/>
<alias value="DDCCTR"/>
</structure>
<group>
<name value="CertDCCtoCoreDataSet"/>
<typeMode value="none"/>
<input>
<name value="src"/>
<type value="CWTPayload"/>
<mode value="source"/>
</input>
<input>
<name value="ddccBundle"/>
<type value="DDCCBundle"/>
<mode value="target"/>
</input>
<rule>
<name value="hcert"/>
<source>
<context value="src"/>
<element value="-260"/>
<variable value="hcert"/>
</source>
<rule>
<name value="eu_DCC_v1"/>
<source>
<context value="hcert"/>
<element value="1"/>
<variable value="dcc"/>
</source>
<rule>
<name value="v"/>
<source>
<context value="dcc"/>
<element value="v"/>
<variable value="v"/>
</source>
<target>
<context value="ddccBundle"/>
<contextType value="variable"/>
<element value="entry"/>
<variable value="outentry"/>
</target>
<target>
<contextType value="variable"/>
<variable value="ddcc"/>
<transform value="create"/>
<parameter>
<valueString
value="http://smart.who.int/ddcc/StructureDefinition/DDCCCoreDataSetVS"/>
</parameter>
</target>
<rule>
<name value="set DDCC"/>
<source>
<context value="v"/>
</source>
<dependent>
<name value="DCCtoCoreDataSet"/>
<variable value="dcc"/>
<variable value="ddcc"/>
</dependent>
</rule>
<rule>
<name value="set certificate"/>
<source>
<context value="v"/>
</source>
<target>
<context value="ddcc"/>
<contextType value="variable"/>
<element value="certificate"/>
<variable value="certificate"/>
</target>
<dependent>
<name value="CertDCCtoCoreDataSetCertificate"/>
<variable value="src"/>
<variable value="dcc"/>
<variable value="v"/>
<variable value="certificate"/>
</dependent>
</rule>
<rule>
<name value="set vaccination"/>
<source>
<context value="v"/>
</source>
<target>
<context value="ddcc"/>
<contextType value="variable"/>
<element value="vaccination"/>
<variable value="vaccination"/>
</target>
<dependent>
<name value="VtoCoreDataSetVS"/>
<variable value="v"/>
<variable value="vaccination"/>
</dependent>
</rule>
<rule>
<name value="set outentry"/>
<source>
<context value="v"/>
</source>
<target>
<context value="outentry"/>
<contextType value="variable"/>
<element value="resource"/>
<transform value="copy"/>
<parameter>
<valueId value="ddcc"/>
</parameter>
</target>
</rule>
</rule>
<rule>
<name value="t"/>
<source>
<context value="dcc"/>
<element value="t"/>
<variable value="t"/>
</source>
<target>
<context value="ddccBundle"/>
<contextType value="variable"/>
<element value="entry"/>
<variable value="outentry"/>
</target>
<target>
<contextType value="variable"/>
<variable value="ddcc"/>
<transform value="create"/>
<parameter>
<valueString
value="http://smart.who.int/ddcc/StructureDefinition/DDCCCoreDataSetTR"/>
</parameter>
</target>
<rule>
<name value="set DDCC"/>
<source>
<context value="t"/>
</source>
<dependent>
<name value="DCCtoCoreDataSet"/>
<variable value="dcc"/>
<variable value="ddcc"/>
</dependent>
</rule>
<rule>
<name value="set certificate"/>
<source>
<context value="t"/>
</source>
<target>
<context value="ddcc"/>
<contextType value="variable"/>
<element value="certificate"/>
<variable value="certificate"/>
</target>
<dependent>
<name value="CertDCCtoCoreDataSetCertificate"/>
<variable value="src"/>
<variable value="dcc"/>
<variable value="t"/>
<variable value="certificate"/>
</dependent>
</rule>
<rule>
<name value="set test"/>
<source>
<context value="t"/>
</source>
<target>
<context value="ddcc"/>
<contextType value="variable"/>
<element value="test"/>
<variable value="test"/>
</target>
<dependent>
<name value="TtoCoreDataSetTR"/>
<variable value="t"/>
<variable value="test"/>
</dependent>
</rule>
<rule>
<name value="set outentry"/>
<source>
<context value="t"/>
</source>
<target>
<context value="outentry"/>
<contextType value="variable"/>
<element value="resource"/>
<transform value="copy"/>
<parameter>
<valueId value="ddcc"/>
</parameter>
</target>
</rule>
</rule>
</rule>
</rule>
</group>
<group>
<name value="DCCtoCoreDataSet"/>
<typeMode value="none"/>
<input>
<name value="dcc"/>
<mode value="source"/>
</input>
<input>
<name value="ddcc"/>
<type value="DDCC"/>
<mode value="target"/>
</input>
<rule>
<name value="set birthDate"/>
<source>
<context value="dcc"/>
<element value="dob"/>
<variable value="birthDate"/>
</source>
<target>
<context value="ddcc"/>
<contextType value="variable"/>
<element value="birthDate"/>
<transform value="copy"/>
<parameter>
<valueId value="birthDate"/>
</parameter>
</target>
</rule>
<rule>
<name value="nam"/>
<source>
<context value="dcc"/>
<element value="nam"/>
<variable value="nam"/>
</source>
<rule>
<name value="set given name"/>
<source>
<context value="nam"/>
<element value="gn"/>
<variable value="given"/>
</source>
<target>
<context value="ddcc"/>
<contextType value="variable"/>
<element value="name"/>
<transform value="evaluate"/>
<parameter>
<valueString value="given.replaceMatches('$', ' ')"/>
</parameter>
</target>
</rule>
<rule>
<name value="add family name"/>
<source>
<context value="nam"/>
<element value="fn"/>
<variable value="family"/>
</source>
<target>
<context value="ddcc"/>
<contextType value="variable"/>
<element value="name"/>
<variable value="tName"/>
</target>
<target>
<context value="ddcc"/>
<contextType value="variable"/>
<element value="name"/>
<transform value="append"/>
<parameter>
<valueId value="tName"/>
</parameter>
<parameter>
<valueId value="family"/>
</parameter>
</target>
</rule>
</rule>
</group>
<group>
<name value="CertDCCtoCoreDataSetCertificate"/>
<typeMode value="none"/>
<input>
<name value="src"/>
<type value="CWTPayload"/>
<mode value="source"/>
</input>
<input>
<name value="dcc"/>
<mode value="source"/>
</input>
<input>
<name value="g"/>
<mode value="source"/>
</input>
<input>
<name value="certificate"/>
<mode value="target"/>
</input>
<rule>
<name value="set period"/>
<source>
<context value="src"/>
</source>
<target>
<context value="certificate"/>
<contextType value="variable"/>
<element value="period"/>
<variable value="period"/>
<transform value="create"/>
<parameter>
<valueString value="Period"/>
</parameter>
</target>
<dependent>
<name value="CwtToPeriod"/>
<variable value="src"/>
<variable value="period"/>
</dependent>
</rule>
<rule>
<name value="set version"/>
<source>
<context value="dcc"/>
<element value="ver"/>
<variable value="ver"/>
</source>
<target>
<context value="certificate"/>
<contextType value="variable"/>
<element value="version"/>
<transform value="copy"/>
<parameter>
<valueId value="ver"/>
</parameter>
</target>
</rule>
<rule>
<name value="set hcid"/>
<source>
<context value="g"/>
<element value="ci"/>
<variable value="ci"/>
</source>
<target>
<context value="certificate"/>
<contextType value="variable"/>
<element value="hcid"/>
<variable value="hcid"/>
</target>
<target>
<context value="hcid"/>
<contextType value="variable"/>
<element value="value"/>
<transform value="copy"/>
<parameter>
<valueId value="ci"/>
</parameter>
</target>
</rule>
<rule>
<name value="set issuer"/>
<source>
<context value="g"/>
<element value="is"/>
<variable value="is"/>
</source>
<target>
<context value="certificate"/>
<contextType value="variable"/>
<element value="issuer"/>
<variable value="issuer"/>
<transform value="create"/>
<parameter>
<valueString value="Reference"/>
</parameter>
</target>
<target>
<context value="issuer"/>
<contextType value="variable"/>
<element value="display"/>
<transform value="copy"/>
<parameter>
<valueId value="is"/>
</parameter>
</target>
</rule>
</group>
<group>
<name value="CwtToPeriod"/>
<typeMode value="none"/>
<input>
<name value="src"/>
<type value="CWTPayload"/>
<mode value="source"/>
</input>
<input>
<name value="tgt"/>
<type value="Period"/>
<mode value="target"/>
</input>
<rule>
<name value="set period start"/>
<source>
<context value="src"/>
<element value="6"/>
<variable value="iat"/>
</source>
<target>
<contextType value="variable"/>
<variable value="epoch"/>
<transform value="append"/>
<parameter>
<valueId value="iat"/>
</parameter>
<parameter>
<valueString value=" seconds"/>
</parameter>
</target>
<target>
<context value="tgt"/>
<contextType value="variable"/>
<element value="start"/>
<transform value="evaluate"/>
<parameter>
<valueString
value="@1970-01-01T00:00:00.000+00:00 + epoch.toQuantity()"/>
</parameter>
</target>
</rule>
<rule>
<name value="set period end"/>
<source>
<context value="src"/>
<element value="4"/>
<variable value="exp"/>
</source>
<target>
<contextType value="variable"/>
<variable value="epoch"/>
<transform value="append"/>
<parameter>
<valueId value="exp"/>
</parameter>
<parameter>
<valueString value=" seconds"/>
</parameter>
</target>
<target>
<context value="tgt"/>
<contextType value="variable"/>
<element value="end"/>
<transform value="evaluate"/>
<parameter>
<valueString
value="@1970-01-01T00:00:00.000+00:00 + epoch.toQuantity()"/>
</parameter>
</target>
</rule>
</group>
<group>
<name value="VtoCoreDataSetVS"/>
<typeMode value="none"/>
<input>
<name value="v"/>
<mode value="source"/>
</input>
<input>
<name value="vaccination"/>
<mode value="target"/>
</input>
<rule>
<name value="set target disease"/>
<source>
<context value="v"/>
<element value="tg"/>
<variable value="tg"/>
</source>
<target>
<context value="vaccination"/>
<contextType value="variable"/>
<element value="disease"/>
<variable value="coding"/>
</target>
<target>
<context value="coding"/>
<contextType value="variable"/>
<element value="system"/>
<transform value="copy"/>
<parameter>
<valueString value="http://snomed.info/sct"/>
</parameter>
</target>
<target>
<context value="coding"/>
<contextType value="variable"/>
<element value="code"/>
<transform value="copy"/>
<parameter>
<valueId value="tg"/>
</parameter>
</target>
</rule>
<rule>
<name value="set vaccine"/>
<source>
<context value="v"/>
<element value="vp"/>
<variable value="vp"/>
</source>
<target>
<context value="vaccination"/>
<contextType value="variable"/>
<element value="vaccine"/>
<variable value="coding"/>
</target>
<target>
<context value="coding"/>
<contextType value="variable"/>
<element value="system"/>
<transform value="copy"/>
<parameter>
<valueString
value="https://ec.europa.eu/health/documents/community-register/html/"/>
</parameter>
</target>
<target>
<context value="coding"/>
<contextType value="variable"/>
<element value="code"/>
<transform value="copy"/>
<parameter>
<valueId value="vp"/>
</parameter>
</target>
</rule>
<rule>
<name value="mp"/>
<source>
<context value="v"/>
<element value="mp"/>
<variable value="mp"/>
</source>
<rule>
<name value="set default brand"/>
<source>
<context value="mp"/>
</source>
<target>
<context value="vaccination"/>
<contextType value="variable"/>
<element value="brand"/>
<variable value="coding"/>
</target>
<target>
<context value="coding"/>
<contextType value="variable"/>
<element value="system"/>
<transform value="copy"/>
<parameter>
<valueString
value="https://id.uvci.eu/valuesets/vaccine-medicinal-product.json"/>
</parameter>
</target>
<target>
<context value="coding"/>
<contextType value="variable"/>
<element value="code"/>
<transform value="copy"/>
<parameter>
<valueId value="mp"/>
</parameter>
</target>
</rule>
<rule>
<name value="coding"/>
<source>
<context value="mp"/>
</source>
<target>
<contextType value="variable"/>
<variable value="coded"/>
<transform value="c"/>
<parameter>
<valueString
value="https://ec.europa.eu/health/documents/community-register/html/"/>
</parameter>
<parameter>
<valueId value="mp"/>
</parameter>
</target>
<rule>
<name value="translate COVID19 brand"/>
<source>
<context value="mp"/>
<condition
value="coded.memberOf('http://smart.who.int/ddcc/ValueSet/vaccine-covid19-euur')"/>
</source>
<target>
<context value="vaccination"/>
<contextType value="variable"/>
<element value="brand"/>
<transform value="translate"/>
<parameter>
<valueId value="coded"/>
</parameter>
<parameter>
<valueString
value="http://smart.who.int/ddcc/ConceptMap/vaccine-covid19-euur-to-icd11"/>
</parameter>
<parameter>
<valueString value="Coding"/>
</parameter>
</target>
</rule>
</rule>
</rule>
<rule>
<name value="set maholder"/>
<source>
<context value="v"/>
<element value="ma"/>
<variable value="ma"/>
</source>
<target>
<context value="vaccination"/>
<contextType value="variable"/>
<element value="maholder"/>
<variable value="coding"/>
</target>
<target>
<context value="coding"/>
<contextType value="variable"/>
<element value="system"/>
<transform value="copy"/>
<parameter>
<valueString
value="https://id.uvci.eu/valuesets/vaccine-mah-manf.json"/>
</parameter>
</target>
<target>
<context value="coding"/>
<contextType value="variable"/>
<element value="code"/>
<transform value="copy"/>
<parameter>
<valueId value="ma"/>
</parameter>
</target>
</rule>
<rule>
<name value="set date"/>
<source>
<context value="v"/>
<element value="dt"/>
<variable value="date"/>
</source>
<target>
<context value="vaccination"/>
<contextType value="variable"/>
<element value="date"/>
<transform value="copy"/>
<parameter>
<valueId value="date"/>
</parameter>
</target>
</rule>
<rule>
<name value="set dose"/>
<source>
<context value="v"/>
<element value="dn"/>
<variable value="dose"/>
</source>
<target>
<context value="vaccination"/>
<contextType value="variable"/>
<element value="dose"/>
<transform value="copy"/>
<parameter>
<valueId value="dose"/>
</parameter>
</target>
</rule>
<rule>
<name value="set totalDoses"/>
<source>
<context value="v"/>
<element value="sd"/>
<variable value="totalDoses"/>
</source>
<target>
<context value="vaccination"/>
<contextType value="variable"/>
<element value="totalDoses"/>
<transform value="copy"/>
<parameter>
<valueId value="totalDoses"/>
</parameter>
</target>
</rule>
<rule>
<name value="set country"/>
<source>
<context value="v"/>
<element value="co"/>
<variable value="co"/>
</source>
<target>
<context value="vaccination"/>
<contextType value="variable"/>
<element value="country"/>
<variable value="coding"/>
</target>
<target>
<context value="coding"/>
<contextType value="variable"/>
<element value="code"/>
<transform value="copy"/>
<parameter>
<valueId value="co"/>
</parameter>
</target>
<target>
<context value="coding"/>
<contextType value="variable"/>
<element value="system"/>
<transform value="copy"/>
<parameter>
<valueString value="urn:iso:std:iso:3166"/>
</parameter>
</target>
</rule>
</group>
<group>
<name value="TtoCoreDataSetTR"/>
<typeMode value="none"/>
<input>
<name value="t"/>
<mode value="source"/>
</input>
<input>
<name value="test"/>
<mode value="target"/>
</input>
<rule>
<name value="tg"/>
<source>
<context value="t"/>
<element value="tg"/>
<variable value="tg"/>
</source>
<rule>
<name value="set default pathogen"/>
<source>
<context value="tg"/>
</source>
<target>
<context value="test"/>
<contextType value="variable"/>
<element value="pathogen"/>
<variable value="coding"/>
</target>
<target>
<context value="coding"/>
<contextType value="variable"/>
<element value="system"/>
<transform value="copy"/>
<parameter>
<valueString value="http://snomed.info/sct"/>
</parameter>
</target>
<target>
<context value="coding"/>
<contextType value="variable"/>
<element value="code"/>
<transform value="copy"/>
<parameter>
<valueId value="tg"/>
</parameter>
</target>
</rule>
<rule>
<name value="coding"/>
<source>
<context value="tg"/>
</source>
<target>
<contextType value="variable"/>
<variable value="coded"/>
<transform value="c"/>
<parameter>
<valueString value="http://snomed.info/sct"/>
</parameter>
<parameter>
<valueId value="tg"/>
</parameter>
</target>
<rule>
<name value="translate COVID19 pathogen"/>
<source>
<context value="tg"/>
<condition
value="coded.memberOf('http://smart.who.int/ddcc/ValueSet/lab-test-pathogen-covid19-snomed')"/>
</source>
<target>
<context value="test"/>
<contextType value="variable"/>
<element value="pathogen"/>
<transform value="translate"/>
<parameter>
<valueId value="coded"/>
</parameter>
<parameter>
<valueString
value="http://smart.who.int/ddcc/ConceptMap/lab-test-pathogen-snomed-to-icd11"/>
</parameter>
<parameter>
<valueString value="Coding"/>
</parameter>
</target>
</rule>
</rule>
</rule>
<rule>
<name value="tt"/>
<source>
<context value="t"/>
<element value="tt"/>
<variable value="tt"/>
</source>
<rule>
<name value="set default type"/>
<source>
<context value="tt"/>
</source>
<target>
<context value="test"/>
<contextType value="variable"/>
<element value="type"/>
<variable value="coding"/>
</target>
<target>
<context value="coding"/>
<contextType value="variable"/>
<element value="system"/>
<transform value="copy"/>
<parameter>
<valueString value="http://loinc.org"/>
</parameter>
</target>
<target>
<context value="coding"/>
<contextType value="variable"/>
<element value="code"/>
<transform value="copy"/>
<parameter>
<valueId value="tt"/>
</parameter>
</target>
</rule>
<rule>
<name value="coding"/>
<source>
<context value="tt"/>
</source>
<target>
<contextType value="variable"/>
<variable value="coded"/>
<transform value="c"/>
<parameter>
<valueString value="http://loinc.org"/>
</parameter>
<parameter>
<valueId value="tt"/>
</parameter>
</target>
<rule>
<name value="translate COVID19 type"/>
<source>
<context value="tt"/>
<condition
value="coded.memberOf('http://smart.who.int/ddcc/ValueSet/lab-test-type-covid19-loinc')"/>
</source>
<target>
<context value="test"/>
<contextType value="variable"/>
<element value="type"/>
<transform value="translate"/>
<parameter>
<valueId value="coded"/>
</parameter>
<parameter>
<valueString
value="http://smart.who.int/ddcc/ConceptMap/lab-test-type-covid19-loinc-to-icd11"/>
</parameter>
<parameter>
<valueString value="Coding"/>
</parameter>
</target>
</rule>
</rule>
</rule>
<rule>
<name value="set brand"/>
<source>
<context value="t"/>
<element value="nm"/>
<variable value="nm"/>
</source>
<target>
<context value="test"/>
<contextType value="variable"/>
<element value="brand"/>
<variable value="coding"/>
</target>
<target>
<context value="coding"/>
<contextType value="variable"/>
<element value="system"/>
<transform value="copy"/>
<parameter>
<valueString value="https://id.uvci.eu/valuesets/test-manf.json"/>
</parameter>
</target>
<target>
<context value="coding"/>
<contextType value="variable"/>
<element value="code"/>
<transform value="copy"/>
<parameter>
<valueId value="nm"/>
</parameter>
</target>
</rule>
<rule>
<name value="set manufacturer"/>
<source>
<context value="t"/>
<element value="ma"/>
<variable value="ma"/>
</source>
<target>
<context value="test"/>
<contextType value="variable"/>
<element value="manufacturer"/>
<variable value="coding"/>
</target>
<target>
<context value="coding"/>
<contextType value="variable"/>
<element value="system"/>
<transform value="copy"/>
<parameter>
<valueString
value="https://covid-19-diagnostics.jrc.ec.europa.eu/devices"/>
</parameter>
</target>
<target>
<context value="coding"/>
<contextType value="variable"/>
<element value="code"/>
<transform value="copy"/>
<parameter>
<valueId value="ma"/>
</parameter>
</target>
</rule>
<rule>
<name value="set date"/>
<source>
<context value="t"/>
<element value="sc"/>
<variable value="date"/>
</source>
<target>
<context value="test"/>
<contextType value="variable"/>
<element value="date"/>
<transform value="copy"/>
<parameter>
<valueId value="date"/>
</parameter>
</target>
</rule>
<rule>
<name value="tr"/>
<source>
<context value="t"/>
<element value="tr"/>
<variable value="tr"/>
</source>
<rule>
<name value="set default result"/>
<source>
<context value="tr"/>
</source>
<target>
<context value="test"/>
<contextType value="variable"/>
<element value="result"/>
<variable value="coding"/>
</target>
<target>
<context value="coding"/>
<contextType value="variable"/>
<element value="system"/>
<transform value="copy"/>
<parameter>
<valueString value="http://snomed.info/sct"/>
</parameter>
</target>
<target>
<context value="coding"/>
<contextType value="variable"/>
<element value="code"/>
<transform value="copy"/>
<parameter>
<valueId value="tr"/>
</parameter>
</target>
</rule>
<rule>
<name value="coding"/>
<source>
<context value="tr"/>
</source>
<target>
<contextType value="variable"/>
<variable value="coded"/>
<transform value="c"/>
<parameter>
<valueString value="http://snomed.info/sct"/>
</parameter>
<parameter>
<valueId value="tr"/>
</parameter>
</target>
<rule>
<name value="translate COVID19 result"/>
<source>
<context value="tr"/>
<condition
value="coded.memberOf('http://smart.who.int/ddcc/ValueSet/lab-test-qual-result-snomed')"/>
</source>
<target>
<context value="test"/>
<contextType value="variable"/>
<element value="result"/>
<transform value="translate"/>
<parameter>
<valueId value="coded"/>
</parameter>
<parameter>
<valueString
value="http://smart.who.int/ddcc/ConceptMap/lab-test-qual-result-snomed-to-icd11"/>
</parameter>
<parameter>
<valueString value="Coding"/>
</parameter>
</target>
</rule>
</rule>
</rule>
<rule>
<name value="set centre"/>
<source>
<context value="t"/>
<element value="tc"/>
<variable value="tc"/>
</source>
<target>
<context value="test"/>
<contextType value="variable"/>
<element value="centre"/>
<variable value="coding"/>
</target>
<target>
<context value="coding"/>
<contextType value="variable"/>
<element value="code"/>
<transform value="copy"/>
<parameter>
<valueId value="tc"/>
</parameter>
</target>
</rule>
<rule>
<name value="set country"/>
<source>
<context value="t"/>
<element value="co"/>
<variable value="co"/>
</source>
<target>
<context value="test"/>
<contextType value="variable"/>
<element value="country"/>
<variable value="coding"/>
</target>
<target>
<context value="coding"/>
<contextType value="variable"/>
<element value="code"/>
<transform value="copy"/>
<parameter>
<valueId value="co"/>
</parameter>
</target>
<target>
<context value="coding"/>
<contextType value="variable"/>
<element value="system"/>
<transform value="copy"/>
<parameter>
<valueString value="urn:iso:std:iso:3166"/>
</parameter>
</target>
</rule>
</group>
</StructureMap>