Why use this template?
Use this PowerShell template when you need to export distribution group metadata. It is generated locally and can be reviewed before you run it yourself in your own PowerShell session.
The template uses ExchangeOnlineManagement and requires View-Only Recipients. Output: CSV report. Level: Beginner. Action: Read-only. Risk: Low.
Review before running
The script is generated in your browser. Read it before you run it, and test it outside production first. “Read-only” describes the script itself; anything you add around it can still change data.
Generate the script
- Open the template in the PowerShell Builder.
- Enter the requested values and review the module, permissions, output and risk.
- Generate the script, read it carefully, and test it outside production before use.
The script is generated locally in your browser. Nothing needs to be uploaded to Opselith.
Generate Export Exchange distribution groups →How to use this result
Use this report for a tenant-wide inventory of Exchange Online distribution-group configuration without expanding every group's membership.
When this helps
- Inventory distribution groups before cleanup, migration or ownership review.
- Review primary SMTP addresses, ManagedBy values and address-list visibility.
- Identify groups whose sender-authentication setting deserves a closer policy review.
How to read the result
- ManagedBy contains the configured owner identifiers; it is not the same thing as group membership.
- This report describes group-level metadata. Use the members-and-owners report when you need one row per direct member.
Things to check
- Distribution groups and mail-enabled security groups have different purposes; do not infer authorization from mail-delivery configuration alone.
- The inventory does not expand nested membership or calculate dynamic distribution-group recipients.
What to do next: Review ownerless or unexpectedly hidden groups, then open the members-and-owners report for groups that require membership validation.
Related tasks
Official references