Outlook 中用于 MSGraphAccess 的 BootstrapToken

BootstrapToken forMSGraphAccess in Outlook

我想在 Outlook 中使用 SSO 通过 MSGrapAccess 获取 BookstrapToken,但我收到错误“13012”。在文档中说这个错误只有在侧载时才有可能,但我在部署插件后也会遇到这个错误。

我没有做任何特别的事情:

bootstrapToken = await OfficeRuntime.auth.getAccessToken({ allowSignInPrompt: true, allowConsentPrompt: true, forMSGraphAccess: true });

这是我得到的错误:

{code: 13012, message: "API is not supported in this platform.", name: "API Not Supported"}

所有权限都在 Azure 中授予。

是否可以获取 BootstrapToken foMSGraphAccess 或者我需要使用不同的登录方法?

谢谢

我找到了让它与参数一起工作的方法。问题是我同时使用 allowConsentPromptforMSGraphAccess。没有 allowConsentPrompt,我可以使用 forMSGraphAccess 没有问题。