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

Next challenges

Recent achievements

  • Global
  • Personal

Recognition

  • Give kudos
  • Received
  • Given

Leaderboard

  • Global

Trophy case

Kudos (beta program)

Kudos logo

You've been invited into the Kudos (beta program) private group. Chat with others in the program, or give feedback to Atlassian.

View group

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

{"errorMessages":[],"errors":{"summary":"Field 'summary' cannot be set. It is not on the appropriate

After my organisation moved jira to cloud i cannot create stories through REST API 

I am running curl command 

curl -v \
-X POST \
-H 'Content-Type: application/json' \
--data '{
"fields": {
"project":
{
"key": "DWH"
},
"summary": "REST ye merry simon.",
"description": "Creating of an issue using project keys and issue type names using the REST API",
"issuetype": {
"name": "Story"
}
}
}' \
-x httpproxy.myorgproxy.com:8080 --proxy-user my@user:mypasswd\
-L https://jira.myprg.eficode.io/rest/api/2/issue/ \

I get following error message running curl command 

{"errorMessages":[],"errors":{"summary":"Field 'summary' cannot be set. It is not on the appropriate screen

I tried to analyze what happens when i create a issue through UI google chrome browser and noticed that it requested following url 

Request URL: https://jira.myorg.eficode.io/rest/quickedit/1.0/userpreferences/create

 

What could be the reason for this error. 

1 answer

0 votes
Dirk Ronsmans Community Leader Feb 15, 2021

Hi @Simon Jespersen ,

When you create an issue through the UI of the issue type Story, does the field "summary" actually appear on the screen?

That is what the error describes, for the issue type Story in project DWH you are trying to set the field "summary" but it appears it is not on the create screen.

Hi Dirk, Thanks for reply 

it seens to me thcreatestory.jpg

Hi Dirk, it seems to me that the summary and description field are there and are mandatory for creating a issue of type Story 

I have tried with Uppercase first letter in summary but i still get the same error. 

Dirk Ronsmans Community Leader Feb 15, 2021

I wonder if the call is just failing cause of some bad information.

Could you change the project part to use the id instead of the key.

"project": {
        "id": "10000"
         },

 

Where you change the id of course to the id of your project. Easiest way to get that is to open the project settings on your browser and check the url for the id.

i'm starting to think the key is not right as I can only find examples (in the documentation) with the project id.

https://developer.atlassian.com/cloud/jira/platform/rest/v2/api-group-issues/#api-rest-api-2-issue-post

Hi Dirk, my projects key is DWH 

this is a copy paste from the URL 

?rapidView=226&projectKey=DWH&view 

do you think it could be some permissions issues ? 

Dirk Ronsmans Community Leader Feb 15, 2021

If you are concerned about permissions you could look at the Permission Helper. That will tell you if something is missing/wrong.

https://support.atlassian.com/jira-cloud-administration/docs/use-the-jira-admin-helper/

Since you said you can create an issue manually (and I hope you tried with the same user) that would be weird tho.

 

For the project id could you go to your project settings and copy it from the url.

image.png

the number behind "pid=", and ofcourse change the json to use id  instead of key. (I just wanna make sure)

id managed to located the  by hover over the edit link in projekt administration PID 11202

i replaced it in the json 

curl -X POST \
-H 'Content-Type: application/json' \
--data '{
"fields": {
"project":
{
"key": "11202"
},
"summary": "REST ye merry simon.",
"description": "Creating of an issue using project keys and issue type names using the REST API",
"issuetype": {
"name": "Story"
}
}
}'

 

Now the error is 

{"errorMessages":[],"errors":{"project":"project is required"}}
Dirk Ronsmans Community Leader Feb 16, 2021

This 

"key": "11202"

should be

"id": "11202"

Tried that, it results in the same error i had to start with

 {"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."}

 This is very strange- 

Dirk Ronsmans Community Leader Feb 16, 2021

Well at least we now know that the project is found with key or id so that's something.

Did you try the permission helper that I mentioned with the user that you are using in your api call?

https://support.atlassian.com/jira-cloud-administration/docs/use-the-jira-admin-helper/

The main thing would be to check if the user has the "Create Issues" permission and the "Browse Project" permission. The permission helper will then tell you if something is missing.

i will try to get our jira Administrator to look into this, i  and have no rights on the jira administrator. 

Like Dirk Ronsmans likes this

Suggest an answer

Log in or Sign up to answer
TAGS
Community showcase
Posted in Jira Software

Presenting the "Best of 2020" Jira Software roundup!

Catch up with Atlassian Product Managers in our 2020 Demo Den round-up! From Advanced Roadmaps to Code in Jira to Next-Gen Workflows, check out the videos below to help up-level your work in the new ...

7,143 views 8 28
Join discussion

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you