question

danilo-meireles6216 avatar image
danilo-meireles6216 asked Tyler Liu answered

OAuth 2.0 Code flow - C#

Hello!

I have difficulty to start using RingCentral Api.

My application type is "Public" and my Platform Type is "Server/Web".

I am using C# to authorize but I got Bad Request and the following answser:


{


"error" : "unauthorized_client",

"error_description" : "Unauthorized for this grant type",

"errors" : [ {


"errorCode" : "OAU-251",

"message" : "Unauthorized for this grant type"

} ]

}


I saw that it is because my Platform Type (Server/Web) does not support password grant type and I need to use "OAuth 2.0 Code flow".


I tried to find an example using "OAuth 2.0 Code flow" in C# but did not find anything. Could you please give me an example that works for me?


Thank you very much!



getting started
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

Tyler Liu avatar image
Tyler Liu answered
Yes, here it is:  https://github.com/ringcentral/ringcentral-demos-oauth  There are C# samples.
1 |3000

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

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