Introduction
The Notification Service module allows other modules to send notifications with dynamic content to users. A notification can either be an email or a push notification delivered by the web push mechanism. Notifications are then sent by submitting an Event that targets a event type and can optionally contain variable values for custom content.
Modules are able to setup notifications by creating Event Types and Subscriptions. Event Types define what the notification is about and contain a list of variables.
Subscriptions created are linked to a specific Event Type and define the notification type, subject, and content. They can also include filter criteria to determine when a notification should be sent. Variables defined in the Event Type can be referenced in the subject, content, and filters of a subscription.
Along with creating custom subscriptions, Notification Service also supports default subscriptions. A default subscription is a pre-configured subscription provided by module developers for all users across tenants, ensuring that users receive important notifications without needing to manually create subscriptions. Default subscriptions are customized by modules for specific event types, notification types, subjects, and content. They can also include filter criteria to control when notifications are sent. This feature simplifies the notification setup process and ensures consistent communication across the user base.
Users can view the list of all default subscriptions that apply to them and can activate or deactivate them accordingly. Default subscriptions are enabled by default for each user, and users cannot change the parameters of these subscriptions, only enable or disable them and modify the notification methods for their own use. On clicking Notification settings link in Portal header, user navigates to default subscription page. This page display the modules that are registered with NOISE along with the default subscriptions exposed by each module. The activation or deactivation of default subscriptions and modification of notifications methods for a subscription are reflected in the user’s notification settings. By default, all notification methods are enabled for the exposed default subscriptions unless specified by module otherwise. Besides these default subscriptions, it is still possible to add individual subscriptions as before. A flag indicating if the subscription is always-on, if set, prevents users from disabling the subscription in the notification settings UI.
While Event Types can only be created by other modules, users can also create and manage custom subscriptions and recipients via the UI. If the user is not logged in at least once, notifications cannot be sent as the user would not exist in the system. The user should either log in at least once or be manually created to be a MACMA user.
Module developers can create Event Types, custom and default Subscriptions, and Events via the module REST API as documented in the OpenAPI specification.
The target audience of this document are module developers who want to integrate their module with the Notification Service.