This page is part of the FHIR Specification (v0.0.82: DSTU 1). 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 R2

6.4 Resource DocumentReference - Content

A reference to a document.

6.4.1 Scope and Usage

A document reference resource is used to describe a document that is made available to a healthcare system. A document is some sequence of bytes that is identifiable, establishes its own context (e.g. what subject, author etc), can be displayed to the user, and has defined update management. The document resource can be used with any document format that has a recognized mime type, and that conforms to this definition.

Typically, Document Reference Resources are used in document indexing systems, such as IHE XDS (see the XDS specific profile), and are used to refer to:

6.4.2 Boundaries and Relationships

FHIR defines both a document format and this document reference. FHIR documents are for documents that are authored and assembled in FHIR. This resource is mainly intended for general references to other documents.

The document that is a target of the reference can be a reference to a FHIR document served by another server, or the target can be stored in the special FHIR Binary Resource, or the target can be stored on some other server system. The document reference is also able to address documents that are retrieved by a service call such as an XDS.b RetrieveDocumentSet, or a DICOM exchange, or a v2 message query, though the way each of these service calls works must be specified in some external stanard or other documentation.

6.4.3 Resource Content

DocumentReference (Resource)Document identifier as assigned by the source of the document. This identifier is specific to this version of the document. This unique identifier may be used elsewhere to identify this version of the documentmasterIdentifier : Identifier 1..1Other identifiers associated with the document, including version independent, source record and workflow related identifiersidentifier : Identifier 0..*Who or what the document is about. The document can be about a person, (patient or healthcare practitioner), a device (I.e. machine) or even a group of subjects (such as a document about a herd of farm animals, or a set of patients that share a common exposure)subject : Resource(Patient|Practitioner|Group| Device) 1..1Specifies the particular kind of document (e.g. Patient Summary, Discharge Summary, Prescription, etc.)type : CodeableConcept 1..1 <<Type of a compositionDocumentType>>A categorization for the type of the document. This may be implied by or derived from the code specified in the Document Typeclass : CodeableConcept 0..1 <<SubType of a clinical documentDocumentClass>>Identifies who is responsible for adding the information to the documentauthor : Resource(Practitioner|Device|Patient| RelatedPerson) 1..*Identifies the organization or group who is responsible for ongoing maintenance of and access to the documentcustodian : Resource(Organization) 0..1A reference to a domain or server that manages policies under which the document is accessed and/or made availablepolicyManager : uri 0..1Which person or organization authenticates that this document is validauthenticator : Resource(Practitioner|Organization) 0..1When the document was createdcreated : dateTime 0..1When the document reference was createdindexed : instant 1..1The status of this document reference (this element modifies the meaning of other elements)status : code 1..1 <<The status of the document referenceDocumentReferenceStatus>>The status of the underlying documentdocStatus : CodeableConcept 0..1 <<Status of the underlying documentReferredDocumentStatus>>Human-readable description of the source document. This is sometimes known as the "title"description : string 0..1A code specifying the level of confidentiality of the XDS Document (this element modifies the meaning of other elements)confidentiality : CodeableConcept 0..* <<Codes specifying the level of confidentiality of the compositionDocumentConfidentiality>>The primary language in which the source document is writtenprimaryLanguage : code 0..1 <<A human languageLanguage>>The mime type of the source documentmimeType : code 1..1 <<The mime type of an attachmentMimeType>>An identifier that identifies that the format and content of the document conforms to additional rules beyond the base format indicated in the mimeTypeformat : uri 0..*The size of the source document this reference refers to in bytessize : integer 0..1A hash of the source document to ensure that changes have not occurredhash : string 0..1A url at which the document can be accessedlocation : uri 0..1RelatesToThe type of relationship that this document has with anther documentcode : code 1..1 <<The type of relationship between documentsDocumentRelationshipType>>The target document of this relationshiptarget : Resource(DocumentReference) 1..1ServiceThe type of the service that can be used to access the documentstype : CodeableConcept 1..1 <<Document Reference Service TypeDocumentServiceType>>Where the service end-point is locatedaddress : string 0..1ParameterThe name of a parametername : string 1..1The value of the named parametervalue : string 0..1ContextThis list of codes represents the main clinical acts, such as a colonoscopy or an appendectomy, being documented. In some cases, the event is inherent in the typeCode, such as a "History and Physical Report" in which the procedure being documented is necessarily a "History and Physical" actevent : CodeableConcept 0..* <<This list of codes represents the main clinical acts being documentedDocumentEventType>>The time period over which the service that is described by the document was providedperiod : Period 0..1The kind of facility where the patient was seenfacilityType : CodeableConcept 0..1 <<XDS Facility TypeDocumentFacilityType>>Relationships that this document has with other document references that already exist (this element modifies the meaning of other elements)relatesTo0..*A list of named parameters that is used in the service callparameter0..*A description of a service call that can be used to retrieve the documentservice0..1The clinical context in which the document was preparedcontext0..1

