Saviynt unveils its cutting-edge Intelligence Suite products to revolutionize Identity Security!
Click HERE to see how Saviynt Intelligence is transforming the industry.
Saviynt Copilot Icon

Required correct JSON Format for firstname in AD connection

Harish1
New Contributor II
New Contributor II

Hi,

We got a requirement to update the AD firstname based on saviynt preferredfirstname or firstname. we are using the below JSON format in update account json.

"givenName": "${user.preferedFirstName!=null?user.preferedFirstName:user.firstname}"

But the challenge is business team wants to exclude some set of users from this firstname update (AD).

Kindly suggest us the correct format. 

7 REPLIES 7

Amit_Malik
Valued Contributor II
Valued Contributor II

Hi @Harish1 , reading your post it looks that their is no logic for exclusion and it is just some users to excluded. You can update their CP and use IF else condition, something like below

"givenName": "${if(user.Location=='India' && user.preferedFirstName!=null){user.preferedFirstName} else {user.firstname}}"

Thanks,

Amit

If this answers your query, Please ACCEPT SOLUTION and give KUDOS.

Kind Regards,
Amit Malik
If this helped you move forward, please click on the "Kudos" button.
If this answers your query, please select "Accept As Solution".

Harish1
New Contributor II
New Contributor II

Hi Amit

Thanks for your response, as we required to completely exclude the set of users with that logic. 

We don't want to update (Bypass) Given Name attribute for some set of ids. 

The above suggested query will update the excluded id also with if or else.

Thanks,

Harish

rushikeshvartak
All-Star
All-Star

You need to use customproperty to define excluded list and use below sample code

"givenName": "${if(user.customproperty60=='excluded' && user.preferedFirstName!=null){user.preferedFirstName} else {user.firstname}}"


Regards,
Rushikesh Vartak
If this helped you move forward, click 'Kudos'. If it solved your query, select 'Accept As Solution'.

Hi Rushikesh,

Thanks for your response, as we required to completely exclude the set of users with that logic. 

We don't want to update (Bypass) Given Name attribute for some set of ids. 

The above suggested query will update the excluded id also with if or else.

Thanks,

Harish

"E_MAIL":"${if(user.email!=null && user.email?.length() >0) ? user.email : (SAVIYNTNOTCHANGED) else (SAVIYNTNOTCHANGED)}"


Regards,
Rushikesh Vartak
If this helped you move forward, click 'Kudos'. If it solved your query, select 'Accept As Solution'.

"givenName":"${if(user.preferedFirstName!=null && user.preferedFirstName?.length() >0) ? user.preferedFirstName : (SAVIYNTNOTCHANGED) else (SAVIYNTNOTCHANGED)}"

we required that, if prefered firstname is there then given name needs to update with the user.prefered firstname else it needs to be update with user.firstname. But for some set of id's the complete logic(if else) needs to be bypass.

I hope you understand now. as per your suggested query user.firstname not in the scope.

Regards,

Harish

You can bypass using SAVIYNTNOTCHANGED


Regards,
Rushikesh Vartak
If this helped you move forward, click 'Kudos'. If it solved your query, select 'Accept As Solution'.