Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Is there any way to find the inactive users and deactivate their account in Jira and Bitbucket

Mahesh Kumar
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
September 22, 2024

Is there any script or automation to find the inactive users and deactivate the accounts of unused users

3 answers

0 votes
Ed Letifov _TechTime - New Zealand_
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.
September 25, 2024

Hello, @Mahesh Kumar 

Install our app User Management for Jira into your Jira Cloud on a 30-days trial, connect to your Organisation with an API key, and you should able to find users who have not been active in Cloud in general, or in Jira specifically or in Bitbucket specifically and de-license them or suspend or deactivate.

Use our User Insights chart or go to Bulk User Actions to dig deeper with various filters.

Reach out to our 24x7 support if you have any questions via chat on the website or Service Desk.

0 votes
Mehmet A _Bloompeak_
Atlassian Partner
September 23, 2024

Hi @Mahesh Kumar ,

There is no direct way of doing this in Jira.

The solution provided by @shiva kumar Gosul lists the issues and then you can check the assignee columns to see the inactive users. However, it will not show the inactive users who are not assigned to any issue.

You need to fetch all users via below rest api and then filter the inactive ones. The rest api has pagination, it takes 50 users on each page. You need to modify the startAt parameter if you have more than 50 users.

/rest/api/3/users?startAt=1

 inactive user.png

Using rest api requires some coding. As an alternative you can try Manage Users for Jira Cloud app developed by our team.

With this app, you can periodically check your users' status and rights to make sure that product access is limited to those who still have a valid business purpose and they have access only to what they need.

You can;

  • List all users, search and sort them by name, active status, last activity time
  • Activate/deactivate users individually or in bulk
  • Grant/remove access individually or in bulk
  • Increase your security and manage your cost more effectively

Hope it helps.

shiva kumar Gosul
Contributor
September 25, 2024

Hi @Mehmet A _Bloompeak_ 

To optimize our process, we proactively identify inactive users with assigned issues and reassign them to active users. If you wish to specifically view inactive users, a simple query can provide the necessary information.

project level

project = "ABC" AND assignee in inactiveUsers()

Team level

IT Team = "XYZ" AND assignee in inactiveUsers()

 

 

Like Mehmet A _Bloompeak_ likes this
Mehmet A _Bloompeak_
Atlassian Partner
September 25, 2024

Hi @shiva kumar Gosul ,

Your approach is helpful for detecting issues assigned to inactive users. In your terminology inactive users are the ones that do not have access to Jira anymore. They were deactivated by the Jira admin via user management page.

I guess what @Mahesh Kumar  is asking different. He is looking for a way to detect users who haven't logged in to Jira for a long period of time(e.g in the last 90 days). So that, he can deactivate their accounts. In his terminology inactive users are the ones who did not logged in to the Jira for a long time.

shiva kumar Gosul
Contributor
September 27, 2024

Thanks @Mehmet A _Bloompeak_ thanks for clarifying. I don't think there is a way to figure to out. I too curious to know how that works

0 votes
shiva kumar Gosul
Contributor
September 23, 2024

@Mahesh Kumar 

There is a method to track inactive users in Jira. Please refer to the following JQL query. I've included statuses to help you easily identify open or in-progress issues assigned to inactive users.

assignee in inactiveUsers() and status not in (closed, Abandoned, Cancelled, Complete)

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
PERMISSIONS LEVEL
Product Admin
TAGS
AUG Leaders

Atlassian Community Events