09-23-2020 03:39 AM
I'm investigating how to dynamically set the security settings so I can give different users access to resources.
AFAIK there's no api to do this so I'm thinking to manipulate the database myself
This is what I've found:
add/remove users/roles in the principals table
connect users to roles in the user_roles table
give read/write permissions to catalog items using the persistent_object_right table (where I'm a bit surprised that the principal column is not a foreign key
What I'm unable to find however is where the 'scale range' and 'spatial range' are stored.
Also: is there another better way?
09-28-2020 06:56 AM
It looks like there is no REST API that can modify scale and spatial range security right now.
Normally we don't recommend customer to change database directly since the catalog design can change from version to version.
I will double check this with Apollo development team.
09-28-2020 11:18 PM
Yes somebody else pointed me to this endpoint to. This is great. But shouldn't there also be an endpoint to manage the users/principals? Then I can handle the entire process of giving access to catalog items to different users
09-29-2020 07:37 AM
Checked this with Apollo development team, and basically it is no possible to create/modify user and roles in REST API right now. This is only available using Data manager or APOLLO server JAVA SDK.
You can submit this as enhancement as ideation or submit development ticket.
Hope it helps.