I'm developing SharePoint hosted add-ins and I need a way to manage user access to the apps I'm developing. For example, I have a site with 3 different SharePoint add-ins that access to lists in the same site, I would like to let a group of users to access 1 application and don't access to the others applications installed.
I came up with 2 different ideas to reach this:
- Create SharePoint groups that corresponds to each application, add the users I want to have access and then in the SharePoint add-in get all the users from a certain group and check if the current user belongs to that group.
- Create a subsite for each SharePoint add-in and manage the permissions from "Site permissions" under "Site settings"
Also I would like to know as well if there is a way to manage "roles" inside the application, for example let some users with permissions as "read-only", other group of users with "edit" and other one with "delete".
Thank you so much in advance.