Public/generated/Get-KriticalUtcmSPOSharingSettings.ps1
|
# Kritical.PS.UTCM | Microsoft Graph UTCM REST API toolkit # (c) 2026 Kritical Pty Ltd | https://kritical.net # Kritical brand banner is rendered at module load via Write-KriticalUtcmBanner. function Get-KriticalUtcmSPOSharingSettings { <# .SYNOPSIS Kritical.UTCM shim for M365DSC resource SPOSharingSettings. .DESCRIPTION Search-replace safe: callers that today invoke Get-M365DSCSPOSharingSettings -Credential $cred -TenantId $tid can rename to Get-KriticalUtcmSPOSharingSettings -Credential $cred -TenantId $tid with ZERO other edits. Parameter shape matches the M365DSC .schema.mof exactly. By default -PreferM365DscBehavior is true. Actual Graph dispatch is delegated to Invoke-KriticalUtcmM365DscSchemaBridge. Bridge maps resource → Graph endpoint per per-resource wave; where mapping is not yet shipped, bridge returns an object with Verdict='UNMAPPED'. .NOTES Workload: SharePoint Param count: 30 #> [CmdletBinding()] param( # Specifies the resource is a single instance, the value must be 'Yes' [Parameter(Mandatory)] [ValidateSet('Yes')] [string]$IsSingleInstance, # Configures sharing capability for SharePoint [ValidateSet('ExistingExternalUserSharingOnly','ExternalUserAndGuestSharing','Disabled','ExternalUserSharingOnly')] [string]$SharingCapability, # Configures sharing capability for mysite (onedrive) [ValidateSet('ExistingExternalUserSharingOnly','ExternalUserAndGuestSharing','Disabled','ExternalUserSharingOnly')] [string]$MySiteSharingCapability, # Enables the administrator to hide the Everyone claim in the People Picker. [bool]$ShowEveryoneClaim, # Enables the administrator to hide the All Users claim groups in People Picker. [bool]$ShowAllUsersClaim, # Enables the administrator to hide the Everyone except external users claim in the People Picker. [bool]$ShowEveryoneExceptExternalUsersClaim, # Creates a Shared with Everyone folder in every user's new OneDrive for Business document library. [bool]$ProvisionSharedWithEveryoneFolder, # Accelerates guest-enabled site collections as well as member-only site collections when the SignInAccelerationDomain parameter is set. [bool]$EnableGuestSignInAcceleration, # When the feature is enabled, all external sharing invitations that are sent will blind copy the e-mail messages listed in the BccExternalSharingsInvitationList. [bool]$BccExternalSharingInvitations, # Specifies a list of e-mail addresses to be BCC'd when the BCC for External Sharing feature is enabled.Multiple addresses can be specified by creating a comma separated list with no spaces. [string]$BccExternalSharingInvitationsList, # Specifies all anonymous links that have been created (or will be created) will expire after the set number of days. [int]$RequireAnonymousLinksExpireInDays, # Specifies the external sharing mode for domains. [ValidateSet('None','AllowList','BlockList')] [string]$SharingDomainRestrictionMode, # Lets administrators choose what type of link appears is selected in the 'Get a link' sharing dialog box in OneDrive for Business and SharePoint Online [ValidateSet('None','Direct','Internal','AnonymousAccess')] [string]$DefaultSharingLinkType, # Allow or deny external users re-sharing [bool]$PreventExternalUsersFromResharing, # Enables the administrator to hide the guest users claim in the People Picker. [bool]$ShowPeoplePickerSuggestionsForGuestUsers, # Configures anonymous link types for files [ValidateSet('View','Edit')] [string]$FileAnonymousLinkType, # Configures anonymous link types for folders [ValidateSet('View','Edit')] [string]$FolderAnonymousLinkType, # When this parameter is set to $true and another user re-shares a document from a user’s OneDrive for Business, the OneDrive for Business owner is notified by e-mail. [bool]$NotifyOwnersWhenItemsReshared, # Specifies the link permission on the tenant level. Valid values to set are View and Edit. A value of None will be set to Edit as its the default value. [ValidateSet('None','View','Edit')] [string]$DefaultLinkPermission, # Only accepted value is 'Present'. [ValidateSet('Present','Absent')] [string]$Ensure, # Credentials of the account to authenticate with. [string]$Credential, # Id of the Azure Active Directory application to authenticate with. [string]$ApplicationId, # Secret of the Azure Active Directory application to authenticate with. [string]$ApplicationSecret, # Name of the Azure Active Directory tenant used for authentication. Format contoso.onmicrosoft.com [string]$TenantId, # Thumbprint of the Azure Active Directory application's authentication certificate to use for authentication. [string]$CertificateThumbprint, # Username can be made up to anything but password will be used for CertificatePassword [string]$CertificatePassword, # Path to certificate used in service principal usually a PFX file. [string]$CertificatePath, # Managed ID being used for authentication. [bool]$ManagedIdentity, # Enable Guest access to a site or Onedrive to expire after [bool]$ExternalUserExpirationRequired, # Specifies Number of days for Guest Access links to expire. [int]$ExternalUserExpireInDays ) Invoke-KriticalUtcmM365DscSchemaBridge -ResourceName 'SPOSharingSettings' -Workload 'SharePoint' -Verb 'Get' -CallerParams $PSBoundParameters } |