Interweave Implementation Guide
0.1.0 - ci-build United Kingdom flag

Interweave Implementation Guide - Local Development build (v0.1.0) built by the FHIR (HL7® FHIR® Standard) Build Tools. See the STU3 profiles here.

Resource Profile: InterweaveDocumentReference

Official URL: https://fhir.interweavedigital.nhs.uk/R4/StructureDefinition/Interweave-DocumentReference Version: 0.0.1
Draft as of 2024-07-15 Computable Name: InterweaveDocumentReference

Interweave DocumentReference resource profile - DRAFT.

  Status: DRAFT: For Review

Introduction

This profile sets minimum expectations for the DocumentReference resource. We use the DocumentReference structure definition as a base to this profile.

Mandatory fields

The following mandatory fields are defined in order to properly describe a DocumentReference:

  1. Status - already mandatory in FHIR, and will generally contain "current". (A practical challenge for many systems can be to accurately maintain this, eg updating to "superseded" when necessary)
  2. DocStatus - will generally contain “final”, as most documents will only be published for regional sharing once they are finalised. However there may be exceptions where it is useful to collaborate on preliminary versions of a document. (It is anticipated that additional guidance on the use of this field for collaborating on specific types of document may be added in future.)
  3. Type - essential information to help categorise the type of document.

    The categorisation of document types is a much debated topic, with a number of alternative standards still vying for precedence. However for practical purposes of consistency a regional design decision has been made based on the SNOMED refset 24501000000105: EHR composition types. This is therefore specified as "preferred" and we ask that SNOMED coding based on this list is provided.

    • It is, of course, permissible to provide more than one code to also support other coding schemes if desired
    • We accept that this is an area where we will need to remain open to consultation as National standards continue to evolve.
  4. date - already mandatory in FHIR and essential for date-based searching and sorting
  5. subject - every document must be linked to a Patient
  6. content - usually a link to retrieve the actual document content (see further guidance below).
  7. content.attachment.contentType It is mandatory to populate the Content Type, so that consumers can be aware and process accordingly.

Data Providers and Data Consumers SHOULD support the following contentTypes:

  • application/pdf
  • text/html
  • image/jpeg
  • image/png (currently not supported in Interweave Portal, however it is on the roadmap)

(This list may be added to by request and discussion)

Other contentTypes should only be used with caution, as not all Data Consumers may be able to view them.

Must Support fields

In addition the following fields are "Must Support" - ie they must be populated if relevant and known:

  1. Identifier - a Local document id should be provided (non-version-specific), such that could be quoted if manually getting in touch to find out more
  2. Author - This is very useful as it provides a person to speak to if more information about the document is needed. Preferably we want exactly one author - the main practitioner involved who should be contacted. (The profile is, however, left open to allow for other more collaborative models of document creation in future).
  3. content.creation - date when this specific version of the document was created.
  4. Context - Encounter - If relevant and possible then it is very useful to link documents back to the Encounter they relate to
  5. Context - Period - A document may related to a period of time (eg a care plan for the coming 6 months). Where this is the case then this field must be populated

Optional fields

Other fields are optional and may be populated if known - on the understanding that not all data consumers will necessarily make use of them. Points of note include:

  • Master Identifier - FHIR also makes provision for both a "master identifier" (version specific). Generally this will link with a Data Provider's in-house document management system, and is therefore an internal implementation detail and of limited relevance for external sharing. If provided then Data Consumers should exercise caution in relying upon it.
  • Category - This provides a higher-level categorisation over-and-above the document "type"
  • Authenticator - More likely to be relevant for internal records management rather than external sharing, but may be populated if desired
  • Description - May be used if there is additional “title” or summary “description” information about the document which is useful to provide. It is not necessary to populate with a repeat of the document “type” - instead feel free to omit if there is nothing additional to add.
  • Additional Context Fields - These include the Event, Facility Type, and Practice Setting. There is also the sourcePatientInfo which may be useful to populate with a version-specific pointer to the patient record at the time the document was created.

Discouraged or Removed fields

  • Custodian - this information is instead provided by the provenance tags
  • Relates To - This is a potentially useful field that may be used to record relationships between documents. However it is not used as-yet, and there is unlikely to be any behaviour in consumer systems to honour it. Please get in touch for further discussion if planning to use it.
  • Content - Related - This provides the opportunity to link to other types of resources – in addition to Encounters. It is anticipated that additional guidance on the use of this field may be added in future, based on specific document types and use-cases. Please get in touch if planning to use this field meanwhile.
  • Security Label - This field is not used and will not be honoured. All data published to the Interweave Exchange will be shared with other participants. (It is possible that additional security mechanisms may be added in future, however this would be subject to further consultation at the time).

Approaches to document content

The DocumentReference this offers three different ways to transmit the document content and it is important to understand the details of this. The sections below cover each option in turn.

  • (1) Embedded document (only supported for messaging NOT online query)

    This is the “simplest” approach, as the document content is embedded directly into the DocumentReference. Note that the contentType (mime-type) is provided so that the consumer is able to judge whether it has the ability to display this format of document eg PDF, etc. (This is the same for all three approaches).

    For example the “content” section of a DocumentReference would look like:

"content": [{​​​​​
       "attachment": {​​​​​
           "contentType": "text/html",
       "data":"PGRpdiB4123ucz0iaHR0cDovL123dy53My5vcmcvMTk5OS94aHRtbCI ... etc..."
       }​​​​​​​​​​​​
   }​​​​​​​​​​​​]

This embedded approach is often suitable for messaging, where a relevant document is being specifically sent (eg Ambulance Transfer of Care). However for online query it has the significant disadvantage of making the DocumentReference resources very large - as the whole document is transferred even when just viewing the list of documents available. Typically there may be many documents about a patient, but only one or two which are relevant for the user to actually view. It is very inefficient (and slow) to transfer the entirety of the documents when a user is only perusing the list.

(NB: Despite this limitation, GP Connect is an important use-case which returns embedded document content. However GP Connect documents are not returned from ordinary online queries and instead must be specifically requested from a screen developed to meet NHSD accreditation requirements. The reason for embedding is that, having requested a patient’s GP Record, it is almost always going to be desired to view the document content).

  • (2) Linked document (recommended)

    This replaces the content in the DocumentReference with a link. For example:

"content": [{​​​​​​​​​​​​
       "attachment": {​​​​​​​​​​​​
           "contentType": "text/html",
           "url": "https://my.server.com/documents/21f51e78-a46d-402c-aa22-dd43e0fec530"
       }​​​​​​​​​​​​
   }​​​​​​​​​​​​]

This is clearly much more efficient. This list of DocumentReferences contains only metadata about the documents, and if the user wants to open the document then it is a case of following the link to download it. This performs a simple binary download of the document bytes – as would be provided by hosting the document on any standard web server.

Note that InterWeave Connect offers a proxy service to avoid the need for point-to-point networking for document downloads. Instead the urls in the DocumentReference are automatically rewritten to point at a central hub which in turn connects to the Data Provider and streams document downloads.

  • (3) FHIR Binary Resource (only recommended if implemented comprehensively)

    Yet another possible approach is to replace the content in the DocumentReference with a link to a FHIR Binary Resource http://hl7.org/fhir/stu3/binary.html. This is similar in principle to the Linked document approach, but adds an extra layer of wrappings and complexity to the Data Provider's implementation. For that reason it is not recommended unless a Data Provider is working with a local system which already exposes documents in this way. Note: that the contentType of the document reference must be the mime type of the document encoded by the binary resource (see GET behaviour below)

    The “content” section of a DocumentReference with a linked Binary Resource would now look like this:

     "content": [{​​​​​​​​​​​​
       "attachment": {​​​​​​​​​​​​
           "contentType": "text/html",
           "url": "https://my.server.com/fhirpath/Binary/21f51e78-a46d-402c-aa22-dd43e0fec530"
       }​​​​​​​​​​​​
     }​​​​​​​​​​​​]

When the link is followed then it again returns the binary content – as would be provided by hosting the document on any standard web server.

(This is because of a feature of the FHIR specification that treats Binary resources differently from any other resource. When a FHIR server receives a GET request for a Binary resource then it MUST return the binary document content rather than the Binary resource. However the FHIR specification also requires that this behaviour can be overridden by a consumer by inserting the HTTP Accept header with value “application/fhir+json” (or even “application/fhir+xml”). This then returns a more complete FHIR data structure with the document content embedded – although for document viewing purposes it is difficult to envisage why a consumer would desire this)

Summary of Requirements for DocumentReference content

  • Data Providers SHOULD use the “linked document” mechanism when publishing documents for on-demand retrieval

    • This is (2) above, which is recommended as a simple and efficient approach.

    • Data Providers MUST NOT embed documents for on-demand retrieval, as this is inefficient

    • Data Providers MAY publish documents as FHIR Binary Resources. This is equivalent from a Data Consumer perspective as it provides a link to follow to download the document. However it is not recommended due to the additional complexity for a Data Provider. If this option is chosen then the Data Provider MUST fully support the FHIR specification.

  • Data Consumers MUST support viewing of documents via a DocumentReference resource which contains a link for downloading the actual document content

    • This covers both of (2) and (3) above as, in practice, both contain a link to download the document content
  • Data Consumers MAY leave the HTTP “Accept” header blank, and SHOULD NOT populate it with anything other than the mime-type advertised by the Data Provider in the DocumentReference

    • There is no expectation of Data Providers being able to offer translation capabilities between mime-types

Usage:

Formal Views of Profile Content

Description of Profiles, Differentials, Snapshots and how the different presentations work.

This structure is derived from DocumentReference

