Search Resources by Type
Search
Type-Level Search
Search within a specific resource type
GET
Search Resources by Type
Type-Level Search
Search for resources of a specific type using search parameters.The FHIR resource type to search (e.g.,
Patient, Observation, Encounter)Endpoint
GET Request
Search using query parameters:POST Request
Use POST for complex searches or when query string length is a concern:Search Parameters
Search parameters are resource-type specific. Common examples:Patient Search
name- Search by patient nameidentifier- Search by identifier (e.g.,identifier=http://example.org/mrn|12345)gender- Filter by gender (male,female,other,unknown)birthdate- Filter by birth date (supports prefixes:eq,gt,lt,ge,le)address- Search by addresstelecom- Search by contact information
Observation Search
patient- Filter by patient referencecode- Filter by observation codedate- Filter by observation datevalue-quantity- Filter by valuestatus- Filter by status
Common Parameters (All Types)
_id- Filter by resource ID_lastUpdated- Filter by last updated date_tag- Filter by tags_profile- Filter by profile_security- Filter by security labels_count- Maximum number of results_sort- Sort order_summary- Summary mode_total- Include total count
Examples
Search Patients by Name
Search Patients by Identifier
Search Observations for a Patient
Search with Date Range
Search with Multiple Parameters
Response
Success (200 OK)
Returns aBundle containing matching resources:
No Results
Returns an empty bundle if no resources match:Modifiers
Search parameters support modifiers::exact- Exact match:contains- Contains substring:text- Text search:above- Above in hierarchy:below- Below in hierarchy:not- Negation:in- Value in set:not-in- Value not in set
Example with Modifiers
Chaining
Chain searches through references:Reverse Chaining
Search resources that reference a specific resource:Notes
- Search parameters are case-sensitive
- Multiple values for the same parameter use AND logic
- Different parameters use AND logic
- Use
_includeand_revincludeto include related resources - Check the resource’s search parameters in the capability statement
Authorizations
Bearer token authentication
Path Parameters
The FHIR resource type (e.g., Patient, Observation, Encounter)
The logical ID of the resource
Query Parameters
Maximum number of results to return
Required range:
x >= 0Sort order (prefix with - for descending)
Summary mode
Available options:
true, text, data, count Include total count
Available options:
none, estimate, accurate Filter by last updated date
Response
Search results
A container for a collection of resources
Resource type
Available options:
Bundle Indicates the purpose of this bundle
Available options:
document, message, transaction, transaction-response, batch, batch-response, history, searchset, collection If search, the total number of matches
Links related to this Bundle
Entry in the bundle