PackagesCanonicalsLogsProblems
    Packages
    rs/hl7.fhir.au.base@1.0.2
    http://hl7.org.au/fhir/StructureDefinition/au-medicationdispense
description: This profile defines a medication dispense structure including core localisation concepts for use as a dispense record in an Australian context.
package_name: rs/hl7.fhir.au.base
derivation: constraint
name: AUBaseMedicationDispense
type: MedicationDispense
elements:
  extension:
    index: 0
    slicing:
      rules: open
      discriminator:
      - {path: url, type: value}
      min: null
      slices:
        groundsForConcurrentSupply:
          match: {url: null}
          schema: {type: Extension, short: Grounds for Concurrent Supply of Medication, url: h, index: 1}
          max: 1
        dispenseNumber:
          match: {url: null}
          schema: {type: Extension, short: Number of this Dispense, url: h, index: 2}
          max: 1
        brandName:
          match: {url: null}
          schema: {type: Extension, short: Medication Brand Name, url: h, index: 3}
          max: 1
        genericName:
          match: {url: null}
          schema: {type: Extension, short: Medication Generic Drug Name, url: h, index: 4}
          max: 1
  identifier:
    index: 5
    slicing:
      rules: open
      discriminator:
      - {path: system, type: value}
      - {path: type, type: value}
      min: null
      slices:
        localDispenseIdentifier:
          match: {system: null, type: null}
          schema:
            short: Local Dispense Identifier
            index: 6
            elements:
              type:
                short: Coded identifier type for local dispense identifier
                index: 7
                elements:
                  coding:
                    index: 8
                    elements:
                      system:
                        pattern: {type: uri, value: 'http://hl7.org.au/fhir/v2/0203'}
                        type: uri
                        index: 9
                      code:
                        pattern: {type: code, value: LDI}
                        type: code
                        index: 10
                    required: [code, system]
                  text:
                    pattern: {type: string, value: Local Dispense Identifier}
                    type: string
                    index: 11
                required: [coding, text]
              system: {short: Namespace for local dispense record identifier, index: 12}
              value: {short: Dispense record identifier, index: 13}
              assigner:
                index: 14
                elements:
                  display: {index: 15}
                required: [display]
            required: [assigner, system, type, value]
  medication:
    short: Dispensed Medication
    choices: [medicationReference]
    index: 32
    slicing:
      slices:
        medicationReference:
          match: {}
          schema:
            short: Dispensed Medication
            choices: [medicationReference]
            index: 32
  medicationCodeableConcept:
    type: CodeableConcept
    short: Coded Dispensed Medication
    constraint:
      inv-amt-tpuu: {human: AMT TPUU valueset membership required, severity: error, expression: 'coding.exists(system=''http://snomed.info/sct'' and extension.where(url=''http://hl7.org.au/fhir/CodeSystem/medication-type'').valueCoding=''BPDSF'') implies coding.where(system=''http://snomed.info/sct'' and extension.where(url=''http://hl7.org.au/fhir/CodeSystem/medication-type'').valueCoding=''BPDSF'').code in ''http://hl7.org.au/fhir/ValueSet/amt-tpuu-codes'''}
      inv-amt-tpp: {human: AMT TPU valueset membership required, severity: error, expression: 'coding.exists(system=''http://snomed.info/sct'' and extension.where(url=''http://hl7.org.au/fhir/CodeSystem/medication-type'').valueCoding=''BPG'') implies coding.where(system=''http://snomed.info/sct'' and extension.where(url=''http://hl7.org.au/fhir/CodeSystem/medication-type'').valueCoding=''BPG'').code in ''http://hl7.org.au/fhir/ValueSet/amt-tpp-codes'''}
      inv-amt-tp: {human: AMT TP valueset membership required, severity: error, expression: 'coding.exists(system=''http://snomed.info/sct'' and extension.where(url=''http://hl7.org.au/fhir/CodeSystem/medication-type'').valueCoding=''BPD'') implies coding.where(system=''http://snomed.info/sct'' and extension.where(url=''http://hl7.org.au/fhir/CodeSystem/medication-type'').valueCoding=''BPD'').code in ''http://hl7.org.au/fhir/ValueSet/amt-tp-codes'''}
      inv-amp-mpuu: {human: AMT MPUU valueset membership required, severity: error, expression: 'coding.exists(system=''http://snomed.info/sct'' and extension.where(url=''http://hl7.org.au/fhir/CodeSystem/medication-type'').valueCoding=''UPDSF'') implies coding.where(system=''http://snomed.info/sct'' and extension.where(url=''http://hl7.org.au/fhir/CodeSystem/medication-type'').valueCoding=''UPDSF'').code in ''http://hl7.org.au/fhir/ValueSet/amt-mpuu-codes'''}
      inv-amt-mpp: {human: AMT MPP valueset membership required, severity: error, expression: 'coding.exists(system=''http://snomed.info/sct'' and extension.where(url=''http://hl7.org.au/fhir/CodeSystem/medication-type'').valueCoding=''UPG'') implies coding.where(system=''http://snomed.info/sct'' and extension.where(url=''http://hl7.org.au/fhir/CodeSystem/medication-type'').valueCoding=''UPG'').code in ''http://hl7.org.au/fhir/ValueSet/amt-mpp-codes'''}
      inv-amt-mp: {human: AMT MP valueset membership required, severity: error, expression: 'coding.exists(system=''http://snomed.info/sct'' and extension.where(url=''http://hl7.org.au/fhir/CodeSystem/medication-type'').valueCoding=''UPD'') implies coding.where(system=''http://snomed.info/sct'' and extension.where(url=''http://hl7.org.au/fhir/CodeSystem/medication-type'').valueCoding=''UPD'').code in ''http://hl7.org.au/fhir/ValueSet/amt-mp-codes'''}
      inv-amt-ctpp: {human: AMT CTPP valueset membership required, severity: error, expression: 'coding.exists(system=''http://snomed.info/sct'' and extension.where(url=''http://hl7.org.au/fhir/CodeSystem/medication-type'').valueCoding=''BPGC'') implies coding.where(system=''http://snomed.info/sct'' and extension.where(url=''http://hl7.org.au/fhir/CodeSystem/medication-type'').valueCoding=''BPGC'').code in ''http://hl7.org.au/fhir/ValueSet/amt-ctpp-codes'''}
    choiceOf: medication
    index: 22
    slicing:
      slices:
        medicationCoded:
          match: {}
          schema:
            type: CodeableConcept
            short: Coded Dispensed Medication
            constraint:
              inv-amt-tpuu: {human: AMT TPUU valueset membership required, severity: error, expression: 'coding.exists(system=''http://snomed.info/sct'' and extension.where(url=''http://hl7.org.au/fhir/CodeSystem/medication-type'').valueCoding=''BPDSF'') implies coding.where(system=''http://snomed.info/sct'' and extension.where(url=''http://hl7.org.au/fhir/CodeSystem/medication-type'').valueCoding=''BPDSF'').code in ''http://hl7.org.au/fhir/ValueSet/amt-tpuu-codes'''}
              inv-amt-tpp: {human: AMT TPU valueset membership required, severity: error, expression: 'coding.exists(system=''http://snomed.info/sct'' and extension.where(url=''http://hl7.org.au/fhir/CodeSystem/medication-type'').valueCoding=''BPG'') implies coding.where(system=''http://snomed.info/sct'' and extension.where(url=''http://hl7.org.au/fhir/CodeSystem/medication-type'').valueCoding=''BPG'').code in ''http://hl7.org.au/fhir/ValueSet/amt-tpp-codes'''}
              inv-amt-tp: {human: AMT TP valueset membership required, severity: error, expression: 'coding.exists(system=''http://snomed.info/sct'' and extension.where(url=''http://hl7.org.au/fhir/CodeSystem/medication-type'').valueCoding=''BPD'') implies coding.where(system=''http://snomed.info/sct'' and extension.where(url=''http://hl7.org.au/fhir/CodeSystem/medication-type'').valueCoding=''BPD'').code in ''http://hl7.org.au/fhir/ValueSet/amt-tp-codes'''}
              inv-amp-mpuu: {human: AMT MPUU valueset membership required, severity: error, expression: 'coding.exists(system=''http://snomed.info/sct'' and extension.where(url=''http://hl7.org.au/fhir/CodeSystem/medication-type'').valueCoding=''UPDSF'') implies coding.where(system=''http://snomed.info/sct'' and extension.where(url=''http://hl7.org.au/fhir/CodeSystem/medication-type'').valueCoding=''UPDSF'').code in ''http://hl7.org.au/fhir/ValueSet/amt-mpuu-codes'''}
              inv-amt-mpp: {human: AMT MPP valueset membership required, severity: error, expression: 'coding.exists(system=''http://snomed.info/sct'' and extension.where(url=''http://hl7.org.au/fhir/CodeSystem/medication-type'').valueCoding=''UPG'') implies coding.where(system=''http://snomed.info/sct'' and extension.where(url=''http://hl7.org.au/fhir/CodeSystem/medication-type'').valueCoding=''UPG'').code in ''http://hl7.org.au/fhir/ValueSet/amt-mpp-codes'''}
              inv-amt-mp: {human: AMT MP valueset membership required, severity: error, expression: 'coding.exists(system=''http://snomed.info/sct'' and extension.where(url=''http://hl7.org.au/fhir/CodeSystem/medication-type'').valueCoding=''UPD'') implies coding.where(system=''http://snomed.info/sct'' and extension.where(url=''http://hl7.org.au/fhir/CodeSystem/medication-type'').valueCoding=''UPD'').code in ''http://hl7.org.au/fhir/ValueSet/amt-mp-codes'''}
              inv-amt-ctpp: {human: AMT CTPP valueset membership required, severity: error, expression: 'coding.exists(system=''http://snomed.info/sct'' and extension.where(url=''http://hl7.org.au/fhir/CodeSystem/medication-type'').valueCoding=''BPGC'') implies coding.where(system=''http://snomed.info/sct'' and extension.where(url=''http://hl7.org.au/fhir/CodeSystem/medication-type'').valueCoding=''BPGC'').code in ''http://hl7.org.au/fhir/ValueSet/amt-ctpp-codes'''}
            choiceOf: medication
            index: 22
  medicationReference:
    type: Reference
    short: Dispensed Medication
    choiceOf: medication
    refers: ['http://hl7.org.au/fhir/StructureDefinition/au-medication']
    index: 33
    slicing:
      slices:
        medicationReference:
          match: {}
          schema:
            type: Reference
            short: Dispensed Medication
            choiceOf: medication
            refers: ['http://hl7.org.au/fhir/StructureDefinition/au-medication']
            index: 33
  medication[x]:
    elements:
      coding:
        index: 23
        slicing:
          rules: open
          discriminator:
          - {path: system, type: value}
          - {path: code, type: value}
          min: null
          slices:
            pbs:
              match: {system: null, code: null}
              schema: {short: PBS Item Code, index: 24}
            gtin:
              match: {system: null, code: null}
              schema: {short: Medication Package Global Trade Item Number (GTIN), index: 25}
            amt:
              match: {system: null, code: null}
              schema:
                short: AMT Medicines
                index: 26
                extensions:
                  medicationClass: {url: h, max: 1, type: Extension, short: Class of Medication Coding, index: 28}
                elements:
                  extension:
                    index: 27
                    slicing:
                      rules: open
                      discriminator:
                      - {path: url, type: value}
                      min: null
                      slices:
                        medicationClass:
                          match: {url: null}
                          schema: {type: Extension, short: Class of Medication Coding, url: h, index: 28}
                          max: 1
            mimsPackage:
              match: {system: null, code: null}
              schema: {short: MIMS Package, index: 29}
              max: 1
      text: {short: Medication primary text, index: 30}
  authorizingPrescription:
    type: Reference
    refers: ['http://hl7.org.au/fhir/StructureDefinition/au-prescription']
    index: 34
  dosageInstruction:
    type: Dosage
    index: 35
    elements:
      additionalInstruction: {index: 36}
      asNeeded:
        choices: []
        index: 38
        slicing:
          rules: open
          discriminator:
          - {path: $this, type: type}
          min: null
          slices:
            asNeededCoding:
              match: {}
              schema:
                choices: []
                index: 40
      asNeeded[x]:
        elements:
          coding: {index: 41}
      route:
        elements:
          coding: {index: 42}
      method:
        elements:
          coding: {index: 43}
package_version: 1.0.2
extensions:
  groundsForConcurrentSupply: {url: h, max: 1, type: Extension, short: Grounds for Concurrent Supply of Medication, index: 1}
  dispenseNumber: {url: h, max: 1, type: Extension, short: Number of this Dispense, index: 2}
  brandName: {url: h, max: 1, type: Extension, short: Medication Brand Name, index: 3}
  genericName: {url: h, max: 1, type: Extension, short: Medication Generic Drug Name, index: 4}
class: profile
kind: resource
url: http://hl7.org.au/fhir/StructureDefinition/au-medicationdispense
base: http://hl7.org/fhir/StructureDefinition/MedicationDispense
version: 1.0.1