@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 -------------------------------------------------------------------

<http://hl7.org/fhir/smart-app-launch/Bundle/example2> a fhir:Bundle ;
  fhir:nodeRole fhir:treeRoot ;
  fhir:Resource.id [ fhir:value "example2"] ;
  fhir:Resource.language [ fhir:value "en"] ;
  fhir:Bundle.type [ fhir:value "collection"] ;
  fhir:Bundle.timestamp [ fhir:value "2023-09-05T20:18:52.638960-07:00"^^xsd:dateTime] ;
  fhir:Bundle.entry [
     fhir:index -1 ;
     fhir:Bundle.entry.fullUrl [ fhir:value "https://ehr.example.com/Organization/examplehealth" ] ;
     fhir:Bundle.entry.resource <https://ehr.example.com/Organization/examplehealth>
  ], [
     fhir:index -1 ;
     fhir:Bundle.entry.fullUrl [ fhir:value "https://ehr.example.com/Organization/ehchospital" ] ;
     fhir:Bundle.entry.resource <https://ehr.example.com/Organization/ehchospital>
  ], [
     fhir:index -1 ;
     fhir:Bundle.entry.fullUrl [ fhir:value "https://ehr.example.com/Organization/ehpmadison" ] ;
     fhir:Bundle.entry.resource <https://ehr.example.com/Organization/ehpmadison>
  ], [
     fhir:index -1 ;
     fhir:Bundle.entry.fullUrl [ fhir:value "https://ehr.example.com/Endpoint/examplehealth-r2" ] ;
     fhir:Bundle.entry.resource <https://ehr.example.com/Endpoint/examplehealth-r2>
  ], [
     fhir:index -1 ;
     fhir:Bundle.entry.fullUrl [ fhir:value "https://ehr.example.com/Endpoint/examplehealth-r4" ] ;
     fhir:Bundle.entry.resource <https://ehr.example.com/Endpoint/examplehealth-r4>
  ] .

