CURL script unable to create JIRA ticket form Bamboo 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.
March 14, 2024

Hi Team,

I am using below CURL to create JIRA ticket and executing this from BMABOO task. but, it gives error. 

curl -H "Authorization: Bearer 3MDgyNTkyNDg4OvlA8+ZZx2sJona6C" -X POST --data "{\"fields\":{\"project\": {\"key\": \"HELLOWS\" }, \"summary\": \"${bamboo.planName} - ${bamboo.buildNumber}\", \"customfield_11601\": \"${bamboo.planKey}-${bamboo.buildNumber}\", \"customfield_11600\": \"${bamboo.proj.pom.releaseVersion}\n\", \"description\": \"Link to the build:\n${bamboo.resultsUrl}\n Link to UAT Deployment logs:\n https://bamboo/browse/RT-HELLOWSUAT/deployments \n Link to PROD Deployment logs:\n https://bamboo/browse/RT-HELLOWSPROD/deployments \n \",\"issuetype\": {\"name\": \"Task\"}}}" -H "Content-Type: application/json" -k https://jira-uat.com/rest/api/2/issue/

 

Error: 

{"errorMessages":[],"errors":{"summary":"Field 'summary' cannot be set. It is not on the appropriate screen, or unknown.","customfield_11601":"Field 'customfield_11601' cannot be set. It is not on the appropriate screen, or unknown.","customfield_11600":"Field 'customfield_11600' cannot be set. It is not on the appropriate screen, or unknown.","description":"Field 'description' cannot be set. It is not on the appropriate screen, or unknown."}}

 

Note: I have Jira-admin level permissions and I have added all those 11600 and 11601 these custom  fields are already context was set . 

 

 

Please  help me how to resolve this issue on Data center 9.12.x  am using.

0 answers

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events