This resource is referenced by [DocumentManifest]

<DocumentReference xmlns="http://hl7.org/fhir"> doco
 <!-- from Resource: extension, modifierExtension, language, text, and contained -->
 <masterIdentifier><!-- 1..1 Identifier Master Version Specific Identifier --></masterIdentifier>
 <identifier><!-- 0..* Identifier Other identifiers for the document --></identifier>
 <subject><!-- 1..1 Resource(Patient|Practitioner|Group|Device) 
     Who|what is the subject of the document --></subject>
 <type><!-- 1..1 CodeableConcept What kind of document this is (LOINC if possible) --></type>
 <class><!-- 0..1 CodeableConcept Categorization of Document --></class>
 <author><!-- 1..* Resource(Practitioner|Device|Patient|RelatedPerson) 
     Who and/or what authored the document --></author>
 <custodian><!-- 0..1 Resource(Organization) Org which maintains the document --></custodian>
 <policyManager value="[uri]"/><!-- 0..1 Manages access policies for the document -->
 <authenticator><!-- 0..1 Resource(Practitioner|Organization) 
     Who/What authenticated the document --></authenticator>
 <created value="[dateTime]"/><!-- 0..1 Document creation time -->
 <indexed value="[instant]"/><!-- 1..1 When this document reference created -->
 <status value="[code]"/><!-- 1..1 current | superceded | entered in error -->
 <docStatus><!-- 0..1 CodeableConcept preliminary | final | appended | amended | entered in error --></docStatus>
 <relatesTo>  <!-- 0..* Relationships to other documents -->
  <code value="[code]"/><!-- 1..1 replaces | transforms | signs | appends -->
  <target><!-- 1..1 Resource(DocumentReference) Target of the relationship --></target>
 </relatesTo>
 <description value="[string]"/><!-- 0..1 Human-readable description (title) -->
 <confidentiality><!-- 0..* CodeableConcept Sensitivity of source document --></confidentiality>
 <primaryLanguage value="[code]"/><!-- 0..1 The marked primary language for the document -->
 <mimeType value="[code]"/><!-- 1..1 Mime type, + maybe character encoding -->
 <format value="[uri]"/><!-- 0..* Format/content rules for the document -->
 <size value="[integer]"/><!-- 0..1 Size of the document in bytes -->
 <hash value="[string]"/><!-- 0..1 HexBinary representation of SHA1 -->
 <location value="[uri]"/><!-- ?? 0..1 Where to access the document -->
 <service>  <!-- ?? 0..1 If access is not fully described by location -->
  <type><!-- 1..1 CodeableConcept Type of service (i.e. XDS.b) --></type>
  <address value="[string]"/><!-- 0..1 Where service is located (usually a URL) -->
  <parameter>  <!-- 0..* Service call parameters -->
   <name value="[string]"/><!-- 1..1 Parameter name in service call -->
   <value value="[string]"/><!-- 0..1 Parameter value for the name -->
  </parameter>
 </service>
 <context>  <!-- 0..1 Clinical context of document -->
  <event><!-- 0..* CodeableConcept Main Clinical Acts Documented --></event>
  <period><!-- 0..1 Period Time of service that is being documented --></period>
  <facilityType><!-- 0..1 CodeableConcept Kind of facility where patient was seen --></facilityType>
 </context>
</DocumentReference>

Alternate definitions: Schema/Schematron, Resource Profile

6.4.3.1 Terminology Bindings

