Set work item security level automatically with Jira Automation
Platform Notice: Cloud Only - This article only applies to Atlassian apps on the cloud platform.
Summary
See how to automatically set security when assigning issues to specific users.
Solution
Prerequisites
Before we create the rule, we'll want to make sure all these requirements are met.
If you keep Automation for Jira as the Actor (the default), confirm both that the atlassian-addons-project-access project role is added to the security scheme and that this Actor has the Browse Projects, Edit Work Items, and Set Security Level permissions. If you change the Actor to a specific user instead, that user must be a member of the target Security Level and hold the same three permissions.
At least 1 security scheme is associated with the project.
The rule Actor is a member of the target Security Level (if keeping Automation for Jira as actor, add the
atlassian-addons-project-accessrole to the security scheme).The Actor has the Browse Projects, Edit Work Items, and Set Security Level permissions.
The Security Level field is on the Edit and View screens.
For full details on configuring work item security, please refer to our documentation.
Automation rule to set the security level based on the Assignee
Our example rule triggers when a work item is assigned to a user or list of users, but the automation trigger can be exchanged for any other trigger that matches your requirements.
Visit your space, and select Space Settings > Automation > Create rule.
Use the Work item assigned trigger.
Select IF: Add a condition.
Choose a Work item field condition.
Select the Assignee field.
Leave the condition as is one of (default).
Choose the user(s) that should trigger this rule.
Add an Action component to the rule.
Select the Edit work item component.
Select the Security level field.
Choose only users who are members of the security level you will set in the Edit work item action. If a triggering assignee is not in that security level, they will lose visibility of the work item once the rule runs.
Choose the appropriate security level.
Save and turn on the rule.
Trigger the rule on a test issue and confirm the Security Level field is set as expected.
If the rule runs but security isn't set, the Actor almost always lacks Set Security Level or isn't a member of the target level — check the audit log for a permission warning.
Related article
Was this helpful?