We can view the user account details for a known account using the following:
Get-AzureADUser -ObjectId AdeleV@M365x562652.OnMicrosoft.com | fl
In the preceding command, AdeleV@M365x562652.OnMicrosoft.com represents the UPN of the user.
We also can use user attributes to find user account details:
Get-AzureADUser -Filter "startswith(GivenName,'Adele')"
The preceding command will filter Azure AD users with GivenName as Adele.
We can also filter users based on a specific attribute value:
Get-AzureADUser -Filter "GivenName eq 'Adele'"
The preceding command will search for the exact user with the given name value Adele.
In my demo environment, I'd like to see a list of disabled accounts. I can do this using the following command: ...