NameFlagsCard.TypeDescription & Constraintsdoco
.. DocumentReference 0..* DocumentReference A reference to a document
... id S 0..1 id Logical id of this artifact
... meta
.... id 0..0
.... versionId S 0..1 id Version specific identifier
.... lastUpdated S 0..1 instant MANDATORY except in Contained Resources. When the resource version last changed.
.... profile S 0..* canonical(StructureDefinition) Profiles this resource claims to conform to. Should list (i) this profile (ii) base profile for this resource.
.... security 0..* Coding DISCOURAGED - may not be honoured by Data Consumers
.... Slices for tag 0..* Coding Tags applied to this resource
Slice: Unordered, Open by value:system
..... tag:Source S 0..1 Coding MANDATORY except in Contained Resources. The Data Provider Id (and display text) of the system supplying the data
...... id 0..0
...... system 1..1 uri Identity of the terminology system
Fixed Value: https://fhir.interweavedigital.nhs.uk/Source
...... version 0..0
...... code S 1..1 code The Data Provider Id of the system supplying the data
...... display S 1..1 string Name of the system supplying the data
..... tag:Provenance S 0..1 Coding MANDATORY except in Contained Resources. The ODS Code (and display text) of the organisation responsible for the data
...... id 0..0
...... system 1..1 uri Identity of the terminology system
Fixed Value: https://fhir.interweavedigital.nhs.uk/Provenance
...... version 0..0
...... code S 1..1 code The ODS Code of the organisation responsible for the data
...... display S 1..1 string Name of the organisation supplying the data
... implicitRules 0..1 uri DISCOURAGED - may not be honoured by Data Consumers
... text 0..1 Narrative DISCOURAGED - the preferred approach is to offer structured data fields which a Data Consumer can then render and present in a manner most suited to its users
... masterIdentifier
.... assigner 0..1 Reference(InterweaveOrganization) Organization that issued id (may be just text)
... Slices for identifier 0..* Identifier Other identifiers for the document
Slice: Unordered, Open by value:system
.... identifier:All Slices Content/Rules for all slices
..... assigner 0..1 Reference(InterweaveOrganization) Organization that issued id (may be just text)
.... identifier:localIdentifier S 0..1 Identifier Other identifiers for the document
..... system S 1..1 uri The namespace for the identifier value
Fixed Value: https://fhir.interweavedigital.nhs.uk/Id/local-documentreference-identifier
..... value S 1..1 string The Local documentreference Identifier. Please prefix with ODS code plus period (XXX.) to ensure unique
..... period 0..0
... status S 1..1 code current | superseded | entered-in-error
... docStatus S 1..1 code preliminary | final | amended | entered-in-error
... type S 1..1 CodeableConcept Type of document
Binding: InterweaveDocumentType (preferred)
.... coding
..... system 1..1 uri Identity of the terminology system
..... code 1..1 code Symbol in syntax defined by the system
..... display 1..1 string Representation defined by the system
... category 0..* CodeableConcept Categorization of document
Binding: DocumentClassValueSet (preferred)
.... coding
..... system 1..1 uri Identity of the terminology system
..... code 1..1 code Symbol in syntax defined by the system
..... display 1..1 string Representation defined by the system
... subject S 1..1 Reference(InterweavePatient) Who is the subject of the document
.... reference 1..1 string Reference to a resource (could be Contained)
.... identifier 0..1 Identifier If relevant could include an id
.... display 1..1 string Description of the referenced resource
... date S 1..1 instant When this document reference was created
... author S 0..* Reference(Practitioner | PractitionerRole | Organization | Device | Patient | RelatedPerson) Who and/or what authored the document. NB: For most use-cases this should contain a single practitioner who is the main contact for any further questions
.... reference 1..1 string Reference to a resource (could be Contained)
.... identifier 0..1 Identifier If relevant could include an id
.... display 1..1 string Description of the referenced resource
... custodian 0..1 Reference(Organization) DISCOURAGED - this information is already covered by the provenance tags
... relatesTo 0..* BackboneElement DISCOURAGED - use with great caution as consumer systems are likely to display a simple list of documents, and may not interpret these relationships
... description 0..1 string Human-readable description (title). Useful to populate, but acceptable to omit if nothing to add over-and-above the 'type'
... securityLabel 0..* CodeableConcept DISCOURAGED - unlikely to be honoured by consumers
... content S 1..* BackboneElement Document referenced
.... attachment S 1..1 Attachment Where to access the document
..... contentType S 1..1 code Mime type of the content, with charset etc.
..... creation S 0..1 dateTime Date attachment was first created
... context
.... encounter S 0..* Reference(InterweaveEncounter) Context of the document content
..... reference 1..1 string Reference to a resource (could be Contained)
..... identifier 0..1 Identifier If relevant could include an id
..... display 0..1 string If relevant, description of the referenced resource
.... period S 0..1 Period Time of service that is being documented
.... practiceSetting 0..1 CodeableConcept Additional details about where the content was created (e.g. clinical specialty)
Binding: UK Core Care Setting Type (preferred)
.... sourcePatientInfo 0..0
.... related 0..* Reference(Resource) DISCOURAGED - see above for linkage to Encounter. Other linkages may be defined in future only if use-cases arise

doco Documentation for this format

Terminology Bindings (Differential)

PathConformanceValueSetURI
DocumentReference.typepreferredInterweaveDocumentType
https://fhir.interweavedigital.nhs.uk/R4/ValueSet/Interweave-DocumentType
from this IG
DocumentReference.categorypreferredDocumentClassValueSet
http://hl7.org/fhir/ValueSet/document-classcodes
from the FHIR Standard
DocumentReference.context.practiceSettingpreferredUKCoreCareSettingType
https://fhir.hl7.org.uk/ValueSet/UKCore-CareSettingType
from this IG
NameFlagsCard.TypeDescription & Constraintsdoco
.. DocumentReference 0..* DocumentReference A reference to a document
... id SΣ 0..1 id Logical id of this artifact
... meta Σ 0..1 Meta Metadata about the resource
.... versionId SΣ 0..1 id Version specific identifier
.... lastUpdated SΣ 0..1 instant MANDATORY except in Contained Resources. When the resource version last changed.
.... profile SΣ 0..* canonical(StructureDefinition) Profiles this resource claims to conform to. Should list (i) this profile (ii) base profile for this resource.
.... security Σ 0..* Coding DISCOURAGED - may not be honoured by Data Consumers
Binding: All Security Labels (extensible): Security Labels from the Healthcare Privacy and Security Classification System.


.... Slices for tag Σ 0..* Coding Tags applied to this resource
Slice: Unordered, Open by value:system
Binding: CommonTags (example): Codes that represent various types of tags, commonly workflow-related; e.g. "Needs review by Dr. Jones".


..... tag:Source SΣ 0..1 Coding MANDATORY except in Contained Resources. The Data Provider Id (and display text) of the system supplying the data
Binding: CommonTags (example): Codes that represent various types of tags, commonly workflow-related; e.g. "Needs review by Dr. Jones".


...... system Σ 1..1 uri Identity of the terminology system
Fixed Value: https://fhir.interweavedigital.nhs.uk/Source
...... code SΣ 1..1 code The Data Provider Id of the system supplying the data
...... display SΣ 1..1 string Name of the system supplying the data
..... tag:Provenance SΣ 0..1 Coding MANDATORY except in Contained Resources. The ODS Code (and display text) of the organisation responsible for the data
Binding: CommonTags (example): Codes that represent various types of tags, commonly workflow-related; e.g. "Needs review by Dr. Jones".


...... system Σ 1..1 uri Identity of the terminology system
Fixed Value: https://fhir.interweavedigital.nhs.uk/Provenance
...... code SΣ 1..1 code The ODS Code of the organisation responsible for the data
...... display SΣ 1..1 string Name of the organisation supplying the data
... implicitRules ?!Σ 0..1 uri DISCOURAGED - may not be honoured by Data Consumers
... text 0..1 Narrative DISCOURAGED - the preferred approach is to offer structured data fields which a Data Consumer can then render and present in a manner most suited to its users
... modifierExtension ?! 0..* Extension Extensions that cannot be ignored
... Slices for identifier Σ 0..* Identifier Other identifiers for the document
Slice: Unordered, Open by value:system
.... identifier:All Slices Content/Rules for all slices
..... use ?!Σ 0..1 code usual | official | temp | secondary | old (If known)
Binding: IdentifierUse (required): Identifies the purpose for this identifier, if known .

..... assigner Σ 0..1 Reference(InterweaveOrganization) Organization that issued id (may be just text)
.... identifier:localIdentifier SΣ 0..1 Identifier Other identifiers for the document
..... use ?!Σ 0..1 code usual | official | temp | secondary | old (If known)
Binding: IdentifierUse (required): Identifies the purpose for this identifier, if known .

..... system SΣ 1..1 uri The namespace for the identifier value
Fixed Value: https://fhir.interweavedigital.nhs.uk/Id/local-documentreference-identifier
..... value SΣ 1..1 string The Local documentreference Identifier. Please prefix with ODS code plus period (XXX.) to ensure unique
Example General: 123456
... status ?!SΣ 1..1 code current | superseded | entered-in-error
Binding: DocumentReferenceStatus (required): The status of the document reference.

... docStatus SΣ 1..1 code preliminary | final | amended | entered-in-error
Binding: CompositionStatus (required): Status of the underlying document.

... type SΣ 1..1 CodeableConcept Type of document
Binding: InterweaveDocumentType (preferred)
... category Σ 0..* CodeableConcept Categorization of document
Binding: DocumentClassValueSet (preferred)
... subject SΣ 1..1 Reference(InterweavePatient) Who is the subject of the document
.... reference ΣC 1..1 string Reference to a resource (could be Contained)
.... identifier Σ 0..1 Identifier If relevant could include an id
.... display Σ 1..1 string Description of the referenced resource
... date SΣ 1..1 instant When this document reference was created
... author SΣ 0..* Reference(Practitioner | PractitionerRole | Organization | Device | Patient | RelatedPerson) Who and/or what authored the document. NB: For most use-cases this should contain a single practitioner who is the main contact for any further questions
.... reference ΣC 1..1 string Reference to a resource (could be Contained)
.... identifier Σ 0..1 Identifier If relevant could include an id
.... display Σ 1..1 string Description of the referenced resource
... custodian 0..1 Reference(Organization) DISCOURAGED - this information is already covered by the provenance tags
... relatesTo Σ 0..* BackboneElement DISCOURAGED - use with great caution as consumer systems are likely to display a simple list of documents, and may not interpret these relationships
.... modifierExtension ?!Σ 0..* Extension Extensions that cannot be ignored even if unrecognized
.... code Σ 1..1 code replaces | transforms | signs | appends
Binding: DocumentRelationshipType (required): The type of relationship between documents.

