{
  "resourceType": "StructureDefinition",
  "id": "medication-ca-core",
  "extension": [
    {
      "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-fmm",
      "valueInteger": 2
    }
  ],
  "url": "http://fhir.infoway-inforoute.ca/cacore/StructureDefinition/medication-ca-core",
  "version": "1.1.0",
  "name": "MedicationCACore",
  "title": "Medication (CA-Core)",
  "status": "active",
  "experimental": false,
  "date": "2025-03-06",
  "publisher": "Canada Health Infoway",
  "contact": [
    {
      "name": "National Standards Release Centre",
      "telecom": [
        {
          "system": "url",
          "value": "http://www.infoway-inforoute.ca"
        },
        {
          "system": "email",
          "value": "standards@infoway-inforoute.ca"
        }
      ]
    }
  ],
  "description": "This profile applies constraints to the Medication resource for CA Core+ to support representation of medication products in the pan-Canadian context.",
  "jurisdiction": [
    {
      "coding": [
        {
          "code": "CA",
          "system": "urn:iso:std:iso:3166"
        }
      ]
    }
  ],
  "copyright": "Copyright © 2025+ Canada Health Infoway. All rights reserved. [Terms of Use and License Agreements](https://ic.infoway-inforoute.ca/en/about/tou). [Privacy Policy](https://www.infoway-inforoute.ca/en/legal/privacy-policy).",
  "fhirVersion": "4.0.1",
  "mapping": [
    {
      "identity": "CACDI",
      "name": "Canadian Core Data for Interoperability (CACDI)",
      "comment": "Mapping for MedicationCACore to  Canadian Core Data for Interoperability (CACDI)."
    }
  ],
  "kind": "resource",
  "abstract": false,
  "type": "Medication",
  "baseDefinition": "http://hl7.org/fhir/StructureDefinition/Medication",
  "derivation": "constraint",
  "differential": {
    "element": [
      {
        "id": "Medication.extension",
        "path": "Medication.extension",
        "slicing": {
          "discriminator": [
            {
              "type": "value",
              "path": "url"
            }
          ],
          "ordered": false,
          "rules": "open"
        }
      },
      {
        "id": "Medication.extension:strength",
        "extension": [
          {
            "url": "http://hl7.org/fhir/StructureDefinition/obligation",
            "extension": [
              {
                "url": "code",
                "valueCode": "MAY:populate-if-known"
              },
              {
                "url": "actor",
                "valueCanonical": "http://fhir.infoway-inforoute.ca/ca-core/ActorDefinition/producer"
              }
            ]
          },
          {
            "extension": [
              {
                "url": "code",
                "valueCode": "SHALL:no-error"
              },
              {
                "url": "actor",
                "valueCanonical": "http://fhir.infoway-inforoute.ca/ca-core/ActorDefinition/consumer"
              }
            ],
            "url": "http://hl7.org/fhir/StructureDefinition/obligation"
          }
        ],
        "path": "Medication.extension",
        "sliceName": "strength",
        "min": 0,
        "max": "1",
        "type": [
          {
            "code": "Extension",
            "profile": [
              "http://prescribeit.ca/fhir/StructureDefinition/ext-medication-strength-description"
            ]
          }
        ]
      },
      {
        "id": "Medication.code",
        "extension": [
          {
            "url": "http://hl7.org/fhir/StructureDefinition/obligation",
            "extension": [
              {
                "url": "code",
                "valueCode": "MAY:populate-if-known"
              },
              {
                "url": "actor",
                "valueCanonical": "http://fhir.infoway-inforoute.ca/ca-core/ActorDefinition/producer"
              }
            ]
          },
          {
            "extension": [
              {
                "url": "code",
                "valueCode": "SHALL:no-error"
              },
              {
                "url": "actor",
                "valueCanonical": "http://fhir.infoway-inforoute.ca/ca-core/ActorDefinition/consumer"
              }
            ],
            "url": "http://hl7.org/fhir/StructureDefinition/obligation"
          }
        ],
        "path": "Medication.code",
        "comment": "The preferred binding on this element may continue to change as pCHDCF undergoes further refinement. The point-in-time materials provided by pCHDCF to create the profiles in this release recommends the use of the PrescriptionMedicinalProduct valueSet which uses a codeSystem canonical url that is heavily implemented in production but is not the preferred codeSystem (HC-CCDD) expressed in THO. This will be addressed through pCHDCF and is expected to resolve any current differences in other pan-Canadian specifications (e.g., PS-CA) that currently utilize the HC-CCDD valueSet.",
        "min": 1,
        "type": [
          {
            "code": "CodeableConcept",
            "profile": [
              "http://fhir.infoway-inforoute.ca/cacore/StructureDefinition/codeableconcept-ca-core"
            ]
          }
        ],
        "binding": {
          "strength": "preferred",
          "valueSet": "https://fhir.infoway-inforoute.ca/ValueSet/prescriptionmedicinalproduct",
          "extension": [
            {
              "url": "http://hl7.org/fhir/tools/StructureDefinition/additional-binding",
              "extension": [
                {
                  "url": "purpose",
                  "valueCode": "candidate"
                },
                {
                  "url": "valueSet",
                  "valueCanonical": "https://fhir.infoway-inforoute.ca/ValueSet/LicensedNaturalHealthProducts"
                },
                {
                  "url": "documentation",
                  "valueMarkdown": "ValueSet for licensed natural health products"
                }
              ]
            },
            {
              "extension": [
                {
                  "url": "purpose",
                  "valueCode": "candidate"
                },
                {
                  "url": "valueSet",
                  "valueCanonical": "http://hl7.org/fhir/uv/ips/ValueSet/whoatc-uv-ips"
                },
                {
                  "url": "documentation",
                  "valueMarkdown": "per pCHDCF: Can be used for the international use case where a medication is not available in Canada and therefore does not appear in the recommended pan-Canadian value sets. ATC is the recommended supporting classification for reporting and analysis"
                }
              ],
              "url": "http://hl7.org/fhir/tools/StructureDefinition/additional-binding"
            },
            {
              "extension": [
                {
                  "url": "purpose",
                  "valueCode": "candidate"
                },
                {
                  "url": "valueSet",
                  "valueCanonical": "https://fhir.infoway-inforoute.ca/ValueSet/pharmaceuticalbiologicproductandsubstancecode"
                },
                {
                  "url": "documentation",
                  "valueMarkdown": "per PCHDCF: The alternate value set can be used for the international use case where the medication is not available in Canada and therefore does not appear in the recommended pan-Canadian value sets"
                }
              ],
              "url": "http://hl7.org/fhir/tools/StructureDefinition/additional-binding"
            },
            {
              "extension": [
                {
                  "url": "purpose",
                  "valueCode": "candidate"
                },
                {
                  "url": "valueSet",
                  "valueCanonical": "https://fhir.infoway-inforoute.ca/ValueSet/DIN"
                },
                {
                  "url": "documentation",
                  "valueMarkdown": "ValueSet for DIN. A Drug Identification Number (DIN) is a computer-generated eight digit number assigned by Health Canada to a drug product prior to being marketed in Canada."
                }
              ],
              "url": "http://hl7.org/fhir/tools/StructureDefinition/additional-binding"
            }
          ]
        },
        "mapping": [
          {
            "identity": "CACDI",
            "map": "Medication"
          }
        ]
      },
      {
        "id": "Medication.code.coding.system",
        "path": "Medication.code.coding.system",
        "mapping": [
          {
            "identity": "CACDI",
            "map": "Drug Code System URI"
          }
        ]
      },
      {
        "id": "Medication.code.coding.display",
        "path": "Medication.code.coding.display",
        "mapping": [
          {
            "identity": "CACDI",
            "map": "Drug English Description"
          },
          {
            "identity": "CACDI",
            "map": "Drug French Description"
          }
        ]
      },
      {
        "id": "Medication.form",
        "path": "Medication.form",
        "type": [
          {
            "code": "CodeableConcept",
            "profile": [
              "http://fhir.infoway-inforoute.ca/cacore/StructureDefinition/codeableconcept-ca-core"
            ]
          }
        ],
        "binding": {
          "strength": "preferred",
          "valueSet": "https://fhir.infoway-inforoute.ca/ValueSet/pharmaceuticaldoseformcode",
          "extension": [
            {
              "url": "http://hl7.org/fhir/tools/StructureDefinition/additional-binding",
              "extension": [
                {
                  "url": "purpose",
                  "valueCode": "candidate"
                },
                {
                  "url": "valueSet",
                  "valueCanonical": "https://fhir.infoway-inforoute.ca/ValueSet/prescriptiondrugform"
                },
                {
                  "url": "documentation",
                  "valueMarkdown": "ValueSet for the prescription's drug form"
                }
              ]
            }
          ]
        }
      },
      {
        "id": "Medication.form.text",
        "extension": [
          {
            "url": "http://hl7.org/fhir/StructureDefinition/elementdefinition-translatable",
            "valueBoolean": true
          },
          {
            "url": "http://hl7.org/fhir/StructureDefinition/obligation",
            "extension": [
              {
                "url": "code",
                "valueCode": "SHALL:populate-if-known"
              },
              {
                "url": "actor",
                "valueCanonical": "http://fhir.infoway-inforoute.ca/ca-core/ActorDefinition/producer"
              }
            ]
          },
          {
            "extension": [
              {
                "url": "code",
                "valueCode": "SHALL:no-error"
              },
              {
                "url": "actor",
                "valueCanonical": "http://fhir.infoway-inforoute.ca/ca-core/ActorDefinition/consumer"
              }
            ],
            "url": "http://hl7.org/fhir/StructureDefinition/obligation"
          }
        ],
        "path": "Medication.form.text",
        "mustSupport": true
      },
      {
        "id": "Medication.ingredient.item[x]",
        "path": "Medication.ingredient.item[x]",
        "slicing": {
          "discriminator": [
            {
              "type": "type",
              "path": "$this"
            }
          ],
          "ordered": false,
          "rules": "open"
        }
      },
      {
        "id": "Medication.ingredient.item[x]:itemCodeableConcept",
        "path": "Medication.ingredient.item[x]",
        "sliceName": "itemCodeableConcept",
        "min": 0,
        "max": "1",
        "type": [
          {
            "code": "CodeableConcept",
            "profile": [
              "http://fhir.infoway-inforoute.ca/cacore/StructureDefinition/codeableconcept-ca-core"
            ]
          }
        ],
        "binding": {
          "strength": "preferred",
          "valueSet": "https://fhir.infoway-inforoute.ca/ValueSet/drugormedicamentsubstancecode"
        }
      }
    ]
  }
}