09-09-21 04:30 PM
Hi BP community,
We recently have implemented the SharePoint Graph api and already have made some custom actions. Now we are trying to create an action similar to the “Check File Exists” from the File Management Utility. With the current “Get Drive Item” action we are able to get the files within a specific folder, however we still have to loop through the whole collection and this is not really efficient.
We have tried creating a custom action using the following get request (relative file path should also include the file name and extension): “https://graph.microsoft.com/v1.0/sites/[SiteId]/drives/[DriveId]/root:/[Relative File Path]”. This action does work when the file exists, however will throw a 404 error when the file does not exists, resulting in no output and thus is not an ideal solution.
Do any of you guys have experience or an idea on how we could create a custom api action similar to the Check File Exist action? Ideally we would like the action to output a flag data item to indicate whether the file exist within a particular folder on SharePoint.
Many thanks in advance!
With kind regards,
Arthur Philippa
13-09-21 05:37 PM
15-09-21 07:27 AM
15-09-21 03:05 PM