PackagesCanonicalsLogsProblems
    Packages
    rs/hl7.fhir.au.base@1.1.1
    http://hl7.org.au/fhir/StructureDefinition/au-healthcareservice
description: This profile defines a healthcare service administration details structure that includes core localisation concepts for use in an Australian context.
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}
  identifier:
    short: Healthcare service identifiers
    index: 3
    slicing:
      rules: open
      discriminator:
      - {path: type, type: pattern}
      - {path: system, type: value}
      min: null
      slices:
        hpio:
          match:
            type:
              coding:
              - {code: NOI, system: 'http://hl7.org.au/fhir/v2/0203'}
            system: http://ns.electronichealth.net.au/id/hi/hpio/1.0
          schema:
            short: Healthcare Provider Identifier – Organisation (HPI-O)
            constraint:
              inv-hpio-0: {human: HPI-O shall be an exactly 16 digit number, severity: error, expression: 'value.matches(''^([0-9]{16})$'')'}
              inv-hpio-1: {human: HPI-O prefix is 800362, severity: error, expression: value.startsWith('800362')}
              inv-hpio-2: {human: HPI-O shall pass the Luhn algorithm check, severity: error, expression: '(((select(value.substring(0,1).toInteger()).select(iif($this<5, $this*2, (($this*2)-9))))+(value.substring(1,1).toInteger())+(select(value.substring(2,1).toInteger()).select(iif($this<5, $this*2, (($this*2)-9))))+(value.substring(3,1).toInteger())+(select(value.substring(4,1).toInteger()).select(iif($this<5, $this*2, (($this*2)-9))))+(value.substring(5,1).toInteger())+(select(value.substring(6,1).toInteger()).select(iif($this<5, $this*2, (($this*2)-9))))+(value.substring(7,1).toInteger())+(select(value.substring(8,1).toInteger()).select(iif($this<5, $this*2, (($this*2)-9))))+(value.substring(9,1).toInteger())+(select(value.substring(10,1).toInteger()).select(iif($this<5, $this*2, (($this*2)-9))))+(value.substring(11,1).toInteger())+(select(value.substring(12,1).toInteger()).select(iif($this<5, $this*2, (($this*2)-9))))+(value.substring(13,1).toInteger())+(select(value.substring(14,1).toInteger()).select(iif($this<5, $this*2, (($this*2)-9))))+(value.substring(15,1).toInteger()))mod 10=0)'}
            index: 4
            elements:
              type:
                short: Identifier type for HPI-O
                pattern:
                  type: CodeableConcept
                  value:
                    coding:
                    - {code: NOI, system: 'http://hl7.org.au/fhir/v2/0203'}
                type: CodeableConcept
                index: 5
                elements:
                  text:
                    pattern: {type: string, value: HPI-O}
                    type: string
                    index: 6
              system:
                short: Namespace for HPI-O
                pattern: {type: uri, value: 'http://ns.electronichealth.net.au/id/hi/hpio/1.0'}
                type: uri
                index: 7
              value: {short: HPI-O number, maxLength: 16, index: 8}
            required: [system, value]
  type: {short: Healthcare service types, index: 9}
  specialty: {short: Healthcare service provided specialties, index: 10}
  serviceProvisionCode: {short: Healthcare service provision conditions, index: 11}
  eligibility: {short: Primary eligibility criteria for service, index: 12}
package_version: 1.1.1
extensions:
  eligibilityDetails: {url: h, type: Extension, short: Healthcare Service Eligibility Detail, index: 1}
  communication: {url: h, 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: 1.1.1