Notifications
SeedDMS is designed to be used by many users at the same time, doing different things. Keeping track of all the changes and requests, e.g. to interact in a workflow, is hard to achieve. That’s where notifications can help. The request to approve a document, informing users about added documents or folder, or when documents where changed are such notifications. Some of those notification can explicitly be requested by each user, other are always send by the system.
Notifications used to be sent by email only for a long time, though the underlying function could use other protocols. A possible alternative will be introduced in this article.
Ntfy
Ntfy is a simple HTTP-based pub-sub notification service.
There are apps for Android, iOS and the desktop to receive (and send) messages
to a topic. Ntfy is open source and the server can be self hosted. Alternatively,
you can use the service at ntfy.sh
for free with a somewhat (but not very limiting)
restricted functionality.
The integration of ntfy in SeedDMS is implemented with an extensions called
ntfy_notification
.
Just download the zip file and
upload it in the extension manager of your SeedDMS installation. The extension
is still in its early developement and configuration is
currently rather simple:
- Set the ntfy server url to
https://ntfy.sh
(or your own server, if you have already setup one) - Choose a random key which is used to encrypt the topic names. Probably make a backup of it and keep it secret.
All other configuration parameters can be left untouched for now.
The extension will add a new menu item ‘Ntfy notification’ on the ‘My Account’ page. The new page contains some information on how to setup the ntfy app, output the user’s personal topic name, and a button to send a test notification. The topic name is a unique string which is currently deduced from the encryption key and the login name. Each user has one topic where all notifications are sent to. The user cannot set the topic name, but this will change when SeedDMS 6.1.x is released. Please keep in mind, that anybody knowing the topic name will be able to subscribe to it and read all notifications. So, keep it secret. There is currently no other authentication method, but this may change in the future as well.
As an admin you should be aware, that all topic names are deduced from the encryption key in the configuration. Changing the key will invalidate all topic names. So, choose a secure encryption key from the very beginning, before users start subscribing to the topics. This will change with SeedDMS 6.1.x when topic names can be set by the users themselves.
Once you installed the app for your mobile phone and subscribed to the topіc, it is about time to send a test notification. It should imediately show up on your phone.