Hi, I use Jira API to sync issues data on our systems.
I need the `emailAddress` field of assignee of a issue. But after research I see that this field is not returned because user privacy.
Admin user can view all users e-mail on Jira GUI, so API with the admin credentials can not see the e-mails of users?
There's a way to retrieve the email of users on Jira API?
I guess you are running into the GDPR changes from last year. In order to access the email address, you need to have an approved app. Please read the following article for more information: https://community.developer.atlassian.com/t/guidelines-for-requesting-access-to-email-address/27603
If your app is not approved or you're writing some custom scripts, then your users need to change the visibility of the email address to "public". I'm not sure if it's sufficient to have an admin user making the HTTP requests to see the emails.
There are various posts about the GDPR changes. See the following search on the Atlassian developer community for "GDPR weekly" where Atlassian provided all the changes in detail: https://community.developer.atlassian.com/search?q=weekly%20gdpr%20order%3Alatest
Hello @Gabriel Oliveira ,
If your trying to pull the email from the assignee field of an issue, I believe you should be able to do a "GET /rest/api/3/issue/{issueIdOrKey}" and expand by adding a "?fields=assignee" to see the email address for the assignee field of that issues.
Try in this format and let me know if this is what you're looking for:
curl -D- -u user:API_Token -X GET -H "X-Atlassian-Token: no-check" https://{base_url}.atlassian.net/rest/api/3/issue/{issueIDOrKey}?fields=assignee
Regards,
Earl
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.