Is there a way to un-watch multiple issues ?

Guys,

Any work around to un-watch or watch multiple issues ?

We can't edit watchers list via bulk edit.

Fyi, I use jira 4.4.1 and 4.4.5.

Thanks, Vishnu.

10 answers

1 accepted

This feature has now been added to the Bulk Issue capability in JIRA (>= 6.0).

See the Watch / Stop Watching section of this article: https://confluence.atlassian.com/display/JIRA/Modifying+Multiple+(Bulk)+Issues

You can use the Jira CLI.

The latest free version 2.6.0:
https://bobswift.atlassian.net/wiki/download/attachments/16285777/jira-cli-2.6.0-distribution.zip?api=v2

Use these actions:

Say <my-user> wants to unwatch all except project <interesting>. Adjust the "jira" batch file, then run this:

jira --action runFromIssueList --search "key in watchedIssues() and project!=&lt;interesting&gt;" 
  --common "--action removeWatchers --issue @issue@ --userId &lt;my-user&gt;"

Thanks! That CLI works great. Just as advertised!

And it *still* works well! :-) I've got 4058 issues in my watchedIssues() list, though, so I need the --limit option as well. Here's an example for people as unfamiliar with the CLI tools as I was a few weeks ago:

./atlassian-cli-3.8.0/atlassian.sh jira --action runFromIssueList --search 'key in watchedIssues() and category not in ("DevOps Projects", "IT Projects")' --limit 1000 --common "--action removeWatchers --issue @issue@ --userId mdiehn"

This is enabled in JIRA 6.0 and later. See Michael Villis's answer, below.

0 votes

Nope that is not possible at the moment. I have done this via database in the past!

No, but there is an issue for you to vote on: https://jira.atlassian.com/browse/JRA-2429

Thanks guys. I added my vote. But it's ideal for last 9 years :(

Through gadget we can add or remove watchers,

just you need to develop gadget to add or remove watchers to filter.

There are two userscripts that are supposed to do this:

JIRA Watch All Issues User Script for Greasemonkey

JIRA 5 Watch All Issues User Script for Greasemonkey

(Greasemonkey is a FF extension; Chrome runs user scripts natively).

Unfortunately none of them works for me (see Reviews tab there). Please try them and write if they work for you

This is enabled in JIRA 6.0 and later. See Michael Villis's answer, below.

Here's a quick Python script that will work as long as you have add/remove watcher rights on the project(s) you are trying to affect (or are just working on yourself).
It requires the Requests library (http://docs.python-requests.org/en/latest/) but since it runs through the REST API requires much lower access than CLI.
import json
import requests

WebSession = requests.Session()
WebSession.auth = ('username','password') #JIRA Credentials go here, Optionally use Base64 Encode/Decode

WebParams = {'jql':'watcher = currentUser()', 'fields':'key', 'maxResults':'9999'} #You can use basically any JIRA search query here in the JQL parameter

WatchList = WebSession.get('https://JIRA Root URL Here/rest/api/latest/search', params=WebParams) #Fill in your JIRA Root

WebParams = {'username': 'User'} #Insert User Name of watcher to delete here, probably yours

for k in WatchList.json()['issues']:
   print 'Removing Watcher ' + WebParams['username'] + ' from issue ' + k['key']
   WebSession.delete('https://JIRA Root URL Here/rest/api/latest/issue/'+k['key']+'/watchers', params=WebParams) #Fill in your JIRA Root

Here's a quick JavaScript for bulk stop watch (will not require any tools other then your browser):

https://gist.github.com/qvaqvaboo/1abbec8054b26dbdd4ae

Suggest an answer

Log in or Join to answer
Community showcase
Sarah Schuster
Posted Jan 29, 2018 in Jira

What are common themes you've seen across successful & failed Jira Software implementations?

Hey everyone! My name is Sarah Schuster, and I'm a Customer Success Manager in Atlassian specializing in Jira Software Cloud. Over the next few weeks I will be posting discussion topics (8 total) to ...

3,156 views 13 19
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you
Atlassian Team Tour

Join us on the Team Tour

We're bringing product updates and pro tips on teamwork to ten cities around the world.

Save your spot