While creating an issue using REST API unable to set issue Status value "In progress"

Dnyaneshwar Borase April 14, 2023

Hi Team,

I am using REST API to create the issue in Jira and I am able to set all the system field and custom field.

Expect I am unable to set the status field and got an error is in attached image.

Also, when I am creating the issue manually, I am not getting that "Status" field on screen while creating an issue.

 

Status not updated.jpg

 

 

Can you please help us how we can fix this issue?

Please find attached screenshot for your reference.

Regards,

Dnyaneshwar Borase

1 answer

0 votes
Andy Heinzer
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
April 19, 2023

Hi,

When you create an issue in Jira, you are not expected to be able to set the status of that issue. Nor can you simply edit the status field like other issue fields.  Instead the status is expected to be changed by calling a transition.  That transition will change the issue into another status.

As such you should be calling the endpoint POST /rest/api/3/issue/{issueIdOrKey}/transitions to change the status of the issue.  Within that payload should be an element such as

 "transition": { "id": "5" }

Where 5 is the id value of the transition name (which is sometimes the same as the status to transition to, but not always).  You might need to refer to the workflow that issue is in to better understand the correct transition to call.  Try GET /rest/api/3/issue/{issueIdOrKey}/transitions to see what is available to that issue in the present state.

I hope that helps.

Andy

Suggest an answer

Log in or Sign up to answer