.... target Σ 1..1 Reference(DocumentReference) Target of the relationship
... description Σ 0..1 string Human-readable description (title). Useful to populate, but acceptable to omit if nothing to add over-and-above the 'type'
... securityLabel Σ 0..* CodeableConcept DISCOURAGED - unlikely to be honoured by consumers
Binding: All Security Labels (extensible): Security Labels from the Healthcare Privacy and Security Classification System.


... content SΣ 1..* BackboneElement Document referenced
.... modifierExtension ?!Σ 0..* Extension Extensions that cannot be ignored even if unrecognized
.... attachment SΣ 1..1 Attachment Where to access the document
..... contentType SΣ 1..1 code Mime type of the content, with charset etc.
Binding: Mime Types (required): The mime type of an attachment. Any valid mime type is allowed.


Example General: text/plain; charset=UTF-8, image/png
..... creation SΣ 0..1 dateTime Date attachment was first created
... context Σ 0..1 BackboneElement Clinical context of document
.... modifierExtension ?!Σ 0..* Extension Extensions that cannot be ignored even if unrecognized
.... encounter S 0..* Reference(InterweaveEncounter) Context of the document content
..... reference ΣC 1..1 string Reference to a resource (could be Contained)
..... identifier Σ 0..1 Identifier If relevant could include an id
..... display Σ 0..1 string If relevant, description of the referenced resource
.... period SΣ 0..1 Period Time of service that is being documented
.... practiceSetting 0..1 CodeableConcept Additional details about where the content was created (e.g. clinical specialty)
Binding: UK Core Care Setting Type (preferred)
.... related 0..* Reference(Resource) DISCOURAGED - see above for linkage to Encounter. Other linkages may be defined in future only if use-cases arise

doco Documentation for this format

Terminology Bindings

PathConformanceValueSetURI
DocumentReference.meta.securityextensibleAll Security Labels
http://hl7.org/fhir/ValueSet/security-labels
from the FHIR Standard
DocumentReference.meta.tagexampleCommonTags
http://hl7.org/fhir/ValueSet/common-tags
from the FHIR Standard
DocumentReference.meta.tag:SourceexampleCommonTags
http://hl7.org/fhir/ValueSet/common-tags
from the FHIR Standard
DocumentReference.meta.tag:ProvenanceexampleCommonTags
http://hl7.org/fhir/ValueSet/common-tags
from the FHIR Standard
DocumentReference.languagepreferredCommonLanguages
Additional Bindings Purpose
AllLanguages Max Binding
http://hl7.org/fhir/ValueSet/languages
from the FHIR Standard
DocumentReference.identifier.userequiredIdentifierUse
http://hl7.org/fhir/ValueSet/identifier-use|4.0.1
from the FHIR Standard
DocumentReference.identifier:localIdentifier.userequiredIdentifierUse
http://hl7.org/fhir/ValueSet/identifier-use|4.0.1
from the FHIR Standard
DocumentReference.statusrequiredDocumentReferenceStatus
http://hl7.org/fhir/ValueSet/document-reference-status|4.0.1
from the FHIR Standard
DocumentReference.docStatusrequiredCompositionStatus
http://hl7.org/fhir/ValueSet/composition-status|4.0.1
from the FHIR Standard
DocumentReference.typepreferredInterweaveDocumentType
https://fhir.interweavedigital.nhs.uk/R4/ValueSet/Interweave-DocumentType
from this IG
DocumentReference.categorypreferredDocumentClassValueSet
http://hl7.org/fhir/ValueSet/document-classcodes
from the FHIR Standard
DocumentReference.relatesTo.coderequiredDocumentRelationshipType
http://hl7.org/fhir/ValueSet/document-relationship-type|4.0.1
from the FHIR Standard
DocumentReference.securityLabelextensibleAll Security Labels
http://hl7.org/fhir/ValueSet/security-labels
from the FHIR Standard
DocumentReference.content.attachment.contentTyperequiredMime Types (a valid code from urn:ietf:bcp:13)
http://hl7.org/fhir/ValueSet/mimetypes|4.0.1
from the FHIR Standard
DocumentReference.context.practiceSettingpreferredUKCoreCareSettingType
https://fhir.hl7.org.uk/ValueSet/UKCore-CareSettingType
from this IG

Constraints

IdGradePath(s)DetailsRequirements
dom-2errorDocumentReferenceIf the resource is contained in another resource, it SHALL NOT contain nested Resources
: contained.contained.empty()
dom-3errorDocumentReferenceIf the resource is contained in another resource, it SHALL be referred to from elsewhere in the resource or SHALL refer to the containing resource
: contained.where((('#'+id in (%resource.descendants().reference | %resource.descendants().as(canonical) | %resource.descendants().as(uri) | %resource.descendants().as(url))) or descendants().where(reference = '#').exists() or descendants().where(as(canonical) = '#').exists() or descendants().where(as(canonical) = '#').exists()).not()).trace('unmatched', id).empty()
dom-4errorDocumentReferenceIf a resource is contained in another resource, it SHALL NOT have a meta.versionId or a meta.lastUpdated
: contained.meta.versionId.empty() and contained.meta.lastUpdated.empty()
dom-5errorDocumentReferenceIf a resource is contained in another resource, it SHALL NOT have a security label
: contained.meta.security.empty()
dom-6best practiceDocumentReferenceA resource should have narrative for robust management
: text.`div`.exists()
ele-1error**ALL** elementsAll FHIR elements must have a @value or children
: hasValue() or (children().count() > id.count())
ext-1error**ALL** extensionsMust have either extensions or value[x], not both
: extension.exists() != value.exists()
NameFlagsCard.TypeDescription & Constraintsdoco
.. DocumentReference 0..* DocumentReference A reference to a document
... id SΣ 0..1 id Logical id of this artifact
... meta Σ 0..1 Meta Metadata about the resource
.... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
.... versionId SΣ 0..1 id Version specific identifier
.... lastUpdated SΣ 0..1 instant MANDATORY except in Contained Resources. When the resource version last changed.
.... source Σ 0..1 uri Identifies where the resource comes from
.... profile SΣ 0..* canonical(StructureDefinition) Profiles this resource claims to conform to. Should list (i) this profile (ii) base profile for this resource.
.... security Σ 0..* Coding DISCOURAGED - may not be honoured by Data Consumers
Binding: All Security Labels (extensible): Security Labels from the Healthcare Privacy and Security Classification System.


.... Slices for tag Σ 0..* Coding Tags applied to this resource
Slice: Unordered, Open by value:system
Binding: CommonTags (example): Codes that represent various types of tags, commonly workflow-related; e.g. "Needs review by Dr. Jones".


..... tag:Source SΣ 0..1 Coding MANDATORY except in Contained Resources. The Data Provider Id (and display text) of the system supplying the data
Binding: CommonTags (example): Codes that represent various types of tags, commonly workflow-related; e.g. "Needs review by Dr. Jones".


...... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
...... system Σ 1..1 uri Identity of the terminology system
Fixed Value: https://fhir.interweavedigital.nhs.uk/Source
...... code SΣ 1..1 code The Data Provider Id of the system supplying the data
...... display SΣ 1..1 string Name of the system supplying the data
...... userSelected Σ 0..1 boolean If this coding was chosen directly by the user
..... tag:Provenance SΣ 0..1 Coding MANDATORY except in Contained Resources. The ODS Code (and display text) of the organisation responsible for the data
Binding: CommonTags (example): Codes that represent various types of tags, commonly workflow-related; e.g. "Needs review by Dr. Jones".


...... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
...... system Σ 1..1 uri Identity of the terminology system
Fixed Value: https://fhir.interweavedigital.nhs.uk/Provenance
...... code SΣ 1..1 code The ODS Code of the organisation responsible for the data
...... display SΣ 1..1 string Name of the organisation supplying the data
...... userSelected Σ 0..1 boolean If this coding was chosen directly by the user
... implicitRules ?!Σ 0..1 uri DISCOURAGED - may not be honoured by Data Consumers
... text 0..1 Narrative DISCOURAGED - the preferred approach is to offer structured data fields which a Data Consumer can then render and present in a manner most suited to its users
... contained 0..* Resource Contained, inline Resources
... extension 0..* Extension Additional content defined by implementations
... modifierExtension ?! 0..* Extension Extensions that cannot be ignored
... masterIdentifier Σ 0..1 Identifier Master Version Specific Identifier
.... id 0..1 string Unique id for inter-element referencing
.... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
.... use ?!Σ 0..1 code usual | official | temp | secondary | old (If known)
Binding: IdentifierUse (required): Identifies the purpose for this identifier, if known .

.... type Σ 0..1 CodeableConcept Description of identifier
Binding: Identifier Type Codes (extensible): A coded type for an identifier that can be used to determine which identifier to use for a specific purpose.

.... system Σ 0..1 uri The namespace for the identifier value
Example General: http://www.acme.com/identifiers/patient
.... value Σ 0..1 string The value that is unique
Example General: 123456
.... period Σ 0..1 Period Time period when id is/was valid for use
.... assigner Σ 0..1 Reference(InterweaveOrganization) Organization that issued id (may be just text)
... Slices for identifier Σ 0..* Identifier Other identifiers for the document
Slice: Unordered, Open by value:system
.... identifier:All Slices Content/Rules for all slices
..... id 0..1 string Unique id for inter-element referencing
..... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
..... use ?!Σ 0..1 code usual | official | temp | secondary | old (If known)
Binding: IdentifierUse (required): Identifies the purpose for this identifier, if known .

..... type Σ 0..1 CodeableConcept Description of identifier
Binding: Identifier Type Codes (extensible): A coded type for an identifier that can be used to determine which identifier to use for a specific purpose.

