Community
A360 Forum
Welcome to Autodesk’s A360 Forums. Share your knowledge, ask questions, and explore popular A360 topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

after creating a bucket with v2 i am getting bad request

1 REPLY 1
Reply
Message 1 of 2
FrankHolidaytoiling
236 Views, 1 Reply

after creating a bucket with v2 i am getting bad request

Hi I use this site for understand to migrate v1 to v2...

http://adndevblog.typepad.com/cloud_and_mobile/2016/09/autodesk-forge-apis-migrating-from-v1-to-v2.h...

 

so I have scopes correct and working and authentication I leave as v1 as blog tell me to. then I change the create bucket to v2 like blog and it says bad request.

 

public static string CreateBucket(string accessToken, string bucketKey, string policy)

{

// (1) Build request

var client = new RestClient();

client.BaseUrl = new System.Uri(baseApiUrl);

// Set resource/end point

var request = new RestRequest();

request.Resource = "oss/v1/buckets";

request.Method = Method.POST;

// Add headers

request.AddHeader("Authorization", "Bearer " + accessToken);

request.AddHeader("Content-Type", "application/json"); // MH: skipping this works.

// Add JSON body. in simplest form.

request.AddJsonBody(new { bucketKey = bucketKey, policy = policy });

 

// (2) Execute request and get response

IRestResponse response = client.Execute(request);

1 REPLY 1
Message 2 of 2

Hi Frank,

Thanks for posting your question. This looks like something you want to post to the Forge Team. If you go to the following link, you will find where you can send in questions like this to the Forge Team.

https://developer.autodesk.com/

 

Here is the direct link to help

https://developer.autodesk.com/en/support/get-help



Hope this helps get you pointed in the right direction for help and have a great day.

Bud Schroeder
AutoCAD Customer Council Beta Programs
Autodesk Inc.

Autodesk Beta Programs!


Tags (1)

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Technology Administrators


Autodesk Design & Make Report