05/09/2023 07:43 AM
Hello,
We have an AD job that triggers UpdateAccountJson to expire account on AD based on term date. But the accounts are not getting expired on AD. The UpdateAccountJson in connection is as follows:
05/09/2023 07:46 AM
05/11/2023 02:09 PM
Can you try with the below
{
"accountExpires": "${(10000 * (user.termDate.getTime() + 11644387200000)) }"
}
05/11/2023 02:18 PM
This looks exactly like the configuration I used.
05/11/2023 02:20 PM
Sorry, looks like I pasted the wrong value. Please try the below
"accountExpires": "${if(user.enddate != null){10000*(user.enddate.getTime() + 11644473600000)} else {'0'}}"
05/18/2023 06:09 AM
I used the following JSON. The task got triggered but it actually disabled the account in AD while we only wanted to expire the account.
{
"accountExpires": "${user.termDate!=null ? 10000 * user.termDate.getTime() + 11644473600000 : 0}"
}
Any suggestion on the configuration only to expire the account?
06/12/2023 10:56 AM
are you still facing this issue or was it resolved.