question

Kumar avatar image
Kumar asked Anirban Sen Chowdhary answered

Unauthorized issue for my new app

I am facing authorization issue.

I created a new app in my developer sandbox portal.

Whenever I send token request to the API

 /restapi/oauth/token 

I get the following error :

{"error":"unauthorized_client","error_description":"Unauthorized for this grant type"}  

Is there any way to solve this. I am unable to get token for my new app

apioauth2
1 |1000

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

1 Answer

·
Anirban Sen Chowdhary avatar image
Anirban Sen Chowdhary answered

The issue can be be due to several reason.

First you need to check if your Client ID and Client secret for this new API is valid.

Then check the applications Platform Type and Application Type from the setting.

Check OAuth Settings to know which type of Authentication your app needs to implement defined by the Platform Type

There can be Authorization Flow or even can be Password Credentials Flow. Based on that your your Oauth grant_type is implemented and you need to call the correct grant_type while calling for token url..

You may have implemented a Platform Type that support a grant_type while you are calling token with some other grant_type.

1 |1000

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.