I have created a bucket like following (Python):
payload = {'bucketKey' : bucketname,'policyKey' : 'transient'}
resp = requests.post(Forge_BASE_URL+'/oss/v2/buckets', headers={'Authorization': config.token,'Content-Type':'application/json'},json=payload)
And then uploaded a file to the bucket created:
url = 'https://developer.api.autodesk.com/oss/v2/buckets/'+bucketname+'/objects/'+encodedfilename
resp = requests.put(url, headers={'Authorization': config.token,'Content-Type' : 'application/octet-stream','Content-Length' : str(filesize)},data= open(modelfilePath + filename, 'rb'))
How can I download the object from the bucket to the local path of the Revit Design Automation engine?
The local path of the Revit Design Automation engine looks like T:\Aces\Jobs\job_id
that is used in C# codes.
Either curl
command or Python codes are appreciated.