question

NiekHodes-0936 avatar image
0 Votes"
NiekHodes-0936 asked ·

SSO on Teams Tab web application doesn't work in Teams Application


Situation:
We are trying to configure a Teams Tab that shows a website.
We used App Studio to configure our app. We followed this guide to do so:
https://dev.to/vishesh/how-to-create-a-microsoft-teams-tab-app-2jon It works perfectly in a browser, however when opening the app in de Teams app in Windows SSO doesn't seem to be working.

We also tried configuring an App registration to configure SSO using the Microsoft Teams Toolkit, and then used the App Studio from there where it did additionally fill in the Single-Sign-On url like this:
api://{tenant}.onmicrosoft.com/{appID}.
Even after configuring this, SSO did still work in the browser, however when using a tab it still was not functional, and we just got a white screen.

We also tried changing the content URL to the saml login page, however that did not change anything: It still worked perfectly via the browser, but not in the app.

When looking at the way to configure this for Sharepoint embedded apps as in this manual: https://docs.microsoft.com/en-us/sharepoint/dev/features/embed-pages-to-teams It seems the content URL adds: SPFX=true&dest={PATH}

We did find a workaround to get SSO working for the app, following the example of this guide: https://tomtalks.blog/2019/11/adding-outlook-email-and-calendar-app-to-microsoft-teams-a-proof-of-concept/.
However this would require extra steps for the users:
When opening the same website in a a tab in a Teams channel first, SSO works perfectly there.
74300-website.png
Then after it worked in that tab in the channel, we can open the app as a personal tab, and then SSO works perfectly there as well (probably because it uses the same token as it did in the channel).

Question:
How can we get SSO to work for our web application in the Teams application?

Current manifest of our app:

{
"$schema": "https://developer.microsoft.com/en-us/json-schemas/teams/v1.8/MicrosoftTeams.schema.json",
"manifestVersion": "1.8",
"version": "1.0.0",
"id": "{SECRET",
"packageName": "com.microsoft.teams.extension",
"developer": {
"name": "Teams App, Inc.",
"websiteUrl": "https://teamstogo.onmicrosoft.com",
"privacyUrl": "https://teamstogo.onmicrosoft.com/privacy",
"termsOfUseUrl": "https://teamstogo.onmicrosoft.com/termsofuse"
},
"icons": {
"color": "color.png",
"outline": "outline.png"
},
"name": {
"short": "KB Owl",
"full": "Knowledge Owl"
},
"description": {
"short": "Short description for Test.",
"full": "Full description of Test."
},
"accentColor": "#FFFFFF",
"staticTabs": [
{
"entityId": "index",
"name": "Personal Tab",
"contentUrl": "https://ogd-test.knowledgeowl.com/help/saml-login",
"websiteUrl": "https://ogd-test.knowledgeowl.com",
"scopes": [
"personal"
]
},
{
"entityId": "about",
"scopes": [
"personal"
]
}
],
"permissions": [
"identity",
"messageTeamMembers"
],
"validDomains": [
"ogd-test.knowledgeowl.com",
"teamstogo.onmicrosoft.com"
],
"webApplicationInfo": {
"id": "{SECRET",
"resource": "api://teamstogo.onmicrosoft.com/{SECRET}"
}
}


office-teams-app-dev
website.png (17.5 KiB)
· 1
10 |1000 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Hi @NiekHodes-0936

According to your description, your issue is more related to development, which we do not support. I will remove "office-teams-windows-itpro" and add "teams-dev" tag. Hope you get better response!

0 Votes 0 ·

1 Answer

MallipriyaMSFT-6171 avatar image
1 Vote"
MallipriyaMSFT-6171 answered ·

Hi @NiekHodes-0936,
Could you please have a look at the SSO for Tabs In Teams document and try this code sample and also please debug and check the console logs for errors in desktop app by following the document - DevTools for Microsoft Teams tabs - Teams | Microsoft Docs.


· 1 ·
10 |1000 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

@NiekHodes-0936 , Is this issue resolved ? any details on log errors?

0 Votes 0 ·