Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

JIRA REST API is creating issue but gives permission error form BMABOO task

Devendar Gangapuram
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.
June 3, 2024

Hi Team,

I have a strange behavior with my JIRA issue access from BMABOO task logs. We are using  CURL script to create a JIRA ticket based on the every new build in BMABOO. 

 

PROEJCT-XYZ:
curl -D- -u abc:def -X POST --data "{\"fields\":{\"project\": {\"key\": \"xyz\" }, \"summary\": \"${bamboo.planName} - ${bamboo.buildNumber}\", \"customfield_10701\": \"${bamboo.planKey}-${bamboo.buildNumber}\", \"customfield_10500\": \"${bamboo.proj.build.releaseVersion} \n\", \"description\": \"Link to the build:\n${bamboo.resultsUrl}\n Link to UAT Deployment logs:\n https://1.2.3.4/browse/CNSY-COMUAT/deployments \n Link to PROD Deployment logs:\n https://1.2.3.4/browse/CNSY-COMPROD/deployments \n \",\"issuetype\": {\"name\": \"Task\"}}}" -H "Content-Type: application/json" -k https://2.4.5.7:443/rest/api/2/issue/

For this project XYZ is, it is  creating ticket form BAMBOO task successful and we can access it fine. But coming to below CURL for project PQR , it is creating ticket but when trying to access the ticket from BAMBOO link (https://1.2.3.4/rest/api/2/issue/33827) gives "you do not have permission to see this issue" error , where both Jira project have same set of users and set of permissions added already, same user able to access ticket from BAMBOO logs link  (https://1.2.3.4/rest/api/2/issue/33827 )

 

PROEJCT-PQR:
curl -D- -u abc:def -X POST --data "{\"fields\":{\"project\": {\"key\": \"pqr\" }, \"summary\": \"${bamboo.planName} - ${bamboo.buildNumber}\", \"customfield_10701\": \"${bamboo.planKey}-${bamboo.buildNumber}\", \"customfield_10500\": \"${bamboo.proj.build.releaseVersion} \n\", \"description\": \"Link to the build:\n${bamboo.resultsUrl}\n Link to UAT Deployment logs:\n https://1.2.3.4/browse/CNSY-PQRUAT/deployments \n Link to PROD Deployment logs:\n https://1.2.3.4/browse/CNSY-PQRPROD/deployments \n \",\"issuetype\": {\"name\": \"Task\"}}}" -H "Content-Type: application/json" -k https://2.4.5.7:443/rest/api/2/issue/

 

Below is the error when we try to access JIRA ticket form the BAMBOO logs 

error message;_

{"id":"33827","key":"pqr-2","self":"
https://1.2.3.4/rest/api/2/issue/33827"}

 

 

JIRA-Error-message.PNG

Please help me how to get rid of this permissions issue , where the user has all the possible permissions, and for other projects we could access the JIRA ticket form the BAMBOO logs link which generates after the CURL script is executed. 

 

Note: Please ignore all IP/host names, we have pasted randomly due to security issues. 

 

 

 

Thanks,

Dev G

 

0 answers

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
SERVER
VERSION
8.20.12
PRODUCT PLAN
STANDARD
TAGS
AUG Leaders

Atlassian Community Events