BokaMera.API.Host

<back to all web services

DeleteCustomerSuperAdminUser

Requires Authentication
Required role:superadmin
The following routes are available for this service:
DELETE/superadmin/company/{Id}Deletes a customer and everything realted to customer, including administrators and bookings etc.

export class BaseModel
{

    public constructor(init?: Partial<BaseModel>) { (Object as any).assign(this, init); }
}

export class LicenseTypeItem extends BaseModel
{
    // @Ignore()
    public Name: string;

    // @Required()
    public LicenseTypesId: number;

    // @Required()
    public LicenseItemsId: number;

    // @Required()
    public NumberOfItems: number;

    public Id: number;
    public ModifiedDate?: string;

    public constructor(init?: Partial<LicenseTypeItem>) { super(init); (Object as any).assign(this, init); }
}

export class Currency extends BaseModel
{
    // @Required()
    public Name: string;

    // @Required()
    public CurrencySign: string;

    // @Required()
    public Active: boolean;

    public ModifiedDate?: string;
    // @Required()
    public Id: string;

    public constructor(init?: Partial<Currency>) { super(init); (Object as any).assign(this, init); }
}

export class Country extends BaseModel
{
    // @References("typeof(BokaMera.API.ServiceModel.Db.Currency)")
    public CurrencyId: string;

    public CurrencyInfo: Currency;
    // @Required()
    public Name: string;

    public Culture: string;
    public TimeZone: string;
    public ModifiedDate?: string;
    // @Required()
    public Id: string;

    public constructor(init?: Partial<Country>) { super(init); (Object as any).assign(this, init); }
}

export class LicensePrice extends BaseModel
{
    // @Ignore()
    public Country: Country;

    // @Ignore()
    public MonthlyPayment: boolean;

    // @Required()
    public LicenseTypeId: number;

    // @Required()
    public CountryId: string;

    // @Required()
    public Price: number;

    public ModifiedDate?: string;

    public constructor(init?: Partial<LicensePrice>) { super(init); (Object as any).assign(this, init); }
}

export class LicenseType extends BaseModel
{
    // @Ignore()
    public LicenseItems: IList<LicenseTypeItem>;

    // @Ignore()
    public Prices: IList<LicensePrice>;

    // @Ignore()
    public PeriodOfNoticeDays: number;

    // @Ignore()
    public NextLicenseOption: LicenseType;

    // @Required()
    public Name: string;

    // @Required()
    public Description: string;

    // @Required()
    public ExtraLicenseOption: boolean;

    public ModifiedDate?: string;
    public Id: number;

    public constructor(init?: Partial<LicenseType>) { super(init); (Object as any).assign(this, init); }
}

export class License extends BaseModel
{
    public Type: LicenseType;
    // @Required()
    public CompanyId: string;

    public Id: number;
    // @Required()
    public TypeId: number;

    // @Required()
    public ValidFrom: string;

    // @Required()
    public ValidTo: string;

    // @Required()
    public Active: boolean;

    // @Required()
    public Updated: string;

    // @Required()
    public Created: string;

    public ModifiedDate?: string;
    public MetaData: string;

    public constructor(init?: Partial<License>) { super(init); (Object as any).assign(this, init); }
}

export class DeletedCustomerInfoResponse
{
    public CompanyId?: string;
    public ActiveLicenses: License[];
    public Comment: string;

    public constructor(init?: Partial<DeletedCustomerInfoResponse>) { (Object as any).assign(this, init); }
}

// @ApiResponse(Description="", StatusCode=400)
// @ApiResponse(Description="Returned if the current user is not allowed to perform the action", StatusCode=401)
export class DeleteCustomerSuperAdminUser implements ICompany
{
    /** @description Enter the companyId for the customer */
    // @ApiMember(Description="Enter the companyId for the customer", ParameterType="query")
    public CompanyId?: string;

    /** @description Id (guid) of company you wish to delete. */
    // @ApiMember(Description="Id (guid) of company you wish to delete.", IsRequired=true)
    public Id: string;

    public GotApprovedByAdmin: boolean;

    public constructor(init?: Partial<DeleteCustomerSuperAdminUser>) { (Object as any).assign(this, init); }
}

TypeScript DeleteCustomerSuperAdminUser DTOs

To override the Content-type in your clients, use the HTTP Accept Header, append the .xml suffix or ?format=xml

HTTP + XML

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: testapi.bokamera.se 
Accept: application/xml
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length

<DeletedCustomerInfoResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/BokaMera.API.ServiceModel.Dtos">
  <ActiveLicenses xmlns:d2p1="http://schemas.datacontract.org/2004/07/BokaMera.API.ServiceModel.Db">
    <d2p1:License>
      <d2p1:Active>false</d2p1:Active>
      <d2p1:CompanyId>00000000-0000-0000-0000-000000000000</d2p1:CompanyId>
      <d2p1:Created>0001-01-01T00:00:00</d2p1:Created>
      <d2p1:Id>0</d2p1:Id>
      <d2p1:MetaData>String</d2p1:MetaData>
      <d2p1:ModifiedDate xmlns:d4p1="http://schemas.datacontract.org/2004/07/System">
        <d4p1:DateTime>0001-01-01T00:00:00Z</d4p1:DateTime>
        <d4p1:OffsetMinutes>0</d4p1:OffsetMinutes>
      </d2p1:ModifiedDate>
      <d2p1:Type>
        <d2p1:Description>String</d2p1:Description>
        <d2p1:ExtraLicenseOption>false</d2p1:ExtraLicenseOption>
        <d2p1:Id>0</d2p1:Id>
        <d2p1:LicenseItems i:nil="true" />
        <d2p1:ModifiedDate xmlns:d5p1="http://schemas.datacontract.org/2004/07/System">
          <d5p1:DateTime>0001-01-01T00:00:00Z</d5p1:DateTime>
          <d5p1:OffsetMinutes>0</d5p1:OffsetMinutes>
        </d2p1:ModifiedDate>
        <d2p1:Name>String</d2p1:Name>
        <d2p1:Prices i:nil="true" />
      </d2p1:Type>
      <d2p1:TypeId>0</d2p1:TypeId>
      <d2p1:Updated>0001-01-01T00:00:00</d2p1:Updated>
      <d2p1:ValidFrom>0001-01-01T00:00:00</d2p1:ValidFrom>
      <d2p1:ValidTo>0001-01-01T00:00:00</d2p1:ValidTo>
    </d2p1:License>
  </ActiveLicenses>
  <Comment>String</Comment>
  <CompanyId>00000000-0000-0000-0000-000000000000</CompanyId>
</DeletedCustomerInfoResponse>