Workflow
Available since v. 1.53.X for Jira Administrators
Since v. 1.58.X:
get workflow transition/transitions by issueKey
added transitionScreenId and transitionStepId parameters
Get all workflow transitions
Method type: GET
URL:
{JIRA_URL}/rest/extender/1.0/workflow/transitions?workflowName={workflowName}
{JIRA_URL}/rest/extender/1.0/workflow/transitions?issueKey={issueKey}
{JIRA_URL}/rest/extender/1.0/workflow/transitions?issueId={issueId}
where
{workflowName} - workflow name
{issueKey} - issue key
{issueId} - issue ID
Parameters:
workflowMode - optional - draft, live or empty
Example URL:
{JIRA_URL}/rest/extender/1.0/workflow/transitions?workflowName=jira
{JIRA_URL}/rest/extender/1.0/workflow/transitions?workflowName=new_workflow&workflowMode=draft
{JIRA_URL}/rest/extender/1.0/workflow/transitions?issueKey=ABC-123
{JIRA_URL}/rest/extender/1.0/workflow/transitions?issueId=1234567
Response format: JSON
Example response:
{
"updateAuthorName": null,
"isSystemWorkflow": true,
"workflowName": "jira",
"isDraftWorkflow": false,
"updatedDate": null,
"workflowDescription": "The default Jira workflow",
"transitions": [
{
"sourceStatus": null,
"transitionScreenId": 12000,
"transitionStepId": 1,
"transitionId": 1,
"isLoop": false,
"destinationStatus": {
"statusId": "1",
"statusCategoryKey": "new",
"statusName": "Open"
},
"isInitialAction": true,
"transitionName": "Create Issue"
},
{
"sourceStatus": [
{
"statusId": "1",
"statusCategoryKey": "new",
"statusName": "Open"
},
{
"statusId": "3",
"statusCategoryKey": "indeterminate",
"statusName": "In Progress"
},
{
"statusId": "4",
"statusCategoryKey": "new",
"statusName": "Reopened"
}
],
"transitionId": 2,
"isLoop": false,
"destinationStatus": {
"statusId": "6",
"statusCategoryKey": "done",
"statusName": "Closed"
},
"transitionName": "Close Issue"
},
{
"sourceStatus": [
{
"statusId": "5",
"statusCategoryKey": "done",
"statusName": "Resolved"
},
{
"statusId": "6",
"statusCategoryKey": "done",
"statusName": "Closed"
}
],
"transitionId": 3,
"isLoop": false,
"destinationStatus": {
"statusId": "4",
"statusCategoryKey": "new",
"statusName": "Reopened"
},
"transitionName": "Reopen Issue"
},
{
"sourceStatus": [
{
"statusId": "1",
"statusCategoryKey": "new",
"statusName": "Open"
},
{
"statusId": "4",
"statusCategoryKey": "new",
"statusName": "Reopened"
}
],
"transitionId": 4,
"isLoop": false,
"destinationStatus": {
"statusId": "3",
"statusCategoryKey": "indeterminate",
"statusName": "In Progress"
},
"transitionName": "Start Progress"
},
{
"sourceStatus": [
{
"statusId": "1",
"statusCategoryKey": "new",
"statusName": "Open"
},
{
"statusId": "3",
"statusCategoryKey": "indeterminate",
"statusName": "In Progress"
},
{
"statusId": "4",
"statusCategoryKey": "new",
"statusName": "Reopened"
}
],
"transitionId": 5,
"isLoop": false,
"destinationStatus": {
"statusId": "5",
"statusCategoryKey": "done",
"statusName": "Resolved"
},
"transitionName": "Resolve Issue"
},
{
"sourceStatus": [
{
"statusId": "3",
"statusCategoryKey": "indeterminate",
"statusName": "In Progress"
}
],
"transitionId": 301,
"isLoop": false,
"destinationStatus": {
"statusId": "1",
"statusCategoryKey": "new",
"statusName": "Open"
},
"transitionName": "Stop Progress"
},
{
"sourceStatus": [
{
"statusId": "5",
"statusCategoryKey": "done",
"statusName": "Resolved"
}
],
"transitionId": 701,
"isLoop": false,
"destinationStatus": {
"statusId": "6",
"statusCategoryKey": "done",
"statusName": "Closed"
},
"transitionName": "Close Issue"
}
]
}
Â
Get transition informations
Method type: GET
URL:
{JIRA_URL}/rest/extender/1.0/workflow/transition/{transitionIdOrName}?workflowName={workflowName}
or
{JIRA_URL}/rest/extender/1.0/workflow/transition/{transitionIdOrName}?issueKey={issueKey}
where
{transitionIdOrName} - transition name or id
{workflowName} - workflow name
{issueKey} - issue key
Parameters:
workflowMode - optional - draft, live or empty
Example URL:
{JIRA_URL}/rest/extender/1.0/workflow/transition/111?workflowName=jira
{JIRA_URL}/rest/extender/1.0/workflow/transition/111?workflowName=test&workflowMode=draft
{JIRA_URL}/rest/extender/1.0/workflow/transition/111?issueKey=ABC-123
Response format: JSON
Example response:
{
"updateAuthorName": "admin",
"isSystemWorkflow": false,
"workflowName": "test",
"isDraftWorkflow": true,
"updatedDate": 1596047650224,
"workflowDescription": "process-management-workflow",
"transition": {
"sourceStatus": [
{
"statusId": "3",
"statusCategoryKey": "indeterminate",
"statusName": "In Progress"
}
],
"transitionId": 111,
"transitionScreenId": 12000,
"transitionStepId": 1,
"postFunctions": [
{
"class.name": "com.atlassian.jira.workflow.function.issue.UpdateIssueStatusFunction"
},
{
"class.name": "com.atlassian.jira.workflow.function.misc.CreateCommentFunction"
},
{
"class.name": "com.atlassian.jira.workflow.function.issue.GenerateChangeHistoryFunction"
},
{
"class.name": "com.atlassian.jira.workflow.function.issue.IssueReindexFunction"
},
{
"eventTypeId": "13",
"class.name": "com.atlassian.jira.workflow.function.event.FireIssueEventFunction"
}
],
"validators": [
{
"selectedCFs": "comment,assignee",
"validationMessage": "Example error",
"bindToFields": "yes",
"class.name": "com.itlab.jira.plugins.extender.workflows.validators.FieldRequired"
}
],
"metaAttributes": {
"jira.i18n.submit": "stopprogress.title",
"jira.description": "",
"jira.i18n.title": "stopprogress.title",
"jira.fieldscreen.id": "10000"
},
"isLoop": false,
"conditions": {
"type": "AND",
"conditions": [
{
"type": "OR",
"conditions": [
[
{
"class.name": "com.atlassian.jira.workflow.condition.AllowOnlyAssignee"
}
],
[
{
"class.name": "com.atlassian.jira.workflow.condition.AllowOnlyReporter"
}
]
]
},
{
"class.name": "com.itlab.jira.plugins.extender.workflows.conditions.HideTransition"
}
]
},
"destinationStatus": {
"statusId": "10003",
"statusCategoryKey": "done",
"statusName": "Cancelled"
},
"transitionName": "Stop progress"
}
}
Â