cancel
Showing results for 
Search instead for 
Did you mean: 

UPDATE: Microsoft Graph - SharePoint Upload Session v2

ewilson
Staff
Staff
Hello Community,

Just wanted to let you all know that an update to the Microsoft Graph - SharePoint Upload Session asset has been published on the DX. This update addresses the issue of the Upload File action not working properly.

You should also be aware that in order to fix this issue the asset had to be converted from a WebAPI service definition to a traditional Visual Business Object (VBO).

You can find the latest asset here.

Cheers,


------------------------------
Eric Wilson
Director, Integrations and Enablement
Blue Prism Digital Exchange
------------------------------
6 REPLIES 6

ritansh.jatwani
Level 9
Great!!
Thanks for the info @ewilson :)​​

------------------------------
Ritansh Jatwani Senior Consultant
Consultant
EY
Gurgaon
*If you find this post helpful mark it as best answer
------------------------------

GlenLane
Level 2
Hi Eric,
Thank you for sharing. Is there a guide anywhere on how to use this to upload a file to Sharepoint please?
Thanks,
Glen

------------------------------
Glen Lane
------------------------------

Hi @GlenLane,

There is a user guide included on the asset page. It describes the 3 actions that are exposed by the VBO and their associated properties.​ In a nutshell:
  • Use the Microsoft Graph - Authentication VBO to get an access token.
  • Call the Create Upload Session action of the Microsoft Graph - Sharepoint Upload Session VBO. You'll pass in your access token as well as the ID of the Sharepoint site, the ID of the Sharepoint drive where the file should be stored, the folder path on Sharepoint, and the name of the file. You can also specify a conflict behavior if you want. This is what will happen if the file you're uploading conflicts with an existing file in the destination Sharepoint folder. If the action is successful, it will return a unique URL that you will use to upload the file to.
  • Lastly, you call the Upload File action passing in the session URL you received, the file name (the same one from the previous action), and optionally a multiplier to use for file chunking. What this means is that the VBO will chop your file up into multiple chunks for uploading. The multiplier allows you to increase the size of those chunks so the upload is less chatty on the network.
That's it. The VBO takes care of the heavy lifting.

Cheers,


------------------------------
Eric Wilson
Director, Integrations and Enablement
Blue Prism Digital Exchange
------------------------------

Thanks @ewilson

In my haste to download it, I failed to see the guide on the same page DOH!

Thank you for the nutshell version, much appreciated!

All the best,

Glen​​

------------------------------
Glen Lane
------------------------------

Hi @ewilson,

Please ignore my post as I had found out the issue and resolved it. Thanks.

Thanks for sharing this. I had done testing on my end but I am getting an exception message below when I run the "Create Upload Session" action. I also attached how I input the parameter. Please advice on this.

{"error":{"code":"BadRequest","message":"Resource not found for the segment 'General'.","innerError":{"date":"2022-03-25T06:35:53","request-id":"e1d81c33-62d7-46f5-9cc2-8bf2eb68c4d7","client-request-id":"e1d81c33-62d7-46f5-9cc2-8bf2eb68c4d7"}}}​

------------------------------
Hian Tee Yeoh
Subject Matter Expert
JABIL
------------------------------

@Hian_TeeYeoh,

Glad to hear you figured it out. 😉

Cheers,


------------------------------
Eric Wilson
Director, Integrations and Enablement
Blue Prism Digital Exchange
------------------------------