external help file | applicable | schema |
---|---|---|
SharePoint Online |
2.0.0 |
Removes a site collection
Remove-PnPTenantSite -Url <String>
[-SkipRecycleBin [<SwitchParameter>]]
[-Force [<SwitchParameter>]]
[-Connection <SPOnlineConnection>]
Removes a site collection which is listed in your tenant administration site.
PS:> Remove-PnPTenantSite -Url https://tenant.sharepoint.com/sites/contoso
This will remove the site collection with the url 'https://tenant.sharepoint.com/sites/contoso' and put it in the recycle bin.
PS:> Remove-PnPTenantSite -Url https://tenant.sharepoint.com/sites/contoso -Force -SkipRecycleBin
This will remove the site collection with the url 'https://tenant.sharepoint.com/sites/contoso' with force and it will skip the recycle bin.
PS:> Remove-PnPTenantSite -Url https://tenant.sharepoint.com/sites/contoso -FromRecycleBin
This will remove the site collection with the url 'https://tenant.sharepoint.com/sites/contoso' from the recycle bin.
Do not ask for confirmation.
Type: SwitchParameter
Parameter Sets: (All)
Required: False
Position: Named
Accept pipeline input: False
Do not add to the tenant scoped recycle bin when selected.
Type: SwitchParameter
Parameter Sets: (All)
Aliases: SkipTrash
Required: False
Position: Named
Accept pipeline input: False
Specifies the full URL of the site collection that needs to be deleted
Type: String
Parameter Sets: (All)
Required: True
Position: 0
Accept pipeline input: True
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