Set Watcher Based on Asignee

Is it possible to automatically set a watcher based on ticket assignee?  I would like to automatically add the assignee's manager to every ticket to which they are assigned.

3 answers

You will need a scripted post-function to do that. My issue here is how do you determine the assignee's manager? If that won't be a problem, try different scripted post-functions for automatically setting Watchers based on a condition. There's a lot of them in the marketplace (Try the JIRA ScriptRunner).

If you find out how to do this I'd be interested in knowing your solution. Particularly how do you determine the manager for the current assignee.



To determine the manager of a user, we normally recommend the following strategy:

  • for users having a manager, story the manager's user name (or user key) as a user property in the user profile
  • if the manager infromation is available in Active Directory / LDAP, synchronize the user property from AD/LDAP so that you can manage the user-manager relation in AD/LDAP. There are add-ons offering this.
    If you do not have AD/LDAP, you can use JIRA REST API to automate setting managers in the user property. 
  • Once the manager's username is stored as a user property, you can use Script Runner to extract the property and add the user as a watcher.

Obviously a custom add-on is always a solution. This would include a manager admin UI and a post-function to add manager as watcher.

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Oct 09, 2018 in Jira Core

How to manage many similar workflows?

I have multiple projects that use variations of the same base workflow. The variations depend on the requirements of the project or issue type. The variations mostly come in the form of new statuses ...

224 views 6 0
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