Skip to content

Latest commit

 

History

History
164 lines (124 loc) · 3.07 KB

Get-PnPGroup.md

File metadata and controls

164 lines (124 loc) · 3.07 KB
external help file applicable schema
SharePoint Server 2013, SharePoint Server 2016, SharePoint Online
2.0.0

Get-PnPGroup

SYNOPSIS

Returns a specific group or all groups.

SYNTAX

ByName

Get-PnPGroup [-Web <WebPipeBind>]
             [-Identity <GroupPipeBind>]
             [-Connection <SPOnlineConnection>]

Members

Get-PnPGroup [-AssociatedMemberGroup [<SwitchParameter>]]
             [-Web <WebPipeBind>]
             [-Connection <SPOnlineConnection>]

Visitors

Get-PnPGroup [-AssociatedVisitorGroup [<SwitchParameter>]]
             [-Web <WebPipeBind>]
             [-Connection <SPOnlineConnection>]

Owners

Get-PnPGroup [-AssociatedOwnerGroup [<SwitchParameter>]]
             [-Web <WebPipeBind>]
             [-Connection <SPOnlineConnection>]

Get-PnPGroup [-Web <WebPipeBind>]
             [-Includes <String[]>]
             [-Connection <SPOnlineConnection>]

EXAMPLES

------------------EXAMPLE 1------------------

PS:> Get-PnPGroup

Returns all groups

------------------EXAMPLE 2------------------

PS:> Get-PnPGroup -Identity 'My Site Users'

This will return the group called 'My Site Users' if available

------------------EXAMPLE 3------------------

PS:> Get-PnPGroup -AssociatedMemberGroup

This will return the current members group for the site

PARAMETERS

-AssociatedMemberGroup

Retrieve the associated member group

Type: SwitchParameter
Parameter Sets: Members

Required: False
Position: Named
Accept pipeline input: False

-AssociatedOwnerGroup

Retrieve the associated owner group

Type: SwitchParameter
Parameter Sets: Owners

Required: False
Position: Named
Accept pipeline input: False

-AssociatedVisitorGroup

Retrieve the associated visitor group

Type: SwitchParameter
Parameter Sets: Visitors

Required: False
Position: Named
Accept pipeline input: False

-Identity

Get a specific group by name

Type: GroupPipeBind
Parameter Sets: ByName
Aliases: Name

Required: False
Position: 0
Accept pipeline input: True

-Includes

Specify properties to include when retrieving objects from the server.

Type: String[]
Parameter Sets: 

Required: False
Position: 0
Accept pipeline input: False

-Web

The web to apply the command to. Omit this parameter to use the current web.

Type: WebPipeBind
Parameter Sets: (All)

Required: False
Position: Named
Accept pipeline input: False

-Connection

Optional connection to be used by cmdlet. Retrieve the value for this parameter by eiter specifying -ReturnConnection on Connect-PnPOnline or by executing Get-PnPConnection.

Type: SPOnlineConnection
Parameter Sets: (All)

Required: False
Position: Named
Accept pipeline input: False

OUTPUTS

RELATED LINKS

SharePoint Developer Patterns and Practices