2nd DSTU Draft For Comment

This page is part of the FHIR Specification (v0.4.0: DSTU 2 Draft). 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: R4B R4 R3 R2

6.2 Resource Media - Content

This resource maintained by the FHIR Management Group Work Group

A photo, video, or audio recording acquired or used in healthcare. The actual content may be inline or provided by direct reference.

6.2.1 Scope and Usage

The Media resource contains photos, videos, and audio recordings. It is used with media acquired or used as part of the healthcare process. Here are some typical usages:

  • Photos of patients and staff for identification purposes
  • Photos and videos of diagnostic or care provision procedures for recording purposes
  • Storing scans and faxes of paper documents where not enough metadata exists to create a DocumentReference
  • Images on diagnostic reports

The Media resource may contain medical images in a DICOM format. While such images may also be accessible through an ImagingStudy resource, the Media resource enables "ready for presentation" access to a specific image. Such images would preferentially be made available in a FHIR ecosystem by the Media.content.url providing a reference to a WADO-RS service to access the image. That WADO-RS service may include rendering the image with annotations and display parameters from an associated DICOM presentation state. Although the Media resource is allowed to contain images collected by a DICOM based system, DICOM images would preferentially be made available in a FHIR ecosystem by provision of a resource with references to a WADO-RS server.

This resource is referenced by DiagnosticReport and DocumentManifest

6.2.2 Resource Content

Structure

NameFlagsCard.TypeDescription & Constraintsdoco
.. Media IDomainResourceA photo, video, or audio recording acquired or used in healthcare. The actual content may be inline or provided by direct reference
Height can only be used for a photo or video
Width can only be used for a photo or video
Length can only be used for an audio or a video
Frames can only be used for a photo
... type Σ1..1codephoto | video | audio
MediaType (Required)
... subtype Σ0..1CodeableConceptThe type of acquisition equipment/process
MediaSubtype (Example)
... identifier Σ0..*IdentifierIdentifier(s) for the image
... created Σ0..1dateTimeWhen the media was taken/recorded (start)
... subject Σ0..1Patient | Practitioner | Group | Device | SpecimenWho/What this Media is a record of
... operator Σ0..1PractitionerThe person who generated the image
... view Σ0..1CodeableConceptImaging view e.g Lateral or Antero-posterior
MediaView (Example)
... deviceName Σ0..1stringName of the device/manufacturer
... height Σ I0..1integerHeight of the image in pixels(photo/video)
... width Σ I0..1integerWidth of the image in pixels (photo/video)
... frames Σ I0..1integerNumber of frames if > 1 (photo)
... duration Σ I0..1integerLength in seconds (audio / video)
... content 1..1AttachmentActual Media - reference or data

UML Diagram

Media (DomainResource)Whether the media is a photo (still image), an audio recording, or a video recordingtype : code 1..1 « Whether the Media is a photo, video, or audioMediaType »Details of the type of the media - usually, how it was acquired (what type of device). If images sourced from a DICOM system, are wrapped in a Media resource, then this is the modalitysubtype : CodeableConcept 0..1 « (Detailed information about the type of the image - its kind, purpose, or the kind of equipment used to generate itMediaSubtype) »Identifiers associated with the image - these may include identifiers for the image itself, identifiers for the context of its collection (e.g. series ids) and context ids such as accession numbers or other workflow identifiersidentifier : Identifier 0..*The date/time when the media was originally recorded. For video and audio, if the length of the recording is not insignificant, this is the start of the recordingcreated : dateTime 0..1Who/What this Media is a record ofsubject : Reference(Patient|Practitioner|Group| Device|Specimen) 0..1The person who administered the collection of the imageoperator : Reference(Practitioner) 0..1The name of the imaging view e.g Lateral or Antero-posterior (AP)view : CodeableConcept 0..1 « (Imaging view (projection) used when collecting an imageMediaView) »The name of the device / manufacturer of the device that was used to make the recordingdeviceName : string 0..1Height of the image in pixels(photo/video)height : integer 0..1Width of the image in pixels (photo/video)width : integer 0..1The number of frames in a photo. This is used with a multi-page fax, or an imaging acquisition context that takes multiple slices in a single image, or an animated gif. If there is more than one frame, this SHALL have a value in order to alert interface software that a multi-frame capable rendering widget is requiredframes : integer 0..1The duration of the recording in seconds - for audio and videoduration : integer 0..1The actual content of the media - inline or by direct reference to the media source filecontent : Attachment 1..1

XML Template

