This guide will provide you with the knowledge and tools you need to effectively manage your Office 365 mailbox using the Get-EXORecipient.

Understanding Exchange Recipient Type Details

When managing an Exchange environment, understanding the different types of recipients is crucial for effective administration. Exchange Online supports a variety of recipient types, each serving different purposes within your organization. The Get-EXORecipient cmdlet is a powerful tool that allows administrators to retrieve and manage these various recipient types. Below, we will explore the main recipient types, how to identify them, and how to find removed recipients.

Recipient type Recipient type Details Require Licenses
User Mailbox UserMailboxYes
Shared Mailbox SharedMailboxNo License Required for Shared Mailbox
Mail ContactMailContactNo License Required Mail for Contact
Mail UserMailUserNo License Required for Mail User
Room MailboxRoomMailboxNo License Required for Room Mailbox
Equipment MailboxEquipmentMailboxNo License Required for Equipment Mailbox
Distribution GroupMailUniversalDistributionGroupNo License Required
Mail-Enabled Security GroupMailUniversalSecurityGroupNo License Required for Mail-Enabled Security Group
Dynamic Distribution GroupDynamicDistributionGroupNo License Required for Dynamic Distribution Group
Microsoft 365 group (Unified Group)GroupMailboxNo, But the member must have a license
Mail-enabled public folderPublicFolderMailboxNo License Required for Mail-enabled public folder

Till the time of writing this post, you cannot use the Get-EXORecipient to preview a Dynamic Distribution Group, as this method is not supported by Microsoft. So you still need to use the Get-Recipient.

Understanding Recipient Management Using Get-EXORecipient

The Get-EXORecipient cmdlet is a command to retrieve information about all recipients in your organization. This includes mailboxes, mail users, mail contacts, distribution groups, dynamic distribution groups, and more. It is beneficial for administrators who need to gather detailed information about the various types of recipients in their environment, whether for reporting, auditing, or management purposes.

Reading All Exchange Online Recipients from Exchange Online

To find all the recipients along with their associated type, use the following cmdlet

Get-EXORecipient | Select-Object DisplayName,RecipientTypeDetails

You can use the Get-EXORecipient to get a list of Exchange objects from the same type, for example, MailUser objects

Get-EXORecipient -RecipientTypeDetails MailUser

Also, you can use this code to get a list of Mailbox users

Get-EXORecipient -RecipientTypeDetails UserMailbox

Reading All Exchange Online Recipients Including The Deleted Recipients

One of the most common parameters in the Get-EXORecipient is theIncludeSoftDeletedRecipients. This parameter returns all the recipients and also includes the deleted Exchange Online recipients that are in soft delete

To identify the soft-deleted mailbox using Get-EXORecipient use the following command

PS> Get-EXORecipient -IncludeSoftDeletedRecipients |where {$_.Identity -like 'Soft Deleted Objects*'}

ExternalDirectoryObjectId :
Identity                  : Soft Deleted Objects\0d5ce5fd-6fa9-6fa9-6fa9-b2ace782d55d
Alias                     : Test.User
DisplayName               : Test.User
Name                      : 0d5ce5fd-6fa9-6fa9-6fa9-b2acee5fd
PrimarySmtpAddress        : Test.User@farismalaeb.com
RecipientType             : MailUser
RecipientTypeDetails      : MailUser
ExchangeVersion           : 1.1 (15.0.0.0)

But for more information, it is better to use Get-EXOMailbox as it returns and supports better and more specific details for UserMailbox

Get-Mailbox -SoftDeletedMailbox | select Name,RecipientTypeDetails,WhenSoftDeleted,IsInactiveMailbox

Conclusion

In this post, we took a look at how to use the Get-EXOrecipient to fetch and read user and recipient information.

Take a look at Exchange Shared Mailbox Permission to learn how to read and grant access to a shared mailbox

5/5 - (2 votes)