Hi All,
In relation to below question : https://answers.atlassian.com/questions/83519/updating-an-issue-s-status-via-the-rest-api .
I have below question on the same. i.e
While doing transition using rest api mentioned in the link will the ID to be transformed be uniform across different projects under JIRA. i.e. For example will mappings like below provided be same for all JIRA Issues across all projects.
id 141 for Closed , id 131 for Accepted like that?.
Please share your thoughts on the same. Thanks
It depends.
The id of a transition is part of a workflow.
If your issues are configured to use the same workflow, then of course the transition will have the same ID, because it's the same workflow. If they're using different workflows, then no. (If you've copied workflows, similar transitions might have the same id, but you can not assume that - two workflows are likely to have different transition ids, even if they look pretty much the same)
Thank a lot for the answer. So first we have to identify possible transitions associated to an issue using API GET /rest/api/2/issue/{issueIdOrKey}/transitions and then make call to transition change API based on those ID values. Is my understanding correct?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Yes, you need to look up what is available, as the id is variable.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Nic,
Thanks for your help in understanding transition. One more clarification related to that I would like to inquire. Please share your thoughts on the same.
My Requirement is to update a Jira Issue (different project can exist) to the "Close" status via Rest API. i.e I want to implicitly change it's status to that of "Close" so that portal user will get to know that it is no longer needed to be worked up on.
But what I infer from your answer is that for each project they can define their own workflows and chances are there where they haven't configured a workflow equivalent to that of "Close".
Is my understanding correct? If so, is there a way we can know the transitions final workflow so that if "close" is not present I can set to that final workflow status.
Please let me know if my question is ambiguous to you. Thanks in advance.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Correct. You will need to read the workflow yourself to work out what the end states might be.
It's perfectly possible for a human to write a workflow that looks like "Badger -> Mushroom -> Snake". This example shows you a number of problems:
In short - you will need to read your workflows. You have to understand what you're coding for.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.