<Media xmlns="http://hl7.org/fhir"> doco
 <!-- from Resource: id, meta, implicitRules, and language -->
 <!-- from DomainResource: text, contained, extension, and modifierExtension -->
 <type value="[code]"/><!-- 1..1 photo | video | audio -->
 <subtype><!-- 0..1 CodeableConcept The type of acquisition equipment/process --></subtype>
 <identifier><!-- 0..* Identifier Identifier(s) for the image --></identifier>
 <created value="[dateTime]"/><!-- 0..1 When the media was taken/recorded (start) -->
 <subject><!-- 0..1 Reference(Patient|Practitioner|Group|Device|Specimen) 
     Who/What this Media is a record of --></subject>
 <operator><!-- 0..1 Reference(Practitioner) The person who generated the image --></operator>
 <view><!-- 0..1 CodeableConcept Imaging view e.g Lateral or Antero-posterior --></view>
 <deviceName value="[string]"/><!-- 0..1 Name of the device/manufacturer -->
 <height value="[integer]"/><!-- ?? 0..1 Height of the image in pixels(photo/video) -->
 <width value="[integer]"/><!-- ?? 0..1 Width of the image in pixels (photo/video) -->
 <frames value="[integer]"/><!-- ?? 0..1 Number of frames if > 1 (photo) -->
 <duration value="[integer]"/><!-- ?? 0..1 Length in seconds (audio / video) -->
 <content><!-- 1..1 Attachment Actual Media - reference or data --></content>
</Media>

JSON Template

{doco
  "resourceType" : "Media",
  // from Resource: id, meta, implicitRules, and language
  // from DomainResource: text, contained, extension, and modifierExtension
  "type" : "<code>", // R! photo | video | audio
  "subtype" : { CodeableConcept }, // The type of acquisition equipment/process
  "identifier" : [{ Identifier }], // Identifier(s) for the image
  "created" : "<dateTime>", // When the media was taken/recorded (start)
  "subject" : { Reference(Patient|Practitioner|Group|Device|Specimen) }, // 
     Who/What this Media is a record of
  "operator" : { Reference(Practitioner) }, // The person who generated the image
  "view" : { CodeableConcept }, // Imaging view e.g Lateral or Antero-posterior
  "deviceName" : "<string>", // Name of the device/manufacturer
  "height" : <integer>, // C? Height of the image in pixels(photo/video)
  "width" : <integer>, // C? Width of the image in pixels (photo/video)
  "frames" : <integer>, // C? Number of frames if > 1 (photo)
  "duration" : <integer>, // C? Length in seconds (audio / video)
  "content" : { Attachment } // R! Actual Media - reference or data
}

Structure

NameFlagsCard.TypeDescription & Constraintsdoco
.. Media IDomainResourceA photo, video, or audio recording acquired or used in healthcare. The actual content may be inline or provided by direct reference
Height can only be used for a photo or video
Width can only be used for a photo or video
Length can only be used for an audio or a video
Frames can only be used for a photo
... type Σ1..1codephoto | video | audio
MediaType (Required)
... subtype Σ0..1CodeableConceptThe type of acquisition equipment/process
MediaSubtype (Example)
... identifier Σ0..*IdentifierIdentifier(s) for the image
... created Σ0..1dateTimeWhen the media was taken/recorded (start)
... subject Σ0..1Patient | Practitioner | Group | Device | SpecimenWho/What this Media is a record of
... operator Σ0..1PractitionerThe person who generated the image
... view Σ0..1CodeableConceptImaging view e.g Lateral or Antero-posterior
MediaView (Example)
... deviceName Σ0..1stringName of the device/manufacturer
... height Σ I0..1integerHeight of the image in pixels(photo/video)
... width Σ I0..1integerWidth of the image in pixels (photo/video)
... frames Σ I0..1integerNumber of frames if > 1 (photo)
... duration Σ I0..1integerLength in seconds (audio / video)
... content 1..1AttachmentActual Media - reference or data

UML Diagram

Media (DomainResource)Whether the media is a photo (still image), an audio recording, or a video recordingtype : code 1..1 « Whether the Media is a photo, video, or audioMediaType »Details of the type of the media - usually, how it was acquired (what type of device). If images sourced from a DICOM system, are wrapped in a Media resource, then this is the modalitysubtype : CodeableConcept 0..1 « (Detailed information about the type of the image - its kind, purpose, or the kind of equipment used to generate itMediaSubtype) »Identifiers associated with the image - these may include identifiers for the image itself, identifiers for the context of its collection (e.g. series ids) and context ids such as accession numbers or other workflow identifiersidentifier : Identifier 0..*The date/time when the media was originally recorded. For video and audio, if the length of the recording is not insignificant, this is the start of the recordingcreated : dateTime 0..1Who/What this Media is a record ofsubject : Reference(Patient|Practitioner|Group| Device|Specimen) 0..1The person who administered the collection of the imageoperator : Reference(Practitioner) 0..1The name of the imaging view e.g Lateral or Antero-posterior (AP)view : CodeableConcept 0..1 « (Imaging view (projection) used when collecting an imageMediaView) »The name of the device / manufacturer of the device that was used to make the recordingdeviceName : string 0..1Height of the image in pixels(photo/video)height : integer 0..1Width of the image in pixels (photo/video)width : integer 0..1The number of frames in a photo. This is used with a multi-page fax, or an imaging acquisition context that takes multiple slices in a single image, or an animated gif. If there is more than one frame, this SHALL have a value in order to alert interface software that a multi-frame capable rendering widget is requiredframes : integer 0..1The duration of the recording in seconds - for audio and videoduration : integer 0..1The actual content of the media - inline or by direct reference to the media source filecontent : Attachment 1..1