<https://ehr.example.com/Organization/examplehealth> a fhir:Organization ;
  fhir:Resource.id [ fhir:value "examplehealth"] ;
  fhir:Resource.language [ fhir:value "en"] ;
  fhir:DomainResource.extension [
     fhir:index -1 ;
     fhir:Element.extension [
       fhir:index -1 ;
       fhir:Extension.url [ fhir:value "brandLogo" ] ;
       fhir:Extension.valueUrl [ fhir:value "https://example.org/examplehealth/logo/main.1024x1024.png" ]
     ] ;
     fhir:Extension.url [ fhir:value "http://hl7.org/fhir/StructureDefinition/organization-brand" ]
  ], [
     fhir:index -1 ;
     fhir:Element.extension [
       fhir:index -1 ;
       fhir:Extension.url [ fhir:value "portalName" ] ;
       fhir:Extension.valueString [ fhir:value "My ExampleHealth Portal" ]
     ], [
       fhir:index -1 ;
       fhir:Extension.url [ fhir:value "portalLogo" ] ;
       fhir:Extension.valueUrl [ fhir:value "https://example.org/examplehealth/logo/main.1024x1024.png" ]
     ], [
       fhir:index -1 ;
       fhir:Extension.url [ fhir:value "portalUrl" ] ;
       fhir:Extension.valueUrl [ fhir:value "https://example.org/examplehealth/patient-portal-url" ]
     ], [
       fhir:index -1 ;
       fhir:Extension.url [ fhir:value "portalEndpoint" ] ;
       fhir:Extension.valueReference [
         fhir:link <http://hl7.org/fhir/smart-app-launch/Endpoint/examplehealth-r4> ;
         fhir:Reference.reference [ fhir:value "Endpoint/examplehealth-r4" ] ;
         fhir:Reference.display [ fhir:value "FHIR R4 Endpoint for ExampleHealth Brand" ]
       ]
     ], [
       fhir:index -1 ;
       fhir:Extension.url [ fhir:value "portalEndpoint" ] ;
       fhir:Extension.valueReference [
         fhir:link <http://hl7.org/fhir/smart-app-launch/Endpoint/examplehealth-r2> ;
         fhir:Reference.reference [ fhir:value "Endpoint/examplehealth-r2" ] ;
         fhir:Reference.display [ fhir:value "FHIR R2 Endpoint for ExampleHealth Brand" ]
       ]
     ] ;
     fhir:Extension.url [ fhir:value "http://hl7.org/fhir/StructureDefinition/organization-portal" ]
  ] ;
  fhir:Organization.identifier [
     fhir:index -1 ;
     fhir:Identifier.system [ fhir:value "urn:ietf:rfc:3986" ] ;
     fhir:Identifier.value [ fhir:value "https://examplehealth.org" ]
  ] ;
  fhir:Organization.active [ fhir:value "true"^^xsd:boolean] ;
  fhir:Organization.type [
     fhir:index -1 ;
     fhir:CodeableConcept.coding [
       fhir:index -1 ;
       fhir:Coding.system [ fhir:value "http://terminology.hl7.org/CodeSystem/organization-type" ] ;
       fhir:Coding.code [ fhir:value "prov" ] ;
       fhir:Coding.display [ fhir:value "Healthcare Provider" ]
     ]
  ] ;
  fhir:Organization.name [ fhir:value "ExampleHealth"] ;
  fhir:Organization.alias [
     fhir:value "GoodHealth Hospital" ;
     fhir:index -1
  ], [
     fhir:value "GoodHealth Mental Health" ;
     fhir:index -1
  ] ;
  fhir:Organization.telecom [
     fhir:index -1 ;
     fhir:ContactPoint.system [ fhir:value "url" ] ;
     fhir:ContactPoint.value [ fhir:value "https://health.example.com" ]
  ] ;
  fhir:Organization.address [
     fhir:index -1 ;
     fhir:Address.city [ fhir:value "Madison" ] ;
     fhir:Address.state [ fhir:value "WI" ] ;
     fhir:Address.country [ fhir:value "US" ]
  ], [
     fhir:index -1 ;
     fhir:Address.city [ fhir:value "Anamosa" ] ;
     fhir:Address.state [ fhir:value "IA" ] ;
     fhir:Address.country [ fhir:value "US" ]
  ], [
     fhir:index -1 ;
     fhir:Address.city [ fhir:value "Cedar Rapids" ] ;
     fhir:Address.state [ fhir:value "IA" ] ;
     fhir:Address.country [ fhir:value "US" ]
  ], [
     fhir:index -1 ;
     fhir:Address.city [ fhir:value "Des Moines" ] ;
     fhir:Address.state [ fhir:value "IA" ] ;
     fhir:Address.country [ fhir:value "US" ]
  ], [
     fhir:index -1 ;
     fhir:Address.city [ fhir:value "Dubuque" ] ;
     fhir:Address.state [ fhir:value "IA" ] ;
     fhir:Address.country [ fhir:value "US" ]
  ], [
     fhir:index -1 ;
     fhir:Address.city [ fhir:value "Fort Dodge" ] ;
     fhir:Address.state [ fhir:value "IA" ] ;
     fhir:Address.country [ fhir:value "US" ]
  ], [
     fhir:index -1 ;
     fhir:Address.city [ fhir:value "Grinnell" ] ;
     fhir:Address.state [ fhir:value "IA" ] ;
     fhir:Address.country [ fhir:value "US" ]
  ], [
     fhir:index -1 ;
     fhir:Address.city [ fhir:value "Marshalltown" ] ;
     fhir:Address.state [ fhir:value "IA" ] ;
     fhir:Address.country [ fhir:value "US" ]
  ], [
     fhir:index -1 ;
     fhir:Address.city [ fhir:value "Peoria" ] ;
     fhir:Address.state [ fhir:value "IA" ] ;
     fhir:Address.country [ fhir:value "US" ]
  ], [
     fhir:index -1 ;
     fhir:Address.city [ fhir:value "Pekin" ] ;
     fhir:Address.state [ fhir:value "IA" ] ;
     fhir:Address.country [ fhir:value "US" ]
  ], [
     fhir:index -1 ;
     fhir:Address.city [ fhir:value "Muscatine" ] ;
     fhir:Address.state [ fhir:value "IA" ] ;
     fhir:Address.country [ fhir:value "US" ]
  ], [
     fhir:index -1 ;
     fhir:Address.city [ fhir:value "Sioux City" ] ;
     fhir:Address.state [ fhir:value "IA" ] ;
     fhir:Address.country [ fhir:value "US" ]
  ] ;
  fhir:Organization.endpoint [
     fhir:index -1 ;
     fhir:link <http://hl7.org/fhir/smart-app-launch/Endpoint/examplehealth-r2> ;
     fhir:Reference.reference [ fhir:value "Endpoint/examplehealth-r2" ] ;
     fhir:Reference.display [ fhir:value "FHIR R2 Endpoint for ExampleHealth Brand" ]
  ], [
     fhir:index -1 ;
     fhir:link <http://hl7.org/fhir/smart-app-launch/Endpoint/examplehealth-r4> ;
     fhir:Reference.reference [ fhir:value "Endpoint/examplehealth-r4" ] ;
     fhir:Reference.display [ fhir:value "FHIR R4 Endpoint for ExampleHealth Brand" ]
  ] .

