我试图使用Sample Graph API应用更改用户的密码,但我发现:变化Azure的AD B2C用户密码与图形API
错误调用图形API响应:
{
"odata.error": {
"code": "Authorization_RequestDenied",
"message": {
"lang": "en",
"value": "Insufficient privileges to complete the operation."
}
}
}
图形API请求:
PATCH /mytenant.onmicrosoft.com/users/some-guid?api-version=1.6 HTTP/1.1
client-request-id: ffd564d3-d716-480f-a66c-07b02b0e32ab
date-time-utc: 2017.08.10 03:04 PM
JSO N文件
{
"passwordProfile": {
"password": "Somepassword1$",
"forceChangePasswordNextLogin": false
}
}
我测试过更新用户的displayName
和工作正常。
{
"displayName": "Joe Consumer"
}
AD应用程序的权限
我已经配置my app permissions as described here.
你能请张贴相关ID +时间戳从这个错误? –
其中是相关ID? https://stackoverflow.com/questions/45593823/wheres-the-correlation-id-in-the-graph-api-response – spottedmahn
我已经添加了它。谢谢你的帮助! @DanielDobalian – spottedmahn