News & Announcements User Community Developer Community

Welcome to the RingCentral Community

Please note the community is currently under maintenance and is read-only.

Search
Make sure to review our Terms of Use and Community Guidelines.
  Please note the community is currently under maintenance and is read-only.
Home » Developers
Resource for parameter [accountId] is not found
Tags: error
Aug 18, 2017 at 7:20am   •   5 replies  •  0 likes
gaash-granot

hi,


i'm trying to get a customer's calls for the first time, but i get the error message in the subject.


the flow that was used:

1. the customer has authorized my application using the authentication flow (i got an access key using ring central's APIs).


2. using the following API, i tried to get the customer's extensions list, but got the error message.

the url i'm using is -

https://platform.ringcentral.com/restapi/v1.0/account/<ACCOUNT-NUMBER>/extension

(i use an account number, not the '~' sign).


3. i used my account in ring central to check the code i wrote, and noticed that when i use a user, that is defined as an admin in ring central, the APIs work without any problem, but when i use a standard user (not an admin), i also get the error in the subject.


my questions are:

1. when granting access, only an admin user can be used during authentication, in order to grant the access to the customer's data?


2. if a standard user can be used to grant access, then what am i doing wrong?


thanks :)


5 Answers
answered on Aug 19, 2017 at 3:23am  
ok, thank you all for your answers.
i checked if the code works when i'm using the '~' sign instead of the account id, using the access token that was created when the standard user granted access, and it worked fine.

then, i checked what was the value of the account id i was using, and it turned out to be ring central owner id. this is actually a bug in my code, but it made me wonder:
how come, that when i used the owner id of an admin user in ring central, it worked fine, and i also managed to get other extensions calls?
how is it possible?

thanks.


 0
answered on Aug 18, 2017 at 5:39pm  
There is a logged-in user as long as you have the access token. "account/~" means the account which contains the user that you used to obtain the access token.

It is true that the access token is unable to fetch information from other accounts. Only fetch information from the current account is possible.

 0
answered on Aug 18, 2017 at 1:57pm  
unfortunatelly, the tilde sign won't help, since there's no looged-in user. the API is executed in a fully back-end system, as part of a batch process. 
What is the user you are Authorizing as to make the API request ? Would that user be a part of the organization / account ?

Per the error, I can think of it as you are authorized as a user A but then the <AccountID> which you are using in the API to retrieve the list of extensions does not belong to the same org / account as the user A


 0
answered on Aug 18, 2017 at 1:21pm  
hi thanks for the reply. unfortunatelly, the tilde sign won't help, since there's no looged-in user. the API is executed in a fully back-end system, as part of a batch process. what else can be the cause for the error? how can it be, that an admin user authorization works, and a stardatd user doesn't?

 0
answered on Aug 18, 2017 at 11:37am  
Hi Gaash,

The GET Extension List API would return the list of extensions created for a particular account. All types of extensions are included in this list.

Now, in order to get the extensions list under an account, you need not be an Admin to make this API request. The GET Extensions List can be retrieved using an Admin or a non-Admin User. 

Based on the description you have provided above, it looks like the <ACCOUNT-NUMBER> that you are providing might not actually belong to the Organization or the account itself.Using a '~' ( tilde ) should work for the logged-in user.

Can you verify if '~' works or not?

 0



A new Community is coming to RingCentral!

Posts are currently read-only as we transition into our new platform.

We thank you for your patience
during this downtime.

Try Workflow Builder

Did you know you can easily automate tasks like responding to SMS, team messages, and more? Plus it's included with RingCentral Video and RingEX plans!

Try RingCentral Workflow Builder

PRODUCTS
RingEX
Message
Video
Phone
OPEN ECOSYSTEM
Developer Platform
APIs
Integrated Apps
App Gallery
Developer support
Games and rewards

RESOURCES
Resource center
Blog
Product Releases
Accessibility
QUICK LINKS
App Download
RingCentral App login
Admin Portal Login
Contact Sales
© 1999-2024 RingCentral, Inc. All rights reserved. Legal Privacy Notice Site Map Contact Us