Get available workflow capabilities
GET
/rest/api/3/workflows/capabilities
Workflows
Validators
Permission validator
"ruleKey": "system:check-permission-validator",
"parameters": {
"permissionKey": "ADMINISTER_PROJECTS"
}
}
permissionKey
The permission required to perform the transition. Allowed values: built-in Jira permissions.Parent or child blocking validator
"ruleKey" : "system:parent-or-child-blocking-validator"
"parameters" : {
"blocker" : "PARENT"
"statusIds" : "1,2,3"
}
}
blocker
currently only supports PARENT
.statusIds
a comma-separated list of status IDs.Previous status validator
"ruleKey": "system:previous-status-validator",
"parameters": {
"previousStatusIds": "10014",
"mostRecentStatusOnly": "true"
}
}
previousStatusIds
a comma-separated list of status IDs, currently only support one ID.mostRecentStatusOnly
when true
only considers the most recent status for the condition evaluation. Allowed values: true
, false
.Validate a field value
Field required
"ruleKey": "system:validate-field-value",
"parameters": {
"ruleType": "fieldRequired",
"fieldsRequired": "assignee",
"ignoreContext": "true",
"errorMessage": "An assignee must be set!"
}
}
fieldsRequired
the ID of the field that is required. For a custom field, it would look like customfield_123
.ignoreContext
controls the impact of context settings on field validation. When set to true
, the validator doesn't check a required field if its context isn't configured for the current issue. When set to false
, the validator requires a field even if its context is invalid. Allowed values: true
, false
.errorMessage
is the error message to display if the user does not provide a value during the transition. A default error message will be shown if you don't provide one (Optional).Field changed
"ruleKey": "system:validate-field-value",
"parameters": {
"ruleType": "fieldChanged",
"groupsExemptFromValidation": "6862ac20-8672-4f68-896d-4854f5efb79e",
"fieldKey": "versions",
"errorMessage": "Affect versions must be modified before transition"
}
}
groupsExemptFromValidation
a comma-separated list of group IDs to be exempt from the validation.fieldKey
the ID of the field that has changed. For a custom field, it would look like customfield_123
.errorMessage
the error message to display if the user does not provide a value during the transition. A default error message will be shown if you don't provide one (Optional).Field has a single value
"ruleKey": "system:validate-field-value",
"parameters": {
"ruleType": "fieldHasSingleValue",
"fieldKey": "created",
"excludeSubtasks": "true"
}
}
fieldKey
the ID of the field to validate. For a custom field, it would look like customfield_123
.excludeSubtasks
Option to exclude values copied from sub-tasks. Allowed values: true
, false
.Field matches regular expression
"ruleKey": "system:validate-field-value",
"parameters": {
"ruleType": "fieldMatchesRegularExpression",
"regexp": "[0-9]{4}",
"fieldKey": "description"
}
}
regexp
the regular expression used to validate the field’s content.fieldKey
the ID of the field to validate. For a custom field, it would look like customfield_123
.Date field comparison
"ruleKey": "system:validate-field-value",
"parameters": {
"ruleType": "dateFieldComparison",
"date1FieldKey": "duedate",
"date2FieldKey": "customfield_10054",
"includeTime": "true",
"conditionSelected": ">="
}
}
date1FieldKey
the ID of the first field to compare. For a custom field, it would look like customfield_123
.date2FieldKey
the ID of the second field to compare. For a custom field, it would look like customfield_123
.includeTime
if true
, compares both date and time. Allowed values: true
, false
.conditionSelected
the condition to compare with. Allowed values: >
, >=
, =
, <=
, <
, !=
.Date range comparison
"ruleKey": "system:validate-field-value",
"parameters": {
"ruleType": "windowDateComparison",
"date1FieldKey": "customfield_10009",
"date2FieldKey": "customfield_10054",
"numberOfDays": "3"
}
}
date1FieldKey
the ID of the first field to compare. For a custom field, it would look like customfield_123
.date2FieldKey
the ID of the second field to compare. For a custom field, it would look like customfield_123
.numberOfDays
maximum number of days past the reference date (date2FieldKey
) to pass validation.Proforma: Forms attached validator
"ruleKey" : "system:proforma-forms-attached"
"parameters" : {}
}
Proforma: Forms submitted validator
"ruleKey" : "system:proforma-forms-submitted"
"parameters" : {}
}
Conditions
Check field value
"ruleKey": "system:check-field-value",
"parameters": {
"fieldId": "description",
"fieldValue": "["Done"]",
"comparator": "=",
"comparisonType": "STRING"
}
}
fieldId
The ID of the field to check the value of. For non-system fields, it will look like customfield_123
. Note: fieldId
is used interchangeably with the idea of fieldKey
here, they refer to the same field.fieldValue
the list of values to check against the field’s value.comparator
The comparison logic. Allowed values: >
, >=
, =
, <=
, <
, !=
.comparisonType
The type of data being compared. Allowed values: STRING
, NUMBER
, DATE
, DATE_WITHOUT_TIME
, OPTIONID
.Restrict issue transition
true
if any of the following criteria is met."ruleKey": "system:restrict-issue-transition",
"parameters": {
"accountIds": "allow-reporter,5e68ac137d64450d01a77fa0",
"roleIds": "10002,10004",
"groupIds": "703ff44a-7dc8-4f4b-9aa6-a65bf3574fa4",
"permissionKeys": "ADMINISTER_PROJECTS",
"groupCustomFields": "customfield_10028",
"allowUserCustomFields": "customfield_10072,customfield_10144,customfield_10007",
"denyUserCustomFields": "customfield_10107"
}
}
accountIds
a comma-separated list of the user account IDs. It also allows generic values like: allow-assignee
, allow-reporter
, and accountIds
Note: This is only supported in team-managed projectsroleIds
a comma-separated list of role IDs.groupIds
a comma-separated list of group IDs.permissionKeys
a comma-separated list of permission keys. Allowed values: built-in Jira permissions.groupCustomFields
a comma-separated list of group custom field IDs.allowUserCustomFields
a comma-separated list of user custom field IDs to allow for issue transition.denyUserCustomFields
a comma-separated list of user custom field IDs to deny for issue transition.Previous status condition
"ruleKey" : "system:previous-status-condition"
"parameters" : {
"previousStatusIds" : "10004",
"not": "true",
"mostRecentStatusOnly" : "true",
"includeCurrentStatus": "true",
"ignoreLoopTransitions": "true"
}
}
previousStatusIds
a comma-separated list of status IDs, current only support one ID.not
indicates if the condition should be reversed. When true
it checks that the issue has not been in the selected statuses. Allowed values: true
, false
.mostRecentStatusOnly
when true only considers the most recent status for the condition evaluation. Allowed values: true
, false
.includeCurrentStatus
includes the current status when evaluating if the issue has been through the selected statuses. Allowed values: true
, false
.ignoreLoopTransitions
ignore loop transitions. Allowed values: true
, false
.Parent or child blocking condition
"ruleKey" : "system:parent-or-child-blocking-condition"
"parameters" : {
"blocker" : "CHILD",
"statusIds" : "1,2,3"
}
}
blocker
currently only supports CHILD
.statusIds
a comma-separated list of status IDs.Separation of duties
"ruleKey": "system:separation-of-duties",
"parameters": {
"fromStatusId": "10161",
"toStatusId": "10160"
}
}
fromStatusId
represents the status ID from which the issue is transitioning. It ensures that the user performing the current transition has not performed any actions when the issue was in the specified status.toStatusId
represents the status ID to which the issue is transitioning. It ensures that the user performing the current transition is not the same user who has previously transitioned the issue.Restrict transitions
"ruleKey": "system:restrict-from-all-users",
"parameters": {
"restrictMode": "users"
}
}
restrictMode
restricts the issue transition including/excluding APIs. Allowed values: "users"
, "usersAndAPI"
.Jira Service Management block until approved
"ruleKey": "system:jsd-approvals-block-until-approved",
"parameters": {
"approvalConfigurationJson": "{"statusExternalUuid...}"
}
}
approvalConfigurationJson
a stringified JSON holding the Jira Service Management approval configuration.Jira Service Management block until rejected
"ruleKey": "system:jsd-approvals-block-until-rejected",
"parameters": {
"approvalConfigurationJson": "{"statusExternalUuid...}"
}
}
approvalConfigurationJson
a stringified JSON holding the Jira Service Management approval configuration.Block in progress approval
"ruleKey": "system:block-in-progress-approval",
"parameters": {}
}
Post functions
Change assignee
"ruleKey": "system:change-assignee",
"parameters": {
"type": "to-selected-user",
"accountId": "example-account-id"
}
}
type
the parameter used to determine the new assignee. Allowed values: to-selected-user
, to-unassigned
, to-current-user
, to-current-user
, to-default-user
, to-default-user
accountId
the account ID of the user to assign the issue to. This parameter is required only when the type is "to-selected-user"
.Copy field value
"ruleKey": "system:copy-value-from-other-field",
"parameters": {
"sourceFieldKey": "description",
"targetFieldKey": "components",
"issueSource": "SAME"
}
}
sourceFieldKey
the field key to copy from. For a custom field, it would look like customfield_123
targetFieldKey
the field key to copy to. For a custom field, it would look like customfield_123
issueSource
SAME
or PARENT
. Defaults to SAME
if no value is provided.Update field
"ruleKey": "system:update-field",
"parameters": {
"field": "customfield_10056",
"value": "asdf",
"mode": "append"
}
}
field
the ID of the field to update. For a custom field, it would look like customfield_123
value
the value to update the field with.mode
append
or replace
. Determines if a value will be appended to the current value, or if the current value will be replaced.Trigger webhook
"ruleKey": "system:trigger-webhook",
"parameters": {
"webhookId": "1"
}
}
webhookId
the ID of the webhook.Screen
Remind people to update fields
"ruleKey": "system:remind-people-to-update-fields",
"params": {
"remindingFieldIds": "assignee,customfield_10025",
"remindingMessage": "The message",
"remindingAlwaysAsk": "true"
}
}
remindingFieldIds
a comma-separated list of field IDs. Note: fieldId
is used interchangeably with the idea of fieldKey
here, they refer to the same field.remindingMessage
the message to display when prompting the users to update the fields.remindingAlwaysAsk
always remind to update fields. Allowed values: true
, false
.Shared transition screen
"ruleKey": "system:transition-screen",
"params": {
"screenId": "3"
}
}
screenId
the ID of the screen.Connect & Forge
Connect rules
"ruleKey": "connect:expression-validator",
"parameters": {
"appKey": "com.atlassian.app",
"config": "",
"id": "90ce590f-e90c-4cd3-8281-165ce41f2ac3",
"disabled": "false",
"tag": ""
}
}
ruleKey
Validator: connect:expression-validator
, Condition: connect:expression-condition
, and Post function: connect:remote-workflow-function
appKey
the reference to the Connect appconfig
a JSON payload string describing the configurationid
the ID of the ruledisabled
determine if the Connect app is disabled. Allowed values: true
, false
.tag
additional tags for the Connect appForge rules
"ruleKey": "forge:expression-validator",
"parameters": {
"key": "ari☁️ecosystem::extension/{appId}/{environmentId}/static/{moduleKey}",
"config": "{"searchString":"workflow validator"}",
"id": "a865ddf6-bb3f-4a7b-9540-c2f8b3f9f6c2"
}
}
ruleKey
Validator: forge:expression-validator
, Condition: forge:expression-condition
, and Post function: forge:workflow-post-function
key
the identifier for the Forge appconfig
the persistent stringified JSON configuration for the Forge ruleid
the ID of the Forge ruleRequest Request Example
Shell
JavaScript
Java
Swift
curl --location --request GET 'http://jira.local:8080/jira/rest//rest/api/3/workflows/capabilities'
Response Response Example
200 - Example 1
{
"connectRules": [
{
"addonKey": "string",
"createUrl": "string",
"description": "string",
"editUrl": "string",
"moduleKey": "string",
"name": "string",
"ruleKey": "string",
"ruleType": "CONDITION",
"viewUrl": "string"
}
],
"editorScope": "PROJECT",
"forgeRules": [
{
"description": "string",
"id": "string",
"name": "string",
"ruleKey": "string",
"ruleType": "CONDITION"
}
],
"projectTypes": "software",
"systemRules": [
{
"description": "string",
"incompatibleRuleKeys": [
"string"
],
"isAvailableForInitialTransition": true,
"isVisible": true,
"name": "string",
"ruleKey": "string",
"ruleType": "CONDITION"
}
],
"triggerRules": [
{
"availableTypes": [
{
"description": "string",
"name": "string",
"type": "string"
}
],
"ruleKey": "string"
}
]
}
Request
Query Params
workflowId
string
optional
projectId
string
optional
issueTypeId
string
optional
Responses
Modified at 2023-07-13 03:27:27