设置 hideFromAddressLists 或 hideFromOutlookClients 时出现 ErrorGroupsAccessDenied [英] ErrorGroupsAccessDenied when setting hideFromAddressLists or hideFromOutlookClients

查看:8
本文介绍了设置 hideFromAddressLists 或 hideFromOutlookClients 时出现 ErrorGroupsAccessDenied的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直在尝试使用 beta API 使用图形在组上设置以下值:

I have been trying to set the following values on a group using graph using the beta API:

{
  "hideFromOutlookClients":  true,
  "hideFromAddressLists":  true
}

但是,我收到以下错误:

However, I get the following error:

{ 
  "code": "ErrorGroupsAccessDenied", 
  "message": "User does not have permissions to execute this action."
}

该应用程序确实具有更新组所需的权限,实际上,更新组的描述就可以了.这两个属性是几个月前添加的,但它们似乎需要不同的许可.我找不到任何其他与组"相关的权限来分配.

The application does have the required permissions for updating a Group, in fact, updating a group's description works just fine. These two properties were added a few months back but they seem to require different permission. I cannot find any other "group" related permission to assign.

在此之前有没有人使用过这些属性可以阐明这个主题?

Has anyone used these properties before that could shed some light on the subject?

推荐答案

我已经测试了你的场景.

I have tested your scene.

要更新hideFromOutlookClients"和hideFromAddressLists",我们必须分配 Group.ReadWrite.All 委托权限.

To update "hideFromOutlookClients" and "hideFromAddressLists", we have to assign Group.ReadWrite.All Delegated Permission.

另外两个委托权限 Directory.ReadWrite.AllDirectory.AccessAsUser.All 不起作用.(但这两个权限用于更新描述")

The other two Delegated Permissions Directory.ReadWrite.All and Directory.AccessAsUser.All don't work. (But these two permissions work for updating "description")

Microsoft Graph API Beta 版不断改进,因此可能会出现一些意想不到的问题.

The beta version of Microsoft Graph API is continuously improving, so there may be some unexpected issues.

更新:

您使用的是应用程序权限而不是委托权限.不幸的是,根据我的测试,目前不支持应用程序权限.您需要分配 Group.ReadWrite.All 委托权限并调用此 API 代表用户.

You are using Application permissions rather than Delegated permissions. Unfortunately, Application permissions are not supported currently based on my test. You need to assign Group.ReadWrite.All Delegated Permission and call this API on behalf of a user.

这篇关于设置 hideFromAddressLists 或 hideFromOutlookClients 时出现 ErrorGroupsAccessDenied的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