19

I have added a few apps to a Sharepoint Online instance using /_layouts/15/AppRegNew.aspx.

How can I manage apps added through this endpoint?

dav_i
  • 363
  • 1
  • 3
  • 9

4 Answers4

24

To look up registration information for an add-in that you have registered, go to http://<SharePointWebsite>/_layouts/15/AppInv.aspx.

To see a list of registered add-in principals (permissions), go to: http://<SharePointWebsite> /_layouts/15/AppPrincipals.aspx.

The second endpoint gives you the App Name and App Identifier (of all the apps) you've used while registering . You can consider this OOB approach if you just want to view a simple list of apps. For more detail, @Unnie's answer should be valid.

Taken from https://msdn.microsoft.com/en-us/library/office/jj687469.aspx

Akhoy
  • 2,911
  • 2
  • 18
  • 28
  • I registered an add-in using AppRegNew.aspx using a generated client ID and secret. AppInv.aspx shows the entry when I paste the client ID and click "Lookup". But for some reason, AppPrincipals.aspx still shows only one entry, which is the main site, with display-name "SharePoint". Is this list updated based on a periodic batch job or is there another reason my recently-added add-in wouldn't show up? – Coderer Aug 14 '20 at 14:58
  • 1
    AppPrincipals.aspx shows the apps for which you've granted permissions to the site. Nothing would show up there if you haven't granted permissions to the app to access the site in some way (read from lists / write to lists etc.). For more detailed steps, take a look at: https://www.wictorwilen.se/blog/sharepoint-2013-using-the-app-only-policy-and-app-principals-instead-of-username-and-password-combos/ or https://www.enjoysharepoint.com/workflow-app-identifier-in-sharepoint-online-app-permissions/. The 2nd link is just to show how the app appears for him after he grants permission. – Akhoy Aug 15 '20 at 06:16
  • Where can I see all the apps, irrespective of whether or not give permission? – variable Aug 12 '22 at 04:13
  • Will the app registered in SPO also list in Azure portal's Enterprise Application? – Mark L Jan 17 '24 at 19:12
3

App registration using /_layouts/15/AppRegNew.aspx or through powershell is done for Remote/Provider Hosted Add-in.

You can install SharePoint Client Browser . Once you install and open your site inside it , you can see App Instances section which will show you all the apps installed in the web. Now once you select the app, from the details on the right hand pane you can find details. From the details if the AppWebFullUrl is null or blank then it is a Remote hosted App , for SP hosted apps App Web will be created.

Also you can do the same using code.

using (ClientContext context = new ClientContext("http://weburl/"))
            {
                Web web = context.Web;
                web.Context.Load(web);
                web.Context.ExecuteQuery();

                // Get all Add-ins installed on the web
                var addInInstance = AppCatalog.GetAppInstances(context, web);
                addInInstance.Context.Load(addInInstance);
                addInInstance.Context.ExecuteQuery();

                foreach (var appInstance in addInInstance)
                {

                    //Check whether it is Remote hosted Add-in
                    if (string.IsNullOrEmpty(appInstance.AppWebFullUrl))
                    {
                        Console.WriteLine("This is a remote hosted add-in");
                        // You can now get all the information about your appInstance object
                        Console.WriteLine("Add-in Title: " + appInstance.Title);
                        Console.WriteLine("Status: " + appInstance.Status);
                        Console.WriteLine("Start Page: " + appInstance.StartPage);
                        Console.WriteLine("Add-in Id: " + appInstance.Id);
                    }
                }
            }
Unnie
  • 8,819
  • 1
  • 22
  • 36
2

They can also be viewed using the "Enterprise Applications" section of the AzureAD/Azure Portal.

Unfortunately if you don't know the name the UI will only show the first 50. It also doesn't seem to show secrets/expiry.

Fowl
  • 167
  • 1
  • 12
  • For reference, I just found out for myself, by default, if you go to Azure AD > Enterprise Applications, it will apply the filter Application Type === Enterprise Applications. I had to clear that filter in order to see the applications I created via the AppRegNew.aspx page. – user1063287 Nov 07 '22 at 05:45
0

I feel your pain - I've submitted a GitHub issue here https://github.com/SharePoint/sp-dev-docs/issues/7321

No traction on this one, so decided to write a custom application to take care of my requirements much like you. See my comments in GitHub issue.

Hope this might help someone!