Question

When I attempt to go to 'https:// -site- /_layouts/15/AppRegNew.aspx' in order to enter OAuth info for my REST based service, I get the message

"Sorry, you don't have access to this page."

where -site- is: sub.company.com/marketing/more/another/ which is the valid URL for the SharePoint site, and I can access this.

The SharePoint Admin says I have full rights to the AppRegNew page. The Admin also gets the same message when she tries to go there. Is there something that needs to be installed to allow this?

Backgroud: I am writing a REST service in Node.js (JavaScript) on a remote server to pull information from a SharePoint site. Note this is not JavaScript inside a browser. My company has their own SharePoint 2013 installed on a server.

I can use REST endpoints to view xml output when I enter it in a browser. However, when I write the code to call the REST service, I get the error back "Access Denied". It is my understanding I need to get an OAuth token via the process documented here: http://spshell.blogspot.com/2015/03/sharepoint-online-o365-oauth.html.

Which is what I am trying to do, but I can't even get to the registration of a new service. Maybe I am going about this the wrong way, if so, could you kindly point me in the correct direction?

Was it helpful?

Solution

I had this same issue. I could not get to AppRegNew.aspx even though I was a farm administrator. I would get the same error, Sorry, you don't have access to this page. I could hit the web service endpoints in a web browser but not via javascript.

I finally fixed my issue by doing the following:

  1. Go to Central Admin

  2. Click "Security" on the left hand Navigation.

  3. Click Specify web application user policy enter image description here

  4. Click Add Users on the top left of the content section

  5. Make sure the correct Web Application is selected that you are targetting and All Zones is selected in the "Select the Zone" drop down. Click Next button.

  6. Add your User to the Users Box and select Full Control and Finish button. enter image description here

Hopefully this works for you, it took me forever to get mine working.

Licensed under: CC-BY-SA with attribution
Not affiliated with sharepoint.stackexchange
scroll top