<iframe src="https://www.googletagmanager.com/ns.html?id=GTM-M74D8PB" height="0" width="0" style="display:none;visibility:hidden">
Loading
Skip to NavigationSkip to Main Content
Okta Expression Language Nesting Statement
Lifecycle Management
Okta Classic Engine
Okta Identity Engine
Overview

Okta Administrators have a list of department attributes with corresponding numerical IDs in an external application. For example, the Operations department has an external app value of 123. 

This article explores whether it is possible to push a value to an external app, such as 123 for the Operations department in the aforementioned example.

Applies To
  • Okta Expression Language (OEL)
  • User Lifecycle Management (LCM)
Solution

The best way to achieve this is by building a nested IF/ELSE expression using Okta Expression Language (OEL). Admins should be able to accomplish this by using an expression similar to the following. For example, if a user has a title containing Operations, the value will be 123. If the user has a title containing IT, the value will be 456. Admins can modify the below expression as needed.
 

String.stringContains(user.title, "Operations") ? '123' : String.stringContains(user.title, "IT") ? '456' : String.stringContains(user.title, "Marketing") ? '789' : null


Related References

Loading
Okta Expression Language Nesting Statement