Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deeplink to file using /viewer/teams does not work in New Teams #2269

Closed
pheidler opened this issue Apr 15, 2024 · 9 comments
Closed

Deeplink to file using /viewer/teams does not work in New Teams #2269

pheidler opened this issue Apr 15, 2024 · 9 comments

Comments

@pheidler
Copy link

Deeplinking to a file not stored in a Channel/Shared Documents folder no longer works in New Teams. This previously worked in Classic Teams using the /viewer/teams API. See here: https://techcommunity.microsoft.com/t5/teams-developer/how-to-open-a-file-in-the-custom-spfx-teams-tab-in-ms-teams/m-p/1786898/highlight/true#M2003

@Prasad-MSFT
Copy link

Hi @pheidler - Could you please let us know which deep link format you have used to navigate to file?

@Prasad-MSFT
Copy link

Hi @pheidler - Could you please let us know from where you got this deep link to file format? Because in the official documentation the format is suggested as:
https://teams.microsoft.com/l/file/<fileId>?tenantId=<tenantId>&fileType=<fileType>&objectUrl=<objectURL>&baseUrl=<baseURL>&serviceName=<Name>&threadId=<threadId>&groupId=<groupId>

Also please do share your complete deep link which you used, (as from the syntax it's not quite clear) so that we can form a similar deep link at our end.

@Prasad-MSFT
Copy link

Prasad-MSFT commented Apr 22, 2024

@Prasad-MSFT Yes, like this: https://teams.microsoft.com/_#/${document.FileType}/viewer/teams/${document.Url}?threadId=${channelId}&baseUrl=${siteUrl}&fileId=${document.FileUniqueId}&ctx=files&viewerAction=view

@pheidler If your file is not stored in any channel, where is it stored in SharePoint? and which thread/channel id are you using in the deeplink Url which you shared?

This is the only supported deep link format for configuring a deep link to connect to a file in a channel:
https://teams.microsoft.com/l/file/<fileId>?tenantId=<tenantId>&fileType=<fileType>&objectUrl=<objectUrl>&baseUrl=<baseUrl>&serviceName=<Name>&threadId=<threadId>&groupId=<groupId>
https://learn.microsoft.com/en-us/microsoftteams/platform/concepts/build-and-test/deep-link-teams#generate-deep-links-to-a-file-in-a-channel

There is no deep link format available in official documentation for files stored outside team's channel.

@pheidler
Copy link
Author

pheidler commented Apr 22, 2024

@Prasad-MSFT It's stored in the backing team site. The channel ID is from the Teams tab context. We use this feature to display documents that are managed through our SPFx app and stored in a separate folder than Shared Documents. If this is not currently supported, can we expect this feature to be added at some point? This is a key feature for us that the switch to New Teams has removed.

@Prasad-MSFT
Copy link

Prasad-MSFT commented Apr 23, 2024

@pheidler - To achieve your requirements, we recommend you give your feedback in Teams Feedback Portal.

@ChetanSharma-msft
Copy link

We are closing this issue for now, please feel free to reopen it, if required.

Copy link
Contributor

Tell us about your experience!

Hi pheidler! We have closed this issue in our system, but we would love to hear your feedback. To let us know how we did, simply use one of the following emoji icons: 👍 for resolved, 👎 for unresolved, or ❤️ for a great experience on this message. Please use the link for more detailed feedback.

Best regards,
Teams Platform

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants