Are you in the loop? Keep up with the latest by making sure you're subscribed to Community Announcements. Just click Watch and select Articles.

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

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Can we create a change request using python script with a free jira account

Rahul Kumar Mishra
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!
Oct 19, 2023
import requests
import json
from jira import JIRA
from jira.client import JIRA

# Jira server and credentials
user = 'xxx'
password = 'xxx'



issue_dict = {
        'project': {'key': 'CHAN'},
        'summary': 'Need Approval for request' ,
        'description' : 'description_str',
        'issuetype': {'name': '[System] Change'}
        }
options={'server': jira_server}        
auth_jira = JIRA(options ,basic_auth=(user , password))
new_issue = auth_jira.create_issue(fields= issue_dict)              


print("ooooooooooooooo" , new_issue)



error I am getting is:

raise JIRAError(
jira.exceptions.JIRAError: JiraError HTTP 401 url: https://topop.atlassian.net/rest/api/2/issue
text: You do not have permission to create issues in this project.

response headers = {'Date': 'Thu, 19 Oct 2023 07:34:27 GMT', 'Content-Type': 'application/json;charset=UTF-8', 'Server': 'AtlassianEdge', 'Timing-Allow-Origin': '*', 'X-Arequestid': 'f810258e9763ec1338b0ff493dd32c52', 'X-Seraph-Loginreason': 'AUTHENTICATED_FAILED', 'Cache-Control': 'no-cache, no-store, no-transform', 'Www-Authenticate': 'OAuth realm="https%3A%2F%2Ftopop.atlassian.net"', 'X-Content-Type-Options': 'nosniff', 'X-Xss-Protection': '1; mode=block', 'Atl-Traceid': '8a41ea636c5ebb9c', 'Report-To': '{"endpoints": [{"url":
"https://dz8aopenkvv6s.cloudfront.net"}], "group": "endpoint-1", "include_subdomains": true, "max_age": 600}', 'Nel': '{"failure_fraction": 0.001, "include_subdomains": true, "max_age": 600, "report_to": "endpoint-1"}', 'Strict-Transport-Security': 'max-age=63072000; includeSubDomains; preload', 'Transfer-Encoding': 'chunked'}
response text = {"errorMessages":["You do not have permission to create issues in this project."],"errors":{}}



0 answers

Suggest an answer

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

Atlassian Community Events