H3YY0U
8/8/2019 - 3:10 AM

get all guest accounts in Azure AD

Get-AzureADUser -All $True |where {$_.UserType -eq 'Guest'} |Select DisplayName, UserPrincipalName, AccountEnabled, mail, UserType |Export-csv "AzureGuestUsers.csv" -NoTypeInformation