Cannot convert Teams user token to ACS token #6990
Labels
documentation
Related to documentation.
msal-angular
Related to @azure/msal-angular package
msal-browser
Related to msal-browser package
Needs: Attention 👋
Awaiting response from the MSAL.js team
public-client
Issues regarding PublicClientApplications
question
Customer is asking for a clarification, use case or information.
Core Library
MSAL.js (@azure/msal-browser)
Wrapper Library
MSAL Angular (@azure/msal-angular)
Public or Confidential Client?
Public
Documentation Location
https://learn.microsoft.com/en-us/azure/communication-services/quickstarts/manage-teams-identity?pivots=programming-language-javascript
Description
I want to convert my Teams User token to an ACS token.
I successfully got my Teams User token with the tool: Angular 16 - MSAL Angular v3 Sample
but
When I want to convert it into ACS token this code drops an error:
const communicationAccessToken: CommunicationAccessToken = await client.getTokenForTeamsUser({ teamsUserAadToken: teamsToken, clientId: this.aadAppId, userObjectId: this.aadTenant, });
Error:
core.mjs:10614 ERROR Error: Uncaught (in promise): RestError: Provided access token is not valid. RestError: Provided access token is not
That token is used which is coming back from the response's payload:
let teamsToken = (this.eventPayload as AuthenticationResult)?.accessToken;
My Teams permissions seem okay.
The text was updated successfully, but these errors were encountered: