【发布时间】:2022-10-13 20:41:28
【问题描述】:
在这个https://learn.microsoft.com/en-us/powershell/microsoftgraph/find-mg-graph-command?view=graph-powershell-1.0 的示例中,我看到了一些叫做“变体”的东西,但是我在搜索时没有找到任何关于“变体”的解释。
具体来说,我正在尝试与我们的 Azure 团队合作,为电子邮件“markRead”功能设置适当的权限:
$graphApiPostUrl = "https://graph.microsoft.com/v1.0/admin/serviceAnnouncement/messages/markRead"
Find-MgGraphCommand -Uri $graphApiPostUrl | Format-Table -AutoSize
我请求了 ServiceMessageViewpoint.Write 许可,他们说他们给了我,但是当我尝试它时,我仍然得到“401 未授权”。我想知道我是否也需要请求变体? [我能够列出/列举电子邮件。]
我最初的问题在这里:Powershell - How to set token for GraphAPI to mark emails as read?
【问题讨论】:
-
您是否尝试对返回的 URL 使用
Invoke-AzRestMethod?
标签: azure azure-security