wrote basic functions for getting user details