Gabriel Smoljar
Mar 27, 2023Brass Contributor
Get direct link to file from RenderListDataAsStream API
I am refactoring old code from using Microsoft.SharePoint.Client.List.GetListItems to RenderListDataAsStream as it seems to support large lists better.
One problem is that I currently get the LinkingUri from ListItem.File.LinkingUri. This is the same link as you would get from sharing with "people with existing access" from the modern UI. I am unable to find a way to include this in the response from RenderListDataAsStream, as getting it in a separate request for each file would be expensive.
Example url: https://contoso.sharepoint.com/sites/teamsite/Shared%20Documents/foobar.xlsx?d=w258e6a73e2574e9ca3a81ab9555d01e9&csf=1&web=1&e=LDfMkk