Skip to content

Commit 37d1e65

Browse files
Merge branch 'main' into docs-editor/New-SPOContainerType-1763060441
2 parents eb8ad5f + a656ba1 commit 37d1e65

File tree

4 files changed

+322
-4
lines changed

4 files changed

+322
-4
lines changed
Lines changed: 94 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,94 @@
1+
---
2+
external help file: Microsoft.Online.SharePoint.PowerShell.dll-Help.xml
3+
Module Name: Microsoft.Online.SharePoint.PowerShell
4+
online version: https://learn.microsoft.com/powershell/module/microsoft.online.sharepoint.powershell/get-sporestrictedsitecreationforapps
5+
applicable: SharePoint Online
6+
title: Get-SPORestrictedSiteCreationForApps
7+
schema: 2.0.0
8+
author: vgaddam-pm
9+
ms.author: vgaddam
10+
ms.reviewer:
11+
---
12+
13+
# Get-SPORestrictedSiteCreationForApps
14+
15+
## SYNOPSIS
16+
17+
This cmdlet allows SharePoint Administrators to check the current configuration of the restricted site creation for apps feature.
18+
19+
## SYNTAX
20+
21+
```
22+
Get-SPORestrictedSiteCreationForApps [-SiteType <RestrictedSiteCreationSiteType>] [<CommonParameters>]
23+
```
24+
25+
## DESCRIPTION
26+
27+
This cmdlet obtains the current configuration information for the restricted site creation for apps feature, including whether it is enabled, the current mode, and the current policies.
28+
29+
> [!Note]
30+
> This feature is currently in preview and may not be available in your tenant.
31+
32+
## EXAMPLES
33+
34+
### Example 1
35+
36+
```powershell
37+
Get-SPORestrictedSiteCreationForApps
38+
```
39+
40+
Example 1 returns all configuration information for the restricted site creation for apps feature. This includes whether the feature is enabled, the current mode (deny or allow), and the app IDs configured for each site type.
41+
42+
### Example 2
43+
44+
```powershell
45+
Get-SPORestrictedSiteCreation –SiteType Communication
46+
```
47+
48+
Example 2 returns a comma-separated list of the app IDs for the `Communication` site type. Depending on whether restricted site creation is in allow or deny mode, these apps are either allowed or denied from creating SharePoint communication sites.
49+
50+
## PARAMETERS
51+
52+
### -SiteType
53+
54+
> Applicable: SharePoint Online
55+
When provided, only return the Microsoft Entra security groups configured for the specified site type.
56+
57+
PARAMVALUE: All | SharePoint | OneDrive | Team | Communication
58+
- All - OneDrive and all SharePoint sites
59+
- SharePoint - All SharePoint sites (but not OneDrive)
60+
- OneDrive - Only OneDrive
61+
- Team - Only SharePoint team sites (group-connected and classic)
62+
- Communication - Only SharePoint communication sites
63+
64+
```yaml
65+
Type: Microsoft.SharePoint.Administration.SPOnlineProvisioning.RestrictedSiteCreationSiteType
66+
Parameter Sets: (All)
67+
Aliases:
68+
Accepted values: All, SharePoint, OneDrive, Team, Communication
69+
70+
Required: False
71+
Position: Named
72+
Default value: None
73+
Accept pipeline input: False
74+
Accept wildcard characters: False
75+
```
76+
77+
### CommonParameters
78+
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216).
79+
80+
## INPUTS
81+
82+
### None
83+
84+
## OUTPUTS
85+
86+
### System.Object
87+
88+
## NOTES
89+
90+
## RELATED LINKS
91+
92+
[Getting started with SharePoint Online Management Shell](/powershell/sharepoint/sharepoint-online/connect-sharepoint-online)
93+
94+
[Set-SPORestrictedSiteCreationForApps](Set-SPORestrictedSiteCreationForApps.md)

sharepoint/sharepoint-ps/Microsoft.Online.SharePoint.PowerShell/Microsoft.Online.SharePoint.PowerShell.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -279,6 +279,9 @@ This cmdlet enables the administrator to check status of all active and availabl
279279
### [Get-SPORestrictedSiteCreation](Get-SPORestrictedSiteCreation.md)
280280
This cmdlet allows SharePoint administrators to check the current configuration of the restricted site creation feature.
281281