<http://hl7.org/fhir/smart-app-launch/Endpoint/examplehealth-r4> a fhir:smart-app-launch .

<http://hl7.org/fhir/smart-app-launch/Endpoint/examplehealth-r2> a fhir:smart-app-launch .

<https://ehr.example.com/Organization/ehchospital> a fhir:Organization ;
  fhir:Resource.id [ fhir:value "ehchospital"] ;
  fhir:Resource.language [ fhir:value "en"] ;
  fhir:DomainResource.extension [
     fhir:index -1 ;
     fhir:Element.extension [
       fhir:index -1 ;
       fhir:Extension.url [ fhir:value "brandLogo" ] ;
       fhir:Extension.valueUrl [ fhir:value "data:image/svg+xml;base64,PHN2ZyB0aXRsZT0iU3Rld2FydCBNZW1vcmlhbCBIb3Nw...+IDwvc3ZnPgo=" ]
     ] ;
     fhir:Extension.url [ fhir:value "http://hl7.org/fhir/StructureDefinition/organization-brand" ]
  ] ;
  fhir:Organization.identifier [
     fhir:index -1 ;
     fhir:Identifier.system [ fhir:value "urn:ietf:rfc:3986" ] ;
     fhir:Identifier.value [ fhir:value "https://ehchospital.example.org" ]
  ] ;
  fhir:Organization.active [ fhir:value "true"^^xsd:boolean] ;
  fhir:Organization.type [
     fhir:index -1 ;
     fhir:CodeableConcept.coding [
       fhir:index -1 ;
       fhir:Coding.system [ fhir:value "http://terminology.hl7.org/CodeSystem/organization-type" ] ;
       fhir:Coding.code [ fhir:value "prov" ] ;
       fhir:Coding.display [ fhir:value "Healthcare Provider" ]
     ]
  ] ;
  fhir:Organization.name [ fhir:value "ExampleHealth Community Hospital"] ;
  fhir:Organization.alias [
     fhir:value "GoodHealth Madison" ;
     fhir:index -1
  ] ;
  fhir:Organization.telecom [
     fhir:index -1 ;
     fhir:ContactPoint.system [ fhir:value "url" ] ;
     fhir:ContactPoint.value [ fhir:value "https://www.ehchospital.example.com" ]
  ] ;
  fhir:Organization.address [
     fhir:index -1 ;
     fhir:Address.city [ fhir:value "Lake City" ] ;
     fhir:Address.state [ fhir:value "IA" ] ;
     fhir:Address.country [ fhir:value "US" ]
  ] ;
  fhir:Organization.partOf [
     fhir:link <http://hl7.org/fhir/smart-app-launch/Organization/examplehealth> ;
     fhir:Reference.reference [ fhir:value "Organization/examplehealth" ]
  ] .

<http://hl7.org/fhir/smart-app-launch/Organization/examplehealth> a fhir:smart-app-launch .

<https://ehr.example.com/Organization/ehpmadison> a fhir:Organization ;
  fhir:Resource.id [ fhir:value "ehpmadison"] ;
  fhir:Resource.language [ fhir:value "en"] ;
  fhir:DomainResource.extension [
     fhir:index -1 ;
     fhir:Element.extension [
       fhir:index -1 ;
       fhir:Extension.url [ fhir:value "brandLogo" ] ;
       fhir:Extension.valueUrl [ fhir:value "https://ehpmadison.example.com/logo.png" ]
     ] ;
     fhir:Extension.url [ fhir:value "http://hl7.org/fhir/StructureDefinition/organization-brand" ]
  ] ;
  fhir:Organization.identifier [
     fhir:index -1 ;
     fhir:Identifier.system [ fhir:value "urn:ietf:rfc:3986" ] ;
     fhir:Identifier.value [ fhir:value "https://ehpmadison.example.com" ]
  ] ;
  fhir:Organization.active [ fhir:value "true"^^xsd:boolean] ;
  fhir:Organization.type [
     fhir:index -1 ;
     fhir:CodeableConcept.coding [
       fhir:index -1 ;
       fhir:Coding.system [ fhir:value "http://terminology.hl7.org/CodeSystem/organization-type" ] ;
       fhir:Coding.code [ fhir:value "prov" ] ;
       fhir:Coding.display [ fhir:value "Healthcare Provider" ]
     ]
  ] ;
  fhir:Organization.name [ fhir:value "ExampleHealth Physicians of Madison"] ;
  fhir:Organization.alias [
     fhir:value "GoodHealth Madison" ;
     fhir:index -1
  ] ;
  fhir:Organization.telecom [
     fhir:index -1 ;
     fhir:ContactPoint.system [ fhir:value "url" ] ;
     fhir:ContactPoint.value [ fhir:value "https://www.ehpmadison.example.com" ]
  ] ;
  fhir:Organization.address [
     fhir:index -1 ;
     fhir:Address.city [ fhir:value "Madison" ] ;
     fhir:Address.state [ fhir:value "WI" ] ;
     fhir:Address.country [ fhir:value "US" ]
  ] ;
  fhir:Organization.partOf [
     fhir:link <http://hl7.org/fhir/smart-app-launch/Organization/examplehealth> ;
     fhir:Reference.reference [ fhir:value "Organization/examplehealth" ]
  ] .

