Thanks. Swagger helped a bit, but I’m still struggling with finding out how to upload a file into a existing bucket. Specifically the path parameter of the GetWriteUri request. I can make the request if I fx type “Test” in the path parameter and then I get a blob URI, but I dont know what to do with this.
After calling UiPath.Server.Configuration.OData.GetWriteUri you get a Response containing a URI and Verb to make your second request. The File is then attached to the PUT Request as a Binary and sent to the Uri obtained from the first GET request.
A good way to determine what the API calls are if it is not well documented in the Support Docs or Swagger is to Inspect your Network Traffic while taking the actions in your Browser with the Orchestrator Web UI.
Thanks a lot! I got a lot further, but I am still missing something.
I get that it is two separate API calls now, and I managed to figure out how to upload the file into a storage bucket.
However I think I need something in relation to the path param in the GET request. I can successfully upload a .xlsx file to the bucket, but it is just a blank file. I need to refer to a file locally on my desktop as you can in the Orchestrator Web UI. So right now I am basically just creating a blank file on the blob instead of uploading a local file to the blob.
Can you see what I am missing here? I guess it maybe has something to do with the “track” line in the network traffic inspector, which is making a POST to dc.services.visualstudio.com/v2/track?
When I try it is needed, otherwise a get a response like this:
<?xml version="1.0" encoding="utf-8"?>
<Message>An HTTP header that's mandatory for this request is not specified.
Nevertheless, I tried the binary PUT request and I was able to upload the file successfully - so thanks for your help