Notification of users even if not tagged.
Do you guys have the functionality for the following?
Currently I surface several threads in a single document. However I also want the document's
owner to be notified if anyone comments in their document. Do you have a code example of this?
The use-case is it's a fallback if people forget to `@` the owner.
Thanks!
Yes indeed! When you create the thread, you can pass the addSubscribers property to set a list of users that should be subscribed to the thread at creation time, and they'll receive notifications about every message in that thread (including the first one).
If you're creating these threads via the API, just pass addSubscribers to your creation request.
If these threads are created implicitly by sending a first message (such as with a Composer or Thread component), you can provide a beforeMessageCreate function to your Cord SDK initialization to add it. (With our new beta components, this is even easier, you can supply it directly to the Composer or Thread component.) You can see an example of both approaches in our Clack repo.