This method creates a new user on the Parallels Pro Control Panel server.
Method |
public void AddUser (User user, string username, string password) |
Parameters |
|
Return Value |
none |
User user = new User();
//Mandatory parameters
user.Username = "user1";
user.Password = "ensim123";
user.Template = "FirstUserTemplate";
//Optional parameters
user.Enabled = true;
user.Admin = false;
user.City = "Sunnyvale";
user.Company = "Parallels Pro Control Panel";
user.Country = "US";
user.Department = "Engg.";
user.Description = "WS Test User";
user.Email = "blackhole@ensim.com";
user.FirstName = "WebServices";
user.LastName = "Test User";
user.MiddleName = "";
user.Office = "Office";
user.Phone = "0123465789";
user.State = "CA";
user.Street = "Office Lane";
w.AddUser(user, "admin@mysite.com", "ensim123");
NOTE: Before running this method, the Parallels Pro Control Panel must contain a template for adding a new user for that site. If a template does not exist, you must create a new template using the Parallels Pro Control Panel or by using Web Services API.