visit the hl7 website
Ontario Subscription HL7® FHIR® Implementation Guide -v1.0.0-ballot1
fhir-logo
  • Index
  • Home
    • Home
    • Introduction
    • Relationship to Other Specifications
    • Scope
    • Glossary
  • Business Context
    • Business Context
    • Business Model
    • Business Data
    • Use Cases
    • Business Rules
  • Technical Context
    • Technical Context
    • Implementer Responsibility
    • Conformance Rules
    • Connectivity Summary
  • FHIR Artifacts
    • FHIR Artifacts
    • Interactions
    • Operations
    • Profiles
    • Terminology
    • System URIs
    • Capability Statement
    • Custom Search Parameters
    • Response Handling
    • Downloads
  • Change Log
    • Change Log
    • Known Issues & Future Developments
    • Revision History
    1. Index
    2. FHIR Artifacts
    3. Operations
    4. Subscription status

For a full list of available versions, see the Directory of published versions

4.2.2. Subscription status


4.2.2.1. Scope

The Subscription $status operation is used to check the current health and state of an active subscription. This "health check" allows a Subscriber to monitor subscriptions and troubleshoot any delivery problems.


4.2.2.2. Interaction Sequence Diagram


4.2.2.3. Specification

This specification is based on the FHIR R5 Backport specification.

Read Subscription Status Request

Get [base]/Subscription/[id]/$status

where [id] is the logical id of the existing Subscription resource.

Read Subscription Status Response

The server returns a 200 OK HTTP status code.


4.2.2.4. Example Subscription Status Message

While this $status operation is defined in FHIR R5 for the Subscription resource, it has also been backported to FHIR R4, functioning in the exact same way.

Request Message

GET /fhir/SubscriptionStatus/{id}/$status
Host: example-fhir-server.com
Accept: application/fhir+json

Backport compliant Response message payload:

<Bundle xmlns="http://hl7.org/fhir">
  <id value="e13caf38-c856-461f-8374-6fe71248684c"/>
  <type value="searchset"/>
  <timestamp value="2020-04-17T10:24:13.1882432-05:00"/>

  <link>
    <relation value="self"/>
    <url value="http://example.org/FHIR/R4/Subscription/$status?subscription=123"/>
  </link>

  <entry>
    <fullUrl value="urn:uuid:815477f2-a94c-4197-a82a-9f974155debc"/>
    <resource>

      <!-- Backport-compliant replacement for SubscriptionStatus -->
      <Parameters>

        <!-- Subscription reference -->
        <parameter>
          <name value="subscription"/>
          <valueReference>
            <reference value="Subscription/123"/>
          </valueReference>
        </parameter>

        <!-- Status of the subscription -->
        <parameter>
          <name value="status"/>
          <valueCode value="active"/>
        </parameter>

        <!-- Backport equivalent of eventsSinceSubscriptionStart -->
        <parameter>
          <name value="events-since-subscription-start"/>
          <valueInteger value="310"/>
        </parameter>

        <!-- Backport equivalent of topic -->
        <parameter>
          <name value="topic"/>
          <valueUri value="http://example.org/FHIR/R5/SubscriptionTopic/admission"/>
        </parameter>

        <!-- Backport 'type' equivalent (query-status in R5 maps to this) -->
        <parameter>
          <name value="type"/>
          <valueCode value="query-status"/>
        </parameter>

      </Parameters>
    </resource>

    <search>
      <mode value="match"/>
    </search>
  </entry>
</Bundle>



4.2.2.5. Expected Bahaviour

4.2.2.6.

Case Scenario Description HTTP Status Code Response Payload
1 The request was successful, and the SubscriptionStatus resource is returned in the response body HTTP 200 OK Returns the Submission Status resource.
2 The submitted Subscription does not exist HTTP 404 Bad Request. Returns an OperationOutcome resource indicating an issue. The client must fix the request and try again.
3 Subsciprtion API cannot return a valid response due to internal issues. HTTP 500 Internal Server Error. Returns an OperationOutcome resource indicating an issue.

Please see the $status Operation Definition page from the R5 Subscriptions Backport for details on the $status operation used for the Ontario Health Subscriptions service.

Version: 1.0.0 FHIR Version: R4.0.1

Powered by SIMPLIFIER.NET

HL7® and FHIR® are the registered trademarks of Health Level Seven International