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

a remove_user http verb ? #5110

Open
xm1234567 opened this issue Mar 7, 2024 · 1 comment
Open

a remove_user http verb ? #5110

xm1234567 opened this issue Mar 7, 2024 · 1 comment
Labels

Comments

@xm1234567
Copy link

Hello,

I try to remove a user from a group by restapi. According to the doc , it needs groups_user_href
Thanks to ggainey 's help,(details of my question) , I know now it is constructed by one part of user-href after the API ROOT appended to the group-href
Eg:

user_href => /pulp/api/v3/users/2/
group_href =>  /pulp/api/v3/groups/1/
then 
groups_user_href => /pulp/api/v3/groups/1/users/2/

I am not sure if my demand to add groups_user_href info is suitable or not, because maybe some usecase needs user_href when doing groups:users/list users query

Or maybe can add explanation/example in the doc to explain how to constructed groups_user_href?

thanks

@pedro-psb
Copy link
Member

I am not sure if my demand to add groups_user_href info is suitable or not, because maybe some usecase needs user_href when doing groups:users/list users query

I don't think there should be exclusive user_ref or group_user_href. We could just have both:

$ pulp group user list --group test-group
[
  {
    "username": "testuser",
    "pulp_href": "/pulp/api/v3/users/2/",
    "group_user_href": "/pulp/api/v3/groups/1/users/2/"
  }
]

Anyway, it should be useful to improve the REST Api docs (on the endpoints that uses group_user_href) by:

  • describing how group_user_href composed
  • linking to this group/user list query, if we add group_user_href to the response.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants