Azure Office365:跟进收件箱powershell
是否有方法将PowerShell命令写入组以“在收件箱中跟踪”Azure Office365:跟进收件箱powershell,azure,powershell,office365,Azure,Powershell,Office365,是否有方法将PowerShell命令写入组以“在收件箱中跟踪” 或者微软图形API 我正在尝试通过代码实现此功能,但看不到任何文档 在office 365中,加入组的每个用户都可以使用下拉列表选择“收件箱中的关注”或“收件箱中的停止关注”: 我不知道是否有可能通过Powershell做到这一点。您可以在Office365的AdminCenter gui的组设置中进行设置 请看这里: 更新: Get-UnifiedGroupLinks -Identity <email address>
或者微软图形API
我正在尝试通过代码实现此功能,但看不到任何
文档
在office 365中,加入组的每个用户都可以使用下拉列表选择“收件箱中的关注”或“收件箱中的停止关注”:
我不知道是否有可能通过Powershell做到这一点。您可以在Office365的AdminCenter gui的组设置中进行设置 请看这里: 更新:
Get-UnifiedGroupLinks -Identity <email address> -LinkType Subscribers
Add-UnifiedGroupLinks -Identity <email address> -LinkType Subscribers -Links <comma separated list of email addresses>
Remove-UnifiedGroupLinks -Identity <email address> -LinkType Subscribers -Links <comma separated list of email addresses>
您似乎可以使用Graph API来实现这一点:
函数“UpdateGroup”和设置“AutoSubscribeenMembers”
注意:这只对新成员有效,对现有成员无效 谢谢你,汉内斯这是我写的PowerShell:
$UserCredential = Get-Credential
$Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://outlook.office365.com/powershell-liveid/ -Credential $UserCredential -Authentication Basic -AllowRedirection
Import-PSSession $Session
<#Get all Office 365 Groups that AutoSubscribeNewMembers disabled#>
$O365Groups = Get-UnifiedGroup | Where-Object{$_.AutoSubscribeNewMembers -eq $false}
<#Iterate through the Groups, enabling the AutoSubscribeNewMember#>
foreach ($group in $O365Groups)
{
Set-UnifiedGroup $group.Identity -AutoSubscribeNewMembers:$true
}
<#Close the Session#>
Remove-PSSession $Session
$UserCredential=获取凭证
$Session=New PSSession-ConfigurationName Microsoft.Exchange-ConnectionUrihttps://outlook.office365.com/powershell-liveid/ -凭证$UserCredential-身份验证基本-AllowerDirection
导入PSSession$会话
$O365Groups=Get UnifiedGroup |其中对象{$\ autosubscribeenMembers-eq$false}
foreach($O365组中的组)
{
设置UnifiedGroup$group.Identity-自动订阅成员:$true
}
删除PSSession$会话
仅适用于组中的新成员我正在搜索相反的命令,由于外部用户接收到不需要向外部发送的组的电子邮件,因此可以从powershell手动取消用户订阅 以下是连接到Exunge Online powershell版本2的powershell命令: 查看订户:
Get-UnifiedGroupLinks -Identity <email address> -LinkType Subscribers
Add-UnifiedGroupLinks -Identity <email address> -LinkType Subscribers -Links <comma separated list of email addresses>
Remove-UnifiedGroupLinks -Identity <email address> -LinkType Subscribers -Links <comma separated list of email addresses>
Get UnifiedGroupLinks-Identity-LinkType订阅者
添加订户:
Get-UnifiedGroupLinks -Identity <email address> -LinkType Subscribers
Add-UnifiedGroupLinks -Identity <email address> -LinkType Subscribers -Links <comma separated list of email addresses>
Remove-UnifiedGroupLinks -Identity <email address> -LinkType Subscribers -Links <comma separated list of email addresses>
addunifiedgrouplinks-Identity-LinkType订阅者-Links
删除订阅服务器:
Get-UnifiedGroupLinks -Identity <email address> -LinkType Subscribers
Add-UnifiedGroupLinks -Identity <email address> -LinkType Subscribers -Links <comma separated list of email addresses>
Remove-UnifiedGroupLinks -Identity <email address> -LinkType Subscribers -Links <comma separated list of email addresses>
删除UnifiedGroupLinks-Identity-LinkType订阅者-Links
我一直在为这个主题编写一些示例命令:(用于完整的代码示例列表) 一些样本:
#Check subscription status for ALL unified groups
Get-UnifiedGroup | Format-Table Name,*subscribe* -AutoSize
这里是PowerShell,用于将所有“成员”添加到“订阅者”(也称为“收件箱中的关注者”)中
请详细描述你的问题。我不知道你说的“收件箱跟进”是什么意思。添加了图片示例