<https://ehr.example.com/Endpoint/examplehealth-r2> a fhir:Endpoint ;
  fhir:Resource.id [ fhir:value "examplehealth-r2"] ;
  fhir:Resource.language [ fhir:value "en"] ;
  fhir:DomainResource.extension [
     fhir:index -1 ;
     fhir:Extension.url [ fhir:value "http://hl7.org/fhir/StructureDefinition/endpoint-fhir-version" ] ;
     fhir:Extension.valueCode [ fhir:value "1.0.2" ]
  ] ;
  fhir:Endpoint.status [ fhir:value "active"] ;
  fhir:Endpoint.connectionType [
     fhir:Coding.system [ fhir:value "http://terminology.hl7.org/CodeSystem/endpoint-connection-type" ] ;
     fhir:Coding.code [ fhir:value "hl7-fhir-rest" ]
  ] ;
  fhir:Endpoint.name [ fhir:value "FHIR DSTU2 Endpoint for ExampleHealth"] ;
  fhir:Endpoint.contact [
     fhir:index -1 ;
     fhir:ContactPoint.system [ fhir:value "url" ] ;
     fhir:ContactPoint.value [ fhir:value "https://open.ehr.example.com" ]
  ] ;
  fhir:Endpoint.payloadType [
     fhir:index -1 ;
     fhir:CodeableConcept.coding [
       fhir:index -1 ;
       fhir:Coding.system [ fhir:value "http://terminology.hl7.org/CodeSystem/endpoint-payload-type" ] ;
       fhir:Coding.code [ fhir:value "none" ]
     ]
  ] ;
  fhir:Endpoint.address [ fhir:value "https://ehr.example.com/ProdFHIR/api/FHIR/R2"] .

<https://ehr.example.com/Endpoint/examplehealth-r4> a fhir:Endpoint ;
  fhir:Resource.id [ fhir:value "examplehealth-r4"] ;
  fhir:Resource.language [ fhir:value "en"] ;
  fhir:DomainResource.extension [
     fhir:index -1 ;
     fhir:Extension.url [ fhir:value "http://hl7.org/fhir/StructureDefinition/endpoint-fhir-version" ] ;
     fhir:Extension.valueCode [ fhir:value "4.0.1" ]
  ] ;
  fhir:Endpoint.status [ fhir:value "active"] ;
  fhir:Endpoint.connectionType [
     fhir:Coding.system [ fhir:value "http://terminology.hl7.org/CodeSystem/endpoint-connection-type" ] ;
     fhir:Coding.code [ fhir:value "hl7-fhir-rest" ]
  ] ;
  fhir:Endpoint.name [ fhir:value "FHIR R4 Endpoint for ExampleHealth"] ;
  fhir:Endpoint.contact [
     fhir:index -1 ;
     fhir:ContactPoint.system [ fhir:value "url" ] ;
     fhir:ContactPoint.value [ fhir:value "https://open.ehr.example.com" ]
  ] ;
  fhir:Endpoint.payloadType [
     fhir:index -1 ;
     fhir:CodeableConcept.coding [
       fhir:index -1 ;
       fhir:Coding.system [ fhir:value "http://terminology.hl7.org/CodeSystem/endpoint-payload-type" ] ;
       fhir:Coding.code [ fhir:value "none" ]
     ]
  ] ;
  fhir:Endpoint.address [ fhir:value "https://ehr.example.com/ProdFHIR/api/FHIR/R4"] .

# - ontology header ------------------------------------------------------------

<http://hl7.org/fhir/smart-app-launch/Bundle/example2.ttl> a owl:Ontology ;
  owl:imports fhir:fhir.ttl ;
  owl:versionIRI <http://build.fhir.org/smart-app-launch/Bundle/example2.ttl> .

# -------------------------------------------------------------------------------------

