Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

As a user, I can use REST API to add object level permission to a user #279

Open
fao89 opened this issue Nov 10, 2021 · 0 comments
Open

Comments

@fao89
Copy link
Owner

fao89 commented Nov 10, 2021

Author: [email protected] ([email protected])

Redmine Issue: 8090, https://pulp.plan.io/issues/8090


There are multiple ways to enable this use case:

Enable the /pulp/api/v3/users/<uuid>/permissions/ API to accept POST, PUT, and PATCH requests for updating user permissions. However, I suspect this would probably present a challenge for the user because each time permissions are being modified, all permissions would need to be submitted in the request. My suspicion is based on an assumption that all permissions are stored in a single JSON object.

The other option is to add separate endpoints for adding and removing permissions. e.g. /pulp/api/v3/users/<uuid>/add_permissions/ and /pulp/api/v3/users/<uuid>/remove_permissions/

Please note that I have not looked into django-guardian what Views and ViewSets it provides for this functionality.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment