WHO Digital Documentation of COVID-19 Certificates (DDCC)
1.0.0 - CI Build International flag

WHO Digital Documentation of COVID-19 Certificates (DDCC), published by WHO. This guide is not an authorized publication; it is the continuous build for version 1.0.0 built by the FHIR (HL7® FHIR® Standard) CI Build. This version is based on the current content of https://github.com/WorldHealthOrganization/ddcc/ and changes regularly. See the Directory of published versions

: null - JSON Representation

Draft as of 2024-10-17

Raw json | Download

{
  "resourceType" : "StructureMap",
  "id" : "CoreDataSetVSLibrary",
  "text" : {
    "status" : "generated",
    "div" : "<div xmlns=\"http://www.w3.org/1999/xhtml\"><p class=\"res-header-id\"><b>Generated Narrative: StructureMap CoreDataSetVSLibrary</b></p><a name=\"CoreDataSetVSLibrary\"> </a><a name=\"hcCoreDataSetVSLibrary\"> </a><a name=\"CoreDataSetVSLibrary-en-US\"> </a><pre class=\"fml\">\r\n<b>map</b><span style=\"color: navy\"> &quot;</span>http://smart.who.int/ddcc/StructureMap/CoreDataSetVSLibrary<span style=\"color: navy\">&quot; = &quot;</span>CoreDataSetVSLibrary<span style=\"color: navy\">&quot;\r\n\r\n</span><b>uses</b><span style=\"color: navy\"> &quot;</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\">&quot; </span><b>alias </b>DDCCVS <b>as </b><b>source</b>\r\n<b>uses</b><span style=\"color: navy\"> &quot;</span><a href=\"http://hl7.org/fhir/R4/bundle.html\" title=\"Bundle\">http://hl7.org/fhir/StructureDefinition/Bundle</a><span style=\"color: navy\">&quot; </span><b>alias </b>AddBundle <b>as </b><b>target</b>\r\n<b>uses</b><span style=\"color: navy\"> &quot;</span><a href=\"http://hl7.org/fhir/R4/patient.html\" title=\"Patient\">http://hl7.org/fhir/StructureDefinition/Patient</a><span style=\"color: navy\">&quot; </span><b>alias </b>Patient <b>as </b><b>target</b>\r\n<b>uses</b><span style=\"color: navy\"> &quot;</span><a href=\"StructureDefinition-DDCCPatient.html\" title=\"DDCC Patient\">http://smart.who.int/ddcc/StructureDefinition/DDCCPatient</a><span style=\"color: navy\">&quot; </span><b>alias </b>DDCCPatient <b>as </b><b>target</b>\r\n<b>uses</b><span style=\"color: navy\"> &quot;</span><a href=\"StructureDefinition-DDCCDocumentReferenceQR.html\" title=\"DDCC DocumentReference return for QR\">http://smart.who.int/ddcc/StructureDefinition/DDCCDocumentReferenceQR</a><span style=\"color: navy\">&quot; </span><b>alias </b>DDCCDocRefQR <b>as </b><b>target</b>\r\n<b>uses</b><span style=\"color: navy\"> &quot;</span><a href=\"StructureDefinition-DDCCVSComposition.html\" title=\"DDCC:VS Composition\">http://smart.who.int/ddcc/StructureDefinition/DDCCVSComposition</a><span style=\"color: navy\">&quot; </span><b>alias </b>DDCCVSComposition <b>as </b><b>target</b>\r\n<b>uses</b><span style=\"color: navy\"> &quot;</span><a href=\"StructureDefinition-DDCCImmunization.html\" title=\"DDCC Immunization\">http://smart.who.int/ddcc/StructureDefinition/DDCCImmunization</a><span style=\"color: navy\">&quot; </span><b>alias </b>DDCCImmunization <b>as </b><b>target</b>\r\n<b>uses</b><span style=\"color: navy\"> &quot;</span><a href=\"StructureDefinition-DDCCImmunizationRecommendation.html\" title=\"DDCC Immunization Recommendation\">http://smart.who.int/ddcc/StructureDefinition/DDCCImmunizationRecommendation</a><span style=\"color: navy\">&quot; </span><b>alias </b>DDCCImmRec <b>as </b><b>target</b>\r\n\r\n<b>imports</b><span style=\"color: navy\"> &quot;</span><a href=\"StructureMap-CoreDataSetLibrary.html\" title=\"CoreDataSetLibrary\">http://smart.who.int/ddcc/StructureMap/CoreDataSetLibrary</a><span style=\"color: navy\">&quot;\r\n</span>\r\n<b>group </b>VSToAddBundle<span style=\"color: navy\">(</span><b>source</b> <span style=\"color: maroon\">ddcc</span><span style=\"color: navy\"> : </span>DDCCVS, <b>target</b> <span style=\"color: maroon\">bundle</span><span style=\"color: navy\"> : </span>AddBundle<span style=\"color: navy\">)</span><span style=\"color: navy\"> {\r\n</span>  ddcc<span style=\"color: navy\"><b> -&gt; </b></span>bundle.type = <span style=\"color: blue\">'transaction'</span> <i>&quot;set bundle type&quot;</i><span style=\"color: navy\">;</span>\r\n  ddcc<span style=\"color: navy\"><b> -&gt; </b></span> <b>uuid</b><span style=\"color: navy\">(</span><span style=\"color: navy\">)</span><b> as </b><span style=\"color: maroon\">pid</span><span style=\"color: navy\">, </span> <b>uuid</b><span style=\"color: navy\">(</span><span style=\"color: navy\">)</span><b> as </b><span style=\"color: maroon\">compid</span><span style=\"color: navy\">, </span> <b>uuid</b><span style=\"color: navy\">(</span><span style=\"color: navy\">)</span><b> as </b><span style=\"color: maroon\">iid</span><span style=\"color: navy\">, </span> <b>uuid</b><span style=\"color: navy\">(</span><span style=\"color: navy\">)</span><b> as </b><span style=\"color: maroon\">irid</span><span style=\"color: navy\">, </span> <b>uuid</b><span style=\"color: navy\">(</span><span style=\"color: navy\">)</span><b> as </b><span style=\"color: maroon\">qrwhoid</span><span style=\"color: navy\">, </span> <b>uuid</b><span style=\"color: navy\">(</span><span style=\"color: navy\">)</span><b> as </b><span style=\"color: maroon\">qrdccid</span><b> then</b><span style=\"color: navy\"> {\r\n</span>    ddcc<span style=\"color: navy\"><b> -&gt; </b></span> bundle.entry<b> as </b><span style=\"color: maroon\">entry</span><span style=\"color: navy\">, </span> entry.fullUrl = <b>append</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'urn:uuid:'</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">pid</span><span style=\"color: navy\">)</span><span style=\"color: navy\">, </span> entry.request<b> as </b><span style=\"color: maroon\">request</span><span style=\"color: navy\">, </span> request.method = <span style=\"color: blue\">'PUT'</span><span style=\"color: navy\">, </span> request.url = <b>append</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'Patient/'</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">pid</span><span style=\"color: navy\">)</span><span style=\"color: navy\">, </span> <b>create</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'http://smart.who.int/ddcc/StructureDefinition/DDCCPatient'</span><span style=\"color: navy\">)</span><b> as </b><span style=\"color: maroon\">patient</span><b> then</b><span style=\"color: navy\"> {\r\n</span>      ddcc<b> then </b>DDCCToPatient<span style=\"color: navy\">(</span><span style=\"color: maroon\">ddcc</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">patient</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">pid</span><span style=\"color: navy\">)</span> <i>&quot;setup patient&quot;</i><span style=\"color: navy\">;</span>\r\n      ddcc<span style=\"color: navy\"><b> -&gt; </b></span>entry.resource = <span style=\"color: maroon\">patient</span> <i>&quot;set patient resource&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;create patient resource&quot;</i><span style=\"color: navy\">;</span>\r\n    ddcc<span style=\"color: navy\"><b> -&gt; </b></span> bundle.entry<b> as </b><span style=\"color: maroon\">entry</span><span style=\"color: navy\">, </span> entry.fullUrl = <b>append</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'urn:uuid:'</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">compid</span><span style=\"color: navy\">)</span><span style=\"color: navy\">, </span> entry.request<b> as </b><span style=\"color: maroon\">request</span><span style=\"color: navy\">, </span> request.method = <span style=\"color: blue\">'PUT'</span><span style=\"color: navy\">, </span> request.url = <b>append</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'Composition/'</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">compid</span><span style=\"color: navy\">)</span><span style=\"color: navy\">, </span> <b>create</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'http://smart.who.int/ddcc/StructureDefinition/DDCCVSComposition'</span><span style=\"color: navy\">)</span><b> as </b><span style=\"color: maroon\">comp</span><b> then</b><span style=\"color: navy\"> {\r\n</span>      ddcc<b> then </b>DDCCToComposition<span style=\"color: navy\">(</span><span style=\"color: maroon\">ddcc</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">comp</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">compid</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">pid</span><span style=\"color: navy\">)</span> <i>&quot;setup composition&quot;</i><span style=\"color: navy\">;</span>\r\n      ddcc<span style=\"color: navy\"><b> -&gt; </b></span> comp.category<b> as </b><span style=\"color: maroon\">category</span><span style=\"color: navy\">, </span> category.coding<b> as </b><span style=\"color: maroon\">coding</span><span style=\"color: navy\">, </span> coding.system = <span style=\"color: blue\">'http://smart.who.int/ddcc/CodeSystem/DDCCCompositionCategoryCodeSystem'</span><span style=\"color: navy\">, </span> coding.code = <span style=\"color: blue\">'ddcc-vs'</span> <i>&quot;set category&quot;</i><span style=\"color: navy\">;</span>\r\n      ddcc<span style=\"color: navy\"><b> -&gt; </b></span>comp.title = <span style=\"color: blue\">'International Certificate of Vaccination or Prophylaxis'</span> <i>&quot;set title&quot;</i><span style=\"color: navy\">;</span>\r\n      ddcc<span style=\"color: navy\"><b> -&gt; </b></span>comp.section<b> as </b><span style=\"color: maroon\">section</span><b> then</b><span style=\"color: navy\"> {\r\n</span>        ddcc<span style=\"color: navy\"><b> -&gt; </b></span> section.code<b> as </b><span style=\"color: maroon\">code</span><span style=\"color: navy\">, </span> code.coding<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: blue\">'11369-6'</span> <i>&quot;set code&quot;</i><span style=\"color: navy\">;</span>\r\n        ddcc.certificate<b> as </b><span style=\"color: maroon\">certificate</span><b> then</b><span style=\"color: navy\"> {\r\n</span>          certificate.issuer<b> as </b><span style=\"color: maroon\">issuer</span><span style=\"color: navy\"><b> -&gt; </b></span>section.author = <span style=\"color: maroon\">issuer</span> <i>&quot;set author&quot;</i><span style=\"color: navy\">;</span>\r\n        <span style=\"color: navy\">}</span> <i>&quot;set certificate&quot;</i><span style=\"color: navy\">;</span>\r\n        <span style=\"color: #b36b00\" title=\"This element was not defined prior to R5\">// ddcc.certificate as certificate -&gt; section.author as author then {             certificate.issuer as issuer then {               issuer.identifier as pha -&gt; author.identifier as identifier, author.type = &quot;Organization&quot; then {                 pha.value as value -&gt; identifier.value = value &quot;set pha&quot;;               } &quot;set author identifier&quot;;             } &quot;set author ref&quot;;                        } &quot;set author&quot;;</span>\r\n        ddcc<span style=\"color: navy\"><b> -&gt; </b></span> section.focus<b> as </b><span style=\"color: maroon\">focus</span><span style=\"color: navy\">, </span> focus.reference = <b>append</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'Immunization/'</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">iid</span><span style=\"color: navy\">)</span> <i>&quot;set focus&quot;</i><span style=\"color: navy\">;</span>\r\n        ddcc<span style=\"color: navy\"><b> -&gt; </b></span> section.entry<b> as </b><span style=\"color: maroon\">entry</span><span style=\"color: navy\">, </span> entry.reference = <b>append</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'Immunization/'</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">iid</span><span style=\"color: navy\">)</span> <i>&quot;add Immunization entry&quot;</i><span style=\"color: navy\">;</span>\r\n        ddcc<span style=\"color: navy\"><b> -&gt; </b></span> section.entry<b> as </b><span style=\"color: maroon\">entry</span><span style=\"color: navy\">, </span> entry.reference = <b>append</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'ImmunizationRecommendation/'</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">irid</span><span style=\"color: navy\">)</span> <i>&quot;add ImmunizationRecommendation entry&quot;</i><span style=\"color: navy\">;</span>\r\n        ddcc<span style=\"color: navy\"><b> -&gt; </b></span> section.entry<b> as </b><span style=\"color: maroon\">entry</span><span style=\"color: navy\">, </span> entry.reference = <b>append</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'DocumentReference/'</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">qrwhoid</span><span style=\"color: navy\">)</span> <i>&quot;add WHO QR entry&quot;</i><span style=\"color: navy\">;</span>\r\n        ddcc<span style=\"color: navy\"><b> -&gt; </b></span> section.entry<b> as </b><span style=\"color: maroon\">entry</span><span style=\"color: navy\">, </span> entry.reference = <b>append</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'DocumentReference/'</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">qrdccid</span><span style=\"color: navy\">)</span> <i>&quot;add DCC QR entry&quot;</i><span style=\"color: navy\">;</span>\r\n      <span style=\"color: navy\">}</span> <i>&quot;set section&quot;</i><span style=\"color: navy\">;</span>\r\n      ddcc<span style=\"color: navy\"><b> -&gt; </b></span>entry.resource = <span style=\"color: maroon\">comp</span> <i>&quot;set composition resource&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;create composition resource&quot;</i><span style=\"color: navy\">;</span>\r\n    ddcc<span style=\"color: navy\"><b> -&gt; </b></span> bundle.entry<b> as </b><span style=\"color: maroon\">entry</span><span style=\"color: navy\">, </span> entry.fullUrl = <b>append</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'urn:uuid:'</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">qrwhoid</span><span style=\"color: navy\">)</span><span style=\"color: navy\">, </span> entry.request<b> as </b><span style=\"color: maroon\">request</span><span style=\"color: navy\">, </span> request.method = <span style=\"color: blue\">'PUT'</span><span style=\"color: navy\">, </span> request.url = <b>append</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'DocumentReference/'</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">qrwhoid</span><span style=\"color: navy\">)</span><span style=\"color: navy\">, </span> <b>create</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'http://smart.who.int/ddcc/StructureDefinition/DDCCDocumentReferenceQR'</span><span style=\"color: navy\">)</span><b> as </b><span style=\"color: maroon\">qr</span><b> then</b><span style=\"color: navy\"> {\r\n</span>      ddcc<b> then </b>DDCCToDocumentReference<span style=\"color: navy\">(</span><span style=\"color: maroon\">ddcc</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">qr</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">qrwhoid</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">pid</span><span style=\"color: navy\">)</span> <i>&quot;setup WHO DocRef&quot;</i><span style=\"color: navy\">;</span>\r\n      ddcc<span style=\"color: navy\"><b> -&gt; </b></span> qr.category<b> as </b><span style=\"color: maroon\">category</span><span style=\"color: navy\">, </span> category.coding<b> as </b><span style=\"color: maroon\">coding</span><span style=\"color: navy\">, </span> coding.system = <span style=\"color: blue\">'http://smart.who.int/ddcc/CodeSystem/DDCCQRCategoryUsageCodeSystem'</span><span style=\"color: navy\">, </span> coding.code = <span style=\"color: blue\">'who'</span> <i>&quot;set category&quot;</i><span style=\"color: navy\">;</span>\r\n      ddcc<span style=\"color: navy\"><b> -&gt; </b></span>qr.description = <span style=\"color: blue\">'WHO QR code for COVID 19 Vaccine Certificate'</span> <i>&quot;set description&quot;</i><span style=\"color: navy\">;</span>\r\n      ddcc<span style=\"color: navy\"><b> -&gt; </b></span>entry.resource = <span style=\"color: maroon\">qr</span> <i>&quot;set WHO QR&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;create WHO QR Doc Ref&quot;</i><span style=\"color: navy\">;</span>\r\n    ddcc<span style=\"color: navy\"><b> -&gt; </b></span> bundle.entry<b> as </b><span style=\"color: maroon\">entry</span><span style=\"color: navy\">, </span> entry.fullUrl = <b>append</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'urn:uuid:'</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">qrdccid</span><span style=\"color: navy\">)</span><span style=\"color: navy\">, </span> entry.request<b> as </b><span style=\"color: maroon\">request</span><span style=\"color: navy\">, </span> request.method = <span style=\"color: blue\">'PUT'</span><span style=\"color: navy\">, </span> request.url = <b>append</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'DocumentReference/'</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">qrdccid</span><span style=\"color: navy\">)</span><span style=\"color: navy\">, </span> <b>create</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'http://smart.who.int/ddcc/StructureDefinition/DDCCDocumentReferenceQR'</span><span style=\"color: navy\">)</span><b> as </b><span style=\"color: maroon\">qr</span><b> then</b><span style=\"color: navy\"> {\r\n</span>      ddcc<b> then </b>DDCCToDocumentReference<span style=\"color: navy\">(</span><span style=\"color: maroon\">ddcc</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">qr</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">qrdccid</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">pid</span><span style=\"color: navy\">)</span> <i>&quot;setup DCC DocRef&quot;</i><span style=\"color: navy\">;</span>\r\n      ddcc<span style=\"color: navy\"><b> -&gt; </b></span> qr.category<b> as </b><span style=\"color: maroon\">category</span><span style=\"color: navy\">, </span> category.coding<b> as </b><span style=\"color: maroon\">coding</span><span style=\"color: navy\">, </span> coding.system = <span style=\"color: blue\">'http://smart.who.int/ddcc/CodeSystem/DDCCQRCategoryUsageCodeSystem'</span><span style=\"color: navy\">, </span> coding.code = <span style=\"color: blue\">'dcc'</span> <i>&quot;set category&quot;</i><span style=\"color: navy\">;</span>\r\n      ddcc<span style=\"color: navy\"><b> -&gt; </b></span>qr.description = <span style=\"color: blue\">'DCC QR code for COVID 19 Vaccine Certificate'</span> <i>&quot;set description&quot;</i><span style=\"color: navy\">;</span>\r\n      ddcc<span style=\"color: navy\"><b> -&gt; </b></span>entry.resource = <span style=\"color: maroon\">qr</span> <i>&quot;set DCC QR&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;create DCC QR Doc Ref&quot;</i><span style=\"color: navy\">;</span>\r\n    ddcc.vaccination first<b> as </b><span style=\"color: maroon\">vaccination</span><span style=\"color: navy\"><b> -&gt; </b></span> bundle.entry<b> as </b><span style=\"color: maroon\">entry</span><span style=\"color: navy\">, </span> entry.fullUrl = <b>append</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'urn:uuid:'</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">iid</span><span style=\"color: navy\">)</span><span style=\"color: navy\">, </span> entry.request<b> as </b><span style=\"color: maroon\">request</span><span style=\"color: navy\">, </span> request.method = <span style=\"color: blue\">'PUT'</span><span style=\"color: navy\">, </span> request.url = <b>append</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'Immunization/'</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">iid</span><span style=\"color: navy\">)</span><span style=\"color: navy\">, </span> <b>create</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'http://smart.who.int/ddcc/StructureDefinition/DDCCImmunization'</span><span style=\"color: navy\">)</span><b> as </b><span style=\"color: maroon\">immunization</span><b> then</b><span style=\"color: navy\"> {\r\n</span>      ddcc.certificate<b> as </b><span style=\"color: maroon\">certificate</span><b> then </b>DDCCToImmunization<span style=\"color: navy\">(</span><span style=\"color: maroon\">vaccination</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">immunization</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">certificate</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">iid</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">pid</span><span style=\"color: navy\">)</span> <i>&quot;setup immunization&quot;</i><span style=\"color: navy\">;</span>\r\n      ddcc<span style=\"color: navy\"><b> -&gt; </b></span>entry.resource = <span style=\"color: maroon\">immunization</span> <i>&quot;set immunization resource&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;create immunization resource&quot;</i><span style=\"color: navy\">;</span>\r\n    ddcc.vaccination first<b> as </b><span style=\"color: maroon\">vaccination</span><span style=\"color: navy\"><b> -&gt; </b></span> bundle.entry<b> as </b><span style=\"color: maroon\">entry</span><span style=\"color: navy\">, </span> entry.fullUrl = <b>append</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'urn:uuid:'</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">irid</span><span style=\"color: navy\">)</span><span style=\"color: navy\">, </span> entry.request<b> as </b><span style=\"color: maroon\">request</span><span style=\"color: navy\">, </span> request.method = <span style=\"color: blue\">'PUT'</span><span style=\"color: navy\">, </span> request.url = <b>append</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'ImmunizationRecommendation/'</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">irid</span><span style=\"color: navy\">)</span><span style=\"color: navy\">, </span> <b>create</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'http://smart.who.int/ddcc/StructureDefinition/DDCCImmunizationRecommendation'</span><span style=\"color: navy\">)</span><b> as </b><span style=\"color: maroon\">immrec</span><b> then</b><span style=\"color: navy\"> {\r\n</span>      vaccination<b> then </b>DDCCToImmRec<span style=\"color: navy\">(</span><span style=\"color: maroon\">vaccination</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">immrec</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">irid</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">iid</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">pid</span><span style=\"color: navy\">)</span> <i>&quot;setup immunization recommendation&quot;</i><span style=\"color: navy\">;</span>\r\n      ddcc<span style=\"color: navy\"><b> -&gt; </b></span>entry.resource = <span style=\"color: maroon\">immrec</span> <i>&quot;set immunization recommendation resource&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;create immunization recommendation resource&quot;</i><span style=\"color: navy\">;</span>\r\n  <span style=\"color: navy\">}</span> <i>&quot;set uuids&quot;</i><span style=\"color: navy\">;</span>\r\n<span style=\"color: navy\">}\r\n\r\n</span><b>group </b>DDCCToImmunization<span style=\"color: navy\">(</span><b>source</b> <span style=\"color: maroon\">src</span>, <b>target</b> <span style=\"color: maroon\">immunization</span><span style=\"color: navy\"> : </span>DDCCImmunization, <b>source</b> <span style=\"color: maroon\">certificate</span>, <b>source</b> <span style=\"color: maroon\">iid</span>, <b>source</b> <span style=\"color: maroon\">pid</span><span style=\"color: navy\">)</span><span style=\"color: navy\"> {\r\n</span>  iid<span style=\"color: navy\"><b> -&gt; </b></span>immunization.id = <span style=\"color: maroon\">iid</span> <i>&quot;set id&quot;</i><span style=\"color: navy\">;</span>\r\n  src.brand<b> as </b><span style=\"color: maroon\">brand</span><span style=\"color: navy\"><b> -&gt; </b></span>immunization.extension<b> as </b><span style=\"color: maroon\">ext</span><b> then</b><span style=\"color: navy\"> {\r\n</span>    brand<span style=\"color: navy\"><b> -&gt; </b></span> ext.url = <span style=\"color: blue\">'http://smart.who.int/ddcc/StructureDefinition/DDCCVaccineBrand'</span><span style=\"color: navy\">, </span> ext.value = <span style=\"color: maroon\">brand</span> <i>&quot;set brand extension values&quot;</i><span style=\"color: navy\">;</span>\r\n  <span style=\"color: navy\">}</span> <i>&quot;set brand extension&quot;</i><span style=\"color: navy\">;</span>\r\n  src.maholder<b> as </b><span style=\"color: maroon\">maholder</span><span style=\"color: navy\"><b> -&gt; </b></span>immunization.extension<b> as </b><span style=\"color: maroon\">ext</span><b> then</b><span style=\"color: navy\"> {\r\n</span>    maholder<span style=\"color: navy\"><b> -&gt; </b></span> ext.url = <span style=\"color: blue\">'http://smart.who.int/ddcc/StructureDefinition/DDCCVaccineMarketAuthorization'</span><span style=\"color: navy\">, </span> ext.value = <span style=\"color: maroon\">maholder</span> <i>&quot;set MA Holder extension values&quot;</i><span style=\"color: navy\">;</span>\r\n  <span style=\"color: navy\">}</span> <i>&quot;set maholder extension&quot;</i><span style=\"color: navy\">;</span>\r\n  src.country<b> as </b><span style=\"color: maroon\">country</span><span style=\"color: navy\"><b> -&gt; </b></span>immunization.extension<b> as </b><span style=\"color: maroon\">ext</span><b> then</b><span style=\"color: navy\"> {\r\n</span>    country.code<b> as </b><span style=\"color: maroon\">code</span><span style=\"color: navy\"><b> -&gt; </b></span> ext.url = <span style=\"color: blue\">'http://smart.who.int/ddcc/StructureDefinition/DDCCCountryOfVaccination'</span><span style=\"color: navy\">, </span> ext.value = <span style=\"color: maroon\">code</span> <i>&quot;set country extension values&quot;</i><span style=\"color: navy\">;</span>\r\n  <span style=\"color: navy\">}</span> <i>&quot;set country extension&quot;</i><span style=\"color: navy\">;</span>\r\n  src.validFrom<b> as </b><span style=\"color: maroon\">validFrom</span><span style=\"color: navy\"><b> -&gt; </b></span>immunization.extension<b> as </b><span style=\"color: maroon\">ext</span><b> then</b><span style=\"color: navy\"> {\r\n</span>    validFrom<span style=\"color: navy\"><b> -&gt; </b></span> ext.url = <span style=\"color: blue\">'http://smart.who.int/ddcc/StructureDefinition/DDCCVaccineValidFrom'</span><span style=\"color: navy\">, </span> ext.value = <span style=\"color: maroon\">validFrom</span> <i>&quot;set valid from extension values&quot;</i><span style=\"color: navy\">;</span>\r\n  <span style=\"color: navy\">}</span> <i>&quot;set vaccine valid extension&quot;</i><span style=\"color: navy\">;</span>\r\n  src<span style=\"color: navy\"><b> -&gt; </b></span>immunization.status = <span style=\"color: blue\">'completed'</span> <i>&quot;set status&quot;</i><span style=\"color: navy\">;</span>\r\n  src.vaccine<b> as </b><span style=\"color: maroon\">vaccine</span><span style=\"color: navy\"><b> -&gt; </b></span> immunization.vaccineCode<b> as </b><span style=\"color: maroon\">vacCode</span><span style=\"color: navy\">, </span> vacCode.coding = <span style=\"color: maroon\">vaccine</span> <i>&quot;set vaccine&quot;</i><span style=\"color: navy\">;</span>\r\n  src<span style=\"color: navy\"><b> -&gt; </b></span> immunization.patient<b> as </b><span style=\"color: maroon\">patient</span><span style=\"color: navy\">, </span> patient.reference = <b>append</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'Patient/'</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">pid</span><span style=\"color: navy\">)</span> <i>&quot;set patient&quot;</i><span style=\"color: navy\">;</span>\r\n  src.manufacturer<b> as </b><span style=\"color: maroon\">manufacturer</span><span style=\"color: navy\"><b> -&gt; </b></span> immunization.manufacturer<b> as </b><span style=\"color: maroon\">tman</span><span style=\"color: navy\">, </span> tman.identifier<b> as </b><span style=\"color: maroon\">ident</span><b> then</b><span style=\"color: navy\"> {\r\n</span>    manufacturer.system<b> as </b><span style=\"color: maroon\">system</span><span style=\"color: navy\"><b> -&gt; </b></span>ident.system = <span style=\"color: maroon\">system</span> <i>&quot;set system&quot;</i><span style=\"color: navy\">;</span>\r\n    manufacturer.code<b> as </b><span style=\"color: maroon\">code</span><span style=\"color: navy\"><b> -&gt; </b></span>ident.value = <span style=\"color: maroon\">code</span> <i>&quot;set value&quot;</i><span style=\"color: navy\">;</span>\r\n  <span style=\"color: navy\">}</span> <i>&quot;set manufacturer identifier&quot;</i><span style=\"color: navy\">;</span>\r\n  src.lot<b> as </b><span style=\"color: maroon\">lot</span><span style=\"color: navy\"><b> -&gt; </b></span>immunization.lotNumber = <span style=\"color: maroon\">lot</span> <i>&quot;set lot number&quot;</i><span style=\"color: navy\">;</span>\r\n  src.date<b> as </b><span style=\"color: maroon\">date</span><span style=\"color: navy\"><b> -&gt; </b></span>immunization.occurrence = <span style=\"color: maroon\">date</span> <i>&quot;set occurrence date&quot;</i><span style=\"color: navy\">;</span>\r\n  src.centre<b> as </b><span style=\"color: maroon\">centre</span><span style=\"color: navy\"><b> -&gt; </b></span>immunization.location<b> as </b><span style=\"color: maroon\">location</span><b> then</b><span style=\"color: navy\"> {\r\n</span>    centre<span style=\"color: navy\"><b> -&gt; </b></span>location.display = <span style=\"color: maroon\">centre</span> <i>&quot;set location display&quot;</i><span style=\"color: navy\">;</span>\r\n  <span style=\"color: navy\">}</span> <i>&quot;set location&quot;</i><span style=\"color: navy\">;</span>\r\n  src.practitioner<b> as </b><span style=\"color: maroon\">practitioner</span><span style=\"color: navy\"><b> -&gt; </b></span>immunization.performer<b> as </b><span style=\"color: maroon\">performer</span><b> then</b><span style=\"color: navy\"> {\r\n</span>    practitioner.value<b> as </b><span style=\"color: maroon\">hw</span><span style=\"color: navy\"><b> -&gt; </b></span>performer.actor<b> as </b><span style=\"color: maroon\">actor</span><b> then</b><span style=\"color: navy\"> {\r\n</span>      hw<span style=\"color: navy\"><b> -&gt; </b></span> actor.type = <span style=\"color: blue\">'Practitioner'</span><span style=\"color: navy\">, </span> actor.identifier<b> as </b><span style=\"color: maroon\">identifier</span><b> then</b><span style=\"color: navy\"> {\r\n</span>        hw<span style=\"color: navy\"><b> -&gt; </b></span>identifier.value = <span style=\"color: maroon\">hw</span> <i>&quot;set hw identifier&quot;</i><span style=\"color: navy\">;</span>\r\n      <span style=\"color: navy\">}</span> <i>&quot;set actor&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;set performer&quot;</i><span style=\"color: navy\">;</span>\r\n  <span style=\"color: navy\">}</span> <i>&quot;set practitioner&quot;</i><span style=\"color: navy\">;</span>\r\n  src<span style=\"color: navy\"><b> -&gt; </b></span>immunization.protocolApplied<b> as </b><span style=\"color: maroon\">protocol</span><b> then</b><span style=\"color: navy\"> {\r\n</span>    src<span style=\"color: navy\"><b> -&gt; </b></span>protocol.authority<b> as </b><span style=\"color: maroon\">authority</span><b> then</b><span style=\"color: navy\"> {\r\n</span>      certificate.issuer<b> as </b><span style=\"color: maroon\">issuer</span><span style=\"color: navy\"><b> -&gt; </b></span>authority.type = <span style=\"color: blue\">'Organization'</span><b> then</b><span style=\"color: navy\"> {\r\n</span>        issuer.identifier<b> as </b><span style=\"color: maroon\">pha</span><span style=\"color: navy\"><b> -&gt; </b></span>authority.identifier<b> as </b><span style=\"color: maroon\">identifier</span><b> then</b><span style=\"color: navy\"> {\r\n</span>          pha.value<b> as </b><span style=\"color: maroon\">value</span><span style=\"color: navy\"><b> -&gt; </b></span>identifier.value = <span style=\"color: maroon\">value</span> <i>&quot;set pha&quot;</i><span style=\"color: navy\">;</span>\r\n        <span style=\"color: navy\">}</span> <i>&quot;set issuer identifier&quot;</i><span style=\"color: navy\">;</span>\r\n      <span style=\"color: navy\">}</span> <i>&quot;set issuer&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;set authority&quot;</i><span style=\"color: navy\">;</span>\r\n    src.disease<b> as </b><span style=\"color: maroon\">disease</span><span style=\"color: navy\"><b> -&gt; </b></span>protocol.targetDisease<b> as </b><span style=\"color: maroon\">tdisease</span><b> then</b><span style=\"color: navy\"> {\r\n</span>      disease<span style=\"color: navy\"><b> -&gt; </b></span>tdisease.coding = <span style=\"color: maroon\">disease</span> <i>&quot;set target disease code&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;set target disease&quot;</i><span style=\"color: navy\">;</span>\r\n    src.dose<b> as </b><span style=\"color: maroon\">dose</span><span style=\"color: navy\"><b> -&gt; </b></span>protocol.doseNumber = <span style=\"color: maroon\">dose</span> <i>&quot;set dose number&quot;</i><span style=\"color: navy\">;</span>\r\n    src.totalDoses<b> as </b><span style=\"color: maroon\">totalDoses</span><span style=\"color: navy\"><b> -&gt; </b></span>protocol.seriesDoses = <span style=\"color: maroon\">totalDoses</span> <i>&quot;set total doses&quot;</i><span style=\"color: navy\">;</span>\r\n  <span style=\"color: navy\">}</span> <i>&quot;set protocolApplied&quot;</i><span style=\"color: navy\">;</span>\r\n<span style=\"color: navy\">}\r\n\r\n</span><b>group </b>DDCCToImmRec<span style=\"color: navy\">(</span><b>source</b> <span style=\"color: maroon\">src</span>, <b>target</b> <span style=\"color: maroon\">immrec</span><span style=\"color: navy\"> : </span>DDCCImmunizationRecommendation, <b>source</b> <span style=\"color: maroon\">irid</span>, <b>source</b> <span style=\"color: maroon\">iid</span>, <b>source</b> <span style=\"color: maroon\">pid</span><span style=\"color: navy\">)</span><span style=\"color: navy\"> {\r\n</span>  src.date<b> as </b><span style=\"color: maroon\">date</span><span style=\"color: navy\"><b> -&gt; </b></span>immrec.date = <span style=\"color: maroon\">date</span> <i>&quot;set date&quot;</i><span style=\"color: navy\">;</span>\r\n  src<span style=\"color: navy\"><b> -&gt; </b></span> immrec.patient<b> as </b><span style=\"color: maroon\">patient</span><span style=\"color: navy\">, </span> patient.reference = <b>append</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'Patient/'</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">pid</span><span style=\"color: navy\">)</span> <i>&quot;set patient&quot;</i><span style=\"color: navy\">;</span>\r\n  src<span style=\"color: navy\"><b> -&gt; </b></span>immrec.recommendation<b> as </b><span style=\"color: maroon\">rec</span><b> then</b><span style=\"color: navy\"> {\r\n</span>    src.vaccine<b> as </b><span style=\"color: maroon\">vaccine</span><span style=\"color: navy\"><b> -&gt; </b></span>rec.vaccineCode<b> as </b><span style=\"color: maroon\">vaccineCode</span><b> then</b><span style=\"color: navy\"> {\r\n</span>      vaccine<span style=\"color: navy\"><b> -&gt; </b></span>vaccineCode.coding = <span style=\"color: maroon\">vaccine</span> <i>&quot;set vaccine code coding&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;set vaccine code&quot;</i><span style=\"color: navy\">;</span>\r\n    src.disease<b> as </b><span style=\"color: maroon\">disease</span><span style=\"color: navy\"><b> -&gt; </b></span>rec.targetDisease<b> as </b><span style=\"color: maroon\">targetDisease</span><b> then</b><span style=\"color: navy\"> {\r\n</span>      disease<span style=\"color: navy\"><b> -&gt; </b></span>targetDisease.coding = <span style=\"color: maroon\">disease</span> <i>&quot;set target disease coding&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;set target disease&quot;</i><span style=\"color: navy\">;</span>\r\n    src<span style=\"color: navy\"><b> -&gt; </b></span>rec.forecastStatus<b> as </b><span style=\"color: maroon\">forecast</span><b> then</b><span style=\"color: navy\"> {\r\n</span>      src<span style=\"color: navy\"><b> -&gt; </b></span>forecast.coding<b> as </b><span style=\"color: maroon\">coding</span><b> then</b><span style=\"color: navy\"> {\r\n</span>        src<span style=\"color: navy\"><b> -&gt; </b></span>coding.system = <span style=\"color: blue\">'http://terminology.hl7.org/2.1.0/CodeSystem-immunization-recommendation-status.html'</span> <i>&quot;set forecast system&quot;</i><span style=\"color: navy\">;</span>\r\n        src<span style=\"color: navy\"><b> -&gt; </b></span>coding.code = <span style=\"color: blue\">'due'</span> <i>&quot;set forecast code&quot;</i><span style=\"color: navy\">;</span>\r\n      <span style=\"color: navy\">}</span> <i>&quot;set forecast status coding&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;set forecast status&quot;</i><span style=\"color: navy\">;</span>\r\n    src<span style=\"color: navy\"><b> -&gt; </b></span>rec.dateCriterion<b> as </b><span style=\"color: maroon\">due_date</span><b> then</b><span style=\"color: navy\"> {\r\n</span>      src<span style=\"color: navy\"><b> -&gt; </b></span>due_date.code<b> as </b><span style=\"color: maroon\">code</span><b> then</b><span style=\"color: navy\"> {\r\n</span>        src<span style=\"color: navy\"><b> -&gt; </b></span>code.coding<b> as </b><span style=\"color: maroon\">coding</span><b> then</b><span style=\"color: navy\"> {\r\n</span>          src<span style=\"color: navy\"><b> -&gt; </b></span>coding.system = <span style=\"color: blue\">'http://loinc.org'</span> <i>&quot;set due date code system&quot;</i><span style=\"color: navy\">;</span>\r\n          src<span style=\"color: navy\"><b> -&gt; </b></span>coding.code = <span style=\"color: blue\">'30980-7'</span> <i>&quot;set due date code code&quot;</i><span style=\"color: navy\">;</span>\r\n        <span style=\"color: navy\">}</span> <i>&quot;set due date code coding&quot;</i><span style=\"color: navy\">;</span>\r\n      <span style=\"color: navy\">}</span> <i>&quot;set due date code&quot;</i><span style=\"color: navy\">;</span>\r\n      src.nextDose<b> as </b><span style=\"color: maroon\">nextDose</span><span style=\"color: navy\"><b> -&gt; </b></span>due_date.value = <span style=\"color: maroon\">nextDose</span> <i>&quot;set due date value&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;set date criterion&quot;</i><span style=\"color: navy\">;</span>\r\n    src.dose<b> as </b><span style=\"color: maroon\">dose</span><span style=\"color: navy\"><b> -&gt; </b></span>rec.doseNumber = <span style=\"color: navy\">(</span>dose.toInteger() + 1<span style=\"color: navy\">)</span> <i>&quot;set dose number&quot;</i><span style=\"color: navy\">;</span>\r\n    src.totalDoses<b> as </b><span style=\"color: maroon\">totalDoses</span><span style=\"color: navy\"><b> -&gt; </b></span>rec.seriesDoses = <span style=\"color: maroon\">totalDoses</span> <i>&quot;set total doses&quot;</i><span style=\"color: navy\">;</span>\r\n    src<span style=\"color: navy\"><b> -&gt; </b></span> rec.supportingImmunization<b> as </b><span style=\"color: maroon\">imm</span><span style=\"color: navy\">, </span> imm.reference = <b>append</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'Immunization/'</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">iid</span><span style=\"color: navy\">)</span> <i>&quot;set supporting immunization&quot;</i><span style=\"color: navy\">;</span>\r\n  <span style=\"color: navy\">}</span> <i>&quot;set recommendation&quot;</i><span style=\"color: navy\">;</span>\r\n<span style=\"color: navy\">}\r\n\r\n</span></pre></div>"
  },
  "url" : "http://smart.who.int/ddcc/StructureMap/CoreDataSetVSLibrary",
  "version" : "1.0.0",
  "name" : "CoreDataSetVSLibrary",
  "status" : "draft",
  "date" : "2024-10-17T05:03:04+00:00",
  "publisher" : "WHO",
  "contact" : [
    {
      "name" : "WHO",
      "telecom" : [
        {
          "system" : "url",
          "value" : "http://who.int"
        }
      ]
    }
  ],
  "jurisdiction" : [
    {
      "coding" : [
        {
          "system" : "http://unstats.un.org/unsd/methods/m49/m49.htm",
          "code" : "001"
        }
      ]
    }
  ],
  "structure" : [
    {
      "url" : "http://smart.who.int/ddcc/StructureDefinition/DDCCCoreDataSetVS",
      "mode" : "source",
      "alias" : "DDCCVS"
    },
    {
      "url" : "http://hl7.org/fhir/StructureDefinition/Bundle",
      "mode" : "target",
      "alias" : "AddBundle"
    },
    {
      "url" : "http://hl7.org/fhir/StructureDefinition/Patient",
      "mode" : "target",
      "alias" : "Patient"
    },
    {
      "url" : "http://smart.who.int/ddcc/StructureDefinition/DDCCPatient",
      "mode" : "target",
      "alias" : "DDCCPatient"
    },
    {
      "url" : "http://smart.who.int/ddcc/StructureDefinition/DDCCDocumentReferenceQR",
      "mode" : "target",
      "alias" : "DDCCDocRefQR"
    },
    {
      "url" : "http://smart.who.int/ddcc/StructureDefinition/DDCCVSComposition",
      "mode" : "target",
      "alias" : "DDCCVSComposition"
    },
    {
      "url" : "http://smart.who.int/ddcc/StructureDefinition/DDCCImmunization",
      "mode" : "target",
      "alias" : "DDCCImmunization"
    },
    {
      "url" : "http://smart.who.int/ddcc/StructureDefinition/DDCCImmunizationRecommendation",
      "mode" : "target",
      "alias" : "DDCCImmRec"
    }
  ],
  "import" : [
    🔗 "http://smart.who.int/ddcc/StructureMap/CoreDataSetLibrary"
  ],
  "group" : [
    {
      "name" : "VSToAddBundle",
      "typeMode" : "none",
      "input" : [
        {
          "name" : "ddcc",
          "type" : "DDCCVS",
          "mode" : "source"
        },
        {
          "name" : "bundle",
          "type" : "AddBundle",
          "mode" : "target"
        }
      ],
      "rule" : [
        {
          "name" : "set bundle type",
          "source" : [
            {
              "context" : "ddcc"
            }
          ],
          "target" : [
            {
              "context" : "bundle",
              "contextType" : "variable",
              "element" : "type",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueString" : "transaction"
                }
              ]
            }
          ]
        },
        {
          "name" : "set uuids",
          "source" : [
            {
              "context" : "ddcc"
            }
          ],
          "target" : [
            {
              "contextType" : "variable",
              "variable" : "pid",
              "transform" : "uuid"
            },
            {
              "contextType" : "variable",
              "variable" : "compid",
              "transform" : "uuid"
            },
            {
              "contextType" : "variable",
              "variable" : "iid",
              "transform" : "uuid"
            },
            {
              "contextType" : "variable",
              "variable" : "irid",
              "transform" : "uuid"
            },
            {
              "contextType" : "variable",
              "variable" : "qrwhoid",
              "transform" : "uuid"
            },
            {
              "contextType" : "variable",
              "variable" : "qrdccid",
              "transform" : "uuid"
            }
          ],
          "rule" : [
            {
              "name" : "create patient resource",
              "source" : [
                {
                  "context" : "ddcc"
                }
              ],
              "target" : [
                {
                  "context" : "bundle",
                  "contextType" : "variable",
                  "element" : "entry",
                  "variable" : "entry"
                },
                {
                  "context" : "entry",
                  "contextType" : "variable",
                  "element" : "fullUrl",
                  "transform" : "append",
                  "parameter" : [
                    {
                      "valueString" : "urn:uuid:"
                    },
                    {
                      "valueId" : "pid"
                    }
                  ]
                },
                {
                  "context" : "entry",
                  "contextType" : "variable",
                  "element" : "request",
                  "variable" : "request"
                },
                {
                  "context" : "request",
                  "contextType" : "variable",
                  "element" : "method",
                  "transform" : "copy",
                  "parameter" : [
                    {
                      "valueString" : "PUT"
                    }
                  ]
                },
                {
                  "context" : "request",
                  "contextType" : "variable",
                  "element" : "url",
                  "transform" : "append",
                  "parameter" : [
                    {
                      "valueString" : "Patient/"
                    },
                    {
                      "valueId" : "pid"
                    }
                  ]
                },
                {
                  "contextType" : "variable",
                  "variable" : "patient",
                  "transform" : "create",
                  "parameter" : [
                    {
                      "valueString" : "http://smart.who.int/ddcc/StructureDefinition/DDCCPatient"
                    }
                  ]
                }
              ],
              "rule" : [
                {
                  "name" : "setup patient",
                  "source" : [
                    {
                      "context" : "ddcc"
                    }
                  ],
                  "dependent" : [
                    {
                      "name" : "DDCCToPatient",
                      "variable" : [
                        "ddcc",
                        "patient",
                        "pid"
                      ]
                    }
                  ]
                },
                {
                  "name" : "set patient resource",
                  "source" : [
                    {
                      "context" : "ddcc"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "entry",
                      "contextType" : "variable",
                      "element" : "resource",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueId" : "patient"
                        }
                      ]
                    }
                  ]
                }
              ]
            },
            {
              "name" : "create composition resource",
              "source" : [
                {
                  "context" : "ddcc"
                }
              ],
              "target" : [
                {
                  "context" : "bundle",
                  "contextType" : "variable",
                  "element" : "entry",
                  "variable" : "entry"
                },
                {
                  "context" : "entry",
                  "contextType" : "variable",
                  "element" : "fullUrl",
                  "transform" : "append",
                  "parameter" : [
                    {
                      "valueString" : "urn:uuid:"
                    },
                    {
                      "valueId" : "compid"
                    }
                  ]
                },
                {
                  "context" : "entry",
                  "contextType" : "variable",
                  "element" : "request",
                  "variable" : "request"
                },
                {
                  "context" : "request",
                  "contextType" : "variable",
                  "element" : "method",
                  "transform" : "copy",
                  "parameter" : [
                    {
                      "valueString" : "PUT"
                    }
                  ]
                },
                {
                  "context" : "request",
                  "contextType" : "variable",
                  "element" : "url",
                  "transform" : "append",
                  "parameter" : [
                    {
                      "valueString" : "Composition/"
                    },
                    {
                      "valueId" : "compid"
                    }
                  ]
                },
                {
                  "contextType" : "variable",
                  "variable" : "comp",
                  "transform" : "create",
                  "parameter" : [
                    {
                      "valueString" : "http://smart.who.int/ddcc/StructureDefinition/DDCCVSComposition"
                    }
                  ]
                }
              ],
              "rule" : [
                {
                  "name" : "setup composition",
                  "source" : [
                    {
                      "context" : "ddcc"
                    }
                  ],
                  "dependent" : [
                    {
                      "name" : "DDCCToComposition",
                      "variable" : [
                        "ddcc",
                        "comp",
                        "compid",
                        "pid"
                      ]
                    }
                  ]
                },
                {
                  "name" : "set category",
                  "source" : [
                    {
                      "context" : "ddcc"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "comp",
                      "contextType" : "variable",
                      "element" : "category",
                      "variable" : "category"
                    },
                    {
                      "context" : "category",
                      "contextType" : "variable",
                      "element" : "coding",
                      "variable" : "coding"
                    },
                    {
                      "context" : "coding",
                      "contextType" : "variable",
                      "element" : "system",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueString" : "http://smart.who.int/ddcc/CodeSystem/DDCCCompositionCategoryCodeSystem"
                        }
                      ]
                    },
                    {
                      "context" : "coding",
                      "contextType" : "variable",
                      "element" : "code",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueString" : "ddcc-vs"
                        }
                      ]
                    }
                  ]
                },
                {
                  "name" : "set title",
                  "source" : [
                    {
                      "context" : "ddcc"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "comp",
                      "contextType" : "variable",
                      "element" : "title",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueString" : "International Certificate of Vaccination or Prophylaxis"
                        }
                      ]
                    }
                  ]
                },
                {
                  "name" : "set section",
                  "source" : [
                    {
                      "context" : "ddcc"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "comp",
                      "contextType" : "variable",
                      "element" : "section",
                      "variable" : "section"
                    }
                  ],
                  "rule" : [
                    {
                      "name" : "set code",
                      "source" : [
                        {
                          "context" : "ddcc"
                        }
                      ],
                      "target" : [
                        {
                          "context" : "section",
                          "contextType" : "variable",
                          "element" : "code",
                          "variable" : "code"
                        },
                        {
                          "context" : "code",
                          "contextType" : "variable",
                          "element" : "coding",
                          "variable" : "coding"
                        },
                        {
                          "context" : "coding",
                          "contextType" : "variable",
                          "element" : "system",
                          "transform" : "copy",
                          "parameter" : [
                            {
                              "valueString" : "http://loinc.org"
                            }
                          ]
                        },
                        {
                          "context" : "coding",
                          "contextType" : "variable",
                          "element" : "code",
                          "transform" : "copy",
                          "parameter" : [
                            {
                              "valueString" : "11369-6"
                            }
                          ]
                        }
                      ]
                    },
                    {
                      "name" : "set certificate",
                      "source" : [
                        {
                          "context" : "ddcc",
                          "element" : "certificate",
                          "variable" : "certificate"
                        }
                      ],
                      "rule" : [
                        {
                          "name" : "set author",
                          "source" : [
                            {
                              "context" : "certificate",
                              "element" : "issuer",
                              "variable" : "issuer"
                            }
                          ],
                          "target" : [
                            {
                              "context" : "section",
                              "contextType" : "variable",
                              "element" : "author",
                              "transform" : "copy",
                              "parameter" : [
                                {
                                  "valueId" : "issuer"
                                }
                              ]
                            }
                          ]
                        }
                      ]
                    },
                    {
                      "name" : "set focus",
                      "source" : [
                        {
                          "context" : "ddcc"
                        }
                      ],
                      "target" : [
                        {
                          "context" : "section",
                          "contextType" : "variable",
                          "element" : "focus",
                          "variable" : "focus"
                        },
                        {
                          "context" : "focus",
                          "contextType" : "variable",
                          "element" : "reference",
                          "transform" : "append",
                          "parameter" : [
                            {
                              "valueString" : "Immunization/"
                            },
                            {
                              "valueId" : "iid"
                            }
                          ]
                        }
                      ]
                    },
                    {
                      "name" : "add Immunization entry",
                      "source" : [
                        {
                          "context" : "ddcc"
                        }
                      ],
                      "target" : [
                        {
                          "context" : "section",
                          "contextType" : "variable",
                          "element" : "entry",
                          "variable" : "entry"
                        },
                        {
                          "context" : "entry",
                          "contextType" : "variable",
                          "element" : "reference",
                          "transform" : "append",
                          "parameter" : [
                            {
                              "valueString" : "Immunization/"
                            },
                            {
                              "valueId" : "iid"
                            }
                          ]
                        }
                      ]
                    },
                    {
                      "name" : "add ImmunizationRecommendation entry",
                      "source" : [
                        {
                          "context" : "ddcc"
                        }
                      ],
                      "target" : [
                        {
                          "context" : "section",
                          "contextType" : "variable",
                          "element" : "entry",
                          "variable" : "entry"
                        },
                        {
                          "context" : "entry",
                          "contextType" : "variable",
                          "element" : "reference",
                          "transform" : "append",
                          "parameter" : [
                            {
                              "valueString" : "ImmunizationRecommendation/"
                            },
                            {
                              "valueId" : "irid"
                            }
                          ]
                        }
                      ]
                    },
                    {
                      "name" : "add WHO QR entry",
                      "source" : [
                        {
                          "context" : "ddcc"
                        }
                      ],
                      "target" : [
                        {
                          "context" : "section",
                          "contextType" : "variable",
                          "element" : "entry",
                          "variable" : "entry"
                        },
                        {
                          "context" : "entry",
                          "contextType" : "variable",
                          "element" : "reference",
                          "transform" : "append",
                          "parameter" : [
                            {
                              "valueString" : "DocumentReference/"
                            },
                            {
                              "valueId" : "qrwhoid"
                            }
                          ]
                        }
                      ]
                    },
                    {
                      "name" : "add DCC QR entry",
                      "source" : [
                        {
                          "context" : "ddcc"
                        }
                      ],
                      "target" : [
                        {
                          "context" : "section",
                          "contextType" : "variable",
                          "element" : "entry",
                          "variable" : "entry"
                        },
                        {
                          "context" : "entry",
                          "contextType" : "variable",
                          "element" : "reference",
                          "transform" : "append",
                          "parameter" : [
                            {
                              "valueString" : "DocumentReference/"
                            },
                            {
                              "valueId" : "qrdccid"
                            }
                          ]
                        }
                      ]
                    }
                  ]
                },
                {
                  "name" : "set composition resource",
                  "source" : [
                    {
                      "context" : "ddcc"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "entry",
                      "contextType" : "variable",
                      "element" : "resource",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueId" : "comp"
                        }
                      ]
                    }
                  ]
                }
              ]
            },
            {
              "name" : "create WHO QR Doc Ref",
              "source" : [
                {
                  "context" : "ddcc"
                }
              ],
              "target" : [
                {
                  "context" : "bundle",
                  "contextType" : "variable",
                  "element" : "entry",
                  "variable" : "entry"
                },
                {
                  "context" : "entry",
                  "contextType" : "variable",
                  "element" : "fullUrl",
                  "transform" : "append",
                  "parameter" : [
                    {
                      "valueString" : "urn:uuid:"
                    },
                    {
                      "valueId" : "qrwhoid"
                    }
                  ]
                },
                {
                  "context" : "entry",
                  "contextType" : "variable",
                  "element" : "request",
                  "variable" : "request"
                },
                {
                  "context" : "request",
                  "contextType" : "variable",
                  "element" : "method",
                  "transform" : "copy",
                  "parameter" : [
                    {
                      "valueString" : "PUT"
                    }
                  ]
                },
                {
                  "context" : "request",
                  "contextType" : "variable",
                  "element" : "url",
                  "transform" : "append",
                  "parameter" : [
                    {
                      "valueString" : "DocumentReference/"
                    },
                    {
                      "valueId" : "qrwhoid"
                    }
                  ]
                },
                {
                  "contextType" : "variable",
                  "variable" : "qr",
                  "transform" : "create",
                  "parameter" : [
                    {
                      "valueString" : "http://smart.who.int/ddcc/StructureDefinition/DDCCDocumentReferenceQR"
                    }
                  ]
                }
              ],
              "rule" : [
                {
                  "name" : "setup WHO DocRef",
                  "source" : [
                    {
                      "context" : "ddcc"
                    }
                  ],
                  "dependent" : [
                    {
                      "name" : "DDCCToDocumentReference",
                      "variable" : [
                        "ddcc",
                        "qr",
                        "qrwhoid",
                        "pid"
                      ]
                    }
                  ]
                },
                {
                  "name" : "set category",
                  "source" : [
                    {
                      "context" : "ddcc"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "qr",
                      "contextType" : "variable",
                      "element" : "category",
                      "variable" : "category"
                    },
                    {
                      "context" : "category",
                      "contextType" : "variable",
                      "element" : "coding",
                      "variable" : "coding"
                    },
                    {
                      "context" : "coding",
                      "contextType" : "variable",
                      "element" : "system",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueString" : "http://smart.who.int/ddcc/CodeSystem/DDCCQRCategoryUsageCodeSystem"
                        }
                      ]
                    },
                    {
                      "context" : "coding",
                      "contextType" : "variable",
                      "element" : "code",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueString" : "who"
                        }
                      ]
                    }
                  ]
                },
                {
                  "name" : "set description",
                  "source" : [
                    {
                      "context" : "ddcc"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "qr",
                      "contextType" : "variable",
                      "element" : "description",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueString" : "WHO QR code for COVID 19 Vaccine Certificate"
                        }
                      ]
                    }
                  ]
                },
                {
                  "name" : "set WHO QR",
                  "source" : [
                    {
                      "context" : "ddcc"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "entry",
                      "contextType" : "variable",
                      "element" : "resource",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueId" : "qr"
                        }
                      ]
                    }
                  ]
                }
              ]
            },
            {
              "name" : "create DCC QR Doc Ref",
              "source" : [
                {
                  "context" : "ddcc"
                }
              ],
              "target" : [
                {
                  "context" : "bundle",
                  "contextType" : "variable",
                  "element" : "entry",
                  "variable" : "entry"
                },
                {
                  "context" : "entry",
                  "contextType" : "variable",
                  "element" : "fullUrl",
                  "transform" : "append",
                  "parameter" : [
                    {
                      "valueString" : "urn:uuid:"
                    },
                    {
                      "valueId" : "qrdccid"
                    }
                  ]
                },
                {
                  "context" : "entry",
                  "contextType" : "variable",
                  "element" : "request",
                  "variable" : "request"
                },
                {
                  "context" : "request",
                  "contextType" : "variable",
                  "element" : "method",
                  "transform" : "copy",
                  "parameter" : [
                    {
                      "valueString" : "PUT"
                    }
                  ]
                },
                {
                  "context" : "request",
                  "contextType" : "variable",
                  "element" : "url",
                  "transform" : "append",
                  "parameter" : [
                    {
                      "valueString" : "DocumentReference/"
                    },
                    {
                      "valueId" : "qrdccid"
                    }
                  ]
                },
                {
                  "contextType" : "variable",
                  "variable" : "qr",
                  "transform" : "create",
                  "parameter" : [
                    {
                      "valueString" : "http://smart.who.int/ddcc/StructureDefinition/DDCCDocumentReferenceQR"
                    }
                  ]
                }
              ],
              "rule" : [
                {
                  "name" : "setup DCC DocRef",
                  "source" : [
                    {
                      "context" : "ddcc"
                    }
                  ],
                  "dependent" : [
                    {
                      "name" : "DDCCToDocumentReference",
                      "variable" : [
                        "ddcc",
                        "qr",
                        "qrdccid",
                        "pid"
                      ]
                    }
                  ]
                },
                {
                  "name" : "set category",
                  "source" : [
                    {
                      "context" : "ddcc"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "qr",
                      "contextType" : "variable",
                      "element" : "category",
                      "variable" : "category"
                    },
                    {
                      "context" : "category",
                      "contextType" : "variable",
                      "element" : "coding",
                      "variable" : "coding"
                    },
                    {
                      "context" : "coding",
                      "contextType" : "variable",
                      "element" : "system",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueString" : "http://smart.who.int/ddcc/CodeSystem/DDCCQRCategoryUsageCodeSystem"
                        }
                      ]
                    },
                    {
                      "context" : "coding",
                      "contextType" : "variable",
                      "element" : "code",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueString" : "dcc"
                        }
                      ]
                    }
                  ]
                },
                {
                  "name" : "set description",
                  "source" : [
                    {
                      "context" : "ddcc"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "qr",
                      "contextType" : "variable",
                      "element" : "description",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueString" : "DCC QR code for COVID 19 Vaccine Certificate"
                        }
                      ]
                    }
                  ]
                },
                {
                  "name" : "set DCC QR",
                  "source" : [
                    {
                      "context" : "ddcc"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "entry",
                      "contextType" : "variable",
                      "element" : "resource",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueId" : "qr"
                        }
                      ]
                    }
                  ]
                }
              ]
            },
            {
              "name" : "create immunization resource",
              "source" : [
                {
                  "context" : "ddcc",
                  "element" : "vaccination",
                  "listMode" : "first",
                  "variable" : "vaccination"
                }
              ],
              "target" : [
                {
                  "context" : "bundle",
                  "contextType" : "variable",
                  "element" : "entry",
                  "variable" : "entry"
                },
                {
                  "context" : "entry",
                  "contextType" : "variable",
                  "element" : "fullUrl",
                  "transform" : "append",
                  "parameter" : [
                    {
                      "valueString" : "urn:uuid:"
                    },
                    {
                      "valueId" : "iid"
                    }
                  ]
                },
                {
                  "context" : "entry",
                  "contextType" : "variable",
                  "element" : "request",
                  "variable" : "request"
                },
                {
                  "context" : "request",
                  "contextType" : "variable",
                  "element" : "method",
                  "transform" : "copy",
                  "parameter" : [
                    {
                      "valueString" : "PUT"
                    }
                  ]
                },
                {
                  "context" : "request",
                  "contextType" : "variable",
                  "element" : "url",
                  "transform" : "append",
                  "parameter" : [
                    {
                      "valueString" : "Immunization/"
                    },
                    {
                      "valueId" : "iid"
                    }
                  ]
                },
                {
                  "contextType" : "variable",
                  "variable" : "immunization",
                  "transform" : "create",
                  "parameter" : [
                    {
                      "valueString" : "http://smart.who.int/ddcc/StructureDefinition/DDCCImmunization"
                    }
                  ]
                }
              ],
              "rule" : [
                {
                  "name" : "setup immunization",
                  "source" : [
                    {
                      "context" : "ddcc",
                      "element" : "certificate",
                      "variable" : "certificate"
                    }
                  ],
                  "dependent" : [
                    {
                      "name" : "DDCCToImmunization",
                      "variable" : [
                        "vaccination",
                        "immunization",
                        "certificate",
                        "iid",
                        "pid"
                      ]
                    }
                  ]
                },
                {
                  "name" : "set immunization resource",
                  "source" : [
                    {
                      "context" : "ddcc"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "entry",
                      "contextType" : "variable",
                      "element" : "resource",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueId" : "immunization"
                        }
                      ]
                    }
                  ]
                }
              ]
            },
            {
              "name" : "create immunization recommendation resource",
              "source" : [
                {
                  "context" : "ddcc",
                  "element" : "vaccination",
                  "listMode" : "first",
                  "variable" : "vaccination"
                }
              ],
              "target" : [
                {
                  "context" : "bundle",
                  "contextType" : "variable",
                  "element" : "entry",
                  "variable" : "entry"
                },
                {
                  "context" : "entry",
                  "contextType" : "variable",
                  "element" : "fullUrl",
                  "transform" : "append",
                  "parameter" : [
                    {
                      "valueString" : "urn:uuid:"
                    },
                    {
                      "valueId" : "irid"
                    }
                  ]
                },
                {
                  "context" : "entry",
                  "contextType" : "variable",
                  "element" : "request",
                  "variable" : "request"
                },
                {
                  "context" : "request",
                  "contextType" : "variable",
                  "element" : "method",
                  "transform" : "copy",
                  "parameter" : [
                    {
                      "valueString" : "PUT"
                    }
                  ]
                },
                {
                  "context" : "request",
                  "contextType" : "variable",
                  "element" : "url",
                  "transform" : "append",
                  "parameter" : [
                    {
                      "valueString" : "ImmunizationRecommendation/"
                    },
                    {
                      "valueId" : "irid"
                    }
                  ]
                },
                {
                  "contextType" : "variable",
                  "variable" : "immrec",
                  "transform" : "create",
                  "parameter" : [
                    {
                      "valueString" : "http://smart.who.int/ddcc/StructureDefinition/DDCCImmunizationRecommendation"
                    }
                  ]
                }
              ],
              "rule" : [
                {
                  "name" : "setup immunization recommendation",
                  "source" : [
                    {
                      "context" : "vaccination"
                    }
                  ],
                  "dependent" : [
                    {
                      "name" : "DDCCToImmRec",
                      "variable" : [
                        "vaccination",
                        "immrec",
                        "irid",
                        "iid",
                        "pid"
                      ]
                    }
                  ]
                },
                {
                  "name" : "set immunization recommendation resource",
                  "source" : [
                    {
                      "context" : "ddcc"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "entry",
                      "contextType" : "variable",
                      "element" : "resource",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueId" : "immrec"
                        }
                      ]
                    }
                  ]
                }
              ]
            }
          ]
        }
      ]
    },
    {
      "name" : "DDCCToImmunization",
      "typeMode" : "none",
      "input" : [
        {
          "name" : "src",
          "mode" : "source"
        },
        {
          "name" : "immunization",
          "type" : "DDCCImmunization",
          "mode" : "target"
        },
        {
          "name" : "certificate",
          "mode" : "source"
        },
        {
          "name" : "iid",
          "mode" : "source"
        },
        {
          "name" : "pid",
          "mode" : "source"
        }
      ],
      "rule" : [
        {
          "name" : "set id",
          "source" : [
            {
              "context" : "iid"
            }
          ],
          "target" : [
            {
              "context" : "immunization",
              "contextType" : "variable",
              "element" : "id",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueId" : "iid"
                }
              ]
            }
          ]
        },
        {
          "name" : "set brand extension",
          "source" : [
            {
              "context" : "src",
              "element" : "brand",
              "variable" : "brand"
            }
          ],
          "target" : [
            {
              "context" : "immunization",
              "contextType" : "variable",
              "element" : "extension",
              "variable" : "ext"
            }
          ],
          "rule" : [
            {
              "name" : "set brand extension values",
              "source" : [
                {
                  "context" : "brand"
                }
              ],
              "target" : [
                {
                  "context" : "ext",
                  "contextType" : "variable",
                  "element" : "url",
                  "transform" : "copy",
                  "parameter" : [
                    {
                      "valueString" : "http://smart.who.int/ddcc/StructureDefinition/DDCCVaccineBrand"
                    }
                  ]
                },
                {
                  "context" : "ext",
                  "contextType" : "variable",
                  "element" : "value",
                  "transform" : "copy",
                  "parameter" : [
                    {
                      "valueId" : "brand"
                    }
                  ]
                }
              ]
            }
          ]
        },
        {
          "name" : "set maholder extension",
          "source" : [
            {
              "context" : "src",
              "element" : "maholder",
              "variable" : "maholder"
            }
          ],
          "target" : [
            {
              "context" : "immunization",
              "contextType" : "variable",
              "element" : "extension",
              "variable" : "ext"
            }
          ],
          "rule" : [
            {
              "name" : "set MA Holder extension values",
              "source" : [
                {
                  "context" : "maholder"
                }
              ],
              "target" : [
                {
                  "context" : "ext",
                  "contextType" : "variable",
                  "element" : "url",
                  "transform" : "copy",
                  "parameter" : [
                    {
                      "valueString" : "http://smart.who.int/ddcc/StructureDefinition/DDCCVaccineMarketAuthorization"
                    }
                  ]
                },
                {
                  "context" : "ext",
                  "contextType" : "variable",
                  "element" : "value",
                  "transform" : "copy",
                  "parameter" : [
                    {
                      "valueId" : "maholder"
                    }
                  ]
                }
              ]
            }
          ]
        },
        {
          "name" : "set country extension",
          "source" : [
            {
              "context" : "src",
              "element" : "country",
              "variable" : "country"
            }
          ],
          "target" : [
            {
              "context" : "immunization",
              "contextType" : "variable",
              "element" : "extension",
              "variable" : "ext"
            }
          ],
          "rule" : [
            {
              "name" : "set country extension values",
              "source" : [
                {
                  "context" : "country",
                  "element" : "code",
                  "variable" : "code"
                }
              ],
              "target" : [
                {
                  "context" : "ext",
                  "contextType" : "variable",
                  "element" : "url",
                  "transform" : "copy",
                  "parameter" : [
                    {
                      "valueString" : "http://smart.who.int/ddcc/StructureDefinition/DDCCCountryOfVaccination"
                    }
                  ]
                },
                {
                  "context" : "ext",
                  "contextType" : "variable",
                  "element" : "value",
                  "transform" : "copy",
                  "parameter" : [
                    {
                      "valueId" : "code"
                    }
                  ]
                }
              ]
            }
          ]
        },
        {
          "name" : "set vaccine valid extension",
          "source" : [
            {
              "context" : "src",
              "element" : "validFrom",
              "variable" : "validFrom"
            }
          ],
          "target" : [
            {
              "context" : "immunization",
              "contextType" : "variable",
              "element" : "extension",
              "variable" : "ext"
            }
          ],
          "rule" : [
            {
              "name" : "set valid from extension values",
              "source" : [
                {
                  "context" : "validFrom"
                }
              ],
              "target" : [
                {
                  "context" : "ext",
                  "contextType" : "variable",
                  "element" : "url",
                  "transform" : "copy",
                  "parameter" : [
                    {
                      "valueString" : "http://smart.who.int/ddcc/StructureDefinition/DDCCVaccineValidFrom"
                    }
                  ]
                },
                {
                  "context" : "ext",
                  "contextType" : "variable",
                  "element" : "value",
                  "transform" : "copy",
                  "parameter" : [
                    {
                      "valueId" : "validFrom"
                    }
                  ]
                }
              ]
            }
          ]
        },
        {
          "name" : "set status",
          "source" : [
            {
              "context" : "src"
            }
          ],
          "target" : [
            {
              "context" : "immunization",
              "contextType" : "variable",
              "element" : "status",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueString" : "completed"
                }
              ]
            }
          ]
        },
        {
          "name" : "set vaccine",
          "source" : [
            {
              "context" : "src",
              "element" : "vaccine",
              "variable" : "vaccine"
            }
          ],
          "target" : [
            {
              "context" : "immunization",
              "contextType" : "variable",
              "element" : "vaccineCode",
              "variable" : "vacCode"
            },
            {
              "context" : "vacCode",
              "contextType" : "variable",
              "element" : "coding",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueId" : "vaccine"
                }
              ]
            }
          ]
        },
        {
          "name" : "set patient",
          "source" : [
            {
              "context" : "src"
            }
          ],
          "target" : [
            {
              "context" : "immunization",
              "contextType" : "variable",
              "element" : "patient",
              "variable" : "patient"
            },
            {
              "context" : "patient",
              "contextType" : "variable",
              "element" : "reference",
              "transform" : "append",
              "parameter" : [
                {
                  "valueString" : "Patient/"
                },
                {
                  "valueId" : "pid"
                }
              ]
            }
          ]
        },
        {
          "name" : "set manufacturer identifier",
          "source" : [
            {
              "context" : "src",
              "element" : "manufacturer",
              "variable" : "manufacturer"
            }
          ],
          "target" : [
            {
              "context" : "immunization",
              "contextType" : "variable",
              "element" : "manufacturer",
              "variable" : "tman"
            },
            {
              "context" : "tman",
              "contextType" : "variable",
              "element" : "identifier",
              "variable" : "ident"
            }
          ],
          "rule" : [
            {
              "name" : "set system",
              "source" : [
                {
                  "context" : "manufacturer",
                  "element" : "system",
                  "variable" : "system"
                }
              ],
              "target" : [
                {
                  "context" : "ident",
                  "contextType" : "variable",
                  "element" : "system",
                  "transform" : "copy",
                  "parameter" : [
                    {
                      "valueId" : "system"
                    }
                  ]
                }
              ]
            },
            {
              "name" : "set value",
              "source" : [
                {
                  "context" : "manufacturer",
                  "element" : "code",
                  "variable" : "code"
                }
              ],
              "target" : [
                {
                  "context" : "ident",
                  "contextType" : "variable",
                  "element" : "value",
                  "transform" : "copy",
                  "parameter" : [
                    {
                      "valueId" : "code"
                    }
                  ]
                }
              ]
            }
          ]
        },
        {
          "name" : "set lot number",
          "source" : [
            {
              "context" : "src",
              "element" : "lot",
              "variable" : "lot"
            }
          ],
          "target" : [
            {
              "context" : "immunization",
              "contextType" : "variable",
              "element" : "lotNumber",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueId" : "lot"
                }
              ]
            }
          ]
        },
        {
          "name" : "set occurrence date",
          "source" : [
            {
              "context" : "src",
              "element" : "date",
              "variable" : "date"
            }
          ],
          "target" : [
            {
              "context" : "immunization",
              "contextType" : "variable",
              "element" : "occurrence",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueId" : "date"
                }
              ]
            }
          ]
        },
        {
          "name" : "set location",
          "source" : [
            {
              "context" : "src",
              "element" : "centre",
              "variable" : "centre"
            }
          ],
          "target" : [
            {
              "context" : "immunization",
              "contextType" : "variable",
              "element" : "location",
              "variable" : "location"
            }
          ],
          "rule" : [
            {
              "name" : "set location display",
              "source" : [
                {
                  "context" : "centre"
                }
              ],
              "target" : [
                {
                  "context" : "location",
                  "contextType" : "variable",
                  "element" : "display",
                  "transform" : "copy",
                  "parameter" : [
                    {
                      "valueId" : "centre"
                    }
                  ]
                }
              ]
            }
          ]
        },
        {
          "name" : "set practitioner",
          "source" : [
            {
              "context" : "src",
              "element" : "practitioner",
              "variable" : "practitioner"
            }
          ],
          "target" : [
            {
              "context" : "immunization",
              "contextType" : "variable",
              "element" : "performer",
              "variable" : "performer"
            }
          ],
          "rule" : [
            {
              "name" : "set performer",
              "source" : [
                {
                  "context" : "practitioner",
                  "element" : "value",
                  "variable" : "hw"
                }
              ],
              "target" : [
                {
                  "context" : "performer",
                  "contextType" : "variable",
                  "element" : "actor",
                  "variable" : "actor"
                }
              ],
              "rule" : [
                {
                  "name" : "set actor",
                  "source" : [
                    {
                      "context" : "hw"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "actor",
                      "contextType" : "variable",
                      "element" : "type",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueString" : "Practitioner"
                        }
                      ]
                    },
                    {
                      "context" : "actor",
                      "contextType" : "variable",
                      "element" : "identifier",
                      "variable" : "identifier"
                    }
                  ],
                  "rule" : [
                    {
                      "name" : "set hw identifier",
                      "source" : [
                        {
                          "context" : "hw"
                        }
                      ],
                      "target" : [
                        {
                          "context" : "identifier",
                          "contextType" : "variable",
                          "element" : "value",
                          "transform" : "copy",
                          "parameter" : [
                            {
                              "valueId" : "hw"
                            }
                          ]
                        }
                      ]
                    }
                  ]
                }
              ]
            }
          ]
        },
        {
          "name" : "set protocolApplied",
          "source" : [
            {
              "context" : "src"
            }
          ],
          "target" : [
            {
              "context" : "immunization",
              "contextType" : "variable",
              "element" : "protocolApplied",
              "variable" : "protocol"
            }
          ],
          "rule" : [
            {
              "name" : "set authority",
              "source" : [
                {
                  "context" : "src"
                }
              ],
              "target" : [
                {
                  "context" : "protocol",
                  "contextType" : "variable",
                  "element" : "authority",
                  "variable" : "authority"
                }
              ],
              "rule" : [
                {
                  "name" : "set issuer",
                  "source" : [
                    {
                      "context" : "certificate",
                      "element" : "issuer",
                      "variable" : "issuer"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "authority",
                      "contextType" : "variable",
                      "element" : "type",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueString" : "Organization"
                        }
                      ]
                    }
                  ],
                  "rule" : [
                    {
                      "name" : "set issuer identifier",
                      "source" : [
                        {
                          "context" : "issuer",
                          "element" : "identifier",
                          "variable" : "pha"
                        }
                      ],
                      "target" : [
                        {
                          "context" : "authority",
                          "contextType" : "variable",
                          "element" : "identifier",
                          "variable" : "identifier"
                        }
                      ],
                      "rule" : [
                        {
                          "name" : "set pha",
                          "source" : [
                            {
                              "context" : "pha",
                              "element" : "value",
                              "variable" : "value"
                            }
                          ],
                          "target" : [
                            {
                              "context" : "identifier",
                              "contextType" : "variable",
                              "element" : "value",
                              "transform" : "copy",
                              "parameter" : [
                                {
                                  "valueId" : "value"
                                }
                              ]
                            }
                          ]
                        }
                      ]
                    }
                  ]
                }
              ]
            },
            {
              "name" : "set target disease",
              "source" : [
                {
                  "context" : "src",
                  "element" : "disease",
                  "variable" : "disease"
                }
              ],
              "target" : [
                {
                  "context" : "protocol",
                  "contextType" : "variable",
                  "element" : "targetDisease",
                  "variable" : "tdisease"
                }
              ],
              "rule" : [
                {
                  "name" : "set target disease code",
                  "source" : [
                    {
                      "context" : "disease"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "tdisease",
                      "contextType" : "variable",
                      "element" : "coding",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueId" : "disease"
                        }
                      ]
                    }
                  ]
                }
              ]
            },
            {
              "name" : "set dose number",
              "source" : [
                {
                  "context" : "src",
                  "element" : "dose",
                  "variable" : "dose"
                }
              ],
              "target" : [
                {
                  "context" : "protocol",
                  "contextType" : "variable",
                  "element" : "doseNumber",
                  "transform" : "copy",
                  "parameter" : [
                    {
                      "valueId" : "dose"
                    }
                  ]
                }
              ]
            },
            {
              "name" : "set total doses",
              "source" : [
                {
                  "context" : "src",
                  "element" : "totalDoses",
                  "variable" : "totalDoses"
                }
              ],
              "target" : [
                {
                  "context" : "protocol",
                  "contextType" : "variable",
                  "element" : "seriesDoses",
                  "transform" : "copy",
                  "parameter" : [
                    {
                      "valueId" : "totalDoses"
                    }
                  ]
                }
              ]
            }
          ]
        }
      ]
    },
    {
      "name" : "DDCCToImmRec",
      "typeMode" : "none",
      "input" : [
        {
          "name" : "src",
          "mode" : "source"
        },
        {
          "name" : "immrec",
          "type" : "DDCCImmunizationRecommendation",
          "mode" : "target"
        },
        {
          "name" : "irid",
          "mode" : "source"
        },
        {
          "name" : "iid",
          "mode" : "source"
        },
        {
          "name" : "pid",
          "mode" : "source"
        }
      ],
      "rule" : [
        {
          "name" : "set date",
          "source" : [
            {
              "context" : "src",
              "element" : "date",
              "variable" : "date"
            }
          ],
          "target" : [
            {
              "context" : "immrec",
              "contextType" : "variable",
              "element" : "date",
              "transform" : "copy",
              "parameter" : [
                {
                  "valueId" : "date"
                }
              ]
            }
          ]
        },
        {
          "name" : "set patient",
          "source" : [
            {
              "context" : "src"
            }
          ],
          "target" : [
            {
              "context" : "immrec",
              "contextType" : "variable",
              "element" : "patient",
              "variable" : "patient"
            },
            {
              "context" : "patient",
              "contextType" : "variable",
              "element" : "reference",
              "transform" : "append",
              "parameter" : [
                {
                  "valueString" : "Patient/"
                },
                {
                  "valueId" : "pid"
                }
              ]
            }
          ]
        },
        {
          "name" : "set recommendation",
          "source" : [
            {
              "context" : "src"
            }
          ],
          "target" : [
            {
              "context" : "immrec",
              "contextType" : "variable",
              "element" : "recommendation",
              "variable" : "rec"
            }
          ],
          "rule" : [
            {
              "name" : "set vaccine code",
              "source" : [
                {
                  "context" : "src",
                  "element" : "vaccine",
                  "variable" : "vaccine"
                }
              ],
              "target" : [
                {
                  "context" : "rec",
                  "contextType" : "variable",
                  "element" : "vaccineCode",
                  "variable" : "vaccineCode"
                }
              ],
              "rule" : [
                {
                  "name" : "set vaccine code coding",
                  "source" : [
                    {
                      "context" : "vaccine"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "vaccineCode",
                      "contextType" : "variable",
                      "element" : "coding",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueId" : "vaccine"
                        }
                      ]
                    }
                  ]
                }
              ]
            },
            {
              "name" : "set target disease",
              "source" : [
                {
                  "context" : "src",
                  "element" : "disease",
                  "variable" : "disease"
                }
              ],
              "target" : [
                {
                  "context" : "rec",
                  "contextType" : "variable",
                  "element" : "targetDisease",
                  "variable" : "targetDisease"
                }
              ],
              "rule" : [
                {
                  "name" : "set target disease coding",
                  "source" : [
                    {
                      "context" : "disease"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "targetDisease",
                      "contextType" : "variable",
                      "element" : "coding",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueId" : "disease"
                        }
                      ]
                    }
                  ]
                }
              ]
            },
            {
              "name" : "set forecast status",
              "source" : [
                {
                  "context" : "src"
                }
              ],
              "target" : [
                {
                  "context" : "rec",
                  "contextType" : "variable",
                  "element" : "forecastStatus",
                  "variable" : "forecast"
                }
              ],
              "rule" : [
                {
                  "name" : "set forecast status coding",
                  "source" : [
                    {
                      "context" : "src"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "forecast",
                      "contextType" : "variable",
                      "element" : "coding",
                      "variable" : "coding"
                    }
                  ],
                  "rule" : [
                    {
                      "name" : "set forecast system",
                      "source" : [
                        {
                          "context" : "src"
                        }
                      ],
                      "target" : [
                        {
                          "context" : "coding",
                          "contextType" : "variable",
                          "element" : "system",
                          "transform" : "copy",
                          "parameter" : [
                            {
                              "valueString" : "http://terminology.hl7.org/2.1.0/CodeSystem-immunization-recommendation-status.html"
                            }
                          ]
                        }
                      ]
                    },
                    {
                      "name" : "set forecast code",
                      "source" : [
                        {
                          "context" : "src"
                        }
                      ],
                      "target" : [
                        {
                          "context" : "coding",
                          "contextType" : "variable",
                          "element" : "code",
                          "transform" : "copy",
                          "parameter" : [
                            {
                              "valueString" : "due"
                            }
                          ]
                        }
                      ]
                    }
                  ]
                }
              ]
            },
            {
              "name" : "set date criterion",
              "source" : [
                {
                  "context" : "src"
                }
              ],
              "target" : [
                {
                  "context" : "rec",
                  "contextType" : "variable",
                  "element" : "dateCriterion",
                  "variable" : "due_date"
                }
              ],
              "rule" : [
                {
                  "name" : "set due date code",
                  "source" : [
                    {
                      "context" : "src"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "due_date",
                      "contextType" : "variable",
                      "element" : "code",
                      "variable" : "code"
                    }
                  ],
                  "rule" : [
                    {
                      "name" : "set due date code coding",
                      "source" : [
                        {
                          "context" : "src"
                        }
                      ],
                      "target" : [
                        {
                          "context" : "code",
                          "contextType" : "variable",
                          "element" : "coding",
                          "variable" : "coding"
                        }
                      ],
                      "rule" : [
                        {
                          "name" : "set due date code system",
                          "source" : [
                            {
                              "context" : "src"
                            }
                          ],
                          "target" : [
                            {
                              "context" : "coding",
                              "contextType" : "variable",
                              "element" : "system",
                              "transform" : "copy",
                              "parameter" : [
                                {
                                  "valueString" : "http://loinc.org"
                                }
                              ]
                            }
                          ]
                        },
                        {
                          "name" : "set due date code code",
                          "source" : [
                            {
                              "context" : "src"
                            }
                          ],
                          "target" : [
                            {
                              "context" : "coding",
                              "contextType" : "variable",
                              "element" : "code",
                              "transform" : "copy",
                              "parameter" : [
                                {
                                  "valueString" : "30980-7"
                                }
                              ]
                            }
                          ]
                        }
                      ]
                    }
                  ]
                },
                {
                  "name" : "set due date value",
                  "source" : [
                    {
                      "context" : "src",
                      "element" : "nextDose",
                      "variable" : "nextDose"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "due_date",
                      "contextType" : "variable",
                      "element" : "value",
                      "transform" : "copy",
                      "parameter" : [
                        {
                          "valueId" : "nextDose"
                        }
                      ]
                    }
                  ]
                }
              ]
            },
            {
              "name" : "set dose number",
              "source" : [
                {
                  "context" : "src",
                  "element" : "dose",
                  "variable" : "dose"
                }
              ],
              "target" : [
                {
                  "context" : "rec",
                  "contextType" : "variable",
                  "element" : "doseNumber",
                  "transform" : "evaluate",
                  "parameter" : [
                    {
                      "valueString" : "dose.toInteger() + 1"
                    }
                  ]
                }
              ]
            },
            {
              "name" : "set total doses",
              "source" : [
                {
                  "context" : "src",
                  "element" : "totalDoses",
                  "variable" : "totalDoses"
                }
              ],
              "target" : [
                {
                  "context" : "rec",
                  "contextType" : "variable",
                  "element" : "seriesDoses",
                  "transform" : "copy",
                  "parameter" : [
                    {
                      "valueId" : "totalDoses"
                    }
                  ]
                }
              ]
            },
            {
              "name" : "set supporting immunization",
              "source" : [
                {
                  "context" : "src"
                }
              ],
              "target" : [
                {
                  "context" : "rec",
                  "contextType" : "variable",
                  "element" : "supportingImmunization",
                  "variable" : "imm"
                },
                {
                  "context" : "imm",
                  "contextType" : "variable",
                  "element" : "reference",
                  "transform" : "append",
                  "parameter" : [
                    {
                      "valueString" : "Immunization/"
                    },
                    {
                      "valueId" : "iid"
                    }
                  ]
                }
              ]
            }
          ]
        }
      ]
    }
  ]
}