Tenant admin site returns 404

180 views Asked by At

I am currently trying to start with Office365-REST-Python-Client for App only authentication. My goal is to end up posting a document to SharePoint, on my way to that, I found that I need the following permissions:

<AppPermissionRequests AllowAppOnlyPolicy="true">
 <AppPermissionRequest Scope="http://sharepoint/content/sitecollection" Right="FullControl" />
 <AppPermissionRequest Scope="http://sharepoint/search" Right="QueryAsUserIgnoreAppPrincipal"/>
 <AppPermissionRequest Scope="http://sharepoint/social/tenant" Right="FullControl" />
 <AppPermissionRequest Scope="http://sharepoint/taxonomy" Right="FullControl" />

However due to the changes that microsoft made I am having a bit of trouble, navigating to https://{tenant}.sharepoint.com/sites/MySite/_layouts/15/appinv.aspx is fine and a I can carry on as normal, only when applying the permissions I will be faced with the message:

Your tenant administrator has to approve this app.

this can be solved by adding -admin after tenant like this: https://{tenant}-admin.sharepoint.com/sites/MySite/_layouts/15/appinv.aspx however when I go to that link, I am getting a 404 when I check it seems that I should go to https://{tenant}-admin.sharepoint.com/site/MySite/_layouts/15/appinv.aspx (sites to site) but then I get a 500 error. Though I am fairly new to SharePoint I really don't understand what I am missing, I have spent hours searching and I honestly have tried a whole bunch of things but having no luck.

1

There are 1 answers

2
Michael Han On

The admin site url is https://{tenant}-admin.sharepoint.com.

So you should go to https://{tenant}-admin.sharepoint.com/_layouts/15/appinv.aspx, without sites/mysite.