我正在创建一个Excel内容外接程序并实现SSO。当它在桌面客户端Excel应用程序上运行时,一切正常。它成功地获得了外接程序令牌,然后获得了MSG令牌。但是,当我在sideloading中使用旁瓣时,方法getAccessTokenAsync()返回的是错误代码1300。
Error code: 13000
Error name: API Not Supported.
Error message: The identity API is not supported for this add-in.我是登录到办公室365帐户,从同一租户授予行政许可。我在舱单上增加了以下内容:
<Requirements>
<Sets DefaultMinVersion="1.1">
<Set Name="IdentityAPI"/>
</Sets>
</Requirements> 而且,Office.context.requirements.isSetSupported('IdentityAPI',1.1)正在返回true。
清单中的<WebApplicationInfo>部分如下所示:
<WebApplicationInfo>
<Id>{application_GUID}</Id>
<Resource>api://localhost:44377/{application_GUID}</Resource>
<Scopes>
<Scope>openid</Scope>
<Scope>offline_access</Scope>
<Scope>profile</Scope>
<Scope>files.read.all</Scope>
<Scope>sites.readwrite.all</Scope>
<Scope>user.read</Scope>
<Scope>files.readwrite.all</Scope>
<Scope>files.read.write</Scope>
</Scopes>
</WebApplicationInfo>https://stackoverflow.com/questions/49736920
复制相似问题