get_user_groups endpoint for chrome-infra-auth |
|
Issue descriptionGiven identity=<email> returns all groups that identity is a member of. A batch variant of this endpoint would be helpful for latency as well.
,
Dec 13 2016
The following revision refers to this bug: https://chromium.googlesource.com/external/github.com/luci/luci-py.git/+/7067fd8f75d5eae5d849cc6695b422469a7b7063 commit 7067fd8f75d5eae5d849cc6695b422469a7b7063 Author: vadimsh <vadimsh@chromium.org> Date: Tue Dec 13 00:27:29 2016 auth_service: Add '/memberships/list' and '/memberships/check' API. BUG= 671456 , 671451 R=tandrii@chromium.org Review-Url: https://codereview.chromium.org/2550143003 [modify] https://crrev.com/7067fd8f75d5eae5d849cc6695b422469a7b7063/appengine/components/components/auth/api.py [modify] https://crrev.com/7067fd8f75d5eae5d849cc6695b422469a7b7063/appengine/components/components/auth/ui/rest_api.py [modify] https://crrev.com/7067fd8f75d5eae5d849cc6695b422469a7b7063/appengine/components/components/auth/ui/rest_api_test.py [modify] https://crrev.com/7067fd8f75d5eae5d849cc6695b422469a7b7063/appengine/components/components/auth/ui/templates/api.html [modify] https://crrev.com/7067fd8f75d5eae5d849cc6695b422469a7b7063/appengine/components/components/auth/ui/ui.py
,
Dec 13 2016
This available on chrome-infra-auth-dev: Single request: GET https://chrome-infra-auth-dev.appspot.com//auth/api/v1/memberships/list?identity=user:vadimsh@google.com Reply: {"memberships": [ {"group": "administrators"}, {"group": "all"}, {"group": "auth-service-access"}, ... ]} Batch request: POST https://chrome-infra-auth-dev.appspot.com//auth/api/v1/memberships/list Request: { "per_identity": { "user:vadimsh@google.com": nil, "user:someone@example.com": nil } } (nil's are call options, currently there are none. This is to make it consistent with /memberships/check batch call that does have options) Reply: { "per_identity": { "user:vadimsh@google.com": {"memberships": [ {"group": "administrators"}, {"group": "all"}, {"group": "auth-service-access"}, ... ]}, "user:someone@example.com": {"memberships": [ {"group": "all"}, {"group": "authenticated-users"}, {"group": "domain-example-com"} ]} } } Please also read the (new) API doc for general overview: https://chrome-infra-auth-dev.appspot.com/auth/api --- Will close as fixed after deploying this to main chrome-infra-auth instance.
,
Dec 13 2016
|
|
►
Sign in to add a comment |
|
Comment 1 by andyb...@chromium.org
, Dec 6 2016