Have you ever run a search query against the root of your FHIR server?
I didn’t know this was possible until recently, and on many FHIR servers it’s not possible at all.
Here’s an example of searching for all resources with an ID of “12345”, regardless of type:
https://server.fire.ly/?_id=12345&_format=json
It returns a Patient AND an Encounter, both with the same FHIR ID.
All FHIR resources inherit from the base Resource. That base resource contains the resource ID as well as the following common Meta elements:
- versionId
- lastUpdated
- source
- profile
- security
- tag
Many of these elements have their own “global” search parameters, just like “_id”.
Here’s the full list of resource level search parameters in R4. There are more in R5:
http://hl7.org/fhir/R4/resource.html#search
Is there a real world use case for these parameters?
The fact that many FHIR servers do not support any or all of them suggests not, and I have a hard time seeing a use case that would benefit an app that uses a FHIR server for its intended purpose.
But for troubleshooting a server I see many potential uses.
Give me all resources updated today:
https://server.fire.ly/?_lastUpdated=2024-07-11&_format=json
This might help me track down issues that came in today, affecting resource types I was unaware had been updated.
All resources with a specific “tag”:
https://server.fire.ly/?_tag=EX20US&_format=json
From an admin or data management perspective I see value here as it shows me resources connected to the same workflow or process.
I have no doubt that these are labor intensive queries, and that excessive use would lead to performance issues with the FHIR server.
But as a troubleshooting tool their value is real.
The example queries above work on Firely servers and on Microsoft Azure servers.
Do they work on your FHIR server? And can you think of real-world use cases where they might be valuable?
---
Download my “FHIR Architecture Decisions” book
FHIR Weekly
Join 1,100+ business and technical leaders.