共用方式為


Set-SPOContainerTypeConfiguration

設定或更新 SharePoint Embedded 中容器類型的組態設定。

語法

Set-SPOContainerTypeConfiguration
   -ContainerTypeId <Guid>
   [-DiscoverabilityDisabled <Boolean>]
   [-SharingRestricted <Boolean>]
   [-ApplicationRedirectUrl <String>]
   [-WhoCanShareAnonymousAllowList <Guid[]>]
   [-WhoCanShareAuthenticatedGuestAllowList <Guid[]>]
   [-OverrideTenantWhoCanShareAnonymousAllowList <Boolean>]
   [-OverrideTenantWhoCanShareAuthenticatedGuestAllowList <Boolean>]
   [[-CopilotEmbeddedChatHosts] <System.Collections.Generic.List`1[System.String]>]
   [-AnonymousLinkExpirationInDays <Int32>]
   [-WhatIf]
   [-Confirm]
   [<CommonParameters>]

Description

對於傳入的任何參數, Set-SPOContainerTypeConfiguration Cmdlet 會設定或更新在 SharePoint Embedded 應用程式下建立之容器類型的設定。

您必須是 SharePoint Embedded 系統管理員才能執行此 Cmdlet。

範例

範例 1

Set-SPOContainerTypeConfiguration -ContainerTypeId 4f0af585-8dcc-0000-223d-661eb2c604e4 -DiscoverabilityDisabled $false

範例 1 會開啟此容器類型的可探索性。 在此容器類型中建立的所有內容都可以在 Microsoft 365 體驗中探索,包括 office.com、onedrive.com、建議的檔案和其他智慧型手機探索體驗。

範例 2

Set-SPOContainerTypeConfiguration -ContainerTypeId 4f0af585-8dcc-0000-223d-661eb2c604e4 -SharingRestricted $false

範例 2 會開啟此容器類型的開放式共用模型。 任何具有編輯許可權的容器成員和來賓使用者都可以共用在容器類型內建立的檔案。

範例 3

Set-SPOContainerTypeConfiguration -ContainerTypeId 4f0af585-8dcc-0000-223d-661eb2c604e4 -OverrideTenantWhoCanShareAnonymousAllowList $true -WhoCanShareAnonymousAllowList <guids>

範例 3 會覆寫租用戶層級 WhoCanShareAnonymousAllowList

範例 4

Set-SPOContainerTypeConfiguration -ContainerTypeId 4f0af585-8dcc-0000-223d-661eb2c604e4 -OverrideTenantWhoCanShareAnonymousAllowList $true -WhoCanShareAnonymousAllowList $null -OverrideTenantWhoCanShareAuthenticatedGuestAllowList $true -WhoCanShareAuthenticatedGuestAllowList $null

範例 4 會以略過檢查的 Null 值覆寫租用戶層級 WhoCanShareAnonymousAllowListWhoCanShareAuthenticatedGuestAllowList 。 這會影響不再將外部共享許可權限制為特定安全組的成員。

範例 5

Set-SPOContainerTypeConfiguration -ContainerTypeId 4f0af585-8dcc-0000-223d-661eb2c604e4 -OverrideTenantWhoCanShareAuthenticatedGuestAllowList $true -WhoCanShareAuthenticatedGuestAllowList $null

範例 5 會以 Null 值覆寫租用戶層級 WhoCanShareAuthenticatedGuestAllowList ,同時保留 WhoCanShareAnonymousAllowList 不變的 。 其效果是不再將共用許可權限制為特定安全組成員的已驗證來賓。

範例 6

Set-SPOContainerTypeConfiguration -ContainerTypeId 4f0af585 -CopilotEmbeddedChatHosts "http://localhost:3000 https://contoso.sharepoint.com https://fabrikam.com"

本範例會設定標識碼為 4f0af585 的容器類型主機 URL。

參數

-AnonymousLinkExpirationInDays

指定設定值之後建立的所有匿名鏈接,都會在設定天數之後過期。

值可以是 1 到 730 天。

若要延遲至租用戶層級設定,請將值設定為 -1。

類型:Int32
Position:Named
預設值:None
必要:False
接受管線輸入:False
接受萬用字元:False

-ApplicationRedirectUrl

此參數會指定應用程式應該重新導向的URL。

類型:String
Position:Named
預設值:None
必要:False
接受管線輸入:False
接受萬用字元:False

-ContainerTypeId

此參數會指定對應至 SharePoint Embedded 應用程式的容器類型識別碼。

類型:Guid
Position:Named
預設值:None
必要:True
接受管線輸入:False
接受萬用字元:False

-CopilotEmbeddedChatHosts

此參數可用來新增允許使用 SharePoint Embedded 應用程式宣告式代理程式體驗的主機 URL。

類型:System.Collections.Generic.List`1[System.String]
Position:3
預設值:None
必要:False
接受管線輸入:False
接受萬用字元:False

-DiscoverabilityDisabled

身為 Microsoft 365 中的 SharePoint 系統管理員,您可以控制內容在 Microsoft 365 體驗中的顯示方式。 當此值為 true 時,SharePoint Embedded 應用程式內容會在整個 Microsoft 365 環境中隱藏,包括 office.com、onedrive.com、建議的章節,或透過其他Microsoft智慧型檔案探索功能。 如果您加入加入Microsoft 365 體驗,您的檔案將會整合到Microsoft 365環境中,參與智慧型手機檔案探索。

PARAMVALUE:True |假

類型:Boolean
Position:Named
預設值:True
必要:False
接受管線輸入:False
接受萬用字元:False
適用於:SharePoint Embedded

-OverrideTenantWhoCanShareAnonymousAllowList

這個設定會判斷容器類型 WhoCanShareAnonymousAllowList 是否覆寫租使用者層級 WhoCanShareAnonymousAllowList

PARAMVALUE:True |假

類型:Boolean
Position:Named
預設值:False
必要:False
接受管線輸入:False
接受萬用字元:False

-OverrideTenantWhoCanShareAuthenticatedGuestAllowList

這個設定會判斷容器類型 WhoCanShareAuthenticatedGuestAllowList 是否覆寫租使用者層級 WhoCanShareAuthenticatedGuestAllowList

PARAMVALUE:True |假

類型:Boolean
Position:Named
預設值:False
必要:False
接受管線輸入:False
接受萬用字元:False

-SharingRestricted

SharePoint Embedded 提供以角色為基礎的共用模型,可讓開發人員根據容器許可權角色來設定檔案共享許可權,並提供限制性與開放式共用模型之間的選擇。 開啟共用模型可讓任何具有編輯許可權的容器成員和來賓用戶共享檔案。 限制性共用模型只允許擁有者或管理員的容器成員共用檔案。

PARAMVALUE:True |假

類型:Boolean
Position:Named
預設值:True
必要:False
接受管線輸入:False
接受萬用字元:False
適用於:SharePoint Embedded

-WhoCanShareAnonymousAllowList

設定允許與匿名 (未經驗證) 使用者以及已驗證來賓用戶共用之安全組的容器類型特定清單。 這必須與 OverrideTenantWhoCanShareAnonymousAllowList一起設定。

注意事項

此允許清單只接受安全組,不接受 Microsoft 365 群組。

每個安全組都會以其 GUID 物件識別元表示。 若要將此清單設定為特定安全組,您必須輸入其 GUID 作為 參數。 您可以使用逗號來分隔多個 GUID,以輸入多個 GUID。 若要略過檢查並允許所有安全組與任何人共用,請將此允許清單和 WhoCanShareAuthenticatedGuestAllowList 設定為 Null 陣列。

類型:Guid[]
Position:Named
預設值:None
必要:False
接受管線輸入:False
接受萬用字元:False

-WhoCanShareAuthenticatedGuestAllowList

設定允許在容器層級與已驗證的來賓用戶共用之安全組的容器類型特定清單。 這必須與 OverrideTenantWhoCanShareAuthenticatedGuestAllowList一起設定。

注意事項

此允許清單只接受安全組,不接受 Microsoft 365 群組。

每個安全組都會以其 GUID 物件識別元表示。 若要將此清單設定為特定安全組,您必須輸入其 GUID 作為 參數。 您可以使用逗號來分隔多個 GUID,以輸入多個 GUID。 若要略過檢查並允許所有安全組共用給已驗證的來賓,請將此允許清單設定為 Null 陣列。

類型:Guid[]
Position:Named
預設值:None
必要:False
接受管線輸入:False
接受萬用字元:False