Urchin

This code sample explains how to add/update or remove Urchin.

SiteForUpdate site = new SiteForUpdate();

site.webhosting = new WebHosting();

//add Urchin

urchin urchinConfig = new urchin();

urchinConfig.Enabled = true; // To remove set to false

site.webhosting._urchin = new urchin();

site.webhosting._urchin = urchinConfig;

//General details

site.DisplayName = "mysite.com";

site.ContactName = "ABC";

site.ShortName = "mysite.com";

site.ContactName = "0132465798";

site.ContactEmail = "blackhole@ensim.com";

site.AdminDisplayName = "Administrator";

site.AdminUserName = "admin@mysite.com";

site.AdminPassword = "ensim123";

site.AdminEmail = "user@example1.com";

//Service Details

site.webhosting.Enabled = true;

site.webhosting.IsIpbased = true;

site.webhosting.BandwidthQuota = 1024;

site.webhosting.BillingCycleStartDay = 1;

site.webhosting.BandwidthActionSendMail = true;

site.webhosting.BandwidthCapped = false;

site.webhosting.DiskQuota = 25;

site.webhosting.MaxUsers = 5;

//Call update method

w.UpdateSite(site, "admin", "ensim123");