question

Neil Baleva avatar image
Neil Baleva asked Phong Vu commented

Is oauth2 client_credentials still available ?

The following page describes oauth using client credentials :

https://ringcentral-api-docs.readthedocs.io/en/stable/authentication/client-creds/

I'd like to know if this auth flow is still available and if so, can I get it added to my dev apps ?

Seems this would be the way to do auth without a user having to login. Use case for this would include pulling call logs and setting up subscription webhooks. Neither of these 2 examples should require user login.

oauth2
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 Phong Vu commented

That is an old article and is not valid anymore.

You should explore and use the JWT flow as discussed in this dev guide article.


2 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.

Neil Baleva avatar image Neil Baleva commented ·

thank you @Phong Vu , for you response. So I have 2 apps created. The first app is jwt auth and used for pulling call logs and creating webhook subscriptions (inbound phone/sms messages). The second app is setup with oauth which allows users send out sms messages.

The issue I am facing is that both apps have different sets of extensions. I never receive inbound sms messages for extensions that I use for sending out sms messages.



0 Likes 0 ·
Phong Vu avatar image Phong Vu ♦♦ Neil Baleva commented ·

If the app that pulls call logs and creating webhook subscriptions to catch inbound SMS messages, does not require to reply an inbound SMS, then you can generate a JWT token of a super admin user and subscribe for the inbound SMS notification for each user under the account. E.g.

var eventFilters = [
'/restapi/v1.0/account/~/extension/XXXXXXX/message-store/instant?type=SMS',
'/restapi/v1.0/account/~/extension/YYYYYYY/message-store/instant?type=SMS',
'/restapi/v1.0/account/~/extension/ZZZZZZZ/message-store/instant?type=SMS',
...
]

This will allow your app to receive inbound SMS messages on behalf of other users.

Because even a super admin user cannot send SMS messages on behalf of other users, so your other app which allows users to login and send SMS messages is the right option.

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