We have an application which uses Azure B2C and Azure Active Directory.
Problem: User A wants to set his specific email address. But this is not possible because User B already used this email address before. User B has a proxyaddresses entry for this email, although User B does not use the emailadress anymore.
We tried to remove the smtp entry in proxaddresses for User B:
Connect-AzureAD -TenantId <TenantID>
$User = Get-AzureADUser -ObjectId "<ObjectIDUserB>"
$User.ProxyAddresses //Displays all proxyaddresses(smtpEntries)
$User.ProxyAddresses.Remove("<smtpEntry>")
Set-AzureADUser -ObjectId "<ObjectIDUserB>" //But then there is no parameter for ProxyAddresses to update
Are we missing something here or is there another way to remove a proxyadress entry for a user in azure ad?
ProxyAddresses attribute for an unlicensed cloud-only user can now be modified using graph.microsoft.com/beta endpoint. For example use Graph Explorer (https://aka.ms/ge) and do a PATCH to update cloud-only non-EXO licensed user's proxyAddresses attribute directly. If using beta endpoint, you will no longer get the "proxyAddresses" is read only error.
PATCH https://graph.microsoft.com/beta/users/userobjectid
{
"proxyAddresses": [
"SMTP:[email protected]"
]
}
NOTE: Make sure of the following if you get a 403
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With