282+
### [Get-SPORestrictedSiteCreationForApps](Get-SPORestrictedSiteCreationForApps.md)
283+
This cmdlet allows SharePoint administrators to check the current configuration of the restricted site creation for apps feature. > [!NOTE] > This feature is currently in preview and may not be available in your tenant.
284+
282285
### [Get-SPOServicePrioritizationAppRegistrations](Get-SPOServicePrioritizationAppRegistrations.md)
283286
Retrieves the list of app registrations configured for service prioritization in SharePoint Online.
284287

@@ -726,6 +729,9 @@ Marks a site as one of multiple possible tenant's organizational news sites. Req
726729
### [Set-SPORestrictedSiteCreation](Set-SPORestrictedSiteCreation.md)
727730
Sets or updates one or more group configurations for restricting site creation.
728731

732+
### [Set-SPORestrictedSiteCreationForApps](Set-SPORestrictedSiteCreationForApps.md)
733+
Sets or updates one or more group configurations for restricting site creation for apps. > [!NOTE] > This feature is currently in preview and may not be available in your tenant.
734+
729735
### [Set-SPOServicePrioritizationAppRegistration](Set-SPOServicePrioritizationAppRegistration.md)
730736
Updates an existing app registration for service prioritization in SharePoint Online.
731737

sharepoint/sharepoint-ps/Microsoft.Online.SharePoint.PowerShell/Set-SPOApplicationPermission.md

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,9 @@ Set-SPOApplicationPermission [-OwningApplicationId] <Guid> [-GuestApplicationId]
2727

2828
The `Set-SPOApplicationPermission` cmdlet manages permissions for a guest application's access to a SharePoint Embedded application. This includes adding, updating, and deleting guest application permissions. A guest application is defined as any application within the enterprise applications of the owning tenant.
2929

30-
You must be a SharePoint Administrator to run this cmdlet. For permissions and the most current information about Windows PowerShell for SharePoint Online, see the online documentation at [Intro to SharePoint Online Management Shell](/powershell/sharepoint/sharepoint-online/introduction-sharepoint-online-management-shell).
30+
You must be a SharePoint Embedded Administrator to run this cmdlet.
31+
32+
For permissions and the most current information about Windows PowerShell for SharePoint Online, see the online documentation at [Intro to SharePoint Online Management Shell](/powershell/sharepoint/sharepoint-online/introduction-sharepoint-online-management-shell).
3133

3234
> [!NOTE]
3335
> Only app-only permissions are supported for guest applications accessing SharePoint Embedded applications. Delegated permissions are not supported and are default set to `None`.
@@ -37,22 +39,22 @@ You must be a SharePoint Administrator to run this cmdlet. For permissions and t
3739
### Example 1
3840

3941
```powershell
40-
Set-SPOApplicationPermission -OwningApplicationId a187e399-0c36-4b98-8f04-1edc167a0996 -ApplicationId 12345678-1234-1234-abcd-abcdefghijkl -PermissionAppOnly Read, Write
42+
Set-SPOApplicationPermission -OwningApplicationId a187e399-0c36-4b98-8f04-1edc167a0996 -GuestApplicationId 12345678-1234-1234-abcd-abcdefghijkl -PermissionAppOnly Read, Write
4143
```
4244

4345
Example 1 gives the guest application with ID `12345678-1234-1234-abcd-abcdefghijkl` app-only Read, Write permissions to access the owning application Microsoft Loop of ID `a187e399-0c36-4b98-8f04-1edc167a0996`.
4446

4547
### Example 2
4648

4749
```powershell
48-
Set-SPOApplicationPermission -OwningApplicationId 5e2795e3-ce8c-4cfb-b302-35fe5cd01597 -ApplicationId 12345678-1234-1234-abcd-abcdefghijkl -PermissionAppOnly ReadContent, WriteContent -PermissionDelegated None
50+
Set-SPOApplicationPermission -OwningApplicationId 5e2795e3-ce8c-4cfb-b302-35fe5cd01597 -GuestApplicationId 12345678-1234-1234-abcd-abcdefghijkl -PermissionAppOnly ReadContent, WriteContent -PermissionDelegated None
4951
```
5052

5153
Example 2 gives the guest application with ID `12345678-1234-1234-abcd-abcdefghijkl` app-only ReadContent, WriteContent permissions to access the owning application Microsoft Designer of ID `a187e399-0c36-4b98-8f04-1edc167a0996`.
5254
### Example 3
5355

