
Overcome taskpane add-in (Word) SSO issue - error 13000
Ed Neary
20
Reputation points
We are creating an add-in that needs to retrieve the user's M365 email - the add-in is a taskpane and made for Word and Excel. The issue occurs when getting the access token prior to calling the graph api.
Office.onReady(async () => {
try {
// fails here
const accessToken = await OfficeRuntime.auth.getAccessToken({ allowSignInPrompt: true });
const user = await getUserDetails(accessToken);
document.getElementById("userInfo").innerText =
`Name: ${user.displayName}\nEmail: ${user.mail || user.userPrincipalName}`;
}
catch (error) {
console.error("Error:", error);
}
});
The error is:
{name: 'API Not Supported', message: 'The identity API is not supported for this add-in.', code: 13000}
The add-in manifest is:
The html and javascript for the add-in is hosted locally:
https://localhost/simple.html
Here are the details for the Azure application:
Microsoft 365 and Office | Development | Office JavaScript API

Sign in to answer