Skip to main content
Question

Error 400 on authentication

  • November 4, 2022
  • 8 replies
  • 997 views

I followed the code example at https://developers.ringcentral.com/guide/voice/ringout#c# but getting error 400 on the "Authorize" line.


One or more errors occurred. (Call failed with status code 400 (Bad Request): POST https://platform.devtest.ringcentral.com/restapi/oauth/token).


Here is code:

static RestClient restClient;

static void Main(string[] args)

{

restClient = new RestClient("client-id",

"client-secret",

"https://platform.devtest.ringcentral.com/");

restClient.Authorize(

"+1470502xxxx",

"101",

"XXXXXXX").Wait();

call_ringout().Wait();

}

Can you tell me what did I do wrong?

8 replies

PhongVu
Community Manager
Forum|alt.badge.img
  • Community Manager
  • November 7, 2022

There was an outage during the weekend on sandbox server. Can you try again and let me know.

BTW, I edited your question to hide app client id and client secret as well as the phone number.


  • Author
  • Participating Frequently
  • November 7, 2022

I got the same error today.

1667838716134.png


  • Author
  • Participating Frequently
  • November 8, 2022

Tested again today and got the same 400 error.


  • Author
  • Participating Frequently
  • November 10, 2022

Can anyone help me?


  • Author
  • Participating Frequently
  • November 11, 2022

I tried again and still getting the same error!


PhongVu
Community Manager
Forum|alt.badge.img
  • Community Manager
  • November 11, 2022

Can you do the exact way as the sample code shows

RestClient rc = new RestClient("client_id", "client_secret", false);

  • Author
  • Participating Frequently
  • November 15, 2022

1668536922908.png


Code and error message.


PhongVu
Community Manager
Forum|alt.badge.img
  • Community Manager
  • November 15, 2022

Can you share the app client id here.