PathDefinitionTypeReference
DocumentReference.type Type of a compositionIncompletehttp://hl7.org/fhir/vs/doc-codes
DocumentReference.class SubType of a clinical documentExamplehttp://hl7.org/fhir/vs/xds-typecodes
DocumentReference.status The status of the document referenceFixedhttp://hl7.org/fhir/document-reference-status
DocumentReference.docStatus Status of the underlying documentIncompletehttp://hl7.org/fhir/vs/composition-status
DocumentReference.relatesTo.code The type of relationship between documentsFixedhttp://hl7.org/fhir/document-relationship-type
DocumentReference.confidentiality Codes specifying the level of confidentiality of the compositionIncompletehttp://hl7.org/fhir/v3/vs/Confidentiality
DocumentReference.primaryLanguage A human languageIncompleteIETF language tag
DocumentReference.mimeType The mime type of an attachmentIncompleteBCP 13 (RFCs 2045, 2046, 2047, 4288, 4289 and 2049)
DocumentReference.service.type Document Reference Service TypeIncompletehttp://hl7.org/fhir/vs/documentreference-service-types
DocumentReference.context.event This list of codes represents the main clinical acts being documentedIncompletehttp://hl7.org/fhir/v3/vs/ActCode
DocumentReference.context.facilityType XDS Facility TypeExamplehttp://hl7.org/fhir/vs/xds-facilitycodes

6.4.3.2 Constraints

6.4.4 Implementation Notes

6.4.4.1 Document Formats

In addition to a mime type (which is mandatory), there is also a format element which carries a URI. This element has one or more identifiers that indicate that the format and/or content of the document conforms to additional rules beyond the base format indicated in the mimeType. This is most often used when the mime-type is text/xml, to provide additional information for finding the correct document.

Defined URIs:

Other URIs can be used for items not on this list.

6.4.4.2 Generating a Document Reference

A client can ask a server to generate a document reference from a document. The server reads the existing document and generates a matching DocumentReference resource, or returns one it has previously generated. Servers may be able to return or generate document references for the following types of content:

Type Comments
FHIR Documents The uri refers to an existing Document
CDA Document The uri is a reference to a Binary end-point that returns either a CDA document, or some kind of CDA Package that the server knows how to process (e.g. an IHE .zip)
Other The server can be asked to generate a document reference for other kinds of documents. For some of these documents (e.g. PDF documents) a server could only provide a DocumentReference it is already existed, or the server had special knowledge of the document

The server either returns a search result containing a single DocumentReference, or it returns an error. If some the URI refers to another server, it is at the discretion of the server whether to retrieve it or return an error.

The operation is initiated by a named query, using _query=generate on the /DocumentReference end point:

  GET [service-url]/DocumentReference/?_query=generate&uri=:url&...

The "uri" parameter is a relative or absolute reference to one of the document types described above. Other parameters may be supplied:

Name Meaning
persist Whether to store the document at the document end-point (/Document) or not once it is generated. Value = true or false (default is for the server to decide)

6.4.5 Search Parameters

Search parameters for this resource. The standard parameters also apply. See Searching for more information about searching in REST, messaging, and services.

NameTypeDescriptionPaths
_idtokenThe logical resource id associated with the resource (must be supported by all servers)
_languagetokenThe language of the resource
authenticatorreferenceWho/What authenticated the documentDocumentReference.authenticator
(Organization, Practitioner)
authorreferenceWho and/or what authored the documentDocumentReference.author
(Device, Patient, Practitioner, RelatedPerson)
classtokenCategorization of DocumentDocumentReference.class
confidentialitytokenSensitivity of source documentDocumentReference.confidentiality
createddateDocument creation timeDocumentReference.created
custodianreferenceOrg which maintains the documentDocumentReference.custodian
(Organization)
descriptionstringHuman-readable description (title)DocumentReference.description
eventtokenMain Clinical Acts DocumentedDocumentReference.context.event
facilitytokenKind of facility where patient was seenDocumentReference.context.facilityType
formattokenFormat/content rules for the documentDocumentReference.format
identifiertokenMaster Version Specific IdentifierDocumentReference.masterIdentifier, DocumentReference.identifier
indexeddateWhen this document reference createdDocumentReference.indexed
languagetokenThe marked primary language for the documentDocumentReference.primaryLanguage
locationstringWhere to access the documentDocumentReference.location
perioddateTime of service that is being documentedDocumentReference.context.period
relatestoreferenceTarget of the relationshipDocumentReference.relatesTo.target
(DocumentReference)
relationtokenreplaces | transforms | signs | appendsDocumentReference.relatesTo.code
relationshipcompositeCombination of relation and relatesTo
sizenumberSize of the document in bytesDocumentReference.size
statustokencurrent | superceded | entered in errorDocumentReference.status
subjectreferenceWho|what is the subject of the documentDocumentReference.subject
(Device, Patient, Practitioner, Group)
typetokenWhat kind of document this is (LOINC if possible)DocumentReference.type

comments powered by Disqus