Get-ExchangeMailbox cmdlet gets the information on the Exchange mailbox.

Input parameters

#
Parameter
Type

Mandatory (R/O)

Description
Valid Values
1 Authentication Information (all parameters)  
2

Identity

(aliases: GUID, DistinguishedName, UserPrincipalName, Name)

string O A property that is used for managing the Exchange mailbox

Value of one of these parameters  can be used as Identity:

#ParameterDescription
1 GUID Globally Unique Identifier (ObjectGuid)
2 DistinguishedName Unique name of the object in Active Directory
3 UserPrincipalName Primary Email address (Login)
4 Name Internal name of the AD object
3 ResultSize int O This parameter specifies the maximum number of results to return  

Output parameters

#PropertyTypeDescriptionValid Values

ExchangeMailboxInfo:

1 ActiveSyncEnabled bool This  property defines whether ActiveSync is enabled for the mailbox or not
  • True - ActiveSync is enabled.
  • False - ActiveSync is not enabled.

The default value depends on the plan.

DeliverAndForwardMail bool The property specifies the message delivery behavior when a ForwardingAddress is specified
  • True - messages are delivered to the current mailbox and forwarded to the specified recipient;

  • False - messages are forwarded and delivered only to the specified recipient. This is the default value.

The value of this property is meaningful only if ForwardingAddress is configured.

DisplayName string Name of the mailbox in the list of Control Panel  
DistinguishedName string Unique name of the object (mailbox) in Active Directory  
EmailAddress string Primary Email address of the mailbox, the same as UserPrincipalName  
EmailAddresses string [] List of the Email addresses of the mailbox  
ForwardingAddress string A forwarding address for messages that are sent to this mailbox A valid value of this property is a recipient of the company.

Recipients: Exchange, POP/IMAP, OWA mailbox, Distribution List, Contact

The default value is null - no forwarding recipient is configured.

GrantFullAccessToRecipients ADObjectIDInfo[] List of recipients (Exchange mailboxes or distribution lists), which have access rights "FullAccess" on this mailbox  
GrantSendOnBehalfToRecipients ADObjectIDInfo[] List of recipients (Exchange mailboxes or distribution lists), which have access rights "SendAs" on this mailbox  
10 GUID string

Globally Unique Identifier (ObjectGuid)

 
11 HideFromAddressBook bool This property specifies whether this mailbox is visible in the address book
  • True - the mailbox is not visible in the address book.

  • False - the mailbox is visible in the address book. This is the default value.

12 ImapEnabled bool

This  property defines whether IMAP protocol is enabled for the mailbox or not

 
  • True - IMAP is enabled. This is the default value.
  • False - IMAP is not enabled. 

13 OriginatingServer string Address of the server (domain name), where the object physically exists  
14 OwaEnabled bool

This property defines whether OWA protocol is enabled for the mailbox or not

  • True - OWA is enabled. This is the default value.
  • False - OWA is not enabled.

15  PopEnabled bool 

This property defines whether POP protocol is enabled for the mailbox or not

  • True - POP is enabled. This is the default value.
  • False - POP is not enabled.

Example of using Get-ExchangeMailbox cmdlet

Getting the Exchange mailbox by EmailAddress:

Get-ExchangeMailbox -Identity bob@accountname.hostpilot.com

Getting not more than 5 mailboxes which email addresses start with "john":

Get-ExchangeMailbox -Identity "john*" -ResultSize 5