FHIR © HL7.org  |  Server Home  |  XIG Home  |  XIG Stats  |  Server Source  |  FHIR  

FHIR IG Statistics: StructureMap/ERPTPrescriptionStructureMapKBVPZNMedication

Packagede.gematik.erp.t-prescription
Resource TypeStructureMap
IdERPTPrescriptionStructureMapKBVPZNMedication
FHIR VersionR4
Sourcehttps://simplifier.net/resolve?scope=de.gematik.erp.t-prescription@1.1.0-ballot-1&canonical=https://gematik.de/fhir/erp-t-prescription/StructureMap/ERPTPrescriptionStructureMapKBVPZNMedication
URLhttps://gematik.de/fhir/erp-t-prescription/StructureMap/ERPTPrescriptionStructureMapKBVPZNMedication
Version1.0.0-ballot-1
Statusdraft
Date2025-07-07
NameERPTPrescriptionStructureMapKBVPZNMedication
TitleE-T-Rezept Structure Map for KBV PZN Medication
DescriptionMaps KBV-PZN ERP Medication to BfArM T-Prescription Medication format

Resources that use this resource

No resources found


Resources that this resource uses

No resources found


Narrative

No narrative content found in resource


Source

{
  "resourceType": "StructureMap",
  "id": "ERPTPrescriptionStructureMapKBVPZNMedication",
  "url": "https://gematik.de/fhir/erp-t-prescription/StructureMap/ERPTPrescriptionStructureMapKBVPZNMedication",
  "title": "E-T-Rezept Structure Map for KBV PZN Medication",
  "description": "Maps KBV-PZN ERP Medication to BfArM T-Prescription Medication format",
  "structure": [
    {
      "url": "http://hl7.org/fhir/StructureDefinition/Medication",
      "mode": "source",
      "alias": "kbvMedicationPZN"
    },
    {
      "url": "http://hl7.org/fhir/StructureDefinition/Medication",
      "mode": "target",
      "alias": "bfarmMedication"
    }
  ],
  "group": [
    {
      "input": [
        {
          "name": "kbvMedicationPZN",
          "type": "kbvMedicationPZN",
          "mode": "source"
        },
        {
          "name": "bfarmMedication",
          "type": "bfarmMedication",
          "mode": "target"
        }
      ],
      "rule": [
        {
          "source": [
            {
              "context": "kbvMedicationPZN",
              "element": "extension",
              "variable": "extVar"
            }
          ],
          "target": [
            {
              "contextType": "variable",
              "context": "bfarmMedication",
              "element": "extension",
              "variable": "tgtExtVar"
            }
          ],
          "rule": [
            {
              "source": [
                {
                  "context": "extVar",
                  "condition": "url='http://fhir.de/StructureDefinition/normgroesse'"
                }
              ],
              "target": [
                {
                  "parameter": [
                    {
                      "valueString": "http://fhir.de/StructureDefinition/normgroesse"
                    }
                  ],
                  "context": "tgtExtVar",
                  "contextType": "variable",
                  "element": "url",
                  "transform": "copy"
                }
              ],
              "rule": [
                {
                  "source": [
                    {
                      "context": "extVar",
                      "element": "value",
                      "variable": "extValVar"
                    }
                  ],
                  "target": [
                    {
                      "parameter": [
                        {
                          "valueId": "extValVar"
                        }
                      ],
                      "context": "tgtExtVar",
                      "contextType": "variable",
                      "element": "value",
                      "transform": "copy"
                    }
                  ],
                  "name": "copyExtensionValue",
                  "documentation": "Copies the the value for each Extension"
                }
              ],
              "name": "copyNormgroesseExtensionUrl",
              "documentation": "Copies the 'normgroesse' extension and sets its URL to 'normgroesseNEW' in the target"
            }
          ],
          "name": "medicationExt",
          "documentation": "Copies the Medication Extensions"
        },
        {
          "source": [
            {
              "context": "kbvMedicationPZN",
              "element": "id",
              "variable": "IdVar"
            }
          ],
          "target": [
            {
              "parameter": [
                {
                  "valueId": "IdVar"
                }
              ],
              "context": "bfarmMedication",
              "contextType": "variable",
              "element": "id",
              "transform": "copy"
            }
          ],
          "name": "medicationId",
          "documentation": "Copies the Medication Id"
        },
        {
          "source": [
            {
              "context": "kbvMedicationPZN",
              "element": "code",
              "variable": "codeVar"
            }
          ],
          "target": [
            {
              "parameter": [
                {
                  "valueId": "codeVar"
                }
              ],
              "context": "bfarmMedication",
              "contextType": "variable",
              "element": "code",
              "transform": "copy"
            }
          ],
          "name": "medicationCode",
          "documentation": "Copies the Medication Code"
        },
        {
          "source": [
            {
              "context": "kbvMedicationPZN",
              "element": "form",
              "variable": "formVar"
            }
          ],
          "target": [
            {
              "parameter": [
                {
                  "valueId": "formVar"
                }
              ],
              "context": "bfarmMedication",
              "contextType": "variable",
              "element": "form",
              "transform": "copy"
            }
          ],
          "name": "medicationForm",
          "documentation": "Copies the Medication Form"
        },
        {
          "source": [
            {
              "context": "kbvMedicationPZN",
              "element": "amount",
              "variable": "amountVar"
            }
          ],
          "target": [
            {
              "contextType": "variable",
              "context": "bfarmMedication",
              "element": "amount",
              "variable": "tgtAmountVar"
            }
          ],
          "rule": [
            {
              "source": [
                {
                  "context": "amountVar",
                  "element": "denominator",
                  "variable": "amountDenominatorVar"
                }
              ],
              "target": [
                {
                  "parameter": [
                    {
                      "valueId": "amountDenominatorVar"
                    }
                  ],
                  "context": "tgtAmountVar",
                  "contextType": "variable",
                  "element": "denominator",
                  "transform": "copy"
                }
              ],
              "name": "medicationAmountDenominator"
            },
            {
              "source": [
                {
                  "context": "amountVar",
                  "element": "numerator",
                  "variable": "amountNumeratorVar"
                }
              ],
              "target": [
                {
                  "contextType": "variable",
                  "context": "tgtAmountVar",
                  "element": "numerator",
                  "variable": "tgtAmountNumeratorVar"
                }
              ],
              "rule": [
                {
                  "source": [
                    {
                      "context": "amountNumeratorVar",
                      "element": "extension",
                      "variable": "amountNumExtVar"
                    }
                  ],
                  "target": [
                    {
                      "contextType": "variable",
                      "context": "tgtAmountNumeratorVar",
                      "element": "extension",
                      "variable": "tgtAmountNumExtVar"
                    }
                  ],
                  "rule": [
                    {
                      "source": [
                        {
                          "context": "amountNumExtVar",
                          "condition": "url='https://fhir.kbv.de/StructureDefinition/KBV_EX_ERP_Medication_PackagingSize'"
                        }
                      ],
                      "target": [
                        {
                          "parameter": [
                            {
                              "valueString": "https://gematik.de/fhir/epa-medication/StructureDefinition/medication-packaging-size-extension"
                            }
                          ],
                          "context": "tgtAmountNumExtVar",
                          "contextType": "variable",
                          "element": "url",
                          "transform": "copy"
                        }
                      ],
                      "rule": [
                        {
                          "source": [
                            {
                              "context": "amountNumExtVar",
                              "element": "value",
                              "variable": "extValVar"
                            }
                          ],
                          "target": [
                            {
                              "parameter": [
                                {
                                  "valueId": "extValVar"
                                }
                              ],
                              "context": "tgtAmountNumExtVar",
                              "contextType": "variable",
                              "element": "value",
                              "transform": "copy"
                            }
                          ],
                          "name": "copyExtensionValue",
                          "documentation": "Copies the the value for each Extension"
                        }
                      ],
                      "name": "copyPackagingSizeExtensionUrl"
                    }
                  ],
                  "name": "medicationAmountExt",
                  "documentation": "Copies the Medication Extensions"
                },
                {
                  "source": [
                    {
                      "context": "amountNumeratorVar",
                      "element": "value",
                      "variable": "amountNumeratorValueVar"
                    }
                  ],
                  "target": [
                    {
                      "parameter": [
                        {
                          "valueId": "amountNumeratorValueVar"
                        }
                      ],
                      "context": "tgtAmountNumeratorVar",
                      "contextType": "variable",
                      "element": "value",
                      "transform": "copy"
                    }
                  ],
                  "name": "medicationAmountNumeratorValue"
                },
                {
                  "source": [
                    {
                      "context": "amountNumeratorVar",
                      "element": "unit",
                      "variable": "amountNumeratorUnitVar"
                    }
                  ],
                  "target": [
                    {
                      "parameter": [
                        {
                          "valueId": "amountNumeratorUnitVar"
                        }
                      ],
                      "context": "tgtAmountNumeratorVar",
                      "contextType": "variable",
                      "element": "unit",
                      "transform": "copy"
                    }
                  ],
                  "name": "medicationAmountNumeratorUnit"
                },
                {
                  "source": [
                    {
                      "context": "amountNumeratorVar",
                      "element": "system",
                      "variable": "amountNumeratorSystemVar"
                    }
                  ],
                  "target": [
                    {
                      "parameter": [
                        {
                          "valueId": "amountNumeratorSystemVar"
                        }
                      ],
                      "context": "tgtAmountNumeratorVar",
                      "contextType": "variable",
                      "element": "system",
                      "transform": "copy"
                    }
                  ],
                  "name": "medicationAmountNumeratorSystem"
                },
                {
                  "source": [
                    {
                      "context": "amountNumeratorVar",
                      "element": "code",
                      "variable": "amountNumeratorCodeVar"
                    }
                  ],
                  "target": [
                    {
                      "parameter": [
                        {
                          "valueId": "amountNumeratorCodeVar"
                        }
                      ],
                      "context": "tgtAmountNumeratorVar",
                      "contextType": "variable",
                      "element": "code",
                      "transform": "copy"
                    }
                  ],
                  "name": "medicationAmountNumeratorCode"
                }
              ],
              "name": "medicationAmountNumerator"
            }
          ],
          "name": "medicationAmount",
          "documentation": "Copies the Medication Amount"
        },
        {
          "source": [
            {
              "context": "kbvMedicationPZN",
              "element": "ingredient",
              "variable": "ingredientVar"
            }
          ],
          "target": [
            {
              "parameter": [
                {
                  "valueId": "ingredientVar"
                }
              ],
              "context": "bfarmMedication",
              "contextType": "variable",
              "element": "ingredient",
              "transform": "copy"
            }
          ],
          "name": "medicationIngredient",
          "documentation": "Copies the Medication Ingredient"
        }
      ],
      "name": "ERPTPrescriptionStructureMapKBVPZNMedication",
      "typeMode": "none",
      "documentation": "Mapping group for medication information transformation"
    }
  ],
  "status": "draft",
  "version": "1.0.0-ballot-1",
  "date": "2025-07-07",
  "name": "ERPTPrescriptionStructureMapKBVPZNMedication",
  "experimental": false
}