Servicenow provides a good documentation page about User Notification Preferences.
Have you ever wondered where these settings are stored in the backend?
Let’s have a look at the main tables and fields where Servicenow stores this data.
Notification Preferences
Notification Preferences Popup | Backend Table / Field |
---|---|
Allow Notifications | User -> Notification [sys_user.notification] |
Notification Channel | Notification Device [cmn_notif_device] |
Notification by Category | Notification Category [sys_notification_category] |
Create Personal Notification | Notification Subscription [sys_notif_subscription] |
System Notification (individual check) | Notification Messages [cmn_notif_message] |
Allow notifications
Allow Notifications enables/disables all notifications for the user.
It is stored in the User record [sys_user], in the Notification field [notification] (this field is not displayed in the form out of the box).
Values: Enable / Disable
![Notification Preferences: Allow Notifications in Popup](https://rubenferrero.com/wp-content/uploads/2022/04/servicenow_notification_preferences_allow_popup.png)
![Notification Preferences: Allow Notifications in User Record](https://rubenferrero.com/wp-content/uploads/2022/04/servicenow_notification_preferences_allow_backend.png)
Notification Channels
Apart from the Primary email, you can add other ways of communication: Another Email account, Instant Message, SMS or Voice.
This information is stored in the Notification Devices table [cmn_notif_device].
![Notification Preferences: Manage Channels in Popup](https://rubenferrero.com/wp-content/uploads/2022/04/servicenow_notification_preferences_by_category_popup.png)
![Notification Preferences: Manage Channels in Notification Devices table](https://rubenferrero.com/wp-content/uploads/2022/04/servicenow_notification_preferences_by_category_backend.png)
Notification by Category
Notifications are grouped by Categories.
These Categories can be defined in the Notification Categories table [sys_notification_category].
Notifications [sysevent_email_action] are linked to this table through the Category [category] field.
![Notification Preferences: Manage Categories in Popup](https://rubenferrero.com/wp-content/uploads/2022/04/servicenow_notification_preferences_channels_popup.png)
![Notification Preferences: Manage Categories in Notification Categories table](https://rubenferrero.com/wp-content/uploads/2022/04/servicenow_notification_preferences_channels_backend.png)
Create Personal Notification
Notifications [sysevent_email_action] have a Subscribable field [subscribable].
When Subscribable is true, users can create a Personal Notification based on it.
Records linking the users to the Subscribable notifications are stored in the Notification Subscription table [sys_notif_subscription]
![Notification Preferences: Manage Personal Notifications in Popup](https://rubenferrero.com/wp-content/uploads/2022/04/servicenow_notification_preferences_personal_popup.png)
![Notification Preferences: Manage Personal Notifications in Notification Subscription table](https://rubenferrero.com/wp-content/uploads/2022/04/servicenow_notification_preferences_personal_backend.png)
System Notification
When a user unsubscribes from a particular notification, a new record is added to the Notification Messages table [cmn_notif_message] (or updated if it was already existing) with Filter [filter] = Unsubscribe
One record is generated for each Notification Channel.
A record is automatically added to this table when a user receives a notification for the first time, with the Filter field empty.
![Notification Preferences: Manage System Notifications in popup](https://rubenferrero.com/wp-content/uploads/2022/04/servicenow_notification_preferences_system_popup.png)
![Notification Preferences: Manage System Notifications in Notification Messages table](https://rubenferrero.com/wp-content/uploads/2022/04/servicenow_notification_preferences_system_backend.png)