..... system Σ 0..1 uri The namespace for the identifier value
Example General: http://www.acme.com/identifiers/patient
..... value Σ 0..1 string The value that is unique
Example General: 123456
..... period Σ 0..1 Period Time period when id is/was valid for use
..... assigner Σ 0..1 Reference(InterweaveOrganization) Organization that issued id (may be just text)
.... identifier:localIdentifier SΣ 0..1 Identifier Other identifiers for the document
..... id 0..1 string Unique id for inter-element referencing
..... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
..... use ?!Σ 0..1 code usual | official | temp | secondary | old (If known)
Binding: IdentifierUse (required): Identifies the purpose for this identifier, if known .

..... type Σ 0..1 CodeableConcept Description of identifier
Binding: Identifier Type Codes (extensible): A coded type for an identifier that can be used to determine which identifier to use for a specific purpose.

..... system SΣ 1..1 uri The namespace for the identifier value
Fixed Value: https://fhir.interweavedigital.nhs.uk/Id/local-documentreference-identifier
..... value SΣ 1..1 string The Local documentreference Identifier. Please prefix with ODS code plus period (XXX.) to ensure unique
Example General: 123456
..... assigner Σ 0..1 Reference(Organization) Organization that issued id (may be just text)
... status ?!SΣ 1..1 code current | superseded | entered-in-error
Binding: DocumentReferenceStatus (required): The status of the document reference.

... docStatus SΣ 1..1 code preliminary | final | amended | entered-in-error
Binding: CompositionStatus (required): Status of the underlying document.

... type SΣ 1..1 CodeableConcept Type of document
Binding: InterweaveDocumentType (preferred)
.... id 0..1 string Unique id for inter-element referencing
.... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
.... coding Σ 0..* Coding Code defined by a terminology system
..... id 0..1 string Unique id for inter-element referencing
..... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
..... system Σ 1..1 uri Identity of the terminology system
..... version Σ 0..1 string Version of the system - if relevant
..... code Σ 1..1 code Symbol in syntax defined by the system
..... display Σ 1..1 string Representation defined by the system
..... userSelected Σ 0..1 boolean If this coding was chosen directly by the user
.... text Σ 0..1 string Plain text representation of the concept
... category Σ 0..* CodeableConcept Categorization of document
Binding: DocumentClassValueSet (preferred)
.... id 0..1 string Unique id for inter-element referencing
.... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
.... coding Σ 0..* Coding Code defined by a terminology system
..... id 0..1 string Unique id for inter-element referencing
..... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
..... system Σ 1..1 uri Identity of the terminology system
..... version Σ 0..1 string Version of the system - if relevant
..... code Σ 1..1 code Symbol in syntax defined by the system
..... display Σ 1..1 string Representation defined by the system
..... userSelected Σ 0..1 boolean If this coding was chosen directly by the user
.... text Σ 0..1 string Plain text representation of the concept
... subject SΣ 1..1 Reference(InterweavePatient) Who is the subject of the document
.... id 0..1 string Unique id for inter-element referencing
.... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
.... reference ΣC 1..1 string Reference to a resource (could be Contained)
.... type Σ 0..1 uri Type the reference refers to (e.g. "Patient")
Binding: ResourceType (extensible): Aa resource (or, for logical models, the URI of the logical model).

.... identifier Σ 0..1 Identifier If relevant could include an id
.... display Σ 1..1 string Description of the referenced resource
... date SΣ 1..1 instant When this document reference was created
... author SΣ 0..* Reference(Practitioner | PractitionerRole | Organization | Device | Patient | RelatedPerson) Who and/or what authored the document. NB: For most use-cases this should contain a single practitioner who is the main contact for any further questions
.... id 0..1 string Unique id for inter-element referencing
.... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
.... reference ΣC 1..1 string Reference to a resource (could be Contained)
.... type Σ 0..1 uri Type the reference refers to (e.g. "Patient")
Binding: ResourceType (extensible): Aa resource (or, for logical models, the URI of the logical model).

.... identifier Σ 0..1 Identifier If relevant could include an id
.... display Σ 1..1 string Description of the referenced resource
... authenticator 0..1 Reference(Practitioner | PractitionerRole | Organization) Who/what authenticated the document
... custodian 0..1 Reference(Organization) DISCOURAGED - this information is already covered by the provenance tags
... relatesTo Σ 0..* BackboneElement DISCOURAGED - use with great caution as consumer systems are likely to display a simple list of documents, and may not interpret these relationships
.... id 0..1 string Unique id for inter-element referencing
.... extension 0..* Extension Additional content defined by implementations
.... modifierExtension ?!Σ 0..* Extension Extensions that cannot be ignored even if unrecognized
.... code Σ 1..1 code replaces | transforms | signs | appends
Binding: DocumentRelationshipType (required): The type of relationship between documents.

.... target Σ 1..1 Reference(DocumentReference) Target of the relationship
... description Σ 0..1 string Human-readable description (title). Useful to populate, but acceptable to omit if nothing to add over-and-above the 'type'
... securityLabel Σ 0..* CodeableConcept DISCOURAGED - unlikely to be honoured by consumers
Binding: All Security Labels (extensible): Security Labels from the Healthcare Privacy and Security Classification System.


... content SΣ 1..* BackboneElement Document referenced
.... id 0..1 string Unique id for inter-element referencing
.... extension 0..* Extension Additional content defined by implementations
.... modifierExtension ?!Σ 0..* Extension Extensions that cannot be ignored even if unrecognized
.... attachment SΣ 1..1 Attachment Where to access the document
..... id 0..1 string Unique id for inter-element referencing
..... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
..... contentType SΣ 1..1 code Mime type of the content, with charset etc.
Binding: Mime Types (required): The mime type of an attachment. Any valid mime type is allowed.


Example General: text/plain; charset=UTF-8, image/png
..... language Σ 0..1 code Human language of the content (BCP-47)
Binding: CommonLanguages (preferred): A human language.

Additional BindingsPurpose
AllLanguages Max Binding

Example General: en-AU
..... data 0..1 base64Binary Data inline, base64ed
..... url Σ 0..1 url Uri where the data can be found
Example General: http://www.acme.com/logo-small.png
..... size Σ 0..1 unsignedInt Number of bytes of content (if url provided)
..... hash Σ 0..1 base64Binary Hash of the data (sha-1, base64ed)
..... title Σ 0..1 string Label to display in place of the data
Example General: Official Corporate Logo
..... creation SΣ 0..1 dateTime Date attachment was first created
.... format Σ 0..1 Coding Format/content rules for the document
Binding: DocumentReferenceFormatCodeSet (preferred): Document Format Codes.

... context Σ 0..1 BackboneElement Clinical context of document
.... id 0..1 string Unique id for inter-element referencing
.... extension 0..* Extension Additional content defined by implementations
.... modifierExtension ?!Σ 0..* Extension Extensions that cannot be ignored even if unrecognized
.... encounter S 0..* Reference(InterweaveEncounter) Context of the document content
..... id 0..1 string Unique id for inter-element referencing
..... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
..... reference ΣC 1..1 string Reference to a resource (could be Contained)
..... type Σ 0..1 uri Type the reference refers to (e.g. "Patient")
Binding: ResourceType (extensible): Aa resource (or, for logical models, the URI of the logical model).

..... identifier Σ 0..1 Identifier If relevant could include an id
..... display Σ 0..1 string If relevant, description of the referenced resource
.... event 0..* CodeableConcept Main clinical acts documented
Binding: v3 Code System ActCode (example): This list of codes represents the main clinical acts being documented.


.... period SΣ 0..1 Period Time of service that is being documented
.... facilityType 0..1 CodeableConcept Kind of facility where patient was seen
Binding: FacilityTypeCodeValueSet (example): XDS Facility Type.

.... practiceSetting 0..1 CodeableConcept Additional details about where the content was created (e.g. clinical specialty)
Binding: UK Core Care Setting Type (preferred)
.... related 0..* Reference(Resource) DISCOURAGED - see above for linkage to Encounter. Other linkages may be defined in future only if use-cases arise

doco Documentation for this format

Terminology Bindings