XML Template

<Media xmlns="http://hl7.org/fhir"> doco
 <!-- from Resource: id, meta, implicitRules, and language -->
 <!-- from DomainResource: text, contained, extension, and modifierExtension -->
 <type value="[code]"/><!-- 1..1 photo | video | audio -->
 <subtype><!-- 0..1 CodeableConcept The type of acquisition equipment/process --></subtype>
 <identifier><!-- 0..* Identifier Identifier(s) for the image --></identifier>
 <created value="[dateTime]"/><!-- 0..1 When the media was taken/recorded (start) -->
 <subject><!-- 0..1 Reference(Patient|Practitioner|Group|Device|Specimen) 
     Who/What this Media is a record of --></subject>
 <operator><!-- 0..1 Reference(Practitioner) The person who generated the image --></operator>
 <view><!-- 0..1 CodeableConcept Imaging view e.g Lateral or Antero-posterior --></view>
 <deviceName value="[string]"/><!-- 0..1 Name of the device/manufacturer -->
 <height value="[integer]"/><!-- ?? 0..1 Height of the image in pixels(photo/video) -->
 <width value="[integer]"/><!-- ?? 0..1 Width of the image in pixels (photo/video) -->
 <frames value="[integer]"/><!-- ?? 0..1 Number of frames if > 1 (photo) -->
 <duration value="[integer]"/><!-- ?? 0..1 Length in seconds (audio / video) -->
 <content><!-- 1..1 Attachment Actual Media - reference or data --></content>
</Media>

JSON Template

{doco
  "resourceType" : "Media",
  // from Resource: id, meta, implicitRules, and language
  // from DomainResource: text, contained, extension, and modifierExtension
  "type" : "<code>", // R! photo | video | audio
  "subtype" : { CodeableConcept }, // The type of acquisition equipment/process
  "identifier" : [{ Identifier }], // Identifier(s) for the image
  "created" : "<dateTime>", // When the media was taken/recorded (start)
  "subject" : { Reference(Patient|Practitioner|Group|Device|Specimen) }, // 
     Who/What this Media is a record of
  "operator" : { Reference(Practitioner) }, // The person who generated the image
  "view" : { CodeableConcept }, // Imaging view e.g Lateral or Antero-posterior
  "deviceName" : "<string>", // Name of the device/manufacturer
  "height" : <integer>, // C? Height of the image in pixels(photo/video)
  "width" : <integer>, // C? Width of the image in pixels (photo/video)
  "frames" : <integer>, // C? Number of frames if > 1 (photo)
  "duration" : <integer>, // C? Length in seconds (audio / video)
  "content" : { Attachment } // R! Actual Media - reference or data
}

 

Alternate definitions: Schema/Schematron, Resource Profile (XML, JSON), Questionnaire

6.2.2.1 Terminology Bindings

PathDefinitionTypeReference
Media.type Whether the Media is a photo, video, or audioFixedhttp://hl7.org/fhir/media-type
Media.subtype Detailed information about the type of the image - its kind, purpose, or the kind of equipment used to generate itExamplehttp://hl7.org/fhir/vs/media-subtype
Media.view Imaging view (projection) used when collecting an imageExamplehttp://hl7.org/fhir/vs/media-view

6.2.2.2 Constraints

  • mda-1: Height can only be used for a photo or video (xpath: not(f:type/@value='audio') or not(f:height))
  • mda-2: Width can only be used for a photo or video (xpath: not(f:type/@value='audio') or not(f:width))
  • mda-3: Frames can only be used for a photo (xpath: (f:type/@value='photo') or not(f:frames))
  • mda-4: Length can only be used for an audio or a video (xpath: not(f:type/@value='photo') or not(f:length))

6.2.3 Search Parameters

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

NameTypeDescriptionPaths
createddateWhen the media was taken/recorded (start)Media.created
identifiertokenIdentifier(s) for the imageMedia.identifier
operatorreferenceThe person who generated the imageMedia.operator
(Practitioner)
patientreferenceWho/What this Media is a record ofMedia.subject
(Patient)
subjectreferenceWho/What this Media is a record ofMedia.subject
(Specimen, Device, Patient, Practitioner, Group)
subtypetokenThe type of acquisition equipment/processMedia.subtype
typetokenphoto | video | audioMedia.type
viewtokenImaging view e.g Lateral or Antero-posteriorMedia.view