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

About the condition that the email address cannot be obtained with the Users acquisition API of the

Y.Miura
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!
August 7, 2023

I want to run the Get Users in Organization REST API to get the account ID and email address of a user in my organization.
I would like to get at least the account ID and email address when executing the REST API, but the description of Responses → UserPage → data → email in the REST API manual below says "The email address of the user. If the user has restricted visibility of the email address, the property will be absent" https://developer.atlassian.com/cloud/admin/organization/rest/api-group-users/#api-v1-orgs-orgid-users-get

With the above REST API, I have confirmed that even a user whose email address is open to "only you and the admins" can get an email address, but under what conditions can't I get an email address?

1 answer

0 votes
David Bakkers
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.
October 20, 2023

Hello @Y.Miura 

"I have confirmed that even a user whose email address is open to "only you and the admins" can get an email address, but under what conditions can't I get an email address?"

It's a common misunderstanding as the documentation doesn't make it clear. That 'Share email address with only you and admins' setting is for users to shares their email address with the admins via THE GUI ONLY, it has no effect on sharing their email address with admins, or anyone else, via THE REST API.

To be able to lookup a user's email address via any REST API endpoint in Jira Cloud, that user must have 'Share email address with everybody' enabled.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events