BokaMera.API.Host

<back to all web services

GetVossTargetGroups

Requires Authentication
Requires any of the roles:bookingsupplier-administrator-write, superadmin
The following routes are available for this service:
GET/voss/targetGroupsGet all Voss target groupsReturns every target group in the Voss tenant (all pages).
// @ts-nocheck

// @DataContract(Name="TargetGroupConfigurationResult")
export class TargetGroupConfigurationResult
{
    // @DataMember(Name="id", IsRequired=true)
    public id: string;

    // @DataMember(Name="organizationNumberRequired")
    public organizationNumberRequired: boolean;

    // @DataMember(Name="organizationNumberUnique")
    public organizationNumberUnique: boolean;

    // @DataMember(Name="customerNumberRequired")
    public customerNumberRequired: boolean;

    // @DataMember(Name="customerAddressRequired")
    public customerAddressRequired: boolean;

    // @DataMember(Name="contactPersonRequired")
    public contactPersonRequired: boolean;

    // @DataMember(Name="expiryDateRequired")
    public expiryDateRequired: boolean;

    // @DataMember(Name="excludeCustomerFromInvoiceFile")
    public excludeCustomerFromInvoiceFile: boolean;

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

export enum TypeEnum
{
    Exclusivity = 'Exclusivity',
}

// @DataContract(Name="TargetGroupTagDto")
export class TargetGroupTagDto
{
    // @DataMember(Name="type", IsRequired=true)
    public type: TypeEnum;

    // @DataMember(Name="tag", IsRequired=true)
    public tag: string;

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

// @DataContract(Name="TargetGroupResult")
export class TargetGroupResult
{
    // @DataMember(Name="id", IsRequired=true)
    public id: string;

    // @DataMember(Name="name", IsRequired=true)
    public name: string;

    // @DataMember(Name="isDefault")
    public isDefault: boolean;

    // @DataMember(Name="externalId")
    public externalId: string;

    // @DataMember(Name="configuration", EmitDefaultValue=false)
    public configuration: TargetGroupConfigurationResult;

    // @DataMember(Name="tags", EmitDefaultValue=false)
    public tags: TargetGroupTagDto[] = [];

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

export class GetVossTargetGroupsResponse
{
    public TotalCount: number;
    public Items: TargetGroupResult[] = [];

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

// @ApiResponse(Description="You were unauthorized to call this service", StatusCode=401)
export class GetVossTargetGroups
{

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

TypeScript GetVossTargetGroups 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.

GET /voss/targetGroups HTTP/1.1 
Host: testapi.bokamera.se 
Accept: application/xml
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length

<GetVossTargetGroupsResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/BokaMera.API.ServiceModel.Dtos">
  <Items xmlns:d2p1="http://schemas.datacontract.org/2004/07/BokaMera.VossIntegration.ApiTools.Model">
    <d2p1:TargetGroupResult i:nil="true" />
  </Items>
  <TotalCount>0</TotalCount>
</GetVossTargetGroupsResponse>