我正在从 https://login.microsoftonline.com/common/oauth2/v2.0/authorize
请求OAuth2.0令牌 . 我正在申请这些范围:
[
'https://graph.microsoft.com/User.Read',
'https://graph.microsoft.com/Calendars.Read.Shared',
'offline_access',
'profile',
'email',
'https://outlook.office.com/mail.read'
]
我试图获得Microsoft Graph范围和Office 365范围,但它给了我:
AADSTS70011:输入参数“scope”的提供值无效 . 范围https://graph.microsoft.com/User.Read https://graph.microsoft.com/Calendars.Read.Shared offline_access profile email https://outlook.office.com/mail.read无效
如果我取出 outlook.office.com
范围或两个 graph.microsoft.com
范围,那么它可以工作 .
有没有办法访问这两个?
1 回答
在v2.0 auth模型中不支持为同一请求中的两个资源请求权限,尝试分离请求,只要您为每个资源受众获取访问令牌,就可以访问这两个API .