R5 Final QA

This page is part of the FHIR Specification (v5.0.0-draft-final: Final QA Preview for R5 - see ballot notes). The current version which supercedes this version is 5.0.0. For a full list of available versions, see the Directory of published versions . Page versions: R5 R4B R4 R3

Example DocumentReference/example (Turtle)

Orders and Observations Work GroupMaturity Level: N/AStandards Status: InformativeCompartments: Device, Encounter, Patient, Practitioner, RelatedPerson

Raw Turtle (+ also see Turtle/RDF Format Specification)

Generic example

@prefix fhir: <http://hl7.org/fhir/> .
@prefix loinc: <https://loinc.org/rdf/> .
@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:DocumentReference ;
  fhir:nodeRole fhir:treeRoot ;
  fhir:id [ fhir:v "example"] ; # 
  fhir:text [
     fhir:status [ fhir:v "extensions" ] ;
     fhir:div "<div xmlns=\"http://www.w3.org/1999/xhtml\"><p><b>Generated Narrative: DocumentReference</b><a name=\"example\"> </a></p><div style=\"display: inline-block; background-color: #d9e0e7; padding: 6px; margin: 4px; border: 1px solid #8da1b4; border-radius: 5px; line-height: 60%\"><p style=\"margin-bottom: 0px\">Resource DocumentReference &quot;example&quot; </p></div><p><b>supporting info</b>: <a href=\"patient-example-xcda.html\">Patient/xcda</a> &quot;Henry LEVIN&quot;</p><p><b>DocumentReference Source Patient</b>: <a href=\"patient-example-xcda.html\">Patient/xcda</a> &quot;Henry LEVIN&quot;</p><p><b>identifier</b>: entryUUID: urn:oid:1.3.6.1.4.1.21367.2005.3.7.1234, uniqueId: urn:oid:1.3.6.1.4.1.21367.2005.3.7</p><p><b>status</b>: current</p><p><b>docStatus</b>: preliminary</p><p><b>type</b>: Outpatient Note <span style=\"background: LightGoldenRodYellow; margin: 4px; border: 1px solid khaki\"> (<a href=\"https://loinc.org/\">LOINC</a>#34108-1)</span></p><p><b>category</b>: History and Physical <span style=\"background: LightGoldenRodYellow; margin: 4px; border: 1px solid khaki\"> (classCodes#History and Physical)</span></p><p><b>subject</b>: <a href=\"patient-example-xcda.html\">Patient/xcda</a> &quot;Henry LEVIN&quot;</p><p><b>context</b>: <a href=\"encounter-example-xcda.html\">Encounter/xcda</a></p><h3>Events</h3><table class=\"grid\"><tr><td>-</td><td><b>Concept</b></td></tr><tr><td>*</td><td>Arm <span style=\"background: LightGoldenRodYellow; margin: 4px; border: 1px solid khaki\"> (eventCodes#T-D8200)</span></td></tr></table><p><b>facilityType</b>: Outpatient <span style=\"background: LightGoldenRodYellow; margin: 4px; border: 1px solid khaki\"> (healthcareFacilityTypeCodes#Outpatient)</span></p><p><b>practiceSetting</b>: General Medicine <span style=\"background: LightGoldenRodYellow; margin: 4px; border: 1px solid khaki\"> (practiceSettingCodes#General Medicine)</span></p><p><b>period</b>: 2004-12-23T08:00:00+11:00 --&gt; 2004-12-23T08:01:00+11:00</p><p><b>date</b>: 24 Dec 2005, 9:43:41 am</p><p><b>author</b>: </p><ul><li><a href=\"practitioner-example-xcda1.html\">Practitioner/xcda1</a> &quot;Sherry DOPPLEMEYER&quot;</li><li><a name=\"a2\"> </a></li></ul><blockquote><p/><p><a name=\"a2\"> </a></p><p><b>name</b>: Gerald Smitty </p></blockquote><h3>Attesters</h3><table class=\"grid\"><tr><td>-</td><td><b>Mode</b></td><td><b>Party</b></td></tr><tr><td>*</td><td>Official <span style=\"background: LightGoldenRodYellow; margin: 4px; border: 1px solid khaki\"> (<a href=\"codesystem-composition-attestation-mode.html\">Composition Attestation Mode</a>#official)</span></td><td><a href=\"organization-example-f001-burgers.html\">Organization/f001</a> &quot;Burgers University Medical Center&quot;</td></tr></table><p><b>custodian</b>: <a href=\"organization-example-f001-burgers.html\">Organization/f001</a> &quot;Burgers University Medical Center&quot;</p><h3>RelatesTos</h3><table class=\"grid\"><tr><td>-</td><td><b>Code</b></td><td><b>Target</b></td></tr><tr><td>*</td><td>Appends <span style=\"background: LightGoldenRodYellow; margin: 4px; border: 1px solid khaki\"> (<a href=\"codesystem-document-relationship-type.html\">Document Relationship Type</a>#appends)</span></td><td><a href=\"documentreference-example.html\">DocumentReference/example</a></td></tr></table><p><b>description</b>: Physical</p><p><b>securityLabel</b>: very restricted <span style=\"background: LightGoldenRodYellow; margin: 4px; border: 1px solid khaki\"> (<a href=\"http://terminology.hl7.org/4.0.0/CodeSystem-v3-Confidentiality.html\">Confidentiality</a>#V)</span></p><blockquote><p><b>content</b></p><h3>Attachments</h3><table class=\"grid\"><tr><td>-</td><td><b>ContentType</b></td><td><b>Language</b></td><td><b>Url</b></td><td><b>Size</b></td><td><b>Hash</b></td><td><b>Title</b></td><td><b>Creation</b></td></tr><tr><td>*</td><td>application/hl7-v3+xml</td><td>en-US</td><td><a href=\"http://example.org/xds/mhd/Binary/07a6483f-732b-461e-86b6-edb665c45510\">http://example.org/xds/mhd/Binary/07a6483f-732b-461e-86b6-edb665c45510</a></td><td>3654</td><td>2jmj7l5rSw0yVb/vlWAYkK/YBwk=</td><td>Physical</td><td>2005-12-24T09:35:00+11:00</td></tr></table><h3>Profiles</h3><table class=\"grid\"><tr><td>-</td><td><b>Value[x]</b></td></tr><tr><td>*</td><td>History and Physical Specification (Details: urn:oid:1.3.6.1.4.1.19376.1.2.3 code urn:ihe:pcc:handp:2008 = 'urn:ihe:pcc:handp:2008', stated as 'History and Physical Specification')</td></tr></table></blockquote></div>"
  ] ; #    Many XDS systems do not trak any id for the author. When systems don't do this, 
