/// <summary> /// Method to create a new user profile data with required parameters. /// </summary> /// <param name="user">User is a set of parameters used for creating a user.</param> public RaasUserprofile CreateUser(User user) { _valuesToCheck = new ArrayList {user.EmailId, user.Password}; _validate.Validate(_valuesToCheck, "Create User"); var json = user.Serialize(); var response = Post(_object, json); return response.Deserialize<RaasUserprofile>(); }
/// <summary> /// Represents a method to update a user profile /// </summary> /// <param name="user">User is a set of parameters used for creating a user with required parameters.</param> /// <param name="userid">A userid is set of unique numerics and characters that uniquely identifies a user.</param> public LoginRadiusPostResponse UpdateUser(string userid, User user) { _valuesToCheck = new ArrayList {userid}; _validate.Validate(_valuesToCheck, "UpdateUser"); var getRequest = new HttpRequestParameter { {"userid", userid} }; var jsonString = user.Serialize(); var response = Post(_object, getRequest, jsonString); return response.Deserialize<LoginRadiusPostResponse>(); }
/// <summary> /// Represents a method to create a new user profile data with required parameters. /// </summary> /// <param name="user">User is a set of parameters used for creating a user.</param> public RaasUserprofile CreateUser(User user) { _validate.Validate(_valuesToCheck = new ArrayList() { user.EmailId, user.Password, user.FirstName, user.LastName, user.Gender, user.BirthDate }, "CreateUser"); var postRequest = new HttpRequestParameter { {"emailid", user.EmailId}, {"password", user.Password}, {"firstname", user.FirstName}, {"lastname", user.LastName}, {"gender", user.Gender}, {"birthdate", user.BirthDate} }; var response = Post(_object, postRequest); return response.Deserialize<RaasUserprofile>(); }
/// <summary> /// Represents a method to register a new user profile with required parameters into your Cloud Storage and triggers the email verification process. /// </summary> /// <param name="user">User is a set of parameters used for registering a user.</param> public LoginRadiusPostResponse RegisterUser(User user) { _valuesToCheck = new ArrayList {user.EmailId, user.Password}; _validate.Validate(_valuesToCheck, "RegisterUser"); var json = user.Serialize(); var response = Post(_object.ChildObject("register"), json); return response.Deserialize<LoginRadiusPostResponse>(); }
/// <summary> /// Represents a method to register a new user profile with required parameters. /// </summary> /// <param name="user">User is a set of parameters used for registering a user.</param> public LoginRadiusPostResponse RegisterUser(User user) { _validate.Validate(_valuesToCheck = new ArrayList() { user.EmailId, user.Password, user.FirstName, user.LastName, user.Gender, user.BirthDate }, "RegisterUser"); var postRequest = new HttpRequestParameter { {"emailid", user.EmailId}, {"password", user.Password}, {"firstname", user.FirstName}, {"lastname", user.LastName}, {"gender", user.Gender}, {"birthdate", user.BirthDate} }; var response = Post(_object.ChildObject("register"), postRequest); return response.Deserialize<LoginRadiusPostResponse>(); }