FHIRResources
Bundle
Maturity Level | Security Category | Resource Category |
---|---|---|
3 | Unclassified | Foundation Resources |
A container for a collection of resources.
Resource Content
Name | Required | Type | Description & Constraints |
---|---|---|---|
identifier | Identifier | Persistent identifier for the bundle | |
type | ✓ | code | document | message | transaction | transaction-response | batch | batch-response | history | searchset | collection |
timestamp | instant | When the bundle was assembled | |
total | unsignedInt | If search, the total number of matches | |
link | BackboneElement | Links related to this Bundle | |
└─ relation | ✓ | string | See http://www.iana.org/assignments/link-relations/link-relations.xhtml#link-relations-1 |
└─ url | ✓ | uri | Reference details for the link |
entry | BackboneElement | Entry in the bundle - will have a resource or information | |
└─ link | BackboneElement | Links related to this entry | |
└─ fullUrl | uri | URI for resource (Absolute URL server address or URI for UUID/OID) | |
└─ resource | Resource | A resource in the bundle | |
└─ search | BackboneElement | Search related information | |
└─── mode | code | match | include | outcome - why this is in the result set | |
└─── score | decimal | Search ranking (between 0 and 1) | |
└─ request | BackboneElement | Additional execution information (transaction/batch/history) | |
└─── method | ✓ | code | GET | HEAD | POST | PUT | DELETE | PATCH |
└─── url | ✓ | uri | URL for HTTP equivalent of this entry |
└─── ifNoneMatch | string | For managing cache currency | |
└─── ifModifiedSince | instant | For managing cache currency | |
└─── ifMatch | string | For managing update contention | |
└─── ifNoneExist | string | For conditional creates | |
└─ response | BackboneElement | Results of execution (transaction/batch/history) | |
└─── status | ✓ | string | Status response code (text optional) |
└─── location | uri | The location (if the operation returns a location) | |
└─── etag | string | The Etag for the resource (if relevant) | |
└─── lastModified | instant | Server's date time modified | |
└─── outcome | Resource | OperationOutcome with hints and warnings (for batch/transaction) | |
signature | Signature | Digital Signature |
Search Parameters
Name | Type | Description | Expression |
---|---|---|---|
composition | reference | The first resource in the bundle, if the bundle type is "document" - this is a composition, and this parameter provides access to search its contents | Bundle.entry[0].resource |
identifier | token | Persistent identifier for the bundle | Bundle.identifier |
message | reference | The first resource in the bundle, if the bundle type is "message" - this is a message header, and this parameter provides access to search its contents | Bundle.entry[0].resource |
timestamp | date | When the bundle was assembled | Bundle.timestamp |
type | token | document | message | transaction | transaction-response | batch | batch-response | history | searchset | collection | Bundle.type |
Scope and Usage
A Bundle is used to gather collections of FHIR resources into a single instance with containing context. Common use cases include:
- Server Operations
- Returning resources that meet search criteria
- Providing version histories of resources
- Data Exchange
- Sending resources in message exchanges
- Grouping resources into clinical documents
- Batch Operations
- Creating/updating/deleting multiple resources atomically
- Managing collections of resources as transactions
- Storage
- Persisting related resources together
Boundaries and Relationships
Resource Collection Methods
There are two primary approaches for collecting resources:
-
Contained Resources
- Resources exist within the container resource
- Can only be interpreted/modified in container context
-
Bundles
- Resources maintain independent existence
- Can be accessed directly via RESTful API
Related Grouping Resources
While Bundles serve as technical containers, FHIR provides three additional resources for logical grouping:
1. List Resource
- Manages flat collections of resources
- Dynamic nature - items can be added/removed
- Supports curation with specific business meaning
- References other resources directly
2. Group Resource
- Defines collections of specific entities (people, animals, devices)
- Can enumerate explicitly or describe qualifying characteristics
- Commonly used for:
- Public health (at-risk populations)
- Clinical trials (test subject pools)
- Group-level operations/observations
3. Composition Resource
- Assembles healthcare information into logical documents
- Provides structure for FHIR documents
- Establishes context and clinical attestation
- Often references Lists within sections
- Full content expressed using Bundles
Note: While these resources create meaningful groupings with specific purposes, a Bundle primarily serves as a technical container for resource transfer and storage. Additional resources may provide other grouping functionality.
Referenced Elements
N/A