I have been using the password flow just fine, however RingCentral will deprecate it and I am moving to Oauth2.0. However I am running into issue and I keep getting the error OAU-250 Unsupported grant type.
This is the URL I am using:
POST Request: https://platform.ringcentral.com/restapi/oauth/token
Params:
grant_type = authorization_code
redirect_uri = url
code = code gotten back from the url
client_id = client_id
Headers:
Content-Type = application/x-www-form-urlencoded
Accept = application/json
Authorization = Basic (base64encode"clientid:clientsecret")
Any feedback is well appreciated.
Normally you should migrate from Password flow to JWT flow, which is kind of equivalent and suitable for Server/No UI app platform type.
If you really want to change the authentication to OAuth 2.0 code flow, the best option is to register a new app with code flow with a specified the Redirect URI and you will need to implement extra code to handle the authorization.
Ok I updated, the settings of my console to use JWT, I then using Postman (for testing) used this URL: https://platform.ringcentral.com/restapi/oauth/token
POST Request
Headers:
Content-Type = application/x-www-form-urlencoded
Authorization = Basic (base64encode"clientid:clientsecret")
Params:
assertion = my JWT token I generated under credentials
grant_type = urn:ietf:params:oauth:grant-type:jwt-bearer
( Note I also tried : grant_type = urn%3Aietf%3Aparams%3Aoauth%3Agrant-type%3Ajwt-bearer )
However this is the error I get which is the exact same error I got when using OAuth 2.0:
I am using cURL, because I am using the FileMaker platform, thanks in advance for any advice.
What is the app client id?
Hi, is there an update on this? Thank you
0eLTUWdZfWzd1aTmBEUteZ
The app auth type is set to JWT flow correctly, so I am sure that something is wrong in your Postman body params. However, the app does not have any scope (app permission)? Check the API you want to call from the API reference to see what app permission does it require and add that scope to your app.
For testing with Postman, use this public collection
Thank you for your help the issue has been fixed by leveraging the sample file you provided. I was passing the parameters as part of the URL and not as part of the Body.
A new Community is coming to RingCentral!
Posts are currently read-only as we transition into our new platform.We thank you for your patience
during this downtime.
Try Workflow Builder
Did you know you can easily automate tasks like responding to SMS, team messages, and more? Plus it's included with RingCentral Video and RingEX plans!Try RingCentral Workflow Builder