I am trying to get the data from User Info list using below JSOM code. but the issue is, it returns the data only when owner group user logged in to the site, for a visitor or even site members are facing issue "list 'user information list' does not exist at site with url http://siteurl, Please suggest what I am missing?

var siteUrl = '/';
var ctx = new SP.ClientContext(siteUrl);
var oList = ctx.get_web().get_lists().getByTitle('User Information List');

It's because the All Users is List and only Administrator has permissions to view it. If you want work under users identity not elevated to administrator, you must set at least view permissions for all users.

In JSOM you cannot run script under Elevated Privileges.

For set permissions use this link for All Users List:


Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.