应用程序Azure Api中的NoPermissionsInAccessToken创建联系人 [英] NoPermissionsInAccessToken in Application Azure Api to Create Contacts

查看:137
本文介绍了应用程序Azure Api中的NoPermissionsInAccessToken创建联系人的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在Microsoft Azure的应用程序权限"中创建联系人时出现NoPermissionsInAccessToken错误.

There is an error of NoPermissionsInAccessToken while creating contacts in Application Permission in Microsoft Azure.

这是我的代码: http://phpfiddle.org/api/raw/094u-5jm7/description ,这就是我要传递的内容 http://prntscr.com/p6uiwx.

Here is my code: http://phpfiddle.org/api/raw/094u-5jm7/description and here is what I am passing http://prntscr.com/p6uiwx.

推荐答案

如果您已经授予Contacts.ReadWrite 应用权限.

If you have already granted Contacts.ReadWrite application permission.

然后,您必须获得管理员的同意.

对于客户端凭据流,您不需要委派权限.

For client credentials flow, you don't need delegated permissions.

我从中得知我的个人帐户只能创建联系人 登录后,这意味着委派了权限.

I get from this that my personal account can only create contacts after sign-in,which means delegated permission.

你是对的.

我无法创建联系人 从应用程序权限?包括这个我无法 区分租户和目录系统公司 帐户,因为我是Azure Active Directory的初学者.

I can't create contacts from applications permissions ? Including this i am unable to differentiate between tenant and directory system & company accounts,as i am beginner with Azure Active Directory.

并非如此,您可以根据应用程序权限创建联系人.但是帐户应该是租户用户.您的租户名称应类似于xxx.onmicrosoft.com,您的租户用户应为username@xx.onmicrosoft.com

Not really, you can create contacts from application permission. But the accounts should be tenant user. Your tenant name should be something like xxx.onmicrosoft.com,your tenant user should be username@xx.onmicrosoft.com

更新:

对于客户端凭据流请求,范围必须为https://graph.microsoft.com/.default

For client credentials flow request, the scope must be https://graph.microsoft.com/.default

并确保该帐户(租户用户)是电子邮件地址,否则我们无法为其创建联系人.

And make sure the account(tenant user) is an email address, or we can not create contacts for it.

这篇关于应用程序Azure Api中的NoPermissionsInAccessToken创建联系人的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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