{
  "resourceType": "StructureDefinition",
  "id": "Extension-UKCore-AllergyIntoleranceEnd",
  "url": "https://fhir.nhs.uk/R4/StructureDefinition/Extension-UKCore-AllergyIntoleranceEnd",
  "version": "1.0.0",
  "name": "ExtensionUKCoreAllergyIntoleranceEnd",
  "title": "Extension UK Core Allergy Intolerance End",
  "status": "draft",
  "date": "2020-04-09",
  "publisher": "HL7 UK",
  "contact": [
    {
      "name": "HL7 UK",
      "telecom": [
        {
          "system": "email",
          "value": "secretariat@hl7.org.uk",
          "use": "work",
          "rank": 1
        }
      ]
    },
    {
      "name": "NHS Digital",
      "telecom": [
        {
          "system": "email",
          "value": "interoperabilityteam@nhs.net",
          "use": "work",
          "rank": 2
        }
      ]
    }
  ],
  "description": "An extension to support the date and/or reason that the allergy or intolerance was no longer valid.",
  "copyright": "Copyright © 2020 HL7 UK Licensed under the Apache License, Version 2.0 (the \"License\"); you may not use this file except in compliance with the License. You may obtain a copy of the License at  http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. HL7® FHIR® standard Copyright © 2011+ HL7  The HL7® FHIR® standard is used under the FHIR license. You may obtain a copy of the FHIR license at  https://www.hl7.org/fhir/license.html.",
  "fhirVersion": "4.0.1",
  "mapping": [
    {
      "identity": "rim",
      "uri": "http://hl7.org/v3",
      "name": "RIM Mapping"
    }
  ],
  "kind": "complex-type",
  "abstract": false,
  "context": [
    {
      "type": "element",
      "expression": "AllergyIntolerance"
    }
  ],
  "type": "Extension",
  "baseDefinition": "http://hl7.org/fhir/StructureDefinition/Extension",
  "derivation": "constraint",
  "differential": {
    "element": [
      {
        "id": "Extension",
        "path": "Extension",
        "short": "Supports the date and reason that the allergy was no longer valid",
        "definition": "Supports the date and reason that the allergy was no longer valid.",
        "max": "1"
      },
      {
        "id": "Extension.extension",
        "path": "Extension.extension",
        "slicing": {
          "discriminator": [
            {
              "type": "value",
              "path": "url"
            }
          ],
          "rules": "open"
        }
      },
      {
        "id": "Extension.extension:endDate",
        "path": "Extension.extension",
        "sliceName": "endDate",
        "short": "The date the allergy or intolerance was recorded as no longer valid",
        "definition": "The date the allergy or intolerance was recorded as no longer valid.",
        "max": "1"
      },
      {
        "id": "Extension.extension:endDate.url",
        "path": "Extension.extension.url",
        "fixedUri": "endDate"
      },
      {
        "id": "Extension.extension:endDate.value[x]",
        "path": "Extension.extension.value[x]",
        "short": "The date the allergy was recorded as no longer valid",
        "definition": "The date the allergy was recorded as no longer valid.",
        "min": 1,
        "type": [
          {
            "code": "dateTime"
          }
        ]
      },
      {
        "id": "Extension.extension:reasonEnded",
        "path": "Extension.extension",
        "sliceName": "reasonEnded",
        "short": "The reason why the allergy or intolerance has been resolved",
        "definition": "The reason why the allergy or intolerance has been resolved.",
        "max": "1"
      },
      {
        "id": "Extension.extension:reasonEnded.url",
        "path": "Extension.extension.url",
        "fixedUri": "reasonEnded"
      },
      {
        "id": "Extension.extension:reasonEnded.value[x]",
        "path": "Extension.extension.value[x]",
        "short": "The reason why the allergy or intolerance has been resolved",
        "definition": "The reason why the allergy or intolerance has been resolved.",
        "min": 1,
        "type": [
          {
            "code": "string"
          }
        ]
      },
      {
        "id": "Extension.url",
        "path": "Extension.url",
        "fixedUri": "https://fhir.nhs.uk/R4/StructureDefinition/Extension-UKCore-AllergyIntoleranceEnd"
      },
      {
        "id": "Extension.value[x]",
        "path": "Extension.value[x]",
        "max": "0"
      }
    ]
  }
}