external help file | applicable | schema |
---|---|---|
SharePoint Online |
2.0.0 |
Retrieve site information.
Get-PnPTenantSite [-Template <String>]
[-Detailed [<SwitchParameter>]]
[-IncludeOneDriveSites [<SwitchParameter>]]
[-Force [<SwitchParameter>]]
[-WebTemplate <String>]
[-Filter <String>]
[-Url <String>]
[-Connection <SPOnlineConnection>]
Use this cmdlet to retrieve site information from your tenant administration.
PS:> Get-PnPTenantSite
Returns all site collections
PS:> Get-PnPTenantSite -Url http://tenant.sharepoint.com/sites/projects
Returns information about the project site
PS:> Get-PnPTenantSite -Detailed
Returns all sites with the full details of these sites
PS:> Get-PnPTenantSite -IncludeOneDriveSites
Returns all sites including all OneDrive for Business sites
PS:> Get-PnPTenantSite -IncludeOneDriveSites -Filter "Url -like '-my.sharepoint.com/personal/'"
Returns all OneDrive for Business sites
PS:> Get-PnPTenantSite -WebTemplate SITEPAGEPUBLISHING#0
Returns all Communication sites
PS:> Get-PnPTenantSite -Filter "Url -like 'sales'"
Returns all sites including 'sales' in the url
By default, not all returned attributes are populated. This switch populates all attributes. It can take several seconds to run. Without this, some attributes will show default values that may not be correct.
Type: SwitchParameter
Parameter Sets: (All)
Required: False
Position: Named
Accept pipeline input: False
Specifies the script block of the server-side filter to apply. See https://technet.microsoft.com/en-us/library/fp161380.aspx
Type: String
Parameter Sets: (All)
Required: False
Position: Named
Accept pipeline input: False
When the switch IncludeOneDriveSites is used, this switch ignores the question shown that the command can take a long time to execute
Type: SwitchParameter
Parameter Sets: (All)
Required: False
Position: Named
Accept pipeline input: False
By default, the OneDrives are not returned. This switch includes all OneDrives.
Type: SwitchParameter
Parameter Sets: (All)
Required: False
Position: Named
Accept pipeline input: False
By default, all sites will be return. Specify a template value alike 'STS#0' here to filter on the template
Type: String
Parameter Sets: (All)
Required: False
Position: Named
Accept pipeline input: False
The URL of the site
Type: String
Parameter Sets: (All)
Aliases: Identity
Required: False
Position: 0
Accept pipeline input: True
Limit results to a specific web template name
Type: String
Parameter Sets: (All)
Required: False
Position: Named
Accept pipeline input: False
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