I'm trying perform an upload of a Inventor part to APS via nodeJS (using Forge_Server_Utils from Petr Broz) . On the server side I have this endpoint implementation, lets say UploadObject :
const { FORGE_CLIENT_ID, FORGE_CLIENT_SECRET } = process.env;
const data = new DataManagementClient({ client_id: FORGE_CLIENT_ID, client_secret: FORGE_CLIENT_SECRET, });
var response: string = ''; const bucketName = context.input.parameters?.bucketname;
const objectKey = context.input.parameters?.objectKey;
const objects = await data.uploadObject(bucketName, objectKey,);
return response;
The third parameter of uploadObject is a buffer parameter. So my question is : how can I pass on, from the client (c#), this data parameter ? I know I have to make a HTTP request, but don't know how it should be structured (headers, ...)
Any help on how to implement this, maybe some pseudo code
TIA, Mark
Since you're mentioning server side and design automation, I'll cover both ways.
First of all, we've migrated the way we handle binary transfers (please refer to this blog post)
For server side, please refer to our recent SDKs that cover the new steps for handling binary transfers.
You can find more info at direct to s3 upload and download sdks blog
Note: the SDKs we are referring to in this blog post are developed and maintained by our developer advocacy team, and are not considered official. There is an ongoing effort to provide official SDKs for Autodesk Platform Services, and we plan to release the official OSS SDKs early next year.
For Design Automation, you can simply pass the urn of the resource with a valid token, and our backend will take care of the upload.
You can find more info here