FHIR Candler4Subscriptions RI Tour
  1. 1

    Intro

  2. 2

    Choose Topic

    Select a subscription topic

  3. 3

    Configure Subscription

    Set details for the subscription

  4. 4

    Select Filters

    Set criteria for triggering

  5. 5

    Request Subscription

    Create the resource on the server

  6. 6

    Server Handshake

    Server tests endpoint

  7. 7

    Trigger Notification

  8. 8

    Review Notifications

  9. 9

    Clean Up

This page contains a tour of topic-based subscriptions in FHIR R4.

In FHIR R4, topics are discovered by looking at the server CapabilityStatement for the SubscriptionTopic Canonical Extension.

For this walkthrough, we will be using the included encounter-complete topic that has a canonical URL of http://example.org/FHIR/SubscriptionTopic/encounter-complete. The current metadata for this server can be viewed here, or requested (in FHIR) at https://subscriptions.argo.run/fhir/r4/metadata.

Note that in FHIR R4, there is not an official required format for representing SubscriptionTopic resources. Since topics are canonical resources, the expectation is that they will be defined by authors (e.g., in Implementation Guides) and communicated out-of-band. For example, for an "encounter-start" topic, both the server and client can function with only the canonical URL and the understanding of what that topic represents.

With that said, one possible way of representing topics in FHIR R4 is to use the model provided in FHIR R5, ported using FHIR cross-version support. This implementation supports topics defined via that mechanism. Our included encounter-complete topic is thus available on this server at Basic/encounter-complete or in FHIR at https://subscriptions.argo.run/fhir/r4/Basic/encounter-complete.

Click next to select the encounter-complete topic.

In this step, we are configuration the subscription options.

The following options are fixed for this walkthrough and are displayed only for reference:
Email FHIR Message REST Hook (http/s POST) Websocket Zulip

The following options are configurable in this walkthrough:

MIME Type to use for notifications:

FHIR JSON FHIR XML

Amount of data to include in notifications:

Empty IDs Only Full Resources

The final piece of configuration for a subscription are filter values. In this tour, we will be using Patient/example as a patient filter for our topic. Note that allowed filters are defined by each topic.

With our configuration complete, we are ready to create our resource and request it on the server.

POST Subscription

Waiting for handshake.

The topic we are using is set to trigger when an Encounter is set to the status of finished. This can be true either when the encounter resource is created, or it could be updated from another state.

Since we specified the filter that encounters need to have a patient that matches Patient/example, we need to also set the subject reference to that patient.

For simplicity during this walkthrough, we will create an encounter with all the values needed to trigger a notification.

POST Encounter

Waiting for notifications...

That completes this tour. If you have any questions, comments, or suggestions for this software, please let us know. A link to the GitHub repository for this project can be found on the top right corner of the screen.

Please click the button below to remove the resources created during this session. Thank you!

Done!
Next
An unhandled error has occurred. Reload 🗙