Downloading a file from Sharepoint
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
16-03-22 11:09 PM
------------------------------
Ankita Karnany
Principal Consultant
Agilisys
London
------------------------------
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
17-03-22 05:16 AM
Have you tried using the Graph API based Sharepoint asset available on DX https://digitalexchange.blueprism.com/dx/entry/3439/solution/microsoft-graph-api---sharepoint. There is an action available in it that downloads file.
------------------------------
Shashank Kumar
DX Integrations Partner Consultant
Blue Prism
Singapore
+6581326707
------------------------------
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
17-03-22 08:58 AM
Seems like the asset doesn't exist..
------------------------------
Ankita Karnany
Principal Consultant
Agilisys
London
------------------------------
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
17-03-22 10:17 AM
Can you try this link https://digitalexchange.blueprism.com/dx/entry/3439/solution/microsoft-graph-api---sharepoint
------------------------------
Shashank Kumar
DX Integrations Partner Consultant
Blue Prism
Singapore
+6581326707
------------------------------
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
17-03-22 11:38 AM
I have managed to download the API, however could you also help with the parameters I need to pass . I haven't used it earlier so not aware on how we can use this.
------------------------------
Ankita Karnany
Principal Consultant
Agilisys
London
------------------------------
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
17-03-22 11:52 PM
There's a new VBO that should be published to the DX early next week. It's called Microsoft Graph - Dowload Files. The VBO provides a simplified means of downloading files from various Microsoft resources including SharePoint, OneDrive, Group drives, User drives, and Pre-Authenticated URLs.
The Download File action on the Microsoft Graph - SharePoint connector may or may not work for you. The issue is that the connector is built using the Web API feature of Blue Prism and that feature doesn't like downloading files that contain binary content (ex. PDFs). That's why we create the new VBO. It can handle binary files as expected.
If the file you're trying to download from SharePoint is a regular text file, the Download File action will work find. There are a few things you need to understand though in order to use the Microsoft Graph assets:
- You also need to use the Microsoft Graph - Authentication VBO. You can find that here. This VBO is used to request an access token from Microsoft. You need to keep track of that token and pass it in as an input parameter to most of the other Microsoft Graph connectors.
- To use the Authentication VBO you need a few things:
- You need to know your Tenant ID on Microsoft 365. Your tenant ID has two forms: You domain or a GUID. Here are some examples: contoso.onmicrosoft.com or 471d90aa-6db9-4a11-9479-799d3a8d7547
- You'll also need a Client ID and Client Secret (for an Application Access token). If you want a Delegated Access token you'll need a Client ID, Client Secret and the username and password of the user account you're trying work on behalf of. There's information about this in the Microsoft Graph - Authentication VBOs user guide.
- Once you have the Authentication VBO sorted and you're able to issue a successful request for a token you'll be ready to work with SharePoint connector. At this point you need to know the Site ID, Drive ID, and File ID of the specific file you want to download. These ID's are unique alphanumeric identifiers. You can get them by working through some of the other actions available on the SharePoint connection (namely the Get and List operations) to see the details of items within the SharePoint site. Alternatively, you could try using Microsoft's Graph Explorer utility to get that information.
Graph Explorer is a web-based utility for testing the various Graph endpoints.
That VBO has a action called HTTP Request File. You can pass in your URL, set the Method to GET, enter the FilePath (where you want to file saved to), and you should be good to go. That is assuming the URL you have doesn't require authentication.
Cheers,
------------------------------
Eric Wilson
Director, Integrations and Enablement
Blue Prism Digital Exchange
------------------------------
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
21-03-22 09:52 PM
------------------------------
Ankita Karnany
Principal Consultant
Agilisys
London
------------------------------
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
29-03-23 04:43 AM
I have a direct download URL of SharePoint but it needs authentication.
My link is : https://spanet.sharepoint.com/sites/TOC/Lists/OMS%20%20Application%20Data/Attachments/954/VA-21841.pdf
What do I need to do to download directly from the download URL using Utility - HTTP VBO?
I tried Utility - HTTP but got a 404 Unauthorized error.
How to pass the authentication?
------------------------------
Abhirup Das
------------------------------
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
29-03-23 05:19 AM
Looks like the user doesn't have the necessary permissions to download the file.
Please check the permissions in the Azure portal
https://learn.microsoft.com/en-us/graph/api/driveitem-get-content?view=graph-rest-1.0&tabs=http
------------------------------
Shashank Kumar
DX Integrations Partner Consultant
Blue Prism
Singapore
+6581326707
------------------------------
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
29-03-23 06:41 AM
I check the permission is given.
The Action Properties are following :
Can you please guide me what I'm doing wrong?
------------------------------
Abhirup Das
------------------------------
