PackagesCanonicalsLogsProblems
    Packages
    rs/hl7.fhir.au.base@0.9.3
    http://hl7.org.au/fhir/StructureDefinition/au-healthcareservice
description: Base profile for Australian context Healthcare Service
package_name: rs/hl7.fhir.au.base
derivation: constraint
name: AUBaseHealthcareService
type: HealthcareService
elements:
  extension:
    index: 0
    slicing:
      rules: open
      discriminator:
      - {path: url, type: value}
      min: null
      slices:
        eligibilityDetails:
          match: {url: null}
          schema: {type: Extension, short: Healthcare service eligibility detail, url: h, index: 1}
        communication:
          match: {url: null}
          schema: {type: Extension, short: Healthcare service communication languages, url: h, index: 2}
          min: 0
  identifier:
    short: Healthcare service identifiers
    index: 3
    slicing:
      rules: open
      discriminator:
      - {path: system, type: value}
      - {path: type, type: value}
      min: null
      slices:
        hpio:
          match: {system: 'http://ns.electronichealth.net.au/id/hi/hpio/1.0', type: null}
          schema:
            short: HPI-O
            index: 4
            elements:
              type:
                index: 5
                elements:
                  coding:
                    short: HPI-O Identifier Type Code
                    index: 6
                    elements:
                      system:
                        pattern: {type: uri, value: 'http://hl7.org.au/fhir/v2/0203'}
                        type: uri
                        index: 7
                      code:
                        pattern: {type: code, value: NOI}
                        type: code
                        index: 8
                    required: [code, system]
                  text:
                    short: HPI-O text description
                    pattern: {type: string, value: HPI-O}
                    type: string
                    index: 9
                required: [text]
              system:
                short: Namespace URI for HPI-O
                pattern: {type: uri, value: 'http://ns.electronichealth.net.au/id/hi/hpio/1.0'}
                type: uri
                index: 10
              value:
                short: HPI-O value
                constraint:
                  inv-hpio-0: {human: The HPI-O shall be a 16 digit number., severity: error, expression: 'matches(''^([0-9]{16})$'')'}
                  inv-hpio-1: {human: HPI-O prefix is 800362, severity: error, expression: startsWith('800362')}
                  inv-hpio-2: {human: The HPI-O Identifier shall pass the Luhn algorithm check, severity: error, expression: '(((select(substring(0,1).toInteger()).select(iif($this<5, $this*2, (($this*2)-9))))+(substring(1,1).toInteger())+(select(substring(2,1).toInteger()).select(iif($this<5, $this*2, (($this*2)-9))))+(substring(3,1).toInteger())+(select(substring(4,1).toInteger()).select(iif($this<5, $this*2, (($this*2)-9))))+(substring(5,1).toInteger())+(select(substring(6,1).toInteger()).select(iif($this<5, $this*2, (($this*2)-9))))+(substring(7,1).toInteger())+(select(substring(8,1).toInteger()).select(iif($this<5, $this*2, (($this*2)-9))))+(substring(9,1).toInteger())+(select(substring(10,1).toInteger()).select(iif($this<5, $this*2, (($this*2)-9))))+(substring(11,1).toInteger())+(select(substring(12,1).toInteger()).select(iif($this<5, $this*2, (($this*2)-9))))+(substring(13,1).toInteger())+(select(substring(14,1).toInteger()).select(iif($this<5, $this*2, (($this*2)-9))))+(substring(15,1).toInteger()))mod 10=0)'}
                index: 11
            required: [system, type, value]
  providedBy:
    type: Reference
    refers: ['http://hl7.org.au/fhir/StructureDefinition/au-organisation']
    index: 12
  specialty:
    short: Healthcare service provided specialties
    index: 13
    slicing:
      rules: open
      discriminator:
      - {path: coding.system, type: value}
      min: null
      slices:
        snomedRole:
          match:
            coding: {system: null}
          schema: {short: Healthcare service specialty SNOMED CT, index: 14}
  location:
    type: Reference
    refers: ['http://hl7.org.au/fhir/StructureDefinition/au-location']
    index: 15
  coverageArea:
    type: Reference
    refers: ['http://hl7.org.au/fhir/StructureDefinition/au-location']
    index: 16
  eligibility: {short: Primary eligibility criteria for service, index: 17}
package_version: 0.9.3
extensions:
  eligibilityDetails: {url: h, type: Extension, short: Healthcare service eligibility detail, index: 1}
  communication: {url: h, min: 0, type: Extension, short: Healthcare service communication languages, index: 2}
class: profile
kind: resource
url: http://hl7.org.au/fhir/StructureDefinition/au-healthcareservice
base: http://hl7.org/fhir/StructureDefinition/HealthcareService
version: '0.1'