-
Type:
Suggestion
-
Resolution: Unresolved
-
Component/s: Forge - Jira Workflow Modules
We are developing a Forge app that needs to programmatically add validator rules to Jira workflows using the REST API.
Using the examples provided in the documentation, the API returns a 200 OK response, but the validator rule is not added to the workflow.
The response body contains a ruleUpdateErrors object with the message:
The workflow rule with this ID does not exist or you do not have permissions to edit its configuration
Currently, there isn’t an API that allows listing or retrieving the IDs of workflow validators that aren't applied to any workflow. The APIs only expose them in the context of workflows and transitions where they are already in use.
Using:
GET /rest/api/3/workflow/rule/config?
{{ }}will only return validators that are already configured on a workflow transition.
Actual Result
The API returns 200 OK, but the rule is not added. The response contains a ruleUpdateErrors message indicating the rule does not exist or permissions are insufficient.
Expected Result
The validator rule should be added to the specified workflow transition if the request is successful or there should be a way to retrieve the id of validators which are not applied to any workflow yet. That would help retrieve the id of newly created validators.