Hi all,
I want to prevent creating sharepoint site every time user create Microsoft Team group.
I read this article https://www.sprobot.io/learn/disable-standard-teams-and-sharepoint-site-creation
I did step 2 Disable SharePoint site creation
I get issue with step 1 Limit Microsoft 365 group creation , I followed this guide https://learn.microsoft.com/en-us/microsoft-365/solutions/manage-creation-of-groups?view=o365-worldwide
.\GroupCreators.ps1
Welcome to Microsoft Graph!
Connected via delegated access using 14d82eec-204b-4c2f-b7e8-296a70dab67e
Readme: https://aka.ms/graph/sdk/powershell
SDK Docs: https://aka.ms/graph/sdk/powershell/docs
API Docs: https://aka.ms/graph/docs
NOTE: You can use the -NoWelcome parameter to suppress this message.
Update-MgBetaDirectorySetting : Insufficient privileges to complete the operation.
Status: 403 (Forbidden)
ErrorCode: Authorization_RequestDenied
Date: 2024-09-20T08:21:40
Headers:
Transfer-Encoding : chunked
Vary : Accept-Encoding
Strict-Transport-Security : max-age=31536000
request-id : bf515205-b265-4fb1-baab-6a9bc3f12836
client-request-id : 6532efd2-1951-4d37-93e4-46480c6671cd
x-ms-ags-diagnostic : {"ServerInfo":{"DataCenter":"Southeast Asia","Slice":"E","Ring":"5","ScaleUnit":"000","RoleInstance":"SI1PEPF00001A31"}}
x-ms-resource-unit : 1
Cache-Control : no-cache
Date : Fri, 20 Sep 2024 08:21:40 GMT
At D:\jack\GroupCreators.ps1:45 char:1
+ Update-MgBetaDirectorySetting -DirectorySettingId $settingsObjectID - ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: ({ DirectorySett...ectorySetting }:<>f__AnonymousType206`3) [Update-MgBetaDirectorySetting_Update], Exception
+ FullyQualifiedErrorId : Authorization_RequestDenied,Microsoft.Graph.Beta.PowerShell.Cmdlets.UpdateMgBetaDirectorySetting_Update
Name Value
---- -----
NewUnifiedGroupWritebackDefault true
EnableMIPLabels false
CustomBlockedWordsList
EnableMSStandardBlockedWords false
ClassificationDescriptions
DefaultClassification
PrefixSuffixNamingRequirement
AllowGuestsToBeGroupOwner false
AllowGuestsToAccessGroups true
GuestUsageGuidelinesUrl
GroupCreationAllowedGroupId
AllowToAddGuests true
UsageGuidelinesUrl
ClassificationList
EnableGroupCreation true
Please give me some advice, thank you very much.