Forum Discussion
iainmac
Jul 01, 2019Copper Contributor
SharePoint 365 Rest API: Add a link item in a document library
Hi I am looking into creating a new link item in a document library using rest api. I have looked around and can not find a solution as yet. Has anyone managed to achieve this? Many thank...
Toby Statham
Jul 10, 2019Brass Contributor
iainmac You need to upload a text file with an extension of .url and it contents as follows
[InternetShortcut]URL = https://yourlink
and then set the the files corresponding List Item "_ShortcutUrl" field to a FieldUrlValue of the link and the filename.
Have done this with CSOM, so should be able to do something similar through the REST API