Create security levels for issues via automation rule
Asked by Marek:

Hi all,

I can manually set security level per case; however, the automation rule keeps failing with the following error:

Action details: {#toc-hId--382986522}
-------------------------------------

##### [JQL condition](https://univestfinancial.atlassian.net/jira/servicedesk/projects/TSD/settings/automate#/rule/18204296/413275684) {#toc-hId-1008639530}

The following issues passed:  
TEST-445  

##### [Edit issue](https://univestfinancial.atlassian.net/jira/servicedesk/projects/TSD/settings/automate#/rule/18204296/413275685) {#toc-hId--798814933}

No fields or field values to edit for issues (could be due to some field values not existing in a given project):  
TEST-445  
What Am I missing? I don't want agents to set security level. I want to have security level set per issue type. Please, let me know what permissions are needed for the "Automation for Jira" actor and where to set them. Thank you,


Answers:
author: Mikael Sandberg
body: Make sure that the project role atlassian-addons-project-access is added to both the security levels in your issue security scheme and that it has been added to the Set Issue Security in your permission scheme for the project.

comments: author: Marek
body: Here are the permissions for **Set Issue Security**:

* Project Role (Administrators)
* Project Role (Service Desk Team)
* Project Role (atlassian-addons-project-access)
* Service Project Customer - Portal Access

And the **Security Level**:

* Group (Test-IT cases)
* Group (site-admins)
* Project Role (atlassian-addons-project-access)


author: Ponnappan Ganapathiya
body: No fields or field values to edit for issues (could be due to some field values not existing in a given project): - This error gives you that the value you provided to set is not in the options for 'Security Level' field(if the field is available) on the given project.

Could you please validate the the option is available in the project.

Project settings-\>Issue Security. If the option is not available then add it or Change the issue security scheme.

comments: author: Marek
body: ***Security Level*** field was added to appropriate screens and once a case is open, as agent, I can set security level to **Test-IT Help**.

Under *Project Settings -\> Issue Security*, correct issue security scheme is selected, and Security Level is listed there as expected.

Anything else I need to check and/or re-configure? Thank you,


author: Ponnappan Ganapathiya
body: Did you try changing the rule Actor to yourself?


author: Marek
body: I pretty much followed this guide: [Automation \| Set "Issue Security Level" via Automation for JIRA \| Automation for Jira \| Atlassian Documentation](https://confluence.atlassian.com/automationkb/automation-set-issue-security-level-via-automation-for-jira-1272383609.html)

* The Actor of the Automation Rule (By Default: **Automation for JIRA** ) needs to be a member of the target Security Level. The Automation for Jira is not a general user as we see in the "User Management" page. Hence, we need to add the "**Project Role (atlassian-addons-project-access)**" to the security scheme.
* The Actor of the automation rule needs to have the below permissions:
  * "Browse Projects" Permission
  * "Edit Issue" Permissions
  * "Set Security Level" Permission
* The "Security Level" field needs to be added to the "Edit" and "View" Issue Screens from the Screen configuration of the Project.


author: Marek
body: I also changed the actor to myself, and it failed with same error.


author: Marek
body: This Project Role (atlassian-addons-project-access), is already added in project permissions to browse, edit and set security level. It's also added to the security level.

What else I need to check?


author: Ponnappan Ganapathiya
body: lets give a try with Trigger. Change it to manual trigger without JQL condition and try once.

Create a issue and change the project level manually. Then reset the project level to default and try to change it via manual trigger.

Possibly the JQL condition may restrict the field edit option.

Even after the problem persists, create a support ticket.


Tags: cloud

jira-service-management

jira-service-management-cloud