I think that users in open source are admins by default
I think you can just send empty payload for users.get_all
like this {}
and it will return all the users in your database 🙂
I wouldn't mind going the requests
route if I could find the API end point from the SDK?
Yeah, but I wouldn't recommend doing it 🙂
Don't even need to specify json=...
😉 Thanks!
clearml.backend_api.session.defs.ENV_HOST.get()
did not work unfortunately 🤔
It's of course not an MLOps issue so I understand it's not high on the priority list, but would be kinda cool to just have a simple view presenting the content of users.get_all
😄
Follow up on this btw, from the WebUI/Server POV, I see there's an "Admin" role, etc. Do those have additional views available, such as users etc?
The UI uses it to access the list of users for presenting in the tasks table 🙂
Ah, the API server /users.get_all
, I see!
you're better off with the default session - you need the auth info there on top of the endpoint
Sorry, not necessarily RBAC (although that is tempting 😉 ), but for now was just wondering if an average joe user has access to see the list of "registered users"?
it's not supported natively in the APIClient
So some UI that shows the contents of users.get_all
?
Oh, well, yes, but then you'll get all the users 🙂
SuccessfulKoala55 , is this hack applicable for most API calls in ClearML?
On it! Should I include the additional user filters described above?
you can hack it with something like:Task._get_default_session().send_request("users", "get_all", json={"id": [<user-id>]})
Then I think users.get_all
would be right up your alley 🙂
RBAC is something you have in the paid versions 🙂
So no direct page to see e.g. how many people have registered and/or if someone accidentally made two (or more) accounts, or somewhere to just delete users, etc
Yeah that works fine 😄 I just fetch it once to map argparse users to their IDs for later filtering.
The Slack Monitoring example should be updated btw, as they now use slack_sdk
instead of slack
(in the import statements)
For getting user info I guess that's a reasonable hack with not much risk
I couldn't find it directly in the SDK at least (in the APIClient)... 🤔