HI,
please, can someone help me with Python 3 code to extract from Jira the list of all users and their email addresses?
Code used:
import jira.client
from jira.client import JIRA
import urllib3
urllib3.disable_warnings()
jira = JIRA(options={'server':'https://jiraDOMAIN.com', 'verify':False}, basic_auth= ('name','password#'))
import requests
import json
url = "https://<jiraDomain<.com/rest/api/2/user/search?startAt=0&maxResults=1000"
headers = {
"Accept": "application/json",
"Bearer": "access token"
}
response = requests.request(
"GET",
url,
headers=headers,
verify=False
)
print(....)
The result that's needed:
User Email
name1 name1@email.com
name2 name2@email.com
etc
Thanks for any help!