#    the only option is for the author information to be contained in the Document Reference   
  fhir:contained ( [
     a fhir:Practitioner ;
     fhir:id [ fhir:v "a2" ] ;
     fhir:name ( [
       fhir:family [ fhir:v "Smitty" ] ;
       fhir:given ( [ fhir:v "Gerald" ] )
     ] )
  ] ) ; # 
  fhir:extension ( [
     fhir:url [ fhir:v "http://hl7.org/fhir/StructureDefinition/workflow-supportingInfo"^^xsd:anyURI ] ;
     fhir:value [
       a fhir:Reference ;
       fhir:reference [ fhir:v "Patient/xcda" ] ;
       fhir:identifier [
         fhir:system [ fhir:v "urn:ietf:rfc:3986"^^xsd:anyURI ] ;
         fhir:value [ fhir:v "urn:oid:1.3.6.1.4.1.21367.2005.3.7.2345" ]
       ]
     ]
  ] [
     fhir:url [ fhir:v "http://hl7.org/fhir/StructureDefinition/documentreference-sourcepatient"^^xsd:anyURI ] ;
     fhir:value [
       a fhir:Reference ;
       fhir:reference [ fhir:v "Patient/xcda" ]
     ]
  ] ) ; # 
  fhir:identifier ( [
     fhir:type [
       fhir:text [ fhir:v "entryUUID" ]
     ] ;
     fhir:system [ fhir:v "urn:ietf:rfc:3986"^^xsd:anyURI ] ;
     fhir:value [ fhir:v "urn:oid:1.3.6.1.4.1.21367.2005.3.7.1234" ]
  ] [
     fhir:type [
       fhir:text [ fhir:v "uniqueId" ]
     ] ;
     fhir:system [ fhir:v "urn:ietf:rfc:3986"^^xsd:anyURI ] ;
     fhir:value [ fhir:v "urn:oid:1.3.6.1.4.1.21367.2005.3.7" ]
  ] ) ; # 
  fhir:status [ fhir:v "current"] ; # 
  fhir:docStatus [ fhir:v "preliminary"] ; # 
  fhir:type [
     fhir:coding ( [
       a loinc:34108-1 ;
       fhir:system [ fhir:v "http://loinc.org"^^xsd:anyURI ] ;
       fhir:code [ fhir:v "34108-1" ] ;
       fhir:display [ fhir:v "Outpatient Note" ]
     ] )
  ] ; # 
  fhir:category ( [
     fhir:coding ( [
       fhir:system [ fhir:v "http://ihe.net/xds/connectathon/classCodes"^^xsd:anyURI ] ;
       fhir:code [ fhir:v "History and Physical" ] ;
       fhir:display [ fhir:v "History and Physical" ]
     ] )
  ] ) ; # 
  fhir:subject [
     fhir:reference [ fhir:v "Patient/xcda" ]
  ] ; # 
  fhir:context ( [
     fhir:reference [ fhir:v "Encounter/xcda" ]
  ] ) ; # 
  fhir:event ( [
     fhir:concept [
       fhir:coding ( [
         fhir:system [ fhir:v "http://ihe.net/xds/connectathon/eventCodes"^^xsd:anyURI ] ;
         fhir:code [ fhir:v "T-D8200" ] ;
         fhir:display [ fhir:v "Arm" ]
       ] )
     ]
  ] ) ; # 
  fhir:facilityType [
     fhir:coding ( [
       fhir:system [ fhir:v "http://www.ihe.net/xds/connectathon/healthcareFacilityTypeCodes"^^xsd:anyURI ] ;
       fhir:code [ fhir:v "Outpatient" ] ;
       fhir:display [ fhir:v "Outpatient" ]
     ] )
  ] ; # 
  fhir:practiceSetting [
     fhir:coding ( [
       fhir:system [ fhir:v "http://www.ihe.net/xds/connectathon/practiceSettingCodes"^^xsd:anyURI ] ;
       fhir:code [ fhir:v "General Medicine" ] ;
       fhir:display [ fhir:v "General Medicine" ]
     ] )
  ] ; # 
  fhir:period [
     fhir:start [ fhir:v "2004-12-23T08:00:00+11:00"^^xsd:dateTime ] ;
     fhir:end [ fhir:v "2004-12-23T08:01:00+11:00"^^xsd:dateTime ]
  ] ; # 
  fhir:date [ fhir:v "2005-12-24T09:43:41+11:00"^^xsd:dateTime] ; # 
  fhir:author ( [
     fhir:reference [ fhir:v "Practitioner/xcda1" ]
  ] [
     fhir:reference [ fhir:v "#a2" ]
  ] ) ; # 
  fhir:attester ( [
     fhir:mode [
       fhir:coding ( [
         fhir:system [ fhir:v "http://hl7.org/fhir/composition-attestation-mode"^^xsd:anyURI ] ;
         fhir:code [ fhir:v "official" ]
       ] )
     ] ;
     fhir:party [
       fhir:reference [ fhir:v "Organization/f001" ]
     ]
  ] ) ; # 
  fhir:custodian [
     fhir:reference [ fhir:v "Organization/f001" ]
  ] ; # 
  fhir:relatesTo ( [
     fhir:code [
       fhir:coding ( [
         fhir:system [ fhir:v "http://hl7.org/fhir/document-relationship-type"^^xsd:anyURI ] ;
         fhir:code [ fhir:v "appends" ]
       ] )
     ] ;
     fhir:target [
       fhir:reference [ fhir:v "DocumentReference/example" ]
     ]
  ] ) ; # 
  fhir:description [ fhir:v "Physical"] ; # 
  fhir:securityLabel ( [
     fhir:coding ( [
       fhir:system [ fhir:v "http://terminology.hl7.org/CodeSystem/v3-Confidentiality"^^xsd:anyURI ] ;
       fhir:code [ fhir:v "V" ] ;
       fhir:display [ fhir:v "very restricted" ]
     ] )
  ] ) ; # 
  fhir:content ( [
     fhir:attachment [
       fhir:contentType [ fhir:v "application/hl7-v3+xml" ] ;
       fhir:language [ fhir:v "en-US" ] ;
       fhir:url [ fhir:v "http://example.org/xds/mhd/Binary/07a6483f-732b-461e-86b6-edb665c45510"^^xsd:anyURI ] ;
       fhir:size [ fhir:v "3654"^^xsd:long ] ;
       fhir:hash [ fhir:v "2jmj7l5rSw0yVb/vlWAYkK/YBwk="^^xsd:base64Binary ] ;
       fhir:title [ fhir:v "Physical" ] ;
       fhir:creation [ fhir:v "2005-12-24T09:35:00+11:00"^^xsd:dateTime ]
     ] ;
     fhir:profile ( [
       fhir:value [
         a fhir:Coding ;
         fhir:system [ fhir:v "urn:oid:1.3.6.1.4.1.19376.1.2.3"^^xsd:anyURI ] ;
         fhir:code [ fhir:v "urn:ihe:pcc:handp:2008" ] ;
         fhir:display [ fhir:v "History and Physical Specification" ]
       ]
     ] )
  ] )] . # 

# -------------------------------------------------------------------------------------


Usage note: every effort has been made to ensure that the examples are correct and useful, but they are not a normative part of the specification.