Forum Discussion
Custome app in left navigation - deeplink to different sharepoint pages?
Hi oskarkuus,
To generate a deep link to a specific SharePoint page in your custom Microsoft Teams app, follow these steps:
Obtain the URL of the SharePoint page you want to link to, for example: https://mycompany.sharepoint.com/sites/Intranat/SitePages/MyPage.aspx.
URI encode the SharePoint URL, replacing any special characters with their encoded values. You can use online tools for this encoding.
Construct the deep link for your Teams app. The format is https://teams.microsoft.com/l/entity/<AppId>/<EntityID>. Replace <AppId> with your app's ID and <EntityID> with the ID of the tab within your app.
For example: https://teams.microsoft.com/l/entity/8bf7ccfe-406b-4129-a504-f406901ae8c5/091a285d-5536-42b5-94c8-94a4060efb79
Append the encoded SharePoint URL as a query parameter named webUrl to the deep link. Ensure the query parameter is properly formatted.
This composed URL should open your app in Microsoft Teams and navigate directly to the specified SharePoint page.
Thank you.
But that is how i think i just wrote how i have done
https://teams.microsoft.com/l/entity/8bf7ccfe-406b-4129-a504-f406901ae8c5/091a285d-5536-42b5-94c8-94a4060efb79?webUrl=https%3A%2F%2Fmycompany.sharepoint.com%2Fsites%2FIntranat%2FSitePages%2FMyPage.aspx
This URL is :
https://teams.microsoft.com/l/entity/<appID>/<entityId>?webUrl=https%3A%2F%2Fmycompany.sharepoint.com%2Fsites%2FIntranat%2FSitePages%2FMyPage.aspx
And according to your guide i think this should be correct?
What am i doing wrong?
- LeonPavesicFeb 12, 2024Silver Contributor
Hi oskarkuus,
it seems you've already tried the correct approach but I would still recommend to check:SharePoint Page Access:
- Verify that users have the necessary permissions to access the specific SharePoint page you're linking to. Insufficient permissions could prevent the deep link from working as expected.
- oskarkuusFeb 12, 2024Brass Contributor
I Have tripplechecked access to sharepoint.
My account created site, page and click on the url
How to get this to work?
- vikram-MFSTMar 06, 2024Former Employee
Hello oskarkuus
sorry for the delay in response ,
We have repro'd the steps with tab app navigation sample but the composed URL works fine in opening app in Microsoft Teams and navigate directly to the specified SharePoint page.
Could you please confirm or let us know whether you are still facing this issue?