The goal of this article is to clarify how to create a group rule with more than one condition using the Okta Expression Language.
- Group Rules
- Okta Expression Language
- Navigate to Directory > Groups > Rules.
- Click Add rule.
- Enter a name for the rule.
- Select Use Okta Expression Language (advanced).
- In the box, enter something such as:
user.title=="Sales" && user.costCenter == "2024" - For Assign to, enter a group name.
- Save rule.
- Next to the newly created rule, click Actions > Activate.
- Using the configuration above, all users with the title "Sales" and cost center "2024" will be automatically assigned to the Sales group.
- The expression language can be customized for any profile attribute.
