Azure active directory 使用守护程序API时计划的401未经授权
我正在使用一个守护进程身份验证API,我能够获取/groups,但是如果尝试使用/groups/GROUPID/planner/plans,我会得到一个未知错误,消息说Azure active directory 使用守护程序API时计划的401未经授权,azure-active-directory,microsoft-graph-api,microsoft-planner,Azure Active Directory,Microsoft Graph Api,Microsoft Planner,我正在使用一个守护进程身份验证API,我能够获取/groups,但是如果尝试使用/groups/GROUPID/planner/plans,我会得到一个未知错误,消息说 401 - Unauthorized: Access is denied due to invalid credentials. You do not have permission to view this directory or page using the credentials that you supplied.
401 - Unauthorized: Access is denied due to invalid credentials.
You do not have permission to view this directory or page using the credentials
that you supplied.
根据文档,我拥有Group.Read.All、Directory.Read.All、Group.ReadWrite.All、Directory.ReadWrite.All权限。我正在使用(无需用户即可访问)
)获取我的令牌的步骤。我已让管理员单击授予访问权限(它们都是“已授予的”)
唯一的问题似乎是planner的东西(我可以获取、创建、删除组,以及其他一切),我使用的是API的v1.0版,我尝试过beta版,但两个版本都不起作用
我在jwt上检查了我的访问令牌,它已经
"roles": [
"Group.Read.All",
"Directory.ReadWrite.All",
"Group.ReadWrite.All",
"Directory.Read.All"
],
我认为这意味着它们都在那里。您使用的是使用应用程序权限的客户端凭据流。但是
GET/groups/{group id}/planner/plans
api不支持应用程序权限。它需要委托权限。看到区别了吗
您正在使用使用应用程序权限的客户端凭据流。但是
GET/groups/{group id}/planner/plans
api不支持应用程序权限。它需要委托权限。看到区别了吗
:(谢谢,我觉得这是一件愚蠢的事,我在半睡半醒的时候就停止了发展。)(谢谢,我觉得这是一件愚蠢的事,我在半睡半醒的时候就停止了发展。