Required role: | superadmin |
DELETE | /superadmin/company/{Id} | Deletes a customer and everything realted to customer, including administrators and bookings etc. |
---|
import java.math.*;
import java.util.*;
import net.servicestack.client.*;
public class dtos
{
@ApiResponse(Description="", StatusCode=400)
// @ApiResponse(Description="Returned if the current user is not allowed to perform the action", StatusCode=401)
public static class DeleteCustomerSuperAdminUser implements ICompany
{
/**
* Enter the companyId for the customer
*/
@ApiMember(Description="Enter the companyId for the customer", ParameterType="query")
public UUID CompanyId = null;
/**
* Id (guid) of company you wish to delete.
*/
@ApiMember(Description="Id (guid) of company you wish to delete.", IsRequired=true)
public UUID Id = null;
public Boolean GotApprovedByAdmin = null;
public UUID getCompanyId() { return CompanyId; }
public DeleteCustomerSuperAdminUser setCompanyId(UUID value) { this.CompanyId = value; return this; }
public UUID getId() { return Id; }
public DeleteCustomerSuperAdminUser setId(UUID value) { this.Id = value; return this; }
public Boolean isGotApprovedByAdmin() { return GotApprovedByAdmin; }
public DeleteCustomerSuperAdminUser setGotApprovedByAdmin(Boolean value) { this.GotApprovedByAdmin = value; return this; }
}
public static class DeletedCustomerInfoResponse
{
public UUID CompanyId = null;
public ArrayList<License> ActiveLicenses = null;
public String Comment = null;
public UUID getCompanyId() { return CompanyId; }
public DeletedCustomerInfoResponse setCompanyId(UUID value) { this.CompanyId = value; return this; }
public ArrayList<License> getActiveLicenses() { return ActiveLicenses; }
public DeletedCustomerInfoResponse setActiveLicenses(ArrayList<License> value) { this.ActiveLicenses = value; return this; }
public String getComment() { return Comment; }
public DeletedCustomerInfoResponse setComment(String value) { this.Comment = value; return this; }
}
public static class License extends BaseModel
{
public LicenseType Type = null;
@Required()
public UUID CompanyId = null;
public Integer Id = null;
@Required()
public Integer TypeId = null;
@Required()
public Date ValidFrom = null;
@Required()
public Date ValidTo = null;
@Required()
public Boolean Active = null;
@Required()
public Date Updated = null;
@Required()
public Date Created = null;
public Date ModifiedDate = null;
public String MetaData = null;
public LicenseType getType() { return Type; }
public License setType(LicenseType value) { this.Type = value; return this; }
public UUID getCompanyId() { return CompanyId; }
public License setCompanyId(UUID value) { this.CompanyId = value; return this; }
public Integer getId() { return Id; }
public License setId(Integer value) { this.Id = value; return this; }
public Integer getTypeId() { return TypeId; }
public License setTypeId(Integer value) { this.TypeId = value; return this; }
public Date getValidFrom() { return ValidFrom; }
public License setValidFrom(Date value) { this.ValidFrom = value; return this; }
public Date getValidTo() { return ValidTo; }
public License setValidTo(Date value) { this.ValidTo = value; return this; }
public Boolean isActive() { return Active; }
public License setActive(Boolean value) { this.Active = value; return this; }
public Date getUpdated() { return Updated; }
public License setUpdated(Date value) { this.Updated = value; return this; }
public Date getCreated() { return Created; }
public License setCreated(Date value) { this.Created = value; return this; }
public Date getModifiedDate() { return ModifiedDate; }
public License setModifiedDate(Date value) { this.ModifiedDate = value; return this; }
public String getMetaData() { return MetaData; }
public License setMetaData(String value) { this.MetaData = value; return this; }
}
public static class BaseModel
{
}
public static class LicenseType extends BaseModel
{
@Ignore()
public IList<LicenseTypeItem> LicenseItems = null;
@Ignore()
public IList<LicensePrice> Prices = null;
@Ignore()
public Integer PeriodOfNoticeDays = null;
@Ignore()
public LicenseType NextLicenseOption = null;
@Required()
public String Name = null;
@Required()
public String Description = null;
@Required()
public Boolean ExtraLicenseOption = null;
public Date ModifiedDate = null;
public Boolean Active = null;
public Integer Id = null;
public IList<LicenseTypeItem> getLicenseItems() { return LicenseItems; }
public LicenseType setLicenseItems(IList<LicenseTypeItem> value) { this.LicenseItems = value; return this; }
public IList<LicensePrice> getPrices() { return Prices; }
public LicenseType setPrices(IList<LicensePrice> value) { this.Prices = value; return this; }
public Integer getPeriodOfNoticeDays() { return PeriodOfNoticeDays; }
public LicenseType setPeriodOfNoticeDays(Integer value) { this.PeriodOfNoticeDays = value; return this; }
public LicenseType getNextLicenseOption() { return NextLicenseOption; }
public LicenseType setNextLicenseOption(LicenseType value) { this.NextLicenseOption = value; return this; }
public String getName() { return Name; }
public LicenseType setName(String value) { this.Name = value; return this; }
public String getDescription() { return Description; }
public LicenseType setDescription(String value) { this.Description = value; return this; }
public Boolean isExtraLicenseOption() { return ExtraLicenseOption; }
public LicenseType setExtraLicenseOption(Boolean value) { this.ExtraLicenseOption = value; return this; }
public Date getModifiedDate() { return ModifiedDate; }
public LicenseType setModifiedDate(Date value) { this.ModifiedDate = value; return this; }
public Boolean isActive() { return Active; }
public LicenseType setActive(Boolean value) { this.Active = value; return this; }
public Integer getId() { return Id; }
public LicenseType setId(Integer value) { this.Id = value; return this; }
}
public static class LicenseTypeItem extends BaseModel
{
@Ignore()
public String Name = null;
@Ignore()
public LicenseType LicenseType = null;
@Required()
public Integer LicenseTypesId = null;
@Required()
public Integer LicenseItemsId = null;
@Required()
public Integer NumberOfItems = null;
public Integer Id = null;
public Date ModifiedDate = null;
public String getName() { return Name; }
public LicenseTypeItem setName(String value) { this.Name = value; return this; }
public LicenseType getLicenseType() { return LicenseType; }
public LicenseTypeItem setLicenseType(LicenseType value) { this.LicenseType = value; return this; }
public Integer getLicenseTypesId() { return LicenseTypesId; }
public LicenseTypeItem setLicenseTypesId(Integer value) { this.LicenseTypesId = value; return this; }
public Integer getLicenseItemsId() { return LicenseItemsId; }
public LicenseTypeItem setLicenseItemsId(Integer value) { this.LicenseItemsId = value; return this; }
public Integer getNumberOfItems() { return NumberOfItems; }
public LicenseTypeItem setNumberOfItems(Integer value) { this.NumberOfItems = value; return this; }
public Integer getId() { return Id; }
public LicenseTypeItem setId(Integer value) { this.Id = value; return this; }
public Date getModifiedDate() { return ModifiedDate; }
public LicenseTypeItem setModifiedDate(Date value) { this.ModifiedDate = value; return this; }
}
public static class LicensePrice extends BaseModel
{
@Ignore()
public Country Country = null;
@Ignore()
public Boolean MonthlyPayment = null;
@Required()
public Integer LicenseTypeId = null;
@Required()
public String CountryId = null;
@Required()
public Integer Price = null;
public Date ModifiedDate = null;
public Country getCountry() { return Country; }
public LicensePrice setCountry(Country value) { this.Country = value; return this; }
public Boolean isMonthlyPayment() { return MonthlyPayment; }
public LicensePrice setMonthlyPayment(Boolean value) { this.MonthlyPayment = value; return this; }
public Integer getLicenseTypeId() { return LicenseTypeId; }
public LicensePrice setLicenseTypeId(Integer value) { this.LicenseTypeId = value; return this; }
public String getCountryId() { return CountryId; }
public LicensePrice setCountryId(String value) { this.CountryId = value; return this; }
public Integer getPrice() { return Price; }
public LicensePrice setPrice(Integer value) { this.Price = value; return this; }
public Date getModifiedDate() { return ModifiedDate; }
public LicensePrice setModifiedDate(Date value) { this.ModifiedDate = value; return this; }
}
public static class Country extends BaseModel
{
@References(Currency.class)
public String CurrencyId = null;
public Currency CurrencyInfo = null;
@Required()
public String Name = null;
public String Culture = null;
public String TimeZone = null;
public Date ModifiedDate = null;
@Required()
public String Id = null;
public String getCurrencyId() { return CurrencyId; }
public Country setCurrencyId(String value) { this.CurrencyId = value; return this; }
public Currency getCurrencyInfo() { return CurrencyInfo; }
public Country setCurrencyInfo(Currency value) { this.CurrencyInfo = value; return this; }
public String getName() { return Name; }
public Country setName(String value) { this.Name = value; return this; }
public String getCulture() { return Culture; }
public Country setCulture(String value) { this.Culture = value; return this; }
public String getTimeZone() { return TimeZone; }
public Country setTimeZone(String value) { this.TimeZone = value; return this; }
public Date getModifiedDate() { return ModifiedDate; }
public Country setModifiedDate(Date value) { this.ModifiedDate = value; return this; }
public String getId() { return Id; }
public Country setId(String value) { this.Id = value; return this; }
}
public static class Currency extends BaseModel
{
@Required()
public String Name = null;
@Required()
public String CurrencySign = null;
@Required()
public Boolean Active = null;
public Date ModifiedDate = null;
@Required()
public String Id = null;
public String getName() { return Name; }
public Currency setName(String value) { this.Name = value; return this; }
public String getCurrencySign() { return CurrencySign; }
public Currency setCurrencySign(String value) { this.CurrencySign = value; return this; }
public Boolean isActive() { return Active; }
public Currency setActive(Boolean value) { this.Active = value; return this; }
public Date getModifiedDate() { return ModifiedDate; }
public Currency setModifiedDate(Date value) { this.ModifiedDate = value; return this; }
public String getId() { return Id; }
public Currency setId(String value) { this.Id = value; return this; }
}
}
Java DeleteCustomerSuperAdminUser DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .other suffix or ?format=other
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
DELETE /superadmin/company/{Id} HTTP/1.1 Host: api.bokamera.se Accept: text/jsonl
HTTP/1.1 200 OK Content-Type: text/jsonl Content-Length: length {Unable to show example output for type 'DeletedCustomerInfoResponse' using the custom 'other' filter}One or more errors occurred. (License type not handled in NextLicenseOption)