I’ve been asked about some of the odd parameters that are now part of sharing links when you’re grabbing a copy of a link to a file or folder to share with someone else. In trying to research the answer, I found that there’s very little information in a single location that addresses this, so I’m going to give it a shot here. Keep in mind that this is my “best guess” on the topic, and it may not be totally correct and/or may change without notice. 🙂
Let’s take a couple of sample URLs:
There are three elements I’ll try to explain… the letter surrounded by colons, the letter that follows the letter surrounded by colons, and the information following the ? at the end of the URL.
The letter surrounded by colons specifies what type of file is being referenced in the URL. I was able to figure out the following file type indicators:
- :b: – PDF
- :f: – Folders
- :i: – Image
- :p: – PowerPoint
- :o: – OneNote
- :t: – Text
- :u: – Undefined
- :v: – Video
- :w: – Word
- :x: – Excel files
The letter following the letter surrounded by colons appears to indicate whether the link is to a file that is read-only (/r) or editable (/s). I was unable to get any other letter option to appear in there, but again, your mileage may vary.
Finally, there are parameters after the ? in the URL. I’ve seen d=, e=, and csf=1. From what I found, it appears that the d= and e= values have to do with creating a unique URL that can still be referenced if the document is moved elsewhere. I didn’t find a clear explanation of how exactly that works, however. The csf=1 parameter is also not readily apparent, other than it causes a lot of online complaints from people trying to figure out why Microsoft puts it there.
Basically, these strange URLs only come into play when you’re creating a sharing link for someone to read or edit a file in your OneDrive or SharePoint Online site. If you’re simply linking to a file that someone has access to via the site permissions, then you can go with a “normal” URL, like https://domain.sharepoint.com/sites/siteName/libraryName/fileName.xlsx.
Hope that helps a bit…
Thanks for this great post that you share to us.
Thanks for the explaination. I am trying to create a sharedURL via a picker in my app that constuctures a web domain and a query par linked to a sharepoint file, which reads into the app on load. For some reason if I grab the manual shareURL from sharepoint it works but cannot get createLink from graph api as it does nto include the ?e= query par, do you know what my problem is?
Thanks for the article. I’m trying to figure out how you go with a “normal” link. Is it possible to create/share one? Thanks.
Many thanks for this, nice piece of deductive work, just what we needed. We are observing something unexpected however. A MS Word file only downloads when “b” is used and not “w”. I’m not in charge of the link creation but it’s another mystery still to be fathomed.
:li: = List Item I believe