For a full list of available versions, see the Directory of published versions
The FHIR Heartbeat Interaction is a mechanism through which the Subscription Server notifies the Subscriber that the service is operational, even though no data is currently available in the queue.
The Subscription Server periodically sends a heartbeat notification (typically an empty or minimal payload) to the Subscriber’s notification endpoint.
The Subscriber is expected to respond with an HTTP 200 OK status, confirming that it is reachable and able to receive notifications.
If the Subscriber fails to respond within a defined timeout or after several retries, the Subscription Server may mark the subscription as inactive or error, depending on its configuration.
If the Subscriber stops receiving a hearbeat from Subscription Service, it needs to send SubscriptionStatus request to investigate the issue.
HeartBeat Request
The Subscription Server sends a heartbeat request to Subscriber's endpoint.
POST [base]/Subscription Endpoint,
HeartBeat Response
The Subscriber returns a 200 OK HTTP status code.
4.1.7.5.
Example Heartbeat Request
HTTP Method:
POST
Headers:
Content-Type: application/fhir+json
Address:
[base]/Subscription Endpoint
HTTP Body contains a HeartBeat Bundle Resource
{
"resourceType": "Bundle",
"type": "history",
"entry": [
{
"resource": {
"resourceType": "SubscriptionStatus",
"status": "active",
"type": "heartbeat",
"subscription": {
"reference": "Subscription/123"
},
"topic": "https://example.org/fhir/SubscriptionTopic/my-topic"
}
}
]
}
| Case | Scenario Description | HTTP Status Code | Response Payload |
|---|---|---|---|
| 1 | Subscriber successfully received the heartbeat notification. | HTTP 200 | Retrieved |
| 2 | Subscriber received not recognized. | HTTP 400 | Subscription not recognized. |