This section describes a Forge preview feature. Preview features are deemed stable; however, they remain under active development and may be subject to shorter deprecation windows. Preview features are suitable for early adopters in production environments.
We release preview features so partners and developers can study, test, and integrate them prior to General Availability (GA). For more information, see Forge release phases: EAP, Preview, and GA.
The jira:actionValidator module lets developers define custom validation against specific Jira actions. Currently, the only supported way to provide this custom validation is by using Jira expressions.
| Property | Type | Required | Description |
|---|---|---|---|
key |
| Yes | A key for the module, which other modules can refer to. Must be unique within the manifest. Regex: |
action | string | Yes | The name of the action. Allowed actions are:
|
expression | string | Yes | The Jira expression that provides the custom validation logic. The expression should return a boolean value:
|
errorMessage | string | No | Error message to display when the validation fails due to Action validator. |
The jira:actionValidator module can be used against specific Jira actions.
This action lets an app execute custom validation whenever a user changes the type of a work item. The validator is triggered across the following flows:
The validator is only invoked when the target type is different from the current type.
The following context variables are available in the validation expression:
user (User):
The user that wants to perform the action.issue (Issue):
The issue being modified.project (Project):
The project the issue belongs to.newIssueType (String): The new issue type ID that the work item is being changed to.newIssueTypeData (IssueType): The new issue type that the work item is being changed to.This example shows manifest file of jira:actionValidator module for workItemTypeChanged action.
1 2modules: 'jira:actionValidator': - key: workitem-type-validator action: 'workItemTypeChanged' expression: 'issue.key=="HSP-1" && newIssueType=="1"' errorMessage: "Work Item type change was blocked by action validator."
The following limitations apply to apps that use the jira:actionValidator module:
jira:actionValidator module per action type.Rate this page: