DEV Community

loading...
Cover image for How to disable welcome message from Office 365 groups
Experts Inside

How to disable welcome message from Office 365 groups

kasuken profile image Emanuele Bartolesi ・1 min read

Keep this post short and productive.
Request from customer: "I want to disable the welcome message for Office 365 groups in my tenant."
Solution:

The only way to remove the welcome message is connect to Exchange Online with PowerShell.
First of all you have to install the PowerShell module "ExchangeOnlineManagement".

Install-Module -Name ExchangeOnlineManagement
Enter fullscreen mode Exit fullscreen mode

Now you can connect to Exchange Online with this command:

Connect-ExchangeOnline -UserPrincipalName "<YOUR UPN>" -ShowProgress $true
Enter fullscreen mode Exit fullscreen mode

When you are connected you can disable the welcome message for the Office 365 (and other settings) with the following command:

Set-UnifiedGroup $group.Identity -AlwaysSubscribeMembersToCalendarEvents:$false -AutoSubscribeNewMembers:$false  -SubscriptionEnabled:$false -UnifiedGroupWelcomeMessageEnabled:$false
Enter fullscreen mode Exit fullscreen mode

You can disable the welcome message for all the Office 365 Groups in your tenant with the script below:

Connect-ExchangeOnline -UserPrincipalName <YOUR UPN> -ShowProgress $true

#$O365Groups = Get-UnifiedGroup | Where-Object { $_.WelcomeMessageEnabled -eq $true }
$O365Groups = Get-UnifiedGroup

foreach ($group in $O365Groups) {
    Write-Host "Disabling Welcome Message on O365 Group: " -NoNewline; Write-Host $group.DisplayName -ForegroundColor Cyan
    Set-UnifiedGroup $group.Identity -AlwaysSubscribeMembersToCalendarEvents:$false -AutoSubscribeNewMembers:$false  -SubscriptionEnabled:$false -UnifiedGroupWelcomeMessageEnabled:$false
}

Disconnect-ExchangeOnline
Enter fullscreen mode Exit fullscreen mode

Discussion

pic
Editor guide