Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Mass unsubscribe from space notifications in confluence

Bryan Collick August 4, 2016

I recently instituted confluence as the primary tool for documentation and collaboration at our company. To jumpstart usage, I created a couple dozen spaces for teams to develop. Somehow, that has turned into email notifications for virtually every edit in our confluence instance, which I do not want. 

 

I know that each email I receive has an unsubscribe link, and I also know that there is a (very long) list of page watches in my personal settings. I'm wondering if there's a better solution to unsubscribe from these hundreds of pages. I'm currently only subscribed to my personal space, so i see no other big levers to pull. 

4 answers

1 accepted

0 votes
Answer accepted
Jakub Pierzchała
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
August 7, 2016

Hi Bryan,

It is not possible to unwatch all pages with a single click out of the box. 

There is a free plugin-in however that allows to do so:

https://marketplace.atlassian.com/plugins/it.logontec.dev.watchremover/server/overview

0 votes
Anton Kulikov April 15, 2021

if you have scriptrunner

 

this code help me

import com.atlassian.confluence.mail.notification.NotificationManager
import com.atlassian.spring.container.ContainerManager
import com.atlassian.sal.api.component.ComponentLocator
import com.atlassian.confluence.pages.PageManager
import com.atlassian.confluence.search.service.ContentTypeEnum
import org.slf4j.Logger
import org.slf4j.LoggerFactory
import com.atlassian.confluence.user.UserAccessor
import com.atlassian.confluence.spaces.SpaceManager
import com.atlassian.user.UserManager 
Logger log = LoggerFactory.getLogger("console") 

def userManager = ComponentLocator.getComponent(UserManager)

NotificationManager nm = ( NotificationManager) ContainerManager.getComponent(
"notificationManager")
PageManager pageManager = ComponentLocator.getComponent(PageManager)
ContentTypeEnum ctp = ComponentLocator.getComponent(ContentTypeEnum)
UserAccessor userAccessor = ComponentLocator.getComponent(UserAccessor)
def spaceManager = ComponentLocator.getComponent(SpaceManager)
def users = userManager.users.find{it.getName() == "username"} 
def nfu = nm.getNotificationsByUser(userAccessor.getUserByName(users?.getName()))
nm.removeAllNotificationsForUser(userAccessor.getUserByName(users.getName()))
return  nm.getNotificationsByUser(userAccessor.getUserByName(users.getName()))
0 votes
veton June 13, 2018

Its not a solution yet, but rather a smarter workaround to clicking on every single "Stop Watching":

  1. Go to Profile > Watches (i.e. https://confluence.YourCompany.net/users/viewnotifications.action)
  2. Open browser Developer Tools (F12)
  3. Run this script:
    $('.link-stop-watching').click()
  4. Refresh the page and repeat until all watches are gone.
Bryan Collick September 11, 2018

clever!

Like Amal Edirisinghe likes this
Amal Edirisinghe March 22, 2020

This is worked for me. Thanks for sharing. 

0 votes
Jakub Pierzchała
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
August 4, 2016

Hi Bryan

You could go to your profile settings and unsubscribe from there (it is called watching).

More info here: https://confluence.atlassian.com/doc/watch-pages-spaces-and-blogs-139579.html

"Manage watches from your user profile" 

Bryan Collick August 5, 2016

Hi Jakub, Thanks for your answer!

 

I know there is a list of page watches in my profile settings; I said that in my original comment. I currently have a long list of hundreds of pages I'm somehow watching. Do I have to click "stop watching" for each one?

Bryan Collick August 5, 2016

Additionally, it seems like I'm getting added to pages that are being created. How do I stop that so that the list of pages I'm watching doesn't continue to grow?

Bryan Collick August 8, 2016

Thanks Jakub! If you want to convert your comment to an answer, I'll use it to answer this question. 

Jakub Pierzchała
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
August 9, 2016

Converted

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events