question

Krzysztof Szczepanik avatar image
Krzysztof Szczepanik asked Phong Vu commented

CallLog API problems

Hi,


I`m willing to create REST API that will call RingCentral to obtain CallLogs (not live calls).
I use JWT token with this link to obtain access token:
https://platform.ringcentral.com/restapi/oauth/token
and it's all successful.1711011937054.pngI don't use RingCentral SDK because I use 3rd party tool to communicate with RingCentral.

So I have access token and my question is how/which API should be called to obtain my company calls?
My company number is +44204506xxxx
I have created Rest Api App on developer portal, I tried to use this api:

1711011422041.png
with production instance by clicking 'Try it out' but it gives me information that I don't have "ReadCompanyCallLog" permissions.

My questions are:
1. Do I use good API if I want to obtain list of call logs from my company number?
2. How can I add permissions to get this "ReadCompanyCallLog" - I'm developer admin on my account and I cannot perform this action
3. How I should place access token that I get from first call into next API calls (it should be in a header but with what key/property?)


Thanks in advance for any help in this topic.

rest api
1711011422041.png (18.7 KiB)
1711011937054.png (22.4 KiB)
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

It is because the JWT was generated by/for a user extension who has the standard (other a custom) user role under your RingCentral account. You have 3 options,

1. Use another user who is a super admin user to generate a new JWT token.

2. Change the current user role to "super admin" role.

3. Create a custom role and check these checkboxes accordingly (and any other user permission you need) and assign the new role to the current user.

screen-shot-2024-03-21-at-71257-am.png


1 |3000

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

Krzysztof Szczepanik avatar image
Krzysztof Szczepanik answered Phong Vu commented

Hi,

thank you for this information but I don't see nothing like 'super admin' role.
Even on my personal dev account I have only those 3 (same as on my company one).1711091743860.png
And where do you create new roles for your app?
I can see only application scopes in Settings.


1711091743860.png (5.9 KiB)
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 ·

That is a wrong place to look and set. Login the account admin portal with a super admin user and set the user role of that user extension.

screen-shot-2024-03-22-at-70122-am.png

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