HL7 FHIR Implementation Guide: Data Access Policies
1.0.0-current - ci-build International flag

HL7 FHIR Implementation Guide: Data Access Policies, published by HL7 International / Security. This guide is not an authorized publication; it is the continuous build for version 1.0.0-current built by the FHIR (HL7® FHIR® Standard) CI Build. This version is based on the current content of https://github.com/HL7/data-access-policies/ and changes regularly. See the Directory of published versions

: A Permission with all the Directory rules - TTL Representation

Page standards status: Informative

Raw ttl | Download


@prefix fhir: <http://hl7.org/fhir/> .
@prefix owl: <http://www.w3.org/2002/07/owl#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .

# - resource -------------------------------------------------------------------

 a fhir:Permission ;
  fhir:nodeRole fhir:treeRoot ;
  fhir:id [ fhir:v "ex-permission-directory-all"] ; # 
  fhir:meta [
    ( fhir:security [
fhir:system [ fhir:v "http://terminology.hl7.org/CodeSystem/v3-ActReason"^^xsd:anyURI ] ;
fhir:code [ fhir:v "HTEST" ]     ] )
  ] ; # 
  fhir:text [
fhir:status [ fhir:v "generated" ] ;
fhir:div "<div xmlns=\"http://www.w3.org/1999/xhtml\"><p class=\"res-header-id\"><b>Generated Narrative: Permission ex-permission-directory-all</b></p><a name=\"ex-permission-directory-all\"> </a><a name=\"hcex-permission-directory-all\"> </a><a name=\"ex-permission-directory-all-en-US\"> </a><p><b>status</b>: Active</p><p><b>asserter</b>: <a href=\"Organization-ex-organization.html\">Organization nowhere</a></p><p><b>date</b>: 2023-11-22</p><p><b>combining</b>: Deny-unless-permit</p><blockquote><p><b>rule</b></p><p><b>type</b>: Permit</p><blockquote><p><b>activity</b></p><p><b>action</b>: <span title=\"Codes:{http://hl7.org/fhir/audit-event-action C}\">Create</span>, <span title=\"Codes:{http://hl7.org/fhir/audit-event-action R}\">Read</span>, <span title=\"Codes:{http://hl7.org/fhir/audit-event-action U}\">Update</span>, <span title=\"Codes:{http://hl7.org/fhir/audit-event-action D}\">Delete</span>, <span title=\"Codes:{http://hl7.org/fhir/audit-event-action E}\">Execute</span></p><p><b>purpose</b>: <span title=\"Codes:{http://terminology.hl7.org/CodeSystem/v3-ActReason HDIRECT}\">directory</span>, <span title=\"Codes:{http://terminology.hl7.org/CodeSystem/v3-ActReason HSYSADMIN}\">health system administration</span></p></blockquote></blockquote><blockquote><p><b>rule</b></p><p><b>type</b>: Permit</p><blockquote><p><b>activity</b></p><p><b>action</b>: <span title=\"Codes:{http://hl7.org/fhir/audit-event-action R}\">Read</span>, <span title=\"Codes:{http://hl7.org/fhir/audit-event-action E}\">Execute</span></p><p><b>purpose</b>: <span title=\"Codes:{http://terminology.hl7.org/CodeSystem/v3-ActReason TREAT}\">treatment</span>, <span title=\"Codes:{http://terminology.hl7.org/CodeSystem/v3-ActReason HPAYMT}\">healthcare payment</span>, <span title=\"Codes:{http://terminology.hl7.org/CodeSystem/v3-ActReason HOPERAT}\">healthcare operations</span></p></blockquote></blockquote><blockquote><p><b>rule</b></p><p><b>type</b>: Permit</p><blockquote><p><b>data</b></p><h3>Expressions</h3><table class=\"grid\"><tr><td style=\"display: none\">-</td><td><b>Description</b></td><td><b>Language</b></td><td><b>Expression</b></td></tr><tr><td style=\"display: none\">*</td><td>select all Practitioner resources where the Practitioner has a PractitionerRole with code of doctor</td><td>application/x-fhir-query</td><td>Practitioner?_has:PractitionerRole:practitioner:role=http://terminology.hl7.org/CodeSystem/practitioner-role|doctor</td></tr></table></blockquote><blockquote><p><b>activity</b></p><p><b>action</b>: <span title=\"Codes:{http://hl7.org/fhir/audit-event-action R}\">Read</span>, <span title=\"Codes:{http://hl7.org/fhir/audit-event-action E}\">Execute</span></p><p><b>purpose</b>: <span title=\"Codes:{http://terminology.hl7.org/CodeSystem/v3-ActReason PATRQT}\">patient requested</span></p></blockquote></blockquote></div>"
  ] ; # 
  fhir:status [ fhir:v "active"] ; # 
  fhir:asserter [
fhir:reference [ fhir:v "Organization/ex-organization" ]
  ] ; # 
  fhir:date ( [ fhir:v "2023-11-22"^^xsd:date] ) ; # 
  fhir:combining [ fhir:v "deny-unless-permit"] ; # 
  fhir:rule ( [
fhir:type [ fhir:v "permit" ] ;
    ( fhir:activity [
      ( fhir:action [
        ( fhir:coding [
fhir:system [ fhir:v "http://hl7.org/fhir/audit-event-action"^^xsd:anyURI ] ;
fhir:code [ fhir:v "C" ]         ] )       ] [
        ( fhir:coding [
fhir:system [ fhir:v "http://hl7.org/fhir/audit-event-action"^^xsd:anyURI ] ;
fhir:code [ fhir:v "R" ]         ] )       ] [
        ( fhir:coding [
fhir:system [ fhir:v "http://hl7.org/fhir/audit-event-action"^^xsd:anyURI ] ;
fhir:code [ fhir:v "U" ]         ] )       ] [
        ( fhir:coding [
fhir:system [ fhir:v "http://hl7.org/fhir/audit-event-action"^^xsd:anyURI ] ;
fhir:code [ fhir:v "D" ]         ] )       ] [
        ( fhir:coding [
fhir:system [ fhir:v "http://hl7.org/fhir/audit-event-action"^^xsd:anyURI ] ;
fhir:code [ fhir:v "E" ]         ] )       ] ) ;
      ( fhir:purpose [
        ( fhir:coding [
fhir:system [ fhir:v "http://terminology.hl7.org/CodeSystem/v3-ActReason"^^xsd:anyURI ] ;
fhir:code [ fhir:v "HDIRECT" ]         ] )       ] [
        ( fhir:coding [
fhir:system [ fhir:v "http://terminology.hl7.org/CodeSystem/v3-ActReason"^^xsd:anyURI ] ;
fhir:code [ fhir:v "HSYSADMIN" ]         ] )       ] )     ] )
  ] ) ; # 
  fhir:_rule ( [
    ( fhir:modifierExtension [
fhir:url [ fhir:v "http://hl7.org/fhir/uv/dap/StructureDefinition/dap.excludeTagged"^^xsd:anyURI ] ;
fhir:value [
a fhir:Coding ;
fhir:system [ fhir:v "http://terminology.hl7.org/CodeSystem/v3-ActCode"^^xsd:anyURI ] ;
fhir:code [ fhir:v "LOCIS" ]       ]     ] ) ;
fhir:type [ fhir:v "permit" ] ;
    ( fhir:activity [
      ( fhir:action [
        ( fhir:coding [
fhir:system [ fhir:v "http://hl7.org/fhir/audit-event-action"^^xsd:anyURI ] ;
fhir:code [ fhir:v "R" ]         ] )       ] [
        ( fhir:coding [
fhir:system [ fhir:v "http://hl7.org/fhir/audit-event-action"^^xsd:anyURI ] ;
fhir:code [ fhir:v "E" ]         ] )       ] ) ;
      ( fhir:purpose [
        ( fhir:coding [
fhir:system [ fhir:v "http://terminology.hl7.org/CodeSystem/v3-ActReason"^^xsd:anyURI ] ;
fhir:code [ fhir:v "TREAT" ]         ] )       ] [
        ( fhir:coding [
fhir:system [ fhir:v "http://terminology.hl7.org/CodeSystem/v3-ActReason"^^xsd:anyURI ] ;
fhir:code [ fhir:v "HPAYMT" ]         ] )       ] [
        ( fhir:coding [
fhir:system [ fhir:v "http://terminology.hl7.org/CodeSystem/v3-ActReason"^^xsd:anyURI ] ;
fhir:code [ fhir:v "HOPERAT" ]         ] )       ] )     ] )
  ] [
    ( fhir:modifierExtension [
fhir:url [ fhir:v "http://hl7.org/fhir/uv/dap/StructureDefinition/dap.excludeTagged"^^xsd:anyURI ] ;
fhir:value [
a fhir:Coding ;
fhir:system [ fhir:v "http://terminology.hl7.org/CodeSystem/v3-ActCode"^^xsd:anyURI ] ;
fhir:code [ fhir:v "LOCIS" ]       ]     ] ) ;
fhir:type [ fhir:v "permit" ] ;
    ( fhir:data [
fhir:expression [
fhir:description [ fhir:v "select all Practitioner resources where the Practitioner has a PractitionerRole with code of doctor" ] ;
fhir:language [ fhir:v "application/x-fhir-query" ] ;
fhir:expression [ fhir:v "Practitioner?_has:PractitionerRole:practitioner:role=http://terminology.hl7.org/CodeSystem/practitioner-role|doctor" ]       ]     ] ) ;
    ( fhir:activity [
      ( fhir:action [
        ( fhir:coding [
fhir:system [ fhir:v "http://hl7.org/fhir/audit-event-action"^^xsd:anyURI ] ;
fhir:code [ fhir:v "R" ]         ] )       ] [
        ( fhir:coding [
fhir:system [ fhir:v "http://hl7.org/fhir/audit-event-action"^^xsd:anyURI ] ;
fhir:code [ fhir:v "E" ]         ] )       ] ) ;
      ( fhir:purpose [
        ( fhir:coding [
fhir:system [ fhir:v "http://terminology.hl7.org/CodeSystem/v3-ActReason"^^xsd:anyURI ] ;
fhir:code [ fhir:v "PATRQT" ]         ] )       ] )     ] )
  ] ) . #