Forums

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

I cannot create issue via Jira Cloud REST API v2

dmitry_zolotnikov May 14, 2020

I use postman and python jira client. The same result in both cases

My request JSON body is the following:

I use this rest endpoint: https://<name>.atlassian.net/rest/api/2/issue

{
"fields": {
"project":
{
"key": "TJ"
},
"summary": "Jira Client Automation: Dummy summary",
"description": "Jira Client Automation: Dummy description",
"issuetype": {
"name": "Task"
}
}
}

 

I receive this:

{
"errorMessages": [],
"errors": {
"summary": "Field 'summary' 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."
}
}

 

I don't have permissions issue. Checked it several times by creating issues through UI manually. Api V3 also responds me the same

1 answer

0 votes
Nic Brough -Adaptavist-
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.
May 14, 2020

That error message either means

  • You don't have the right fields on the create screen
  • You are using an account that can log into Jira but does not have the right permissions to view and create issues in that project
dmitry_zolotnikov May 14, 2020

It's not the case.

Because i use my own account and it can create issues in UI. And i have mandatory fields which are Summary, Project and Issue Type. So they are being filled correctly programatically as well. Other ideas? 

 

Screenshot 2020-05-14 at 15.02.12.pngScreenshot 2020-05-14 at 15.02.03.png

Nic Brough -Adaptavist-
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.
May 14, 2020

Ok, so that sounds like your authentication is not doing what you think it is, and it's not logging in as you.

dmitry_zolotnikov May 14, 2020

Dear Nic,

maybe you will use some facts, but not assumptions in your comments? I use generated API token from user's panel in Jira Cloud UI. And i use trivial HTTP Basic auth mechanism. I can list available issues and projects for example

 

Thanks a lot

Nic Brough -Adaptavist-
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.
May 14, 2020

The facts are that the error message you are seeing is generated in the two cases I described.

dmitry_zolotnikov May 16, 2020

Is there any chance that my user's API token has different permissions than my personal account itself? Sounds weird, but who knows how Jira works behind the scene. This error message is really vague and too abstract hiding real root cause

dmitry_zolotnikov May 16, 2020

Also let's apply deduction method. i see  and i showed you already all that fields on the issue create UI screen. How to double check permissions issue probability? 

mika nokka February 3, 2022

I was getting the same "Statustext:Field 'Summary' cannot be set. It is not on the appropriate screen, or unknown" error when settind standar Summary and Desciption.

In my case problem was solved when used email  (not username) related to my user account when doing basic auth (and using Jira Cloud generated token)

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events