question

Andrew Schwartz avatar image
Andrew Schwartz asked Andrew Schwartz commented

OAuth login with RingCentral account

I've been testing various API calls with my dev account and had no problems with the auth flow. I now have started testing making API calls for a RingCentral business account and the sign in step of auth is failing, saying phone number and password don't match. However, I'm able to log into service.ringcentral.com with the same credentials. Does a RingCentral user need to create a dev account to use the API? Why is the login attempt failing?

authentication
1 |3000

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

1 Answer

Phong Vu avatar image
Phong Vu answered Andrew Schwartz commented

Did you change the app client id and client secret for your production? Also the server must be changed to platform.ringcentral.com/


3 comments
1 |3000

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

Andrew Schwartz avatar image Andrew Schwartz commented ·

No, I didn't change client ID and client secret. Do I need to change them? My understanding was that client ID and secret were related to my app, but that others could access the database through my app. Am I confused?

So you're saying that instead of platform.devtest.ringcentral.com, I need to change to platform.ringcentral.com? Are these changes that are required after graduating an app?

0 Likes 0 ·
Phong Vu avatar image Phong Vu ♦♦ Andrew Schwartz commented ·

You wrote "I'm able to log into service.ringcentral.com with the same credentials". This meant that you were logging in with a user's credentials in the production account. To use that user's credentials with your app, you need to graduate the app to production, grab the production app client id and client secret and use the production server. Here is how to set the client id and secret in the sample code

RINGCENTRAL_CLIENT_ID= "Your-Production-ClientId"
RINGCENTRAL_CLIENT_SECRET= "Your-Production-ClientSecret"
RINGCENTRAL_SERVER_URL= "https://platform.ringcentral.com"

rcsdk = SDK(RINGCENTRAL_CLIENT_ID, RINGCENTRAL_CLIENT_SECRET, RINGCENTRAL_SERVER_URL)


1 Like 1 ·
Andrew Schwartz avatar image Andrew Schwartz Phong Vu ♦♦ commented ·

Thank you so much for the detailed answer, that's exactly what I needed to know.

0 Likes 0 ·

Developer sandbox tools

Using the RingCentral Phone for Desktop, you can dial or receive test calls, send and receive test SMS or Fax messages in your sandbox environment.

Download RingCentral Phone for Desktop:

Tip: switch to the "sandbox mode" before logging in the app:

  • On MacOS: press "fn + command + f2" keys
  • On Windows: press "Ctrl + F2" keys