SharePoint / sp-dev-docs

SharePoint & Viva Connections Developer Documentation
https://docs.microsoft.com/en-us/sharepoint/dev/
Creative Commons Attribution 4.0 International
1.24k stars 1.01k forks source link

Viva Connections Desktop App Issue: Custom API calls are failing #8591

Closed Srpatil212 closed 1 year ago

Srpatil212 commented 1 year ago

What type of issue is this?

other

What SharePoint development model, framework, SDK or API is this about?

πŸ’₯ SharePoint Framework

Target SharePoint environment

SharePoint Online

What browser(s) / client(s) have you tested

Additional environment details

Desktop App for Microsoft Teams

Issue description

Following authentication calls in MS Teams Desktop client are failing while calling custom AD authenticated API calls.

https://tenant.sharepoint.com/_api/Microsoft.SharePoint.Internal.ClientSideComponent.Token.AcquireOBOToken?resource=resource id&clientId=SharePointOnlineClientExtensibilityWebApplicationPrincipalID

Error messages differ from time to time. Following have been observed:

  1. AADSTS500131: Assertion audience does not match the Client app presenting the assertion. The audience in the assertion was 'https://tenant.sharepoint.com/' and the expected audience is 'api://tenantid/microsoft.spfx3rdparty.com' or one of the Application Uris of this application with App ID (SharePoint Online Client Extensibility Web Application Principal). The downstream client must request a token for the expected audience (the application that made the OBO request) and this application should use that token as the assertion.\

2.One or more errors occurred. 3.Authentication Method is not allowed.

Please refer below screenshots for the same.

image image image

ghost commented 1 year ago

Thank you for reporting this issue. We will be triaging your incoming issue as soon as possible.

AJIXuMuK commented 1 year ago

@Srpatil212 - are you using Sync to Teams to add the SPFx app to the Teams? or do you have a custom manifest? If the latter - could you please share the manifest?

Thanks!

Srpatil212 commented 1 year ago

@AJIXuMuK Since this is Viva Connections app of Microsoft teams , we have just added the app in Teams. Our home site for sharepoint tenant has custom spfx webparts and in them we have api calls. Viva connections app is opening our sharepoint home site and the custom api calls in spfx webparts failing as mentioned above. This issue is specifically for Viva Connections app in Teams desktop client.

AJIXuMuK commented 1 year ago

@Srpatil212 could you please send the request id and request date? You can find those in the request headers.

Srpatil212 commented 1 year ago

I can share the request id and date with you separately. Please let me know your microsoft communication id.

AJIXuMuK commented 1 year ago

@Srpatil212 it's aterentiev@microsoft.com

AJIXuMuK commented 1 year ago

Marking as feedback needed as haven't heard anything back. We also made some changes that can potentially fix this issue. These changes should be rolled out next week.

ghost commented 1 year ago

This issue has been automatically marked as stale because it has marked as requiring author feedback but has not had any activity for 7 days. It will be closed if no further activity occurs within the next 7 days of this comment. Please see our wiki for more information: Issue List Labels: Needs Author Feedback & Issue List: No response from the original issue author

ghost commented 1 year ago

Closing issue due to no response from the original author. Please refer to our wiki for more details, including how to remediate this action if you feel this was done prematurely or in error: No response from the original issue author