{
  "resourceType": "StructureDefinition",
  "text": {
    "status": "empty",
    "div": "<div xmlns=\"http://www.w3.org/1999/xhtml\" />"
  },
  "url": "http://ehealthontario.ca/fhir/StructureDefinition/ca-on-eReferral-profile-AllergyIntolerance",
  "version": "v0.10.0",
  "name": "AllergyIntolerance",
  "title": "AllergyIntolerance",
  "status": "draft",
  "description": "This profile details the clinical assessment of an allergy or intolerance; a propensity, or a potential risk to an individual, to have an adverse reaction on future exposure to the specified substance, or class of substance.",
  "fhirVersion": "4.0.0",
  "kind": "resource",
  "abstract": false,
  "type": "AllergyIntolerance",
  "baseDefinition": "http://hl7.org/fhir/StructureDefinition/AllergyIntolerance",
  "derivation": "constraint",
  "snapshot": {},
  "differential": {
    "element": [
      {
        "id": "AllergyIntolerance.meta",
        "path": "AllergyIntolerance.meta",
        "min": 1,
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.meta.profile",
        "path": "AllergyIntolerance.meta.profile",
        "comment": "#### **_` FOR eREFERRAL USAGE: The meta.profile = http://ehealthontario.ca/fhir/StructureDefinition/ca-on-eReferral-profile-AllergyIntolerance|1.0.0 `_**\r\n\r\nIt is up to the server and/or other infrastructure of policy to determine whether/how these claims are verified and/or updated over time.  The list of profile URLs is a set.",
        "min": 1,
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.identifier",
        "path": "AllergyIntolerance.identifier",
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.identifier.system",
        "path": "AllergyIntolerance.identifier.system",
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.identifier.value",
        "path": "AllergyIntolerance.identifier.value",
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.clinicalStatus",
        "path": "AllergyIntolerance.clinicalStatus",
        "min": 1,
        "mustSupport": true,
        "binding": {
          "strength": "required",
          "valueSet": "http://hl7.org/fhir/ValueSet/allergyintolerance-clinical"
        }
      },
      {
        "id": "AllergyIntolerance.clinicalStatus.coding",
        "path": "AllergyIntolerance.clinicalStatus.coding",
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.clinicalStatus.coding.system",
        "path": "AllergyIntolerance.clinicalStatus.coding.system",
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.clinicalStatus.coding.code",
        "path": "AllergyIntolerance.clinicalStatus.coding.code",
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.clinicalStatus.coding.display",
        "path": "AllergyIntolerance.clinicalStatus.coding.display",
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.verificationStatus",
        "path": "AllergyIntolerance.verificationStatus",
        "mustSupport": true,
        "binding": {
          "strength": "required",
          "valueSet": "http://hl7.org/fhir/ValueSet/allergyintolerance-verification"
        }
      },
      {
        "id": "AllergyIntolerance.verificationStatus.coding",
        "path": "AllergyIntolerance.verificationStatus.coding",
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.verificationStatus.coding.system",
        "path": "AllergyIntolerance.verificationStatus.coding.system",
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.verificationStatus.coding.code",
        "path": "AllergyIntolerance.verificationStatus.coding.code",
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.verificationStatus.coding.display",
        "path": "AllergyIntolerance.verificationStatus.coding.display",
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.type",
        "path": "AllergyIntolerance.type",
        "mustSupport": true,
        "binding": {
          "strength": "required",
          "valueSet": "http://hl7.org/fhir/ValueSet/allergy-intolerance-type"
        }
      },
      {
        "id": "AllergyIntolerance.category",
        "path": "AllergyIntolerance.category",
        "mustSupport": true,
        "binding": {
          "strength": "required",
          "valueSet": "http://hl7.org/fhir/ValueSet/allergy-intolerance-category"
        }
      },
      {
        "id": "AllergyIntolerance.criticality",
        "path": "AllergyIntolerance.criticality",
        "mustSupport": true,
        "binding": {
          "strength": "required",
          "valueSet": "http://hl7.org/fhir/ValueSet/allergy-intolerance-criticality"
        }
      },
      {
        "id": "AllergyIntolerance.code",
        "path": "AllergyIntolerance.code",
        "slicing": {
          "discriminator": [
            {
              "type": "type",
              "path": "$this"
            }
          ],
          "rules": "open"
        },
        "min": 1,
        "mustSupport": true,
        "binding": {
          "strength": "required",
          "valueSet": "https://build.fhir.org/ig/HL7/fhir-ips/ValueSet-allergy-intolerance-substance-condition-uv-ips.html"
        }
      },
      {
        "id": "AllergyIntolerance.code:absentOrUnknownAllergy",
        "path": "AllergyIntolerance.code",
        "sliceName": "absentOrUnknownAllergy",
        "mustSupport": true,
        "binding": {
          "strength": "required",
          "valueSet": "http://hl7.org/fhir/uv/ips/2019Sep/ValueSet-absent-or-unknown-allergies-uv-ips.html"
        }
      },
      {
        "id": "AllergyIntolerance.code:absentOrUnknownAllergy.coding",
        "path": "AllergyIntolerance.code.coding",
        "mustSupport": true,
        "binding": {
          "strength": "required",
          "valueSet": "http://hl7.org/fhir/uv/ips/2019Sep/ValueSet-absent-or-unknown-allergies-uv-ips.html"
        }
      },
      {
        "id": "AllergyIntolerance.code:absentOrUnknownAllergy.coding.system",
        "path": "AllergyIntolerance.code.coding.system",
        "mustSupport": true,
        "binding": {
          "strength": "required",
          "valueSet": "http://hl7.org/fhir/uv/ips/CodeSystem/absent-unknown-uv-ips"
        }
      },
      {
        "id": "AllergyIntolerance.code:absentOrUnknownAllergy.coding.code",
        "path": "AllergyIntolerance.code.coding.code",
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.code:absentOrUnknownAllergy.coding.display",
        "path": "AllergyIntolerance.code.coding.display",
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.patient",
        "path": "AllergyIntolerance.patient",
        "type": [
          {
            "code": "Reference",
            "targetProfile": [
              "https://simplifier.net/ereferral-ontario/ereferralpatient"
            ],
            "aggregation": [
              "referenced"
            ]
          }
        ],
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.patient.reference",
        "path": "AllergyIntolerance.patient.reference",
        "min": 1,
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.onset[x]",
        "path": "AllergyIntolerance.onset[x]",
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.recordedDate",
        "path": "AllergyIntolerance.recordedDate",
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.lastOccurrence",
        "path": "AllergyIntolerance.lastOccurrence",
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.note",
        "path": "AllergyIntolerance.note",
        "max": "1",
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.note.text",
        "path": "AllergyIntolerance.note.text",
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.reaction",
        "path": "AllergyIntolerance.reaction",
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.reaction.substance",
        "path": "AllergyIntolerance.reaction.substance",
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.reaction.substance.coding",
        "path": "AllergyIntolerance.reaction.substance.coding",
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.reaction.substance.coding.system",
        "path": "AllergyIntolerance.reaction.substance.coding.system",
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.reaction.substance.coding.code",
        "path": "AllergyIntolerance.reaction.substance.coding.code",
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.reaction.manifestation",
        "path": "AllergyIntolerance.reaction.manifestation",
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.reaction.manifestation.coding",
        "path": "AllergyIntolerance.reaction.manifestation.coding",
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.reaction.manifestation.coding.system",
        "path": "AllergyIntolerance.reaction.manifestation.coding.system",
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.reaction.manifestation.coding.code",
        "path": "AllergyIntolerance.reaction.manifestation.coding.code",
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.reaction.description",
        "path": "AllergyIntolerance.reaction.description",
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.reaction.onset",
        "path": "AllergyIntolerance.reaction.onset",
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.reaction.severity",
        "path": "AllergyIntolerance.reaction.severity",
        "mustSupport": true
      },
      {
        "id": "AllergyIntolerance.reaction.note",
        "path": "AllergyIntolerance.reaction.note",
        "mustSupport": true
      }
    ]
  }
}