Using the JIRA 5.0.x remote API, is it possible to change the issue type of an existing issue?
I wasn't having any luck with the REST API issue update. It worked for some fields, but "issuetype" returns a 204 with reason "No Content", no error message, and the issue type doesn't actually update.
I tried a PUT on /rest/api/latest/KEY-1234 with this JSON message body, as the API docs suggest for updating other fields:
{"update": {"issuetype": [{"set": "Bug"}]}}
The API example doesn't actually work when I try it for their example of "labels" or "components" fields.
I haven't tried it, but I would suspect you need to use the issuetype id as indicated in http://docs.atlassian.com/jira/REST/latest/#id161572
I had already tried that, and tried it again. Same result. No error, no result payload, no change to the issue.
I try this
hostname/rest/api/2/issue/16591/editmeta
this returns
fields with possible values and operation
Example: for summary
[required] => 1
[schema] => stdClass Object ( [type] => string [system] => summary )
[name] => Summary
[operations] => Array ( [0] => set )
but for issuetype there was empty array in operation. Does this mean i cannot change issuetype for issue 16591? I can change issuetype from jira but why i cannot i change using api?
Hi, solution is here: https://jira.atlassian.com/browse/JRA-33927
Hi Team,
Try update an issue type without operations with the following steps:
{ "fields": { "summary": "something's wrong", "issuetype": {"id": "2"} } }
curl -D- -u admin:admin -X PUT --data @C:\change_issuetype.json -H "Content-Type: application/json" http://localhost:8616/rest/api/2/issue/DEMO-1
Reference from https://developer.atlassian.com/display/JIRADEV/JIRA+REST+API+Example+-+Edit+issues
If you hit into an error when change issue type via REST API, please raise a ticket to https://support.atlassian.com.
Hope this help.
Thanks.
Regards,John Chin
It looks like you're new here. Sign in or register to get started.