Forum Discussion
Link to a personal chat from Task browser
diegoSpace What do you mean by a Task web browser? Could you please share some screenshots of the issue?
Gousia_Begum Thanks for your reply
When I use Messaging Extensions I am receiving a 'FetchTask' event, and I am returning a task with a URL, so a "Teams browser" is open.
In the web page displayed with that URL, I add a text link (<a href=linkToPersonalChat>Open personal chat</a>). I want this link opens directly the personal chat in Teams client (as happens when use a button in a Card sent a channel), but what I see is Teams page in this "Teams browser".
I hope you can understand me
Thanks,
Diego
- Gousia_BegumMar 04, 2020Microsoft
diegoSpace If you are trying to open the link from a web page you could pass it under microsoftTeams.executeDeeplink('yourdeeplink url'); If you want to open it using a card, please try putting a Action.OpenURL which will directly open the chat with the user.
- diegoSpaceMar 04, 2020Brass Contributor
Gousia_BegumThanks for your reply.
If I try to use 'microsoftTeams.executeDeeplink' in the web page displayed in a task I get an error: 'microsoftTeams.executeDeeplink is not a function'. However, 'microsoftTeams.tasks.submitTask();' is working
Do I need to add something to use the 'executeDeeplink'?
- Gousia_BegumMar 06, 2020Microsoft
diegoSpace Could you please confirm if you have included the script for MsTeams in your web page?
"https://unpkg.com/@microsoft/teams-js@1.4.2/dist/MicrosoftTeams.js"After adding this you can use it like:
<script>
microsoftTeams.initialize();
microsoftTeams.executeDeepLink('your Deeplink')
</script>