Oct 04 2022 09:11 AM - edited Oct 04 2022 09:12 AM
I am developing a Teams Tab App where the user needs to authenticate using an external API which sends back a token. As the tab is reloaded everytime it is exited and entered again, the user would need to authenticate again. I would like to store this token somewhere. localStorage is an option, but it would be even better if I could store this token in some kind of storage associated to the Teams user using the app, so, for example, it does not need to relogin when switching from Team in web to Team standalone app.
For this, and for other use cases, I would like to know whether it is possible to store data associated to the Teams account that is using the app, so it can be later retrieved (something like a localStorage but associated to the account).
I have already had a look at this thread https://techcommunity.microsoft.com/t5/teams-developer/is-there-a-way-to-store-retrieve-persistent-d... but I don't see how getContext (as the answer says) can help me with my task. An explanation on this if it's possible will also help.
Thank you
Oct 05 2022 11:01 PM
Oct 10 2022 03:28 AM
@Peaverin -With SSO in Teams, app users have the advantage of using Teams to access apps. After logging into Teams using Microsoft or Microsoft 365 account, app users can use your app without needing to sign in again. Your app is available to app users on any device with access granted through Azure AD.
Reference Document-Overview to authentication for tabs using SSO in Teams with Azure AD - Teams | Microsoft Learn
Sample Link-Microsoft-Teams-Samples/samples at main · OfficeDev/Microsoft-Teams-Samples (github.com)
Oct 17 2022 04:46 AM
Dec 05 2022 08:18 AM
Dec 05 2022 10:49 PM