I am trying to change the task status using REST API but getting below error
{
"errorMessages": [
"It seems that you have tried to perform a workflow operation (Canceled) that is not valid for the current state of this issue (TEST-5181). The likely cause is that somebody has changed the issue recently, please look at the issue history for details."
],
"errors": {}
}
POST Request was https://<domain>/rest/api/2/issue/TEST-5181/transitions
{
"transition": {
"id": "1111"
}
}
To make sure that i have available trsnsition for that task i did GET request https://<domain>/rest/api/2/issue/TEST-5181/transitions, I got below response which shows me that I should be able to change status to id=1111, which is canceled
{
"expand": "transitions",
"transitions": [
{
"id": "1111",
"name": "Canceled",
"to": {
"name": "Canceled",
"id": "11406",
"statusCategory": {
"id": 3,
"key": "done",
"colorName": "green",
"name": "Done"
}
}
},
{
"id": "981",
"name": "IRM Review",
"to": {
"name": "Review",
"id": "12900",
"statusCategory": {
"id": 2,
"key": "new",
"colorName": "blue-gray",
"name": "To Do"
}
}
}
]
}
@Avitesh KesharwaniCan you take a look at workflow, these kind of issues occur when workflow doesn't permit transition from current status to target status.
Easiest way to check is to check UI if this is allowed via UI or check current workflow diagram for issue type in project.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.