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

StructureMap:

Official URL: http://smart.who.int/ddcc/StructureMap/SHCtoDDCC Version: 1.0.0
Draft as of 2024-10-17 Computable Name: SHCtoDDCC

Generated Narrative: StructureMap SHCtoDDCC

map "http://smart.who.int/ddcc/StructureMap/SHCtoDDCC" = "SHCtoDDCC"

uses "http://hl7.org/fhir/uv/shc-vaccination/StructureDefinition/shc-vaccination-bundle-dm" alias SHCVaccinationBundleDM as source
uses "http://hl7.org/fhir/uv/shc-vaccination/StructureDefinition/shc-patient-general-dm" alias SHCPatientDM as source
uses "http://hl7.org/fhir/uv/shc-vaccination/StructureDefinition/shc-vaccination-dm" alias SHCImmunizationDM as source
uses "http://hl7.org/fhir/StructureDefinition/Bundle" alias Bundle as target
uses "http://smart.who.int/ddcc/StructureDefinition/DDCCDocument" alias DDCCDocument as target
uses "http://smart.who.int/ddcc/StructureDefinition/DDCCPatient" alias DDCCPatient as target
uses "http://smart.who.int/ddcc/StructureDefinition/DDCCComposition" alias DDCCComposition as target
uses "http://smart.who.int/ddcc/StructureDefinition/DDCCOrganization" alias DDCCOrganization as target
uses "http://smart.who.int/ddcc/StructureDefinition/DDCCCountryOfVaccination" alias DDCCCountryOfVaccination as target
uses "http://smart.who.int/ddcc/StructureDefinition/DDCCVaccineBrand" alias DDCCVaccineBrand as target
uses "http://smart.who.int/ddcc/StructureDefinition/DDCCImmunization" alias DDCCImmunization as target

group SHCtoDDCC(source shc : SHCVaccinationBundleDM, target ddcc : Bundle) {
  shc.entry as patientEntrySHC then {
    patientEntrySHC.resource : Patient first as patientSHC then {
      shc.entry as immunizationEntrySHC then {
        immunizationEntrySHC.resource : Immunization as immunizationSHC then {
          immunizationEntrySHC -> ddcc.type = 'collection' "Bundle type";
          immunizationEntrySHC -> ddcc.entry as ddccEntry then {
            immunizationSHC -> ddccEntry.resource = create('Bundle') as ddccdocument then {
              immunizationSHC -> ddccdocument.type = 'document' "DDCC Document type";
              patientSHC -> ddccdocument.entry as ddccDocumentEntry then {
                patientSHC -> ddccDocumentEntry.resource = create('Patient') as patientDDCC then SHCPatienttoDDCC(patientSHC, patientDDCC) "DDCC Document patient resource";
              } "DDCC Document patient entry";
              immunizationSHC -> ddccdocument.entry as ddccDocumentEntry then {
                immunizationSHC -> ddccDocumentEntry.resource = create('Immunization') as immunizationDDCC then SHCImmunizationtoDDCC(immunizationSHC, immunizationDDCC) "DDCC Document immunization resource";
              } "DDCC Document immunization entry";
            } "DDCC Document bundle";
          } "DDCC Document entry";
        } "Is immunization entry";
      } "For each immunization entry";
    } "Is Patient entry";
  } "map patient";
}

group SHCPatienttoDDCC(source patient : SHCPatientDM, target patientDDCC : DDCCPatient) {
  immunization.status as status -> immunizationDDCC.status = status "Status";
  immunization.coding as coding -> immunizationDDCC.coding = coding "Coding";
  immunization.occurrence as occurrenceDateTime -> immunizationDDCC.occurrence = occurrenceDateTime "Occurrence DateTime";
  immunization.manfacturer as manfacturer -> immunizationDDCC.manfacturer = manfacturer "Manufacturer";
  immunization.lotNumber as lotNumber -> immunizationDDCC.lotNumber = lotNumber "Lot Number";
}

group SHCImmunizationtoDDCC(source immunization : SHCImmunizationDM, target immunizationDDCC : DDCCImmunization) {
  immunization.status as status -> immunizationDDCC.status = status "Status";
  immunization.coding as coding -> immunizationDDCC.coding = coding "Coding";
  immunization.occurrence as occurrenceDateTime -> immunizationDDCC.occurrence = occurrenceDateTime "Occurrence DateTime";
  immunization.manfacturer as manfacturer -> immunizationDDCC.manfacturer = manfacturer "Manufacturer";
  immunization.lotNumber as lotNumber -> immunizationDDCC.lotNumber = lotNumber "Lot Number";
}