41
Views
7
Comments
Solved
[Autodesk Forge Connector] 400 bad request Autodesk
Question
autodesk-forge-connector
Web icon
Forge component by Rafael Fantato

Hey,

I´m trying to use your Autodesk module.


Here, when I clic to allow ("Permitir"):


This is the request:



What can I do? 


Thanks in advance.


Javi.



Solution

Hi Javier,

I'm having a hard time replicating the 400 Bad Request.


Just so you know what I did:

  1. Published it the latest version of the component in my personal environment
  2. Signed up for an Autodesk Account
  3. Changed ClientId and Client Secret
  4. Changed the RedirectUri being passed in: (to my personal environment's hostname)
    1. Callback > Preparation > GetToken
    2. ThreeLegged > "Autorizar App" link > GetAuthorize
  5. Opened ThreeLegged webcreen on the browser
  6. Clicked "Autorizar App"
  7. Clicked "Allow" on the Autodesk Authorization Screen
  8. It redirected me to the Callback screen with the correct Bearer Token to authorize API calls

Cristiana Umbelino wrote:

Hi Javier,

I'm having a hard time replicating the 400 Bad Request.


Just so you know what I did:

  1. Published it the latest version of the component in my personal environment
  2. Signed up for an Autodesk Account
  3. Changed ClientId and Client Secret
  4. Changed the RedirectUri being passed in: (to my personal environment's hostname)
    1. Callback > Preparation > GetToken
    2. ThreeLegged > "Autorizar App" link > GetAuthorize
  5. Opened ThreeLegged webcreen on the browser
  6. Clicked "Autorizar App"
  7. Clicked "Allow" on the Autodesk Authorization Screen
  8. It redirected me to the Callback screen with the correct Bearer Token to authorize API calls


Hi Cristiana, 

I deleted it and reupload the module following your steps. The authenticate works now! 


Thanks for all and sorry because I´m rookie with Outsystems.


Hi Cristiana,

I have followed the mentioned steps until step 6. Post clicked on "Autorizar App" getting below error message.

Pls help to resolve the issue.

Appreciate for earliest reply.

Sonali 

This seems like some authentication information is missing. Can you share the error logged on Service Center?

Did you check this part on the component's description?

See What You Can Do:
https://developer.autodesk.com/ 

Change Site Properties with your own Autodesk Forge App Client ID and Client Secret

Configure your Autodesk Forge App Callback URL to Web Screen "Callback" to use the 3-Legged Token with authorization screen.

Cristiana Umbelino wrote:

This seems like some authentication information is missing. Can you share the error logged on Service Center?

Did you check this part on the component's description?

See What You Can Do:
https://developer.autodesk.com/ 

Change Site Properties with your own Autodesk Forge App Client ID and Client Secret

Configure your Autodesk Forge App Callback URL to Web Screen "Callback" to use the 3-Legged Token with authorization screen.

Hi Cristiana, 


The secret and Client Id are OK, and I configured the Callback URL..

Here you have the errors:

Thanks in advance,


Javi.


I'll assume that the hard-coded URLs for the author's personal environment were changed as well and therefore the problem is not there.

From the Stack trace this happens when calling the OAuthAuthentication3Legged API method. Usually a HTTP 400 means that some parameter is not being sent according to the APIs documentation. By having a look at it here , it seems that the code is still up to date to documentation.


I'd advise you to set the Integration mode to Full (check how here) and try again the request. This will give more information of what data was sent and what was received. If it doesn't help please be aware that in that screenshot can be sensitive information regarding access to Autodesk.

I'll replicate that and understand the issue but can't promise a reply in a timely manner. Sorry about that.

Solution

Hi Javier,

I'm having a hard time replicating the 400 Bad Request.


Just so you know what I did:

  1. Published it the latest version of the component in my personal environment
  2. Signed up for an Autodesk Account
  3. Changed ClientId and Client Secret
  4. Changed the RedirectUri being passed in: (to my personal environment's hostname)
    1. Callback > Preparation > GetToken
    2. ThreeLegged > "Autorizar App" link > GetAuthorize
  5. Opened ThreeLegged webcreen on the browser
  6. Clicked "Autorizar App"
  7. Clicked "Allow" on the Autodesk Authorization Screen
  8. It redirected me to the Callback screen with the correct Bearer Token to authorize API calls

Cristiana Umbelino wrote:

Hi Javier,

I'm having a hard time replicating the 400 Bad Request.


Just so you know what I did:

  1. Published it the latest version of the component in my personal environment
  2. Signed up for an Autodesk Account
  3. Changed ClientId and Client Secret
  4. Changed the RedirectUri being passed in: (to my personal environment's hostname)
    1. Callback > Preparation > GetToken
    2. ThreeLegged > "Autorizar App" link > GetAuthorize
  5. Opened ThreeLegged webcreen on the browser
  6. Clicked "Autorizar App"
  7. Clicked "Allow" on the Autodesk Authorization Screen
  8. It redirected me to the Callback screen with the correct Bearer Token to authorize API calls


Hi Cristiana, 

I deleted it and reupload the module following your steps. The authenticate works now! 


Thanks for all and sorry because I´m rookie with Outsystems.


Hi Cristiana,

I have followed the mentioned steps until step 6. Post clicked on "Autorizar App" getting below error message.

Pls help to resolve the issue.

Appreciate for earliest reply.

Sonali 

No problem Javier. Happy to help.

Keep the feedback and questions coming! :)

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.