Hi Guys,
I am working to store the email Address in proxy address of AD but when we are changing the email we found that it is storing in Capital SMTP although we have to store only primary email address in Capital SMTP but when we are trying to store the updated email Address it is also storing in Capital SMTP. I want to store in all other email in Small smtp but not happening. Can you guide or give suggestion how we can acheieve this one. I am attaching the screenshot for reference.
Hello,
The Proxy Email Address is an Multi Valued attribute and it a complex one.
Hence, in order to handle this attribute changes post Name Change or any other change which will impact this attribute value, you have to get it done through “Before Provisioning” Cloud Rule. I have done the same in my projects as well.
In order to implement this affectively, you can use a below approach.
- Create a “DisplayNameHistory” identity attribute. ALso, create an identity attribute to store proxyAddresses details of the user or else, you can also fetch the existing proxyAddress details from Account attribute as well (whichever is fine with you)
- Create a Transform which will store the DisplayName Attribute like (OldValue<>NewValue)
- Map this attribute identity attribute of “DisplayNameHistory” in AD - Create Account Provisioning Policy to one of the attribute
- Exclude this attribute from provisioning in AD.
- Then, in the before provisioning rule, call the APIs to fetch the details of existing proxyAddresses 1 by 1 and then, you have to re-arrange all the proxy addresses values. Refer the below sample code.
If you see, I am adding a new address to SMTP and explicitly removing the old value assigned to CAPITAL SMTP. You have to re-arrange all the values accordingly.
I hope this helps!
Hi @md_faisal Can I ask what Exchange mode you are running?