question

RisingFlight-7863 avatar image
1 Vote"
RisingFlight-7863 asked henrycrist-0272 published

Azure AD Export AD groups

When i go to Azure Active Directory

Home-->Contoso-->users-->Ben
under groups(Preview) i can see all groups for user Ben i.e mail enabled security, security, Distribution,Microsoft 365.
i want to export Group Names, Group Types, Email to csv file for this user. how do i do it.

  1. If i just need to export Distribution groups how do i do.

  2. if i have users in csv file how can i import the csv file and export the output(groups) to csv file from Azure AD powershell

users
john1@mydomain.com
John2@mydomain.com

windows-serverazure-active-directorywindows-server-powershell
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

SimonBurbery-9608 avatar image
0 Votes"
SimonBurbery-9608 answered

This script will output all Azure AD groups and members - you can add the 'Where-Object {$_.MailEnabled -eq $true}' to get only distribution groups. Or easily modify to include additonal information in the output.
https://www.howdoiuseacomputer.com/index.php/2021/09/12/azure-ad-output-groups-and-members-to-csv/

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

henrycrist-0272 avatar image
0 Votes"
henrycrist-0272 answered henrycrist-0272 published

Also looking for this. Found a comprehensive discussion from the comments. Thanks guys. Keep updating kindly.


5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.