The find users endpoint - https://developer.atlassian.com/cloud/jira/platform/rest/v3/#api-rest-api-3-user-search-get, only returns the list of active users. Do I need to pass a parameter so that it returns disabled users too?
Hello @Nitin Patel ,
I'd just like to inform that JRACLOUD-74331 has been fixed.
I am now marking this thread as resolved.
Cheers,
Dario
Hello @Nitin Patel ,
I you want to also get the inactive users, you should call the endpoint to Get all users instead:
Get all users
GET /rest/api/3/users/search
Returns a list of all (active and inactive) users.
Please test this and let me know if it works as expected.
Cheers,
Dario
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Dario B
this endpoint does not return the `emailAddress` field while the /user/search API does. Is there a way to have both the things? We want to fetch all users (active and inactive) along with their emailAddresses.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Nitin Patel ,
This could actually be related to the changes to our products and APIs to improve user privacy in accordance with the European General Data Protection Regulation (GDPR). For details please see:
As mentioned in above page, the email address will be returned or not depending on the user's Profile Visibility Settings (for the most of the REST API user related endpoints) and it can be the case that either this is still under development or they decided not to include the email address for the Get all users endpoint.
I am currently discussing this behavior with DEV I will update this thread in the next days.
Cheers,
Dario
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello @Nitin Patel ,
I have created the below bug ticket to either have a consistent behavior among the user related REST API endpoints or have explicitly documented why the ones to get all users are not returning the emailAddress field:
Please vote for the above bug ticket and set yourself as a watcher so that you will be notified in case of any update/progress. The bug will be addressed according to the Atlassian Cloud bug fixing policy.
In the meanwhile, as a workaround, you can use the one I added to the bug ticket:
Workaround
If you want to get the list of all the users, active and inactive for your instance including the email address you can use the Export Users button on the top left of the User Management page for your site:
This way you can configure what will be included and what not and you will get in return a CSV file including email address, account ID and other useful data that can be easily parsed.
I hope this helps.
Cheers,
Dario
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
To add more details:
This bug is affected by the email visibility setting on your instance:
- Jira Settings > System > General Configuration > User email visibility
If this is set to "Show to logged in users only" (which is the default), then this endpoint does not return the email addresses at all (that's a bug, visible email addresses should be returned)
However, if you change this setting to "public", then email addresses are returned, but if the person's email visibility is set to "public" then this would cause their email address to be returned even for anonymous requests, which may not be desirable.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hey,
The workaround won't help us as we manage our customers' jira account via API tokens only and we don't have access to their jira account.
Is there a timeline on when this bug will be fixed? It is important to us and currently, we're not able to do that.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello @Nitin Patel ,
There is no ETA for this bug yet.
As already written the only 2 possible ways to proceed at the moment are to ask the site-admin of the Jira instance to either:
Please follow the bug ticket for updates.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.