Very few FHIR servers implement Subscriptions. Azure is no exception. But Azure’s EventGrid does almost the same thing. Here’s how it works.
First, what does the Subscription resource in FHIR do?
It defines a notification from the FHIR server to another system when particular criteria are met — usually when a resource is updated in a certain way.
Where implemented, this notification is sent using a web-hook, web socket, or email.
As you can see, it’s more than just a data resource. It requires a lot of effort on the FHIR server side before it can work.
Hence the lack of uptake and implementation.
Azure has a system wide feature called EventGrid that notifies of changes to a wide variety of Platform services. Recently this feature was extended to cover FHIR and DICOM servers.
It works like this:
- You define an EventGrid Event
- You choose which FHIR resource triggers the Event
- You choose whether the trigger action taken on the resource is a Create, Update or Delete
- You specify a pre-built web-hook endpoint to receive the notification
The web-hook can be any endpoint that successfully recognizes the EventGrid handshake and is capable of receiving an EventGrid Event notification.
Here’s an example of what EventGrid sends to the receiving endpoint when an event is triggered.
More than enough information for the receiving system to take action.
Events can be set up manually in the Azure portal. Via code while an app is running. Or using Terraform as part of a setup script.
A single endpoint can listen for changes to multiple resources on one or more FHIR servers and take a host of different actions in response.
More about Azure FHIR Events: https://learn.microsoft.com/en-us/azure/healthcare-apis/events/events-overview
More about FHIR Subscriptions: http://hl7.org/fhir/R4/subscription.html
---
Sign up to “The Tuesday FHIR Sessions” and receive an email every Tuesday where I go deep on a single FHIR topic.