Transaction

A transaction Bundle allows multiple related FHIR operations to be submitted in a single request. Each operation is represented as an entry within a Bundle of type transaction and is processed together as a coordinated unit of work.

Health Gorilla supports transaction Bundles to enable submission of interdependent operations where consistent processing and reference resolution across resources is required.

Use Cases

Typical use cases for transaction Bundles include:

  • Creating multiple related resources that reference one another
  • Updating or deleting interdependent resources in a single request
  • Submitting coordinated changes where operations must be evaluated together
  • Preserving referential integrity across newly created resources

Scope and Behavior

This page documents transaction processing behavior for the FHIR R4 Bundle resource. Transaction Bundles are used strictly as a request container and are not persisted or retrievable as standalone clinical resources.

Health Gorilla evaluates transaction Bundles as a coordinated set of operations. Entries are processed according to the request instructions defined in the Bundle and are not treated as independent submissions.

Bundle Structure Requirements

Transaction requests must be submitted as a FHIR Bundle resource with the following characteristics:

  • resourceType must be Bundle
  • type must be set to transaction
  • Each entry must include:
    • a resource element containing a valid FHIR resource
    • a request element defining the HTTP method and target URL for that entry

All processing instructions are defined within the request body.

Entry Correlation and Reference Resolution (fullUrl)

Transaction Bundles may include internal references between entries. To support reference resolution during processing, entries may include a fullUrl value.

  • The fullUrl provides a temporary identifier used to resolve references between entries in the request Bundle
  • References to resources created within the same transaction may use the corresponding fullUrl
  • fullUrl values are used only during transaction processing and are not persisted as resource identifiers

Processing Behavior

  • Transaction processing is synchronous
  • Entries are processed according to the HTTP method and target URL defined in each entry.request
  • Internal references between entries are resolved during processing
  • Processing results are returned in a response Bundle of type transaction-response
  • Each response entry corresponds to a request entry and includes the outcome for that operation

Error Handling

If transaction processing fails:

  • An appropriate HTTP status code is returned
  • A FHIR OperationOutcome resource describes the error condition
  • The response indicates which entry or condition caused the failure

Clients should not assume partial success semantics when submitting transaction Bundles.

Limitations and Notes

  • Transaction Bundles are intended for coordinated operations with logical dependencies
  • For independent operations where partial success is acceptable, use a batch Bundle instead
  • Resource-specific validation rules and side effects are documented on individual resource pages

Related Information