HL7 FHIR
FHIR (Fast Healthcare Interoperability Resources) is a standard developed by HL7 International for exchanging healthcare information electronically. Published as a Standard for Trial Use (STU) with R4 achieving Normative status for core resources in 2019, FHIR defines a set of resources, a RESTful API, and data types for representing clinical and administrative healthcare data. FHIR supports JSON, XML, and RDF serialization formats.
Common FHIR Resources
FHIR organizes healthcare data into discrete resources, each representing a specific clinical or administrative concept. Resources are the fundamental unit of interoperability in FHIR. Each resource has a defined structure, a set of data elements, and a standard RESTful API for CRUD operations.
| Resource | Category | Description |
|---|---|---|
| Patient | Identification | Demographics and administrative information about an individual receiving care or other health-related services. |
| Observation | Clinical | Measurements and simple assertions about a patient, device, or other subject. Covers vital signs, lab results, and clinical findings. |
| Condition | Clinical | A clinical condition, problem, diagnosis, or other event, situation, issue, or clinical concept that has risen to a level of concern. |
| MedicationRequest | Clinical | An order or request for supply of medication and instructions for administration to a patient. |
| DiagnosticReport | Clinical | Findings and interpretation of diagnostic tests performed on patients, groups of patients, devices, and locations. |
| Encounter | Workflow | An interaction between a patient and healthcare provider(s) for the purpose of providing healthcare services or assessing the health status of a patient. |
| Procedure | Clinical | An action performed on or for a patient as part of the provision of care. Includes surgical procedures, diagnostic procedures, and therapeutic procedures. |
| AllergyIntolerance | Clinical | Risk of harmful or undesirable physiological response uniquely associated with exposure to a substance. Covers drug allergies, food allergies, and environmental allergies. |
Data Types
FHIR defines a type system for representing data elements within resources. Data types are categorized as primitive types (simple values), complex general-purpose types (reusable structures), metadata types (for describing knowledge artifacts), and special types (for references, narratives, and extensions).
| Category | Types |
|---|---|
| Primitive | boolean, integer, string, decimal, uri, url, canonical, base64Binary, instant, date, dateTime, time, code, oid, id, markdown, unsignedInt, positiveInt, uuid |
| Complex General | Ratio, Period, Range, Attachment, Identifier, HumanName, Address, ContactPoint, Coding, CodeableConcept, Quantity, Money, Duration, Age, Distance, Count |
| Metadata | ContactDetail, Contributor, DataRequirement, RelatedArtifact, UsageContext, TriggerDefinition, Expression, ParameterDefinition |
| Special | Reference, Narrative, Extension, Meta, Dosage, ElementDefinition |
RESTful API
FHIR defines a RESTful API based on HTTP. Servers expose resources at predictable URLs following the pattern [base]/[resourceType]/[id]. The API supports standard HTTP methods for CRUD operations along with FHIR-specific operations.
| Interaction | HTTP Method | URL Pattern | Description |
|---|---|---|---|
| read | GET | [base]/[type]/[id] | Read the current state of a resource |
| vread | GET | [base]/[type]/[id]/_history/[vid] | Read a specific version of a resource |
| update | PUT | [base]/[type]/[id] | Update an existing resource by its id |
| patch | PATCH | [base]/[type]/[id] | Partially update a resource |
| delete | DELETE | [base]/[type]/[id] | Delete a resource |
| create | POST | [base]/[type] | Create a new resource (server assigns id) |
| search | GET/POST | [base]/[type]?params | Search resources by filter criteria |
| history | GET | [base]/[type]/[id]/_history | Retrieve change history for a resource |
| transaction | POST | [base] | Execute a batch of operations atomically |
| capabilities | GET | [base]/metadata | Get server capability statement |
Search Parameters
FHIR search uses query parameters appended to resource URLs. Each resource type defines specific search parameters. Parameters have defined types that determine how values are matched.
| Type | Description | Example |
|---|---|---|
| number | Numeric value search | Observation?value-quantity=gt5.4 |
| date | Date/time value search with prefixes (eq, ne, gt, lt, ge, le, sa, eb, ap) | Patient?birthdate=ge2000-01-01 |
| string | String matching (starts-with by default) | Patient?name=eve |
| token | Code or identifier search, optionally scoped by system | Condition?code=http://snomed.info/sct|73211009 |
| reference | Reference to another resource | Observation?subject=Patient/123 |
| composite | Combination of two parameter values | Observation?code-value-quantity=http://loinc.org|8480-6$gt100 |
| quantity | Numeric value with optional system and unit | Observation?value-quantity=5.4|http://unitsofmeasure.org|mg |
| uri | URI value search | ValueSet?url=http://hl7.org/fhir/ValueSet/example |
FHIR Versions
FHIR has been published in multiple releases. R4 (v4.0.1) is the current widely adopted version and the first to include Normative content. R5 (v5.0.0) was published in March 2023 with additional Normative resources and improvements to subscriptions, workflow, and clinical reasoning.
| Version | Date | Status | Notes |
|---|---|---|---|
| DSTU1 | 2014-09 | Superseded | Initial Draft Standard for Trial Use |
| DSTU2 | 2015-10 | Superseded | Widely implemented; basis for Argonaut Project |
| STU3 | 2017-03 | Superseded | Standard for Trial Use; significant maturity improvements |
| R4 (v4.0.1) | 2019-10 | Normative (core) | First Normative release; required by US Core / ONC |
| R4B (v4.3.0) | 2022-05 | Mixed | Incremental update for R5 migration path |
| R5 (v5.0.0) | 2023-03 | Mixed STU/Normative | Subscriptions redesign, improved workflow resources |
Official Specification
The authoritative FHIR specification is published by HL7 International at hl7.org/fhir. The US Core Implementation Guide, which defines FHIR profiles for US healthcare, is published at hl7.org/fhir/us/core. For SMART on FHIR authorization, see docs.smarthealthit.org.