Hello,
I'm building a notification system and I'd like to be able to send links trought a chat bot that open inside of the team app.
At the moment, I'm using a concat statement with the task ID to generate a link :
<a href="@{concat('https://tasks.office.com/ZZZ.com/en-CA/Home/Task/', string(outputs('Obtenir_les_détails_de_la_tâche')?['body/id']))}">Vous pouvez accéder a la tache en cliquant ici</a>
This works "okay", but it open the Planner app inside of a web browser. I'd like to stay inside of the teams app.
I can see that the link that is accesible in the planner tab under the three dots and "copy the link to this task" in teams actually has the wanted behavior:
If I copy that and send it to myself trough a workflow chat bot, it does exactly what I want.
How can I generate this type of link inside of my power automate flow?
https://teams.microsoft.com/l/entity/com.microsoft.teamspace.tab.planner/tt.c_19:3127b66dae40474d9a949e3323567ba7@thread.tacv2_p_LCkwMrJ9B06NkLBOlKLtMX0AAGI6_h_1714585257351?tenantId=c7d8bfd1-a4c1-4aac-9142-d7810f1284e3&webUrl=https%3A%2F%2Ftasks.teams.microsoft.com%2Fteamsui%2FpersonalApp%2Falltasklists&context=%7B%22subEntityId%22%3A%22%2Fv1%2Fplan%2FLCkwMrJ9B06NkLBOlKLtMX0AAGI6%2Ftask%2FlYYryrkNNk6fnsJtV2kNoX0AAx3M%22%2C%22channelId%22%3A%2219%3A3127b66dae40474d9a949e3323567ba7%40thread.tacv2%22%7D
The structure seems a bit more complicated then just a task ID as a parameter so I'm not sure if the concat strategy would be valid in this case 🙄
I managed to get it to work!
If anyone elese is looking for a solution here how I did it:
{"subEntityId":"/v1/plan/LCkwMrJ9B06NkLBOlKLtMX1AAGI6/task/lYYryrkMNk6fnsJtV2kNoX0AAx3M","channelId":"19:3127b66dae40474b9a949e3323567ba7@thread.tacv2"}​
That will generate a link that points to a specific task and open inside of the team planner tab. Here is my actual formula:
concat('https://teams.microsoft.com/l/entity/com.microsoft.teamspace.tab.planner/tt.c_19:3127b66dae40474d9b949e3323567ba7@thread.tacv2_p_LCkwMrJ9B06NkLBOlPLtMX0AAGI6_h_1714585257351?tenantId=c7d8bfd1-a4c1-4abc-9142-d7810f1284e3
&webUrl=https%3A%2F%2Ftasks.teams.microsoft.com%2Fteamsui%2FpersonalApp%2Falltasklists&context=', encodeUriComponent(replace('{"subEntityId":"/v1/plan/LCkwMrJ7B06NkLAOlKLtMX0AAGI6/task/lYYrytkNNk6fnsJtV2kNoX0AAx3M","channelId":"19:3127b66dae40474d9a949e3323567ba7@thread.tacv2"}', 'lYYryrkNNk6fnsJtV2kNoX0AAx3M', variables('Task_ID'))))