Api REST -> Best way for get an User id #5921
-
Hi, I'm working with the Chamilo REST API, and I need to use a user's ID to be able to perform different actions. What is the best way to get a user's ID via their "username" in your opinion? |
Beta Was this translation helpful? Give feedback.
Replies: 4 comments 3 replies
-
Good morning, |
Beta Was this translation helpful? Give feedback.
-
Theoretically, this should give you a list of users and the id for each On my system it returns an empty list, though. |
Beta Was this translation helpful? Give feedback.
-
Hello @misterakko, thank you for the information, indeed I use ''get_users'' also. However, this is not practical in the sense that it requires retrieving a list and working on it in order to extract the right information. It would have been nice if there was a "get_user" action that was less data intensive. |
Beta Was this translation helpful? Give feedback.
-
Exactly, being able to retrieve the information of a single user (in particular their ID), via their unique identifier (email). Thank you very much for taking this into account. :) |
Beta Was this translation helpful? Give feedback.
I just created #6078 feature request to do that. Please continue there (rather than here) if your requirement is any different from the one described.