Skip to main content
The First Step
July 27, 2021
Question

Unable to obtain an oAuth token in development. Error states "Invalid resource owner credentials"

So, I have been trying to get the Call Log API set up and am going through the development process. I created an app and ensured that I can login to both login.ringcentral.com and developers.ringcentral.com using the same credentials for both areas. The "Try It" button shows that the app has permissions so I have tried obtaining an oAuth token by sending an API request to https://platform.devtest.ringcentral.com and get an "invalid grant" error with a message of "Invalid resource owner credentials" I have tried sending the request via postman and via the ringcentral gitHub API explorer (https://ringcentral.github.io/api-explorer/#!/Authentication/oauth_token_post) and both return the same error. I am using password as the grant_type and have confirmed that the app I created does support the password flow. The app credentials even show "Active" for the password in the sandbox area. I am using 14243227530 as the user. I have also tried using the email associated with the account but have had no luck. Please let me know what I am doing wrong. Thanks!

2 replies

PhongVu
Community Manager
Community Manager
August 5, 2021

Answered in this thread.

The First Step
August 5, 2021

If you are trying in postman client to obtain Auth token, format will be as below:

POST https://platform.devtest.ringcentral.com/restapi/oauth/token

Body: username=<phone_number>&password=<password>&extension=<extension>&grant_type=password

Headers: Content-Type: application/x-www-form-urlencoded

Authorization: Basic <base 64 of Clienid:ClientSecret>

Client id and secret values you will get from app dashboard