5456
```powershell
55-
Set-SPOApplicationPermission -OwningApplicationId 5e2795e3-ce8c-4cfb-b302-35fe5cd01597 -ApplicationId 12345678-1234-1234-abcd-abcdefghijkl -PermissionAppOnly None -PermissionDelegated None
57+
Set-SPOApplicationPermission -OwningApplicationId 5e2795e3-ce8c-4cfb-b302-35fe5cd01597 -GuestApplicationId 12345678-1234-1234-abcd-abcdefghijkl -PermissionAppOnly None -PermissionDelegated None
5658
```
5759

5860
Example 3 sets guest application permissions to None for the guest application with ID `12345678-1234-1234-abcd-abcdefghijkl`. This has deleted previous permissions for that guest application to access owning application of `a187e399-0c36-4b98-8f04-1edc167a0996`.
Lines changed: 216 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,216 @@
1+
---
2+
external help file: Microsoft.Online.SharePoint.PowerShell.dll-Help.xml
3+
Module Name: Microsoft.Online.SharePoint.PowerShell
4+
online version: https://learn.microsoft.com/powershell/module/microsoft.online.sharepoint.powershell/set-sporestrictedsitecreationforapps
5+
applicable: SharePoint Online
6+
title: Set-SPORestrictedSiteCreationForApps
7+
schema: 2.0.0
8+
author: vgaddam-pm
9+
ms.author: vgaddam
10+
ms.reviewer: jmcdowe
11+
---
12+
13+
# Set-SPORestrictedSiteCreationForApps
14+
15+
## SYNOPSIS
16+
17+
Sets or updates one or more app configurations for restricting site creation.
18+
19+
## SYNTAX
20+
21+
```
22+
Set-SPORestrictedSiteCreationForApps [-Enabled <Boolean>] [-Mode <RestrictedSiteCreationMode>]
23+
[-SiteType <RestrictedSiteCreationSiteType>] [-RestrictedSiteCreationApps <String>] [-WhatIf] [-Confirm]
24+
[<CommonParameters>]
25+
```
26+
27+
## DESCRIPTION
28+
29+
This cmdlet sets or updates the configuration or setting for the Restricted Site Creation For Apps feature.
30+
31+
> [!Note]
32+
> This feature is currently in preview and may not be available in your tenant.
33+
34+
## EXAMPLES
35+
36+
### Example 1
37+
38+
```powershell
39+
Set-SPORestrictedSiteCreationForApps –Enabled:$true
40+
```
41+
42+
Example 1 enables the restricted site creation for apps feature for the tenant.
43+
44+
### Example 2
45+
46+
```powershell
47+
Set-SPORestrictedSiteCreationForApps –Mode Allow
48+
```
49+
50+
Example 2 sets restricted site creation for apps to allow mode. In this mode, an app is only able to create a site if that app is in the list specified for a matching site type.
51+
52+
### Example 3
53+
54+
```powershell
55+
Set-SPORestrictedSiteCreationForApps –SiteType "All" -RestrictedSiteCreationApps "281e395b-7316-4cb2-b5bb-8881426ee411"
56+
```
57+
58+
Example 3 updates the policy for the `All` site type to apply to the app with the app ID 281e395b-7316-4cb2-b5bb-8881426ee411. This app is now either allowed or denied (depending on the current mode) from creating all OneDrive and SharePoint sites.
59+
60+
### Example 4
61+
62+
```powershell
63+
Set-SPORestrictedSiteCreationForApps –SiteType "Team" -RestrictedSiteCreationApps "78159241-04a9-41d2-8dd4-ac568e9766a3,1f95829b-e1c8-4406-b2be-508c36f4bca5"
64+
```
65+
66+
Example 4 updates the policy for the `Team` site type to apply to the two apps specified. Both apps now either allowed or denied from creating Team sites, depending on the current mode.
67+
68+
### Example 5
69+
70+
```powershell
71+
Set-SPORestrictedSiteCreationForApps –SiteType "OneDrive" -RestrictedSiteCreationApps ""
72+
```
73+
74+
Example 5 clears the policy for the `OneDrive` site type so that it no longer applies to any apps.
75+
76+
## PARAMETERS
77+
78+
### -Enabled
79+
80+
> Applicable: SharePoint Online
81+
82+
PARAMVALUE: true | false
83+
Enables or disables Restricted Site Creation For Apps feature in tenant.
84+
85+
```yaml
86+
Type: System.Boolean
87+
Parameter Sets: (All)
88+
Aliases:
89+
90+
Required: False
91+
Position: Named
92+
Default value: None
93+
Accept pipeline input: False
94+
Accept wildcard characters: False
95+
```
96+
97+
### -Mode
98+
99+
> Applicable: SharePoint Online
100+
101+
Specifies whether policies allow or deny apps from creating sites.
102+
PARAMVALUE: Deny | Allow
103+
- Deny – an app will be blocked from creating a site if any policy applies to them.
104+
- Allow – an app will only be allowed to create a site if a policy applies to them.
105+
106+
> [!NOTE]
107+
> The restricted site creation mode is shared across all site type policies. It is not possible to use deny mode for one site type and allow mode for a different site type. When the mode is changed, all policies are cleared.
108+
109+
```yaml
110+
Type: Microsoft.SharePoint.Administration.SPOnlineProvisioning.RestrictedSiteCreationMode
111+
Parameter Sets: (All)
112+
Aliases:
113+
Accepted values: Deny, Allow
114+
115+
Required: False
116+
Position: Named
117+
Default value: None
118+
Accept pipeline input: False
119+
Accept wildcard characters: False
120+
```
121+
122+
### -RestrictedSiteCreationApps
123+
124+
> Applicable: SharePoint Online
125+
126+
A comma-separated list of up to 100 app IDs. When paired with the `–SiteType` parameter, defines a new policy which applies to the specified apps.
127+
Set to the empty string `""` to clear the policy for a site type.
128+
129+
```yaml
130+
Type: System.String
131+
Parameter Sets: (All)
132+
Aliases:
133+
134+
Required: False
135+
Position: Named
136+
Default value: None
137+
Accept pipeline input: False
138+
Accept wildcard characters: False
139+
```
140+
141+
### -SiteType
142+
143+
> Applicable: SharePoint Online
144+
145+
When paired with the `–RestrictedSiteCreationApps` parameter, creates a new policy which applies to the specified types of sites.
146+
147+
PARAMVALUE: All | SharePoint | OneDrive | Team | Communication
148+
- All - OneDrive and all SharePoint sites
149+
- SharePoint - All SharePoint sites (but not OneDrive)
150+
- OneDrive - Only OneDrive
151+
- Team - Only SharePoint team sites (group-connected and classic)
152+
- Communication - Only SharePoint communication sites
153+
154+
```yaml
155+
Type: Microsoft.SharePoint.Administration.SPOnlineProvisioning.RestrictedSiteCreationSiteType
156+
Parameter Sets: (All)
157+
Aliases:
158+
Accepted values: All, SharePoint, OneDrive, Team, Communication
159+
160+
Required: False
161+
Position: Named
162+
Default value: None
163+
Accept pipeline input: False
164+
Accept wildcard characters: False
165+
```
166+
167+
### -Confirm
168+
Prompts you for confirmation before running the cmdlet.
169+
170+
```yaml
171+
Type: System.Management.Automation.SwitchParameter
172+
Parameter Sets: (All)
173+
Aliases: cf
174+
175+
Required: False
176+
Position: Named
177+
Default value: None
178+
Accept pipeline input: False
179+
Accept wildcard characters: False
180+
```
181+
182+
### -WhatIf
183+
Shows what would happen if the cmdlet runs.
184+
The cmdlet is not run.
185+
186+
```yaml
187+
Type: System.Management.Automation.SwitchParameter
188+
Parameter Sets: (All)
189+
Aliases: wi
190+
191+
Required: False
192+
Position: Named
193+
Default value: None
194+
Accept pipeline input: False
195+
Accept wildcard characters: False
196+
```
197+
198+
### CommonParameters
199+
200+
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216).
201+
202+
## INPUTS
203+
204+
### None
205+
206+
## OUTPUTS
207+
208+
### System.Object
209+
210+
## NOTES
211+
212+
## RELATED LINKS
213+
214+
[Getting started with SharePoint Online Management Shell](/powershell/sharepoint/sharepoint-online/connect-sharepoint-online)
215+
216+
[Get-SPORestrictedSiteCreationForApps](Get-SPORestrictedSiteCreationForApps.md)

0 commit comments

Comments
 (0)