PackagesCanonicalsLogsProblems
    Packages
    ch.fhir.ig.ch-atc@3.3.0-ballot
    http://fhir.ch/ig/ch-atc/StructureDefinition/PolicyAuditEvent
description: This profile defines the content of the policy audit events which a community has to provide for a patients audit trail.
package_name: ch.fhir.ig.ch-atc
derivation: constraint
name: PolicyAuditEvent
type: AuditEvent
elements:
  type:
    binding: {strength: extensible, valueSet: 'http://hl7.org/fhir/ValueSet/audit-event-type'}
    index: 0
  subtype:
    index: 1
    slicing:
      rules: open
      discriminator:
      - {path: system, type: value}
      min: 1
      slices:
        PolicyAuditEventType:
          match: {system: 'urn:oid:2.16.756.5.30.1.127.3.10.7'}
          schema:
            short: PolicyAuditEventType
            binding: {strength: required, valueSet: 'http://fhir.ch/ig/ch-atc/ValueSet/PolicyAuditEventType'}
            _required: true
            index: 2
            elements:
              system:
                pattern: {type: Uri, value: 'urn:oid:2.16.756.5.30.1.127.3.10.7'}
                index: 3
            required: [system]
  recorded: {index: 4}
  agent:
    short: Participants
    index: 5
    elements:
      role:
        binding: {strength: required, valueSet: 'http://fhir.ch/ig/ch-atc/ValueSet/EprParticipant'}
        index: 6
      who:
        elements:
          identifier: {type: Identifier, index: 7}
        required: [identifier]
      name: {index: 8}
      requestor: {index: 9}
    required: [role, name]
  entity:
    index: 10
    slicing:
      rules: open
      discriminator:
      - {path: type.code, type: value}
      - {path: role.code, type: value}
      min: null
      slices:
        Patient:
          match:
            type: {code: null}
            role: {code: null}
          schema:
            _required: true
            index: 11
            elements:
              what:
                elements:
                  identifier: {index: 12}
        Resource:
          match:
            type: {code: '2'}
            role: {code: null}
          schema:
            short: Resource (HCP, Group, Representative of Patient)
            index: 13
            elements:
              what:
                elements:
                  identifier: {type: Identifier, short: 'Identifier: HCP (GLN), Group (OID)', index: 14}
              type:
                index: 15
                elements:
                  code:
                    pattern: {type: Code, value: '2'}
                    index: 16
                required: [code]
              role:
                binding: {strength: required, valueSet: 'http://fhir.ch/ig/ch-atc/ValueSet/EprParticipant'}
                index: 17
              name: {index: 18}
              detail:
                index: 19
                slicing:
                  rules: open
                  discriminator:
                  - {path: type, type: value}
                  min: null
                  slices:
                    AccessLevel:
                      match: {type: AccessLevel}
                      schema:
                        short: AccessLevel if subtype is Create or Update
                        index: 20
                        elements:
                          type:
                            short: The type of extra detail provided in the value
                            pattern: {type: String, value: AccessLevel}
                            index: 21
                          value: {type: base64Binary, short: 'one of urn:e-health-suisse:2015:policies:access-level: normal, restricted, delegation-and-restricted, delegation-and-normal or full', index: 22}
                    AccessLimitedToDate:
                      match: {type: AccessLimitedToDate}
                      schema:
                        short: AccessLimitedToDate if subtype is Create or Update
                        index: 23
                        elements:
                          type:
                            pattern: {type: String, value: AccessLimitedToDate}
                            index: 24
                          value: {type: base64Binary, short: Date in property value, index: 25}
                    ProvideLevel:
                      match: {type: ProvideLevel}
                      schema:
                        short: ProvideLevel if subtype is ATC_POL_DEF_CONFLEVEL
                        index: 26
                        elements:
                          type:
                            pattern: {type: String, value: ProvideLevel}
                            index: 27
                          value: {type: base64Binary, short: 'one of urn:e-health-suisse:2015:policies:provide-level: normal, restricted or secret', index: 28}
            required: [role, name, type]
package_version: 3.3.0-ballot
class: profile
kind: resource
url: http://fhir.ch/ig/ch-atc/StructureDefinition/PolicyAuditEvent
base: http://fhir.ch/ig/ch-epr-fhir/StructureDefinition/ch-epr-fhir-auditevent
version: 3.3.0-ballot
required: [subtype]