EHR.Network Notification Service – Unified REST APIs for multi-channel app notifications

Unified notification service provides REST APIs to add complex notification functionality into any healthcare application. It currently supports notifications via email, SMS and PUSH channels.

This service implements the functionality required for all the supported notification channels internally and provides a unified REST API interface for the applications. Because of this approach, applications that use this service do not have to implement clients for all the different notification channels they use. 

The service also includes an integrated scheduler feature that helps applications deliver advanced features such as repeat notifications, scheduled notifications, address lookups and personalized messages. The lookup functionality uses EHR.Network APIs to resolve IDs of platform entities such as Patient, Practitioner and Organization to deliver personalized messages.

Major features of the service

The notification service supports many advanced functionality that are required by modern applications. Below list covers the major features, but is not exhaustive.

  1. Channels – Email, SMS & PUSH
  2. Message scheduling options
    1. Immediate
    2. At specific instant(s) – Datetime, weekdays & times
    3. Repeated at specific intervals 
    4. Repeated at specific intervals till end time
    5. Repeated at specific intervals for specified cycles
  3. Multiple message cycles – Create multiple notification schedules for the same notification. The service will automatically process and deliver them at the scheduled times 
  4. Personalized messages for multiple recipients – Supports multiple recipients in the same notification. The service will processes and delivers personalized messages individually to all the recipients
  5. Priority messages – Supports fast track processing and reserved queue to help deliver priority messages faster
  6. Resolve recipient addresses at runtime – The UUIDs of platform entities such as Patient, Practitioner and Organisation are resolved to their email address & mobile number for message delivery
  7. Message personalization using variables in subject and message body – Supports variables in the message. These variables get resolved from EHR.Network and actual values will be added in their place in the outgoing messages to make them personalized
  8. Organization level gateways – Register and activate gateways for every channel Organizations can maintain multiple active gateways and appropriately use them when creating notifications
  9. Delivery failure tracking – Successful and failed messages are logged and tracked. Actionable reports generated from this data for administration and troubleshooting
  10. PUSH notification without appID – Workflow to help applications implement PUSH notifications using platform UUIDs instead of dynamic appIDs. So applications do not have to implement functionality to collect and manage appIDs of the client application instances
  11. Multiple template support for SMS – Supports multiple registered message templates for SMS. Ability to choose templates for each notification
  12. Free form email & PUSH notifications – Use flexible message formats for email & PUSH notifications
  13. Email attachments – Sending base64 encoded files as Email attachments 
  14. Feedback and reports – Variety of operational and diagnostic reports for end users to identify and rectify any message delivery problems.

Resources supported by the Notification Service

The notification service supports multiple resources that enable scheduling and delivery of notifications. Brief details are given below for reference.

Gateway resource

Gateway resource is used to manage the external message gateways that the service uses to deliver the notifications. At least one gateway should be configured before notifications can be scheduled for that channel. An organization can configure multiple gateways for one channel and specify which one to use while scheduling notifications.

Notification resource

Notification resource is used to schedule the actual notifications. This resource allows the scheduling of notifications to multiple recipients at the same time. 

This resource accepts several UUIDs from the EHR.Network platform as variables in the message subject, message body and as recipients. These UUIDs are resolved at runtime from EHR.Network and replaced appropriately(email/mobile in recipients & names in the body). 

The variablesList API to get the full list of supported variables.

For Notifications marked as “Urgent”, such lookups are not done to prevent any delays. Urgent messages also do not support attachments.

Message resource

Message resource keeps track of the outgoing notification messages for audit/reporting and trouble-shooting purposes. This resource also maintains the message delivery status. The message resources have a life of 60 days, after which they are automatically deleted by the service.

Use cases

  1. Singnup/onboarding workflows – Implement Patient and User signup workflows in conjunction with the User and Person APIs. Send OTPs by SMS and confirmation links by email
  2. Task reminders/followups – Implement application workflows to support Task management APIs. Send reminder and follow up messages by SMS/Email or PUSH. Schedule multiple reminders as per user preference
  3. Appointment confirmation/reminders – Support the appointment service APIs with confirmation requests and reminders. Send appointment confirmation and reminder messages by SMS/Email or PUSH. Schedule multiple reminders as per user preference
  4. Medication reminders – Send reminders to patients on their medications leveraging EHR APIs. Send medication reminders by SMS/PUSH
  5. Improved user security – Key actions such as password/email changes can be made more secure using OTPs

More about the Notification Service