question

Minh Vuong avatar image
Minh Vuong asked Becky-Community_Manager edited

Cannot make SMS quick start example work, please help!

I tried to follow instruction in https://developers.ringcentral.com/guide/messaging/quick-start#c# using my sandbox credential number +13133982564. However, I cannot go pass the Autorize code:

restClient.Authorize(RINGCENTRAL_USERNAME, RINGCENTRAL_EXTENSION, RINGCENTRAL_PASSWORD).Wait();

I got the error: "StatusCode: 400, ReasonPhrase: 'Bad Request', Version: 1.1, Content: System.Net.Http.StreamContent, Headers: ...".

Could anyone give me some advice on this?

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.

Phong Vu avatar image
Phong Vu answered

I see you have 2 test apps, one of that is your own creation and the other one created by the quick start template. The one you created is incorrect type for the quick start code.

Double check the app client id and client secret you are using in your code. You must use the client id and client secret of the "SMS Quick Start App" app.

1 |3000

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

Minh Vuong avatar image
Minh Vuong answered Phong Vu commented

Thanks Phong, I have removed the incorrect type app and used the client id/secret from the quick start template. I tested with Australian number and got error "MSG-240" saying "International SMS is not available for account". Do I need to upgrade my account?

1 comment
1 |3000

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

Phong Vu avatar image Phong Vu ♦♦ commented ·

Sandbox account does not support international call, nor international SMS. If you just want to test SMS API call, you can login your sandbox service web, add a new user with a new direct number, you can then send SMS message from one users phone number to another user's phone number.

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