PathConformanceValueSetURI
DocumentReference.meta.securityextensibleAll Security Labels
http://hl7.org/fhir/ValueSet/security-labels
from the FHIR Standard
DocumentReference.meta.tagexampleCommonTags
http://hl7.org/fhir/ValueSet/common-tags
from the FHIR Standard
DocumentReference.meta.tag:SourceexampleCommonTags
http://hl7.org/fhir/ValueSet/common-tags
from the FHIR Standard
DocumentReference.meta.tag:ProvenanceexampleCommonTags
http://hl7.org/fhir/ValueSet/common-tags
from the FHIR Standard
DocumentReference.languagepreferredCommonLanguages
Additional Bindings Purpose
AllLanguages Max Binding
http://hl7.org/fhir/ValueSet/languages
from the FHIR Standard
DocumentReference.masterIdentifier.userequiredIdentifierUse
http://hl7.org/fhir/ValueSet/identifier-use|4.0.1
from the FHIR Standard
DocumentReference.masterIdentifier.typeextensibleIdentifier Type Codes
http://hl7.org/fhir/ValueSet/identifier-type
from the FHIR Standard
DocumentReference.identifier.userequiredIdentifierUse
http://hl7.org/fhir/ValueSet/identifier-use|4.0.1
from the FHIR Standard
DocumentReference.identifier.typeextensibleIdentifier Type Codes
http://hl7.org/fhir/ValueSet/identifier-type
from the FHIR Standard
DocumentReference.identifier:localIdentifier.userequiredIdentifierUse
http://hl7.org/fhir/ValueSet/identifier-use|4.0.1
from the FHIR Standard
DocumentReference.identifier:localIdentifier.typeextensibleIdentifier Type Codes
http://hl7.org/fhir/ValueSet/identifier-type
from the FHIR Standard
DocumentReference.statusrequiredDocumentReferenceStatus
http://hl7.org/fhir/ValueSet/document-reference-status|4.0.1
from the FHIR Standard
DocumentReference.docStatusrequiredCompositionStatus
http://hl7.org/fhir/ValueSet/composition-status|4.0.1
from the FHIR Standard
DocumentReference.typepreferredInterweaveDocumentType
https://fhir.interweavedigital.nhs.uk/R4/ValueSet/Interweave-DocumentType
from this IG
DocumentReference.categorypreferredDocumentClassValueSet
http://hl7.org/fhir/ValueSet/document-classcodes
from the FHIR Standard
DocumentReference.subject.typeextensibleResourceType
http://hl7.org/fhir/ValueSet/resource-types
from the FHIR Standard
DocumentReference.author.typeextensibleResourceType
http://hl7.org/fhir/ValueSet/resource-types
from the FHIR Standard
DocumentReference.relatesTo.coderequiredDocumentRelationshipType
http://hl7.org/fhir/ValueSet/document-relationship-type|4.0.1
from the FHIR Standard
DocumentReference.securityLabelextensibleAll Security Labels
http://hl7.org/fhir/ValueSet/security-labels
from the FHIR Standard
DocumentReference.content.attachment.contentTyperequiredMime Types (a valid code from urn:ietf:bcp:13)
http://hl7.org/fhir/ValueSet/mimetypes|4.0.1
from the FHIR Standard
DocumentReference.content.attachment.languagepreferredCommonLanguages
Additional Bindings Purpose
AllLanguages Max Binding
http://hl7.org/fhir/ValueSet/languages
from the FHIR Standard
DocumentReference.content.formatpreferredDocumentReferenceFormatCodeSet (a valid code from http://ihe.net/fhir/ValueSet/IHE.FormatCode.codesystem)
http://hl7.org/fhir/ValueSet/formatcodes
from the FHIR Standard
DocumentReference.context.encounter.typeextensibleResourceType
http://hl7.org/fhir/ValueSet/resource-types
from the FHIR Standard
DocumentReference.context.eventexampleActCode
http://terminology.hl7.org/ValueSet/v3-ActCode
DocumentReference.context.facilityTypeexampleFacilityTypeCodeValueSet
http://hl7.org/fhir/ValueSet/c80-facilitycodes
from the FHIR Standard
DocumentReference.context.practiceSettingpreferredUKCoreCareSettingType
https://fhir.hl7.org.uk/ValueSet/UKCore-CareSettingType
from this IG

Constraints

IdGradePath(s)DetailsRequirements
dom-2errorDocumentReferenceIf the resource is contained in another resource, it SHALL NOT contain nested Resources
: contained.contained.empty()
dom-3errorDocumentReferenceIf the resource is contained in another resource, it SHALL be referred to from elsewhere in the resource or SHALL refer to the containing resource
: contained.where((('#'+id in (%resource.descendants().reference | %resource.descendants().as(canonical) | %resource.descendants().as(uri) | %resource.descendants().as(url))) or descendants().where(reference = '#').exists() or descendants().where(as(canonical) = '#').exists() or descendants().where(as(canonical) = '#').exists()).not()).trace('unmatched', id).empty()
dom-4errorDocumentReferenceIf a resource is contained in another resource, it SHALL NOT have a meta.versionId or a meta.lastUpdated
: contained.meta.versionId.empty() and contained.meta.lastUpdated.empty()
dom-5errorDocumentReferenceIf a resource is contained in another resource, it SHALL NOT have a security label
: contained.meta.security.empty()
dom-6best practiceDocumentReferenceA resource should have narrative for robust management
: text.`div`.exists()
ele-1error**ALL** elementsAll FHIR elements must have a @value or children
: hasValue() or (children().count() > id.count())
ext-1error**ALL** extensionsMust have either extensions or value[x], not both
: extension.exists() != value.exists()

This structure is derived from DocumentReference

Summary

Mandatory: 7 elements(17 nested mandatory elements)
Must-Support: 25 elements
Fixed: 3 elements
Prohibited: 7 elements

Structures

This structure refers to these other structures:

Slices

This structure defines the following Slices:

  • The element 1 is sliced based on the value of DocumentReference.meta.tag
  • The element 1 is sliced based on the value of DocumentReference.identifier

Differential View

This structure is derived from DocumentReference

NameFlagsCard.TypeDescription & Constraintsdoco
.. DocumentReference 0..* DocumentReference A reference to a document
... id S 0..1 id Logical id of this artifact
... meta
.... id 0..0
.... versionId S 0..1 id Version specific identifier
.... lastUpdated S 0..1 instant MANDATORY except in Contained Resources. When the resource version last changed.
.... profile S 0..* canonical(StructureDefinition) Profiles this resource claims to conform to. Should list (i) this profile (ii) base profile for this resource.
.... security 0..* Coding DISCOURAGED - may not be honoured by Data Consumers
.... Slices for tag 0..* Coding Tags applied to this resource
Slice: Unordered, Open by value:system
..... tag:Source S 0..1 Coding MANDATORY except in Contained Resources. The Data Provider Id (and display text) of the system supplying the data
...... id 0..0
...... system 1..1 uri Identity of the terminology system
Fixed Value: https://fhir.interweavedigital.nhs.uk/Source
...... version 0..0
...... code S 1..1 code The Data Provider Id of the system supplying the data
...... display S 1..1 string Name of the system supplying the data
..... tag:Provenance S 0..1 Coding MANDATORY except in Contained Resources. The ODS Code (and display text) of the organisation responsible for the data
...... id 0..0
...... system 1..1 uri Identity of the terminology system
Fixed Value: https://fhir.interweavedigital.nhs.uk/Provenance
...... version 0..0
...... code S 1..1 code The ODS Code of the organisation responsible for the data
...... display S 1..1 string Name of the organisation supplying the data
... implicitRules 0..1 uri DISCOURAGED - may not be honoured by Data Consumers
... text 0..1 Narrative DISCOURAGED - the preferred approach is to offer structured data fields which a Data Consumer can then render and present in a manner most suited to its users
... masterIdentifier
.... assigner 0..1 Reference(InterweaveOrganization) Organization that issued id (may be just text)
... Slices for identifier 0..* Identifier Other identifiers for the document
Slice: Unordered, Open by value:system
.... identifier:All Slices Content/Rules for all slices
..... assigner 0..1 Reference(InterweaveOrganization) Organization that issued id (may be just text)
.... identifier:localIdentifier S 0..1 Identifier Other identifiers for the document
..... system S 1..1 uri The namespace for the identifier value
Fixed Value: https://fhir.interweavedigital.nhs.uk/Id/local-documentreference-identifier
..... value S 1..1 string The Local documentreference Identifier. Please prefix with ODS code plus period (XXX.) to ensure unique
..... period 0..0
... status S 1..1 code current | superseded | entered-in-error
... docStatus S 1..1 code preliminary | final | amended | entered-in-error
... type S 1..1 CodeableConcept Type of document
Binding: InterweaveDocumentType (preferred)
.... coding
..... system 1..1 uri Identity of the terminology system
..... code 1..1 code Symbol in syntax defined by the system
..... display 1..1 string Representation defined by the system
... category 0..* CodeableConcept Categorization of document
Binding: DocumentClassValueSet (preferred)
.... coding
..... system 1..1 uri Identity of the terminology system
..... code 1..1 code Symbol in syntax defined by the system
..... display 1..1 string Representation defined by the system
... subject S 1..1 Reference(InterweavePatient) Who is the subject of the document
.... reference 1..1 string Reference to a resource (could be Contained)
.... identifier 0..1 Identifier If relevant could include an id
.... display 1..1 string Description of the referenced resource
... date S 1..1 instant When this document reference was created
... author S 0..* Reference(Practitioner | PractitionerRole | Organization | Device | Patient | RelatedPerson) Who and/or what authored the document. NB: For most use-cases this should contain a single practitioner who is the main contact for any further questions
.... reference 1..1 string Reference to a resource (could be Contained)
.... identifier 0..1 Identifier If relevant could include an id
.... display 1..1 string Description of the referenced resource
... custodian 0..1 Reference(Organization) DISCOURAGED - this information is already covered by the provenance tags
... relatesTo 0..* BackboneElement DISCOURAGED - use with great caution as consumer systems are likely to display a simple list of documents, and may not interpret these relationships
... description 0..1 string Human-readable description (title). Useful to populate, but acceptable to omit if nothing to add over-and-above the 'type'
... securityLabel 0..* CodeableConcept DISCOURAGED - unlikely to be honoured by consumers
... content S 1..* BackboneElement Document referenced
.... attachment S 1..1 Attachment Where to access the document
..... contentType S 1..1 code Mime type of the content, with charset etc.
..... creation S 0..1 dateTime Date attachment was first created
... context
.... encounter S 0..* Reference(InterweaveEncounter) Context of the document content
..... reference 1..1 string Reference to a resource (could be Contained)
..... identifier 0..1 Identifier If relevant could include an id
..... display 0..1 string If relevant, description of the referenced resource
.... period S 0..1 Period Time of service that is being documented
.... practiceSetting 0..1 CodeableConcept Additional details about where the content was created (e.g. clinical specialty)
Binding: UK Core Care Setting Type (preferred)
.... sourcePatientInfo 0..0
.... related 0..* Reference(Resource) DISCOURAGED - see above for linkage to Encounter. Other linkages may be defined in future only if use-cases arise

doco Documentation for this format

Terminology Bindings (Differential)

PathConformanceValueSetURI
DocumentReference.typepreferredInterweaveDocumentType
https://fhir.interweavedigital.nhs.uk/R4/ValueSet/Interweave-DocumentType
from this IG
DocumentReference.categorypreferredDocumentClassValueSet
http://hl7.org/fhir/ValueSet/document-classcodes
from the FHIR Standard
DocumentReference.context.practiceSettingpreferredUKCoreCareSettingType
https://fhir.hl7.org.uk/ValueSet/UKCore-CareSettingType
from this IG

Key Elements View

NameFlagsCard.TypeDescription & Constraintsdoco
.. DocumentReference 0..* DocumentReference A reference to a document
... id SΣ 0..1 id Logical id of this artifact
... meta Σ 0..1 Meta Metadata about the resource
.... versionId SΣ 0..1 id Version specific identifier
.... lastUpdated SΣ 0..1 instant MANDATORY except in Contained Resources. When the resource version last changed.
.... profile SΣ 0..* canonical(StructureDefinition) Profiles this resource claims to conform to. Should list (i) this profile (ii) base profile for this resource.
.... security Σ 0..* Coding DISCOURAGED - may not be honoured by Data Consumers
Binding: All Security Labels (extensible): Security Labels from the Healthcare Privacy and Security Classification System.


.... Slices for tag Σ 0..* Coding Tags applied to this resource
Slice: Unordered, Open by value:system
Binding: CommonTags (example): Codes that represent various types of tags, commonly workflow-related; e.g. "Needs review by Dr. Jones".


..... tag:Source SΣ 0..1 Coding MANDATORY except in Contained Resources. The Data Provider Id (and display text) of the system supplying the data
Binding: CommonTags (example): Codes that represent various types of tags, commonly workflow-related; e.g. "Needs review by Dr. Jones".


...... system Σ 1..1 uri Identity of the terminology system
Fixed Value: https://fhir.interweavedigital.nhs.uk/Source
...... code SΣ 1..1 code The Data Provider Id of the system supplying the data
...... display SΣ 1..1 string Name of the system supplying the data
..... tag:Provenance SΣ 0..1 Coding MANDATORY except in Contained Resources. The ODS Code (and display text) of the organisation responsible for the data
Binding: CommonTags (example): Codes that represent various types of tags, commonly workflow-related; e.g. "Needs review by Dr. Jones".


...... system Σ 1..1 uri Identity of the terminology system
Fixed Value: https://fhir.interweavedigital.nhs.uk/Provenance
...... code SΣ 1..1 code The ODS Code of the organisation responsible for the data
...... display SΣ 1..1 string Name of the organisation supplying the data
... implicitRules ?!Σ 0..1 uri DISCOURAGED - may not be honoured by Data Consumers
... text 0..1 Narrative DISCOURAGED - the preferred approach is to offer structured data fields which a Data Consumer can then render and present in a manner most suited to its users
... modifierExtension ?! 0..* Extension Extensions that cannot be ignored
... Slices for identifier Σ 0..* Identifier Other identifiers for the document
Slice: Unordered, Open by value:system
.... identifier:All Slices Content/Rules for all slices
..... use ?!Σ 0..1 code usual | official | temp | secondary | old (If known)
Binding: IdentifierUse (required): Identifies the purpose for this identifier, if known .

..... assigner Σ 0..1 Reference(InterweaveOrganization) Organization that issued id (may be just text)
.... identifier:localIdentifier SΣ 0..1 Identifier Other identifiers for the document
..... use ?!Σ 0..1 code usual | official | temp | secondary | old (If known)
Binding: IdentifierUse (required): Identifies the purpose for this identifier, if known .

..... system SΣ 1..1 uri The namespace for the identifier value
Fixed Value: https://fhir.interweavedigital.nhs.uk/Id/local-documentreference-identifier
..... value SΣ 1..1 string The Local documentreference Identifier. Please prefix with ODS code plus period (XXX.) to ensure unique
Example General: 123456
... status ?!SΣ 1..1 code current | superseded | entered-in-error
Binding: DocumentReferenceStatus (required): The status of the document reference.

... docStatus SΣ 1..1 code preliminary | final | amended | entered-in-error
Binding: CompositionStatus (required): Status of the underlying document.

... type SΣ 1..1 CodeableConcept Type of document
Binding: InterweaveDocumentType (preferred)
... category Σ 0..* CodeableConcept Categorization of document
Binding: DocumentClassValueSet (preferred)
... subject SΣ 1..1 Reference(InterweavePatient) Who is the subject of the document
.... reference ΣC 1..1 string Reference to a resource (could be Contained)
.... identifier Σ 0..1 Identifier If relevant could include an id
.... display Σ 1..1 string Description of the referenced resource
... date SΣ 1..1 instant When this document reference was created
... author SΣ 0..* Reference(Practitioner | PractitionerRole | Organization | Device | Patient | RelatedPerson) Who and/or what authored the document. NB: For most use-cases this should contain a single practitioner who is the main contact for any further questions
.... reference ΣC 1..1 string Reference to a resource (could be Contained)
.... identifier Σ 0..1 Identifier If relevant could include an id
.... display Σ 1..1 string Description of the referenced resource
... custodian 0..1 Reference(Organization) DISCOURAGED - this information is already covered by the provenance tags
... relatesTo Σ 0..* BackboneElement DISCOURAGED - use with great caution as consumer systems are likely to display a simple list of documents, and may not interpret these relationships
.... modifierExtension ?!Σ 0..* Extension Extensions that cannot be ignored even if unrecognized
.... code Σ 1..1 code replaces | transforms | signs | appends
Binding: DocumentRelationshipType (required): The type of relationship between documents.

.... target Σ 1..1 Reference(DocumentReference) Target of the relationship
... description Σ 0..1 string Human-readable description (title). Useful to populate, but acceptable to omit if nothing to add over-and-above the 'type'
... securityLabel Σ 0..* CodeableConcept DISCOURAGED - unlikely to be honoured by consumers
Binding: All Security Labels (extensible): Security Labels from the Healthcare Privacy and Security Classification System.


... content SΣ 1..* BackboneElement Document referenced
.... modifierExtension ?!Σ 0..* Extension Extensions that cannot be ignored even if unrecognized
.... attachment SΣ 1..1 Attachment Where to access the document
..... contentType SΣ 1..1 code Mime type of the content, with charset etc.
Binding: Mime Types (required): The mime type of an attachment. Any valid mime type is allowed.


Example General: text/plain; charset=UTF-8, image/png
..... creation SΣ 0..1 dateTime Date attachment was first created
... context Σ 0..1 BackboneElement Clinical context of document
.... modifierExtension ?!Σ 0..* Extension Extensions that cannot be ignored even if unrecognized
.... encounter S 0..* Reference(InterweaveEncounter) Context of the document content
..... reference ΣC 1..1 string Reference to a resource (could be Contained)
..... identifier Σ 0..1 Identifier If relevant could include an id
..... display Σ 0..1 string If relevant, description of the referenced resource
.... period SΣ 0..1 Period Time of service that is being documented
.... practiceSetting 0..1 CodeableConcept Additional details about where the content was created (e.g. clinical specialty)
Binding: UK Core Care Setting Type (preferred)
.... related 0..* Reference(Resource) DISCOURAGED - see above for linkage to Encounter. Other linkages may be defined in future only if use-cases arise

doco Documentation for this format

Terminology Bindings

PathConformanceValueSetURI
DocumentReference.meta.securityextensibleAll Security Labels
http://hl7.org/fhir/ValueSet/security-labels
from the FHIR Standard
DocumentReference.meta.tagexampleCommonTags
http://hl7.org/fhir/ValueSet/common-tags
from the FHIR Standard
DocumentReference.meta.tag:SourceexampleCommonTags
http://hl7.org/fhir/ValueSet/common-tags
from the FHIR Standard
DocumentReference.meta.tag:ProvenanceexampleCommonTags
http://hl7.org/fhir/ValueSet/common-tags
from the FHIR Standard
DocumentReference.languagepreferredCommonLanguages
Additional Bindings Purpose
AllLanguages Max Binding
http://hl7.org/fhir/ValueSet/languages
from the FHIR Standard
DocumentReference.identifier.userequiredIdentifierUse
http://hl7.org/fhir/ValueSet/identifier-use|4.0.1
from the FHIR Standard
DocumentReference.identifier:localIdentifier.userequiredIdentifierUse
http://hl7.org/fhir/ValueSet/identifier-use|4.0.1
from the FHIR Standard
DocumentReference.statusrequiredDocumentReferenceStatus
http://hl7.org/fhir/ValueSet/document-reference-status|4.0.1
from the FHIR Standard
DocumentReference.docStatusrequiredCompositionStatus
http://hl7.org/fhir/ValueSet/composition-status|4.0.1
from the FHIR Standard
DocumentReference.typepreferredInterweaveDocumentType
https://fhir.interweavedigital.nhs.uk/R4/ValueSet/Interweave-DocumentType
from this IG
DocumentReference.categorypreferredDocumentClassValueSet
http://hl7.org/fhir/ValueSet/document-classcodes
from the FHIR Standard
DocumentReference.relatesTo.coderequiredDocumentRelationshipType
http://hl7.org/fhir/ValueSet/document-relationship-type|4.0.1
from the FHIR Standard
DocumentReference.securityLabelextensibleAll Security Labels
http://hl7.org/fhir/ValueSet/security-labels
from the FHIR Standard
DocumentReference.content.attachment.contentTyperequiredMime Types (a valid code from urn:ietf:bcp:13)
http://hl7.org/fhir/ValueSet/mimetypes|4.0.1
from the FHIR Standard
DocumentReference.context.practiceSettingpreferredUKCoreCareSettingType
https://fhir.hl7.org.uk/ValueSet/UKCore-CareSettingType
from this IG

Constraints

IdGradePath(s)DetailsRequirements
dom-2errorDocumentReferenceIf the resource is contained in another resource, it SHALL NOT contain nested Resources
: contained.contained.empty()
dom-3errorDocumentReferenceIf the resource is contained in another resource, it SHALL be referred to from elsewhere in the resource or SHALL refer to the containing resource
: contained.where((('#'+id in (%resource.descendants().reference | %resource.descendants().as(canonical) | %resource.descendants().as(uri) | %resource.descendants().as(url))) or descendants().where(reference = '#').exists() or descendants().where(as(canonical) = '#').exists() or descendants().where(as(canonical) = '#').exists()).not()).trace('unmatched', id).empty()
dom-4errorDocumentReferenceIf a resource is contained in another resource, it SHALL NOT have a meta.versionId or a meta.lastUpdated
: contained.meta.versionId.empty() and contained.meta.lastUpdated.empty()
dom-5errorDocumentReferenceIf a resource is contained in another resource, it SHALL NOT have a security label
: contained.meta.security.empty()
dom-6best practiceDocumentReferenceA resource should have narrative for robust management
: text.`div`.exists()
ele-1error**ALL** elementsAll FHIR elements must have a @value or children
: hasValue() or (children().count() > id.count())
ext-1error**ALL** extensionsMust have either extensions or value[x], not both
: extension.exists() != value.exists()

Snapshot View

NameFlagsCard.TypeDescription & Constraintsdoco
.. DocumentReference 0..* DocumentReference A reference to a document
... id SΣ 0..1 id Logical id of this artifact
... meta Σ 0..1 Meta Metadata about the resource
.... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
.... versionId SΣ 0..1 id Version specific identifier
.... lastUpdated SΣ 0..1 instant MANDATORY except in Contained Resources. When the resource version last changed.
.... source Σ 0..1 uri Identifies where the resource comes from
.... profile SΣ 0..* canonical(StructureDefinition) Profiles this resource claims to conform to. Should list (i) this profile (ii) base profile for this resource.
.... security Σ 0..* Coding DISCOURAGED - may not be honoured by Data Consumers
Binding: All Security Labels (extensible): Security Labels from the Healthcare Privacy and Security Classification System.


.... Slices for tag Σ 0..* Coding Tags applied to this resource
Slice: Unordered, Open by value:system
Binding: CommonTags (example): Codes that represent various types of tags, commonly workflow-related; e.g. "Needs review by Dr. Jones".


..... tag:Source SΣ 0..1 Coding MANDATORY except in Contained Resources. The Data Provider Id (and display text) of the system supplying the data
Binding: CommonTags (example): Codes that represent various types of tags, commonly workflow-related; e.g. "Needs review by Dr. Jones".


...... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
...... system Σ 1..1 uri Identity of the terminology system
Fixed Value: https://fhir.interweavedigital.nhs.uk/Source
...... code SΣ 1..1 code The Data Provider Id of the system supplying the data
...... display SΣ 1..1 string Name of the system supplying the data
...... userSelected Σ 0..1 boolean If this coding was chosen directly by the user
..... tag:Provenance SΣ 0..1 Coding MANDATORY except in Contained Resources. The ODS Code (and display text) of the organisation responsible for the data
Binding: CommonTags (example): Codes that represent various types of tags, commonly workflow-related; e.g. "Needs review by Dr. Jones".


...... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
...... system Σ 1..1 uri Identity of the terminology system
Fixed Value: https://fhir.interweavedigital.nhs.uk/Provenance
...... code SΣ 1..1 code The ODS Code of the organisation responsible for the data
...... display SΣ 1..1 string Name of the organisation supplying the data
...... userSelected Σ 0..1 boolean If this coding was chosen directly by the user
... implicitRules ?!Σ 0..1 uri DISCOURAGED - may not be honoured by Data Consumers
... text 0..1 Narrative DISCOURAGED - the preferred approach is to offer structured data fields which a Data Consumer can then render and present in a manner most suited to its users
... contained 0..* Resource Contained, inline Resources
... extension 0..* Extension Additional content defined by implementations
... modifierExtension ?! 0..* Extension Extensions that cannot be ignored
... masterIdentifier Σ 0..1 Identifier Master Version Specific Identifier
.... id 0..1 string Unique id for inter-element referencing
.... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
.... use ?!Σ 0..1 code usual | official | temp | secondary | old (If known)
Binding: IdentifierUse (required): Identifies the purpose for this identifier, if known .

.... type Σ 0..1 CodeableConcept Description of identifier
Binding: Identifier Type Codes (extensible): A coded type for an identifier that can be used to determine which identifier to use for a specific purpose.

.... system Σ 0..1 uri The namespace for the identifier value
Example General: http://www.acme.com/identifiers/patient
.... value Σ 0..1 string The value that is unique
Example General: 123456
.... period Σ 0..1 Period Time period when id is/was valid for use
.... assigner Σ 0..1 Reference(InterweaveOrganization) Organization that issued id (may be just text)
... Slices for identifier Σ 0..* Identifier Other identifiers for the document
Slice: Unordered, Open by value:system
.... identifier:All Slices Content/Rules for all slices
..... id 0..1 string Unique id for inter-element referencing
..... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
..... use ?!Σ 0..1 code usual | official | temp | secondary | old (If known)
Binding: IdentifierUse (required): Identifies the purpose for this identifier, if known .

..... type Σ 0..1 CodeableConcept Description of identifier
Binding: Identifier Type Codes (extensible): A coded type for an identifier that can be used to determine which identifier to use for a specific purpose.

..... system Σ 0..1 uri The namespace for the identifier value
Example General: http://www.acme.com/identifiers/patient
..... value Σ 0..1 string The value that is unique
Example General: 123456
..... period Σ 0..1 Period Time period when id is/was valid for use
..... assigner Σ 0..1 Reference(InterweaveOrganization) Organization that issued id (may be just text)
.... identifier:localIdentifier SΣ 0..1 Identifier Other identifiers for the document
..... id 0..1 string Unique id for inter-element referencing
..... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
..... use ?!Σ 0..1 code usual | official | temp | secondary | old (If known)
Binding: IdentifierUse (required): Identifies the purpose for this identifier, if known .

..... type Σ 0..1 CodeableConcept Description of identifier
Binding: Identifier Type Codes (extensible): A coded type for an identifier that can be used to determine which identifier to use for a specific purpose.

..... system SΣ 1..1 uri The namespace for the identifier value
Fixed Value: https://fhir.interweavedigital.nhs.uk/Id/local-documentreference-identifier
..... value SΣ 1..1 string The Local documentreference Identifier. Please prefix with ODS code plus period (XXX.) to ensure unique
Example General: 123456
..... assigner Σ 0..1 Reference(Organization) Organization that issued id (may be just text)
... status ?!SΣ 1..1 code current | superseded | entered-in-error
Binding: DocumentReferenceStatus (required): The status of the document reference.

... docStatus SΣ 1..1 code preliminary | final | amended | entered-in-error
Binding: CompositionStatus (required): Status of the underlying document.

... type SΣ 1..1 CodeableConcept Type of document
Binding: InterweaveDocumentType (preferred)
.... id 0..1 string Unique id for inter-element referencing
.... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
.... coding Σ 0..* Coding Code defined by a terminology system
..... id 0..1 string Unique id for inter-element referencing
..... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
..... system Σ 1..1 uri Identity of the terminology system
..... version Σ 0..1 string Version of the system - if relevant
..... code Σ 1..1 code Symbol in syntax defined by the system
..... display Σ 1..1 string Representation defined by the system
..... userSelected Σ 0..1 boolean If this coding was chosen directly by the user
.... text Σ 0..1 string Plain text representation of the concept
... category Σ 0..* CodeableConcept Categorization of document
Binding: DocumentClassValueSet (preferred)
.... id 0..1 string Unique id for inter-element referencing
.... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
.... coding Σ 0..* Coding Code defined by a terminology system
..... id 0..1 string Unique id for inter-element referencing
..... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
..... system Σ 1..1 uri Identity of the terminology system
..... version Σ 0..1 string Version of the system - if relevant
..... code Σ 1..1 code Symbol in syntax defined by the system
..... display Σ 1..1 string Representation defined by the system
..... userSelected Σ 0..1 boolean If this coding was chosen directly by the user
.... text Σ 0..1 string Plain text representation of the concept
... subject SΣ 1..1 Reference(InterweavePatient) Who is the subject of the document
.... id 0..1 string Unique id for inter-element referencing
.... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
.... reference ΣC 1..1 string Reference to a resource (could be Contained)
.... type Σ 0..1 uri Type the reference refers to (e.g. "Patient")
Binding: ResourceType (extensible): Aa resource (or, for logical models, the URI of the logical model).

.... identifier Σ 0..1 Identifier If relevant could include an id
.... display Σ 1..1 string Description of the referenced resource
... date SΣ 1..1 instant When this document reference was created
... author SΣ 0..* Reference(Practitioner | PractitionerRole | Organization | Device | Patient | RelatedPerson) Who and/or what authored the document. NB: For most use-cases this should contain a single practitioner who is the main contact for any further questions
.... id 0..1 string Unique id for inter-element referencing
.... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
.... reference ΣC 1..1 string Reference to a resource (could be Contained)
.... type Σ 0..1 uri Type the reference refers to (e.g. "Patient")
Binding: ResourceType (extensible): Aa resource (or, for logical models, the URI of the logical model).

.... identifier Σ 0..1 Identifier If relevant could include an id
.... display Σ 1..1 string Description of the referenced resource
... authenticator 0..1 Reference(Practitioner | PractitionerRole | Organization) Who/what authenticated the document
... custodian 0..1 Reference(Organization) DISCOURAGED - this information is already covered by the provenance tags
... relatesTo Σ 0..* BackboneElement DISCOURAGED - use with great caution as consumer systems are likely to display a simple list of documents, and may not interpret these relationships
.... id 0..1 string Unique id for inter-element referencing
.... extension 0..* Extension Additional content defined by implementations
.... modifierExtension ?!Σ 0..* Extension Extensions that cannot be ignored even if unrecognized
.... code Σ 1..1 code replaces | transforms | signs | appends
Binding: DocumentRelationshipType (required): The type of relationship between documents.

.... target Σ 1..1 Reference(DocumentReference) Target of the relationship
... description Σ 0..1 string Human-readable description (title). Useful to populate, but acceptable to omit if nothing to add over-and-above the 'type'
... securityLabel Σ 0..* CodeableConcept DISCOURAGED - unlikely to be honoured by consumers
Binding: All Security Labels (extensible): Security Labels from the Healthcare Privacy and Security Classification System.


... content SΣ 1..* BackboneElement Document referenced
.... id 0..1 string Unique id for inter-element referencing
.... extension 0..* Extension Additional content defined by implementations
.... modifierExtension ?!Σ 0..* Extension Extensions that cannot be ignored even if unrecognized
.... attachment SΣ 1..1 Attachment Where to access the document
..... id 0..1 string Unique id for inter-element referencing
..... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
..... contentType SΣ 1..1 code Mime type of the content, with charset etc.
Binding: Mime Types (required): The mime type of an attachment. Any valid mime type is allowed.


Example General: text/plain; charset=UTF-8, image/png
..... language Σ 0..1 code Human language of the content (BCP-47)
Binding: CommonLanguages (preferred): A human language.

Additional BindingsPurpose
AllLanguages Max Binding

Example General: en-AU
..... data 0..1 base64Binary Data inline, base64ed
..... url Σ 0..1 url Uri where the data can be found
Example General: http://www.acme.com/logo-small.png
..... size Σ 0..1 unsignedInt Number of bytes of content (if url provided)
..... hash Σ 0..1 base64Binary Hash of the data (sha-1, base64ed)
..... title Σ 0..1 string Label to display in place of the data
Example General: Official Corporate Logo
..... creation SΣ 0..1 dateTime Date attachment was first created
.... format Σ 0..1 Coding Format/content rules for the document
Binding: DocumentReferenceFormatCodeSet (preferred): Document Format Codes.

... context Σ 0..1 BackboneElement Clinical context of document
.... id 0..1 string Unique id for inter-element referencing
.... extension 0..* Extension Additional content defined by implementations
.... modifierExtension ?!Σ 0..* Extension Extensions that cannot be ignored even if unrecognized
.... encounter S 0..* Reference(InterweaveEncounter) Context of the document content
..... id 0..1 string Unique id for inter-element referencing
..... extension 0..* Extension Additional content defined by implementations
Slice: Unordered, Open by value:url
..... reference ΣC 1..1 string Reference to a resource (could be Contained)
..... type Σ 0..1 uri Type the reference refers to (e.g. "Patient")
Binding: ResourceType (extensible): Aa resource (or, for logical models, the URI of the logical model).

..... identifier Σ 0..1 Identifier If relevant could include an id
..... display Σ 0..1 string If relevant, description of the referenced resource
.... event 0..* CodeableConcept Main clinical acts documented
Binding: v3 Code System ActCode (example): This list of codes represents the main clinical acts being documented.


.... period SΣ 0..1 Period Time of service that is being documented
.... facilityType 0..1 CodeableConcept Kind of facility where patient was seen
Binding: FacilityTypeCodeValueSet (example): XDS Facility Type.

.... practiceSetting 0..1 CodeableConcept Additional details about where the content was created (e.g. clinical specialty)
Binding: UK Core Care Setting Type (preferred)
.... related 0..* Reference(Resource) DISCOURAGED - see above for linkage to Encounter. Other linkages may be defined in future only if use-cases arise

doco Documentation for this format

Terminology Bindings

PathConformanceValueSetURI
DocumentReference.meta.securityextensibleAll Security Labels
http://hl7.org/fhir/ValueSet/security-labels
from the FHIR Standard
DocumentReference.meta.tagexampleCommonTags
http://hl7.org/fhir/ValueSet/common-tags
from the FHIR Standard
DocumentReference.meta.tag:SourceexampleCommonTags
http://hl7.org/fhir/ValueSet/common-tags
from the FHIR Standard
DocumentReference.meta.tag:ProvenanceexampleCommonTags
http://hl7.org/fhir/ValueSet/common-tags
from the FHIR Standard
DocumentReference.languagepreferredCommonLanguages
Additional Bindings Purpose
AllLanguages Max Binding
http://hl7.org/fhir/ValueSet/languages
from the FHIR Standard
DocumentReference.masterIdentifier.userequiredIdentifierUse
http://hl7.org/fhir/ValueSet/identifier-use|4.0.1
from the FHIR Standard
DocumentReference.masterIdentifier.typeextensibleIdentifier Type Codes
http://hl7.org/fhir/ValueSet/identifier-type
from the FHIR Standard
DocumentReference.identifier.userequiredIdentifierUse
http://hl7.org/fhir/ValueSet/identifier-use|4.0.1
from the FHIR Standard
DocumentReference.identifier.typeextensibleIdentifier Type Codes
http://hl7.org/fhir/ValueSet/identifier-type
from the FHIR Standard
DocumentReference.identifier:localIdentifier.userequiredIdentifierUse
http://hl7.org/fhir/ValueSet/identifier-use|4.0.1
from the FHIR Standard
DocumentReference.identifier:localIdentifier.typeextensibleIdentifier Type Codes
http://hl7.org/fhir/ValueSet/identifier-type
from the FHIR Standard
DocumentReference.statusrequiredDocumentReferenceStatus
http://hl7.org/fhir/ValueSet/document-reference-status|4.0.1
from the FHIR Standard
DocumentReference.docStatusrequiredCompositionStatus
http://hl7.org/fhir/ValueSet/composition-status|4.0.1
from the FHIR Standard
DocumentReference.typepreferredInterweaveDocumentType
https://fhir.interweavedigital.nhs.uk/R4/ValueSet/Interweave-DocumentType
from this IG
DocumentReference.categorypreferredDocumentClassValueSet
http://hl7.org/fhir/ValueSet/document-classcodes
from the FHIR Standard
DocumentReference.subject.typeextensibleResourceType
http://hl7.org/fhir/ValueSet/resource-types
from the FHIR Standard
DocumentReference.author.typeextensibleResourceType
http://hl7.org/fhir/ValueSet/resource-types
from the FHIR Standard
DocumentReference.relatesTo.coderequiredDocumentRelationshipType
http://hl7.org/fhir/ValueSet/document-relationship-type|4.0.1
from the FHIR Standard
DocumentReference.securityLabelextensibleAll Security Labels
http://hl7.org/fhir/ValueSet/security-labels
from the FHIR Standard
DocumentReference.content.attachment.contentTyperequiredMime Types (a valid code from urn:ietf:bcp:13)
http://hl7.org/fhir/ValueSet/mimetypes|4.0.1
from the FHIR Standard
DocumentReference.content.attachment.languagepreferredCommonLanguages
Additional Bindings Purpose
AllLanguages Max Binding
http://hl7.org/fhir/ValueSet/languages
from the FHIR Standard
DocumentReference.content.formatpreferredDocumentReferenceFormatCodeSet (a valid code from http://ihe.net/fhir/ValueSet/IHE.FormatCode.codesystem)
http://hl7.org/fhir/ValueSet/formatcodes
from the FHIR Standard
DocumentReference.context.encounter.typeextensibleResourceType
http://hl7.org/fhir/ValueSet/resource-types
from the FHIR Standard
DocumentReference.context.eventexampleActCode
http://terminology.hl7.org/ValueSet/v3-ActCode
DocumentReference.context.facilityTypeexampleFacilityTypeCodeValueSet
http://hl7.org/fhir/ValueSet/c80-facilitycodes
from the FHIR Standard
DocumentReference.context.practiceSettingpreferredUKCoreCareSettingType
https://fhir.hl7.org.uk/ValueSet/UKCore-CareSettingType
from this IG

Constraints

IdGradePath(s)DetailsRequirements
dom-2errorDocumentReferenceIf the resource is contained in another resource, it SHALL NOT contain nested Resources
: contained.contained.empty()
dom-3errorDocumentReferenceIf the resource is contained in another resource, it SHALL be referred to from elsewhere in the resource or SHALL refer to the containing resource
: contained.where((('#'+id in (%resource.descendants().reference | %resource.descendants().as(canonical) | %resource.descendants().as(uri) | %resource.descendants().as(url))) or descendants().where(reference = '#').exists() or descendants().where(as(canonical) = '#').exists() or descendants().where(as(canonical) = '#').exists()).not()).trace('unmatched', id).empty()
dom-4errorDocumentReferenceIf a resource is contained in another resource, it SHALL NOT have a meta.versionId or a meta.lastUpdated
: contained.meta.versionId.empty() and contained.meta.lastUpdated.empty()
dom-5errorDocumentReferenceIf a resource is contained in another resource, it SHALL NOT have a security label
: contained.meta.security.empty()
dom-6best practiceDocumentReferenceA resource should have narrative for robust management
: text.`div`.exists()
ele-1error**ALL** elementsAll FHIR elements must have a @value or children
: hasValue() or (children().count() > id.count())
ext-1error**ALL** extensionsMust have either extensions or value[x], not both
: extension.exists() != value.exists()

This structure is derived from DocumentReference

Summary

Mandatory: 7 elements(17 nested mandatory elements)
Must-Support: 25 elements
Fixed: 3 elements
Prohibited: 7 elements

Structures

This structure refers to these other structures:

Slices

This structure defines the following Slices:

  • The element 1 is sliced based on the value of DocumentReference.meta.tag
  • The element 1 is sliced based on the value of DocumentReference.identifier

 

Other representations of profile: CSV, Excel, Schematron

Notes:

Differences between Interweave STU3 and R4 profiles

Element name Change details
identifier:localIdentifier.system
  • Changed Fixed value from https://fhir.yhcr.nhs.uk/Id/local-documentreference-identifier to https://fhir.interweavedigital.nhs.uk/Id/local-documentreference-identifier
type
  • Changed valueSet from https://fhir.yhcr.nhs.uk/ValueSet/Interweave-DocumentType to https://fhir.interweavedigital.nhs.uk/R4/ValueSet/Interweave-DocumentType
category
  • Renamed from class to category
  • Max Cardinality changed from 1 to *
  • Changed valueSet from http://hl7.org/fhir/ValueSet/c80-doc-classcodes to http://hl7.org/fhir/ValueSet/document-classcodes
date
  • Renamed from indexed to date
created
  • Deleted
author
  • Type Reference: Added Target Type PractitionerRole
authenticator
  • Type Reference: Added Target Type PractitionerRole
context.encounter
  • Max Cardinality changed from 1 to *
context.practiceSetting
  • Changed valueSet from https://fhir.hl7.org.uk/STU3/ValueSet/CareConnect-CareSettingType-1 to https://fhir.hl7.org.uk/ValueSet/UKCore-CareSettingType

Graphical relationship diagram

DocumentReference resource graphical relationship diagram