Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failing to fetch token for userID provided by Teams Authenticator #2501

Open
priytosh-tripathi opened this issue Sep 6, 2024 · 10 comments
Open
Labels
teams issue issue that has been reviewed and likely teams specific teams-developer-support

Comments

@priytosh-tripathi
Copy link

priytosh-tripathi commented Sep 6, 2024

We're getting multiple instances where the userId provided by the function in teamsjs library, named microsoftTeams.authentication.getUser() fails to get a valid token from another function named microsoftTeams.authentication.getAuthToken() in the same session.

Teamsjs library version - 2.22.0

@AE-MS
Copy link
Contributor

AE-MS commented Sep 6, 2024

We're getting multiple instances where the userId provided the function in teamsjs library, named microsoftTeams.authentication.getUser() fails to get a valid token from another function named microsoftTeams.authentication.getAuthToken() in the same session.

Teamsjs library version - 2.22.0

Thanks for reporting this, @priytosh-tripathi. Are there any errors or rejected promises returned when you run this?

If you are able, can you please collect teamjs logs when you repro the problem so I can review them? Thanks!

@priytosh-tripathi
Copy link
Author

Some of the common Error Messages and their frequencies are as below:

  1. "Payload_AdditionalData": Teams token retrieval failure: Error: Failed to get auth token. Token is empty due to auth provider library error.,
    "count_": 12502

  2. "Payload_AdditionalData": Teams token retrieval failure: Error: Error: Unexpected {"Description":"(pii)","Domain":"com.microsoft.oneauth","ErrorCode":"1001","Message":"An unexpected error occurred.","SystemErrorCode":"3489661028","Tag":"7q6ch","Type":"OneAuth","additional_query_parameters_count":"1","all_error_tags":"7q6ch|7q6ch","api_error_code":"3489661028","api_error_context":"(pii)","api{Location}},
    "count_": 1290

  3. "Payload_AdditionalData": Teams token retrieval failure: Error: Error: Unexpected {"Description":"(pii)","Domain":"com.microsoft.oneauth","ErrorCode":"1001","Message":"An unexpected error occurred.","SystemErrorCode":"2147943811","Tag":"4wbr5","Type":"OneAuth","additional_query_parameters_count":"1","all_error_tags":"4wbr5|4wbr5","api_error_code":"2147943811","api_error_context":"(pii)","api{Location}},
    "count_": 510

  4. "Payload_AdditionalData": Teams token retrieval failure: Error: Error: ApiContractViolation {"Description":"(pii)","Domain":"com.microsoft.oneauth","ErrorCode":"2400","Message":"The operation attempted is invalid.","SystemErrorCode":"2156265473","Tag":"7q6cd","Type":"OneAuth","additional_query_parameters_count":"2","all_error_tags":"7q6cd|7q6cd","api_error_code":"2156265473","api_error_context":"(p{Location}},
    "count_": 346

@AE-MS
Copy link
Contributor

AE-MS commented Sep 10, 2024

These errors appear to be coming from OneAuth library used by Teams. I'll let the Teams developer support folks investigate further.
FYI @Wajeed-msft

@erinha erinha added the teams issue issue that has been reviewed and likely teams specific label Sep 10, 2024
@priytosh-tripathi
Copy link
Author

Hi @AE-MS / @Wajeed-msft ,

A gentle query about if we have an update on this?

@priytosh-tripathi
Copy link
Author

Hi @AE-MS / @Wajeed-msft ,

Do we have some update on this?

@Nivedipa-MSFT
Copy link

@priytosh-tripathi - Apologies for the delay. We will test this and update you soon.

@priytosh-tripathi
Copy link
Author

Sure thing @Nivedipa-MSFT - Thanks for the update!

@Nivedipa-MSFT
Copy link

@priytosh-tripathi - Could you please share your code snippet and repro video to try at our end?

@priytosh-tripathi
Copy link
Author

@Nivedipa-MSFT I have sent you message async regarding this issue. Please let me know the specific logs you need.
It isnot possible to repro this so I am unable to share video.

@Nivedipa-MSFT
Copy link

@priytosh-tripathi - We are checking this with engineering team, we will let you know once we get any input from them.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
teams issue issue that has been reviewed and likely teams specific teams-developer-support
Projects
None yet
Development

No branches or pull requests

4 participants