Edit

Share via


Get-DynamicDistributionGroupMember

This cmdlet is available only in the cloud-based service.

Use the Get-DynamicDistributionGroupMember cmdlet to view the calculated membership list that's stored on dynamic distribution group objects. The results from this cmdlet are updated every 24 hours.

Use the Get-DistributionGroupMember cmdlet to view the members of distribution groups and mail-enabled security groups.

For information about the parameter sets in the Syntax section below, see Exchange cmdlet syntax.

Syntax

Default (Default)

Get-DynamicDistributionGroupMember
    [-Identity] <DynamicDistributionGroupMemberIdParameter>
    [-Credential <PSCredential>]
    [-IncludeSoftDeletedObjects]
    [-ResultSize <Unlimited>]
    [<CommonParameters>]

Description

You need to be assigned permissions before you can run this cmdlet. Although this article lists all parameters for the cmdlet, you might not have access to some parameters if they aren't included in the permissions assigned to you. To find the permissions required to run any cmdlet or parameter in your organization, see Find the permissions required to run any Exchange cmdlet.

Examples

Example 1

Get-DynamicDistributionGroupMember -Identity "Temporary Employees"

This example returns the existing members for the dynamic distribution group named Temporary Employees.

Parameters

-Credential

Applicable: Exchange Online, Exchange Online Protection

The Credential parameter specifies the username and password that's used to run this command. Typically, you use this parameter in scripts or when you need to provide different credentials that have the required permissions.

A value for this parameter requires the Get-Credential cmdlet. To pause this command and receive a prompt for credentials, use the value (Get-Credential). Or, before you run this command, store the credentials in a variable (for example, $cred = Get-Credential) and then use the variable name ($cred) for this parameter. For more information, see Get-Credential.

Parameter properties

Type:PSCredential
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-Identity

Applicable: Exchange Online, Exchange Online Protection

The Identity parameter specifies the dynamic distribution group. You can use any value that uniquely identifies the group. For example:

  • Name
  • Alias
  • Distinguished name (DN)
  • Canonical DN
  • Email address
  • GUID

Parameter properties

Type:DynamicDistributionGroupMemberIdParameter
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:0
Mandatory:True
Value from pipeline:True
Value from pipeline by property name:False
Value from remaining arguments:False

-IncludeSoftDeletedObjects

Applicable: Exchange Online, Exchange Online Protection

The IncludeSoftDeletedGroups switch specifies whether to include soft-deleted group members in the results. You don't need to specify a value with this switch.

Soft-deleted group members are deleted Microsoft 365 Groups or mailboxes that are still recoverable.

Parameter properties

Type:SwitchParameter
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-ResultSize

Applicable: Exchange Online, Exchange Online Protection

The ResultSize parameter specifies the maximum number of results to return. If you want to return all requests that match the query, use unlimited for the value of this parameter. The default value is 1000.

Parameter properties

Type:Unlimited
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.