11-24-2022 03:24 AM
Hi Team,
We have a requirement to update the description from Saviynt to AD while the account is disabled.
I have achieved the first part of the requirement, however the full requirement is "the description attribute should be set to: !DepartingOutOfOffice - clear content on <today+30>, delete on <today+180>".
Can we get the date set in disableaccountjson AD connection which gets cleared after 30 days and will be deleted entirely after 180 days.
Logic used now:{
"userAccountControl": "514",
"deleteAllGroups": "No",
"description": "${if(user?.employeeclass.toString().startsWith('V')&&user?.employeeclass.toString().startsWith('EV')){'!DepartingOutOfOffice'}}",
"adminDescription": "",
"streetAddress": "",
"l": "",
"postalCode": "",
"co": "",
"c": "",
"company": "",
"st": "",
"moveUsertoOU": "${if(user?.customer?.id==4){'OU=Contractors,OU=NonEmployees,OU=Quahog,OU=Americas,DC=BAIN,DC=com'}else if(user?.employeeclass.toString().startsWith('V')&&user?.employeeclass.toString().startsWith('V')){'OU=!DepartingOutOfOffice,OU=Alumni,OU=Global,DC=BAIN,DC=com'}else if(account?.accountID?.toString().indexOf('OU=Elevated')!= -1){'OU=Elevated Accounts,OU=Global,DC=BAIN,DC=com'}else if (account?.accountID?.toString().indexOf('OU=Cloud Administrator')!= -1){'OU=Cloud Administrator Accounts,OU=Azure,OU=Resources,OU=Global,DC=BAIN,DC=com'}else{'OU=Quahog,OU=Americas,DC=BAIN,DC=com'}}"
}
Please advise.
Regards,
Ekata
11-24-2022 06:11 AM
You can create technical rule / analytics report for deletion 😕 disabling account after certain days
11-24-2022 06:14 AM
Yes we already have it in place to remove it after 180 days.. I just need to add the function of clearing the description from AD after 30 days. Can we do that?
Regards,
Ekata
11-24-2022 06:26 AM
You can trigger update account tasks from analytics actionable report
11-24-2022 06:43 AM
Thanks. I can do that
11-24-2022 06:16 AM
"description": "${if(user?.employeeclass.toString().startsWith('V')&&user?.employeeclass.toString().startsWith('EV')){'!DepartingOutOfOffice'}}", We need to remove the bold letters in description once it reaches 30 days in that particular OU.
11-25-2022 05:12 AM
Hi Team,
I have updated the analytics to remove the description but how can we update the json to get the description as "!DepartingOutOfOffice - clear content on <today+30>, delete on <today+180>" with the mentioned date/time interval
Please advise.
Regards,
ekata
11-25-2022 05:13 AM
"description":"${if(user?.employeeclass.toString().startsWith('V')&&user?.employeeclass.toString().startsWith('EV')){'!DepartingOutOfOffice - clear content on' +{StatementDate = Calender.getInstance();StatementDate.add(Calender.DAY_OF_MONTH,+30);StatementDate.format('yyyy-MM-dd')}}}",
Tried this but can not update it correctly.
Error: Error while Update operation for account-9999123091 in AD - Error parsing JSON
11-25-2022 05:45 AM
Seems issue with date function
11-25-2022 06:12 AM
Can you advise the correct function to achieve it.
Regards,
Ekata
11-28-2022 08:56 AM
You have error is json validate json using json validator
12-01-2022 03:20 AM
Thanks. I could get the correct function.