As part of recent changes from the Microsoft Outlook REST API deprecation https://devblogs.microsoft.com/microsoft365dev/new-nested-app-authentication-for-office-add-ins-legacy-exchange-tokens-off-by-default-in-october-2024/ we have made changes in our Outlook add-in to use NAA approach.
It was working without any issues, after changing to Outlook(New) the silent token acquire is not happening.
Note: I have a Azure app with a single tenant account.
this.pca = await PublicClientNext.createPublicClientApplication(getMsalConfig());
gmsalConfig -> i am passing ClientId, Authority and supportsnestedappauth
I have added all the required permissions and everything is followed from the documentation end. But the this.pca.getAllAccounts() always return undefined even I have tried with getAccountByUserName
which also returns null. Since the account is null, it’s trying to get a token from acquireTokenPopup
but that throws the exception. “Error: Unable to acquire access token: ServerError: invalid_client: AADSTS700046: Invalid Reply Address. Reply Address must have scheme brk-9199bf20-a13f-4107-85dc-02114787ef48:// and be of Single Page Application type. Trace ID: e050041b-eeb5-4e40-a6ce-b608c694ff00 Correlation ID: 01907de7-0afe-7de8-a132-cf696df88406 Timestamp: 2024-07-04 13:21:11Z