<StructureDefinition xmlns="http://hl7.org/fhir">
  <meta>
    <lastUpdated value="2018-07-12T09:56:34.452+01:00" />
  </meta>
  <url value="https://fhir.nhs.uk/STU3/StructureDefinition/CareConnect-ITK-MedicationDispense-1" />
  <version value="1.1.0" />
  <name value="CareConnect-ITK-MedicationDispense-1" />
  <status value="active" />
  <date value="2024-01-22T11:39:06.3872207+00:00" />
  <publisher value="NHS Digital" />
  <contact>
    <name value="Interoperability Team" />
    <telecom>
      <system value="email" />
      <value value="interoperabilityteam@nhs.net" />
      <use value="work" />
    </telecom>
  </contact>
  <description value="Indicates that a medication product is to be or has been dispensed for a named person/patient." />
  <purpose value="CURATED BY INTEROPen see: http://www.interopen.org/careconnect-curation-methodology/" />
  <copyright value="Copyright © 2016 HL7 UK&#xD;&#xA;&#xD;&#xA;Licensed under the Apache License, Version 2.0 (the &quot;License&quot;); you may not use this file except in compliance with the License. You may obtain a copy of the License at&#xD;&#xA;&#xD;&#xA;http://www.apache.org/licenses/LICENSE-2.0&#xD;&#xA;&#xD;&#xA;Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an &quot;AS IS&quot; 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.&#xD;&#xA;&#xD;&#xA;HL7® FHIR® standard Copyright © 2011+ HL7&#xD;&#xA;&#xD;&#xA;The HL7® FHIR® standard is used under the FHIR license. You may obtain a copy of the FHIR license at&#xD;&#xA;&#xD;&#xA;https://www.hl7.org/fhir/license.html" />
  <fhirVersion value="3.0.1" />
  <kind value="resource" />
  <abstract value="false" />
  <type value="MedicationDispense" />
  <baseDefinition value="http://hl7.org/fhir/StructureDefinition/MedicationDispense" />
  <derivation value="constraint" />
  <differential>
    <element id="MedicationDispense.identifier.assigner">
      <path value="MedicationDispense.identifier.assigner" />
      <type>
        <code value="Reference" />
        <targetProfile value="https://fhir.hl7.org.uk/STU3/StructureDefinition/CareConnect-Organization-1" />
      </type>
    </element>
    <element id="MedicationDispense.partOf">
      <path value="MedicationDispense.partOf" />
      <type>
        <code value="Reference" />
        <targetProfile value="https://fhir.nhs.uk/STU3/StructureDefinition/CareConnect-ITK-Procedure-1" />
      </type>
    </element>
    <element id="MedicationDispense.medicationReference:medicationReference">
      <path value="MedicationDispense.medicationReference" />
      <sliceName value="medicationReference" />
      <type>
        <code value="Reference" />
        <targetProfile value="https://fhir.nhs.uk/STU3/StructureDefinition/CareConnect-ITK-Medication-1" />
      </type>
    </element>
    <element id="MedicationDispense.subject">
      <path value="MedicationDispense.subject" />
      <type>
        <code value="Reference" />
        <targetProfile value="https://fhir.hl7.org.uk/STU3/StructureDefinition/CareConnect-Patient-1" />
      </type>
    </element>
    <element id="MedicationDispense.context">
      <path value="MedicationDispense.context" />
      <type>
        <code value="Reference" />
        <targetProfile value="https://fhir.nhs.uk/STU3/StructureDefinition/CareConnect-ITK-Encounter-1" />
      </type>
    </element>
    <element id="MedicationDispense.performer">
      <path value="MedicationDispense.performer" />
      <max value="1" />
    </element>
    <element id="MedicationDispense.performer.actor">
      <path value="MedicationDispense.performer.actor" />
      <type>
        <code value="Reference" />
        <targetProfile value="https://fhir.hl7.org.uk/STU3/StructureDefinition/CareConnect-Organization-1" />
      </type>
      <type>
        <code value="Reference" />
        <targetProfile value="https://fhir.hl7.org.uk/STU3/StructureDefinition/CareConnect-Patient-1" />
      </type>
      <type>
        <code value="Reference" />
        <targetProfile value="https://fhir.hl7.org.uk/STU3/StructureDefinition/CareConnect-Practitioner-1" />
      </type>
      <type>
        <code value="Reference" />
        <targetProfile value="https://fhir.nhs.uk/STU3/StructureDefinition/ITK-RelatedPerson-1" />
      </type>
    </element>
    <element id="MedicationDispense.performer.onBehalfOf">
      <path value="MedicationDispense.performer.onBehalfOf" />
      <type>
        <code value="Reference" />
        <targetProfile value="https://fhir.hl7.org.uk/STU3/StructureDefinition/CareConnect-Organization-1" />
      </type>
    </element>
    <element id="MedicationDispense.authorizingPrescription">
      <path value="MedicationDispense.authorizingPrescription" />
      <type>
        <code value="Reference" />
        <targetProfile value="https://fhir.hl7.org.uk/STU3/StructureDefinition/CareConnect-MedicationRequest-1" />
      </type>
    </element>
    <element id="MedicationDispense.type">
      <path value="MedicationDispense.type" />
      <short value="To identify the type of medication supply." />
      <binding>
        <extension url="http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName">
          <valueString value="MedicationDispenseType" />
        </extension>
        <strength value="required" />
        <description value="A ValueSet to identify the type of medication supply." />
        <valueSetReference>
          <reference value="https://fhir.hl7.org.uk/STU3/ValueSet/CareConnect-MedicationSupplyType-1" />
        </valueSetReference>
      </binding>
    </element>
    <element id="MedicationDispense.quantity.extension">
      <path value="MedicationDispense.quantity.extension" />
      <slicing>
        <discriminator>
          <type value="value" />
          <path value="url" />
        </discriminator>
        <rules value="open" />
      </slicing>
    </element>
    <element id="MedicationDispense.quantity.extension:quantityText">
      <path value="MedicationDispense.quantity.extension" />
      <sliceName value="quantityText" />
      <short value="Quantity representation" />
      <definition value="Quantity representation." />
      <max value="1" />
      <type>
        <code value="Extension" />
        <profile value="https://fhir.hl7.org.uk/STU3/StructureDefinition/Extension-CareConnect-MedicationQuantityText-1" />
      </type>
    </element>
    <element id="MedicationDispense.quantity.extension:quantityText.url">
      <path value="MedicationDispense.quantity.extension.url" />
      <fixedUri value="https://fhir.hl7.org.uk/STU3/StructureDefinition/Extension-CareConnect-MedicationQuantityText-1" />
    </element>
    <element id="MedicationDispense.destination">
      <path value="MedicationDispense.destination" />
      <type>
        <code value="Reference" />
        <targetProfile value="https://fhir.hl7.org.uk/STU3/StructureDefinition/CareConnect-Location-1" />
      </type>
    </element>
    <element id="MedicationDispense.receiver">
      <path value="MedicationDispense.receiver" />
      <type>
        <code value="Reference" />
        <targetProfile value="https://fhir.hl7.org.uk/STU3/StructureDefinition/CareConnect-Patient-1" />
      </type>
      <type>
        <code value="Reference" />
        <targetProfile value="https://fhir.hl7.org.uk/STU3/StructureDefinition/CareConnect-Practitioner-1" />
      </type>
    </element>
    <element id="MedicationDispense.note">
      <path value="MedicationDispense.note" />
      <max value="1" />
    </element>
    <element id="MedicationDispense.note.author[x]">
      <path value="MedicationDispense.note.author[x]" />
      <type>
        <code value="string" />
      </type>
      <type>
        <code value="Reference" />
        <targetProfile value="https://fhir.hl7.org.uk/STU3/StructureDefinition/CareConnect-Patient-1" />
      </type>
      <type>
        <code value="Reference" />
        <targetProfile value="https://fhir.hl7.org.uk/STU3/StructureDefinition/CareConnect-Practitioner-1" />
      </type>
      <type>
        <code value="Reference" />
        <targetProfile value="https://fhir.nhs.uk/STU3/StructureDefinition/ITK-RelatedPerson-1" />
      </type>
    </element>
    <element id="MedicationDispense.dosageInstruction.method">
      <path value="MedicationDispense.dosageInstruction.method" />
      <max value="0" />
    </element>
    <element id="MedicationDispense.substitution.responsibleParty">
      <path value="MedicationDispense.substitution.responsibleParty" />
      <type>
        <code value="Reference" />
        <targetProfile value="https://fhir.hl7.org.uk/STU3/StructureDefinition/CareConnect-Practitioner-1" />
      </type>
    </element>
    <element id="MedicationDispense.detectedIssue">
      <path value="MedicationDispense.detectedIssue" />
      <max value="0" />
    </element>
    <element id="MedicationDispense.notDone">
      <path value="MedicationDispense.notDone" />
      <max value="0" />
    </element>
    <element id="MedicationDispense.notDoneReason[x]">
      <path value="MedicationDispense.notDoneReason[x]" />
      <max value="0" />
    </element>
    <element id="MedicationDispense.eventHistory">
      <path value="MedicationDispense.eventHistory" />
      <max value="0" />
    </element>
  </differential>
</StructureDefinition>