admin管理员组文章数量:1356762
I am working on an Outlook Add-In where I want to access the Microsoft Graph API. I am trying to replace the following code:
function getAccesToken(callback) {
Office.context.mailbox.getCallbackTokenAsync({ isRest: true }, callback);
}
With:
function getAccesToken(callback) {
Office.auth.getAccessTokenAsync({ forceConsent: false }, function(result) {
if (result.status === "succeeded") {
callback({ status: "succeeded", value: result.value });
} else {
callback({ status: "failed", error: result.error });
}
});
}
In order to use Office.auth.getAccessTokenAsync, I updated my manifest.xml to include the element as follows:
<VersionOverrides xmlns="; xsi:type="VersionOverridesV1_0">
<Requirements>
<bt:Sets>
<bt:Set Name="Mailbox" MinVersion="1.3" />
</bt:Sets>
</Requirements>
<Hosts>
......
</Hosts>
<Resources>
......
</Resources>
<WebApplicationInfo>
<Id>Your-App-Client-ID</Id>
<Resource>api://Your-App-Client-ID</Resource>
<Scopes>
<Scope>Mail.ReadWrite</Scope>
<Scope>Mail.Send</Scope>
</Scopes>
</WebApplicationInfo>
</VersionOverrides>
Problem: When I try to upload my manifest file, I receive the following error:
Upload failed. Please check the manifest file and try again.
What I've Tried:
- Double-checked that is placed within .
- Verified the Id matches my Azure AD App Registration's Application (client) ID.
本文标签:
版权声明:本文标题:Outlook Add-In: Replacing Office.context.mailbox.getCallbackTokenAsync with Office.auth.getAccessTokenAsync Fails to Validate Ma 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1744011456a2575639.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论