SOLVED

Replacement cmdlets for Msol cmdlets for Mailbox Validation

Copper Contributor

Due to the looming deprecation of AzureAD and Msol cmdlets, I am trying to search for replacement Graph SDK cmdlets for the following cmdlets which is about showing the validation error of O365 mailbox.

 

 

Get-MsolUser -UserPrincipalName $wsUserPrincipalName | Select-Object ValidationStatus
(Get-MsolUser -UserPrincipalName $wsUserPrincipalName).errors[0].ErrorDetail.objecterrors.errorrecord.ErrorDescription

 

 

AAAA.JPGAbove please find an image showing the output of the 2 cmdlets.
Thanks.

2 Replies
best response confirmed by John_Lee2025 (Copper Contributor)
Solution
There's no proper replacement for this, afaik. In Graph, the onPremisesProvisioningErrors property covers some scenarios, but it's not an exact replacement.

Thanks @Vasil Michev 
I got a similar response when I asked the same question via https://serviceshub.microsoft.com 

It is disappointing because I have been relying on this cmdlet to proactively fix hybrid account provisioning errors.  I don't really want to wait till users report provisioning errors and have to individually go to check it out on O365 Admin Center.

1 best response

Accepted Solutions
best response confirmed by John_Lee2025 (Copper Contributor)
Solution
There's no proper replacement for this, afaik. In Graph, the onPremisesProvisioningErrors property covers some scenarios, but it's not an exact replacement.

View solution in original post