ConsumerApi

<back to all web services

FindAvailableFilterRequest

Consumer
Requires Authentication
Required role:Consumer
The following routes are available for this service:
GET/find/filtering

library ConsumerApi;
import 'package:servicestack/servicestack.dart';

enum Parking
{
    StreetParking,
    ParkingGarageNearby,
}

enum PaymentOption
{
    Visa,
    MasterCard,
    AmericanExpress,
    Diners,
    Vipps,
}

enum PriceMainDish
{
    Value,
    Medium,
    High,
    FineDining,
}

enum DayOfWeek
{
    Sunday,
    Monday,
    Tuesday,
    Wednesday,
    Thursday,
    Friday,
    Saturday,
}

class OpenAtTimeDto implements IConvertible
{
    DayOfWeek? weekDay;
    int? hour;
    int? minute;

    OpenAtTimeDto({this.weekDay,this.hour,this.minute});
    OpenAtTimeDto.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        weekDay = JsonConverters.fromJson(json['weekDay'],'DayOfWeek',context!);
        hour = json['hour'];
        minute = json['minute'];
        return this;
    }

    Map<String, dynamic> toJson() => {
        'weekDay': JsonConverters.toJson(weekDay,'DayOfWeek',context!),
        'hour': hour,
        'minute': minute
    };

    getTypeName() => "OpenAtTimeDto";
    TypeContext? context = _ctx;
}

class BarTypeEsDto implements IConvertible
{
    String? slug;
    String? title;

    BarTypeEsDto({this.slug,this.title});
    BarTypeEsDto.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        slug = json['slug'];
        title = json['title'];
        return this;
    }

    Map<String, dynamic> toJson() => {
        'slug': slug,
        'title': title
    };

    getTypeName() => "BarTypeEsDto";
    TypeContext? context = _ctx;
}

class BarSpecialityEsDto implements IConvertible
{
    String? slug;
    String? title;

    BarSpecialityEsDto({this.slug,this.title});
    BarSpecialityEsDto.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        slug = json['slug'];
        title = json['title'];
        return this;
    }

    Map<String, dynamic> toJson() => {
        'slug': slug,
        'title': title
    };

    getTypeName() => "BarSpecialityEsDto";
    TypeContext? context = _ctx;
}

class BrandApiDto implements IConvertible
{
    String? name;

    BrandApiDto({this.name});
    BrandApiDto.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        name = json['name'];
        return this;
    }

    Map<String, dynamic> toJson() => {
        'name': name
    };

    getTypeName() => "BrandApiDto";
    TypeContext? context = _ctx;
}

class CuisineEsDto implements IConvertible
{
    String? label;
    String? slug;

    CuisineEsDto({this.label,this.slug});
    CuisineEsDto.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        label = json['label'];
        slug = json['slug'];
        return this;
    }

    Map<String, dynamic> toJson() => {
        'label': label,
        'slug': slug
    };

    getTypeName() => "CuisineEsDto";
    TypeContext? context = _ctx;
}

class MealTypeApiDto implements IConvertible
{
    String? label;
    String? slug;

    MealTypeApiDto({this.label,this.slug});
    MealTypeApiDto.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        label = json['label'];
        slug = json['slug'];
        return this;
    }

    Map<String, dynamic> toJson() => {
        'label': label,
        'slug': slug
    };

    getTypeName() => "MealTypeApiDto";
    TypeContext? context = _ctx;
}

class EatingSuitabilityApiDto implements IConvertible
{
    String? label;
    String? slug;

    EatingSuitabilityApiDto({this.label,this.slug});
    EatingSuitabilityApiDto.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        label = json['label'];
        slug = json['slug'];
        return this;
    }

    Map<String, dynamic> toJson() => {
        'label': label,
        'slug': slug
    };

    getTypeName() => "EatingSuitabilityApiDto";
    TypeContext? context = _ctx;
}

class ParkingApiDto implements IConvertible
{
    String? label;
    Parking? slug;

    ParkingApiDto({this.label,this.slug});
    ParkingApiDto.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        label = json['label'];
        slug = JsonConverters.fromJson(json['slug'],'Parking',context!);
        return this;
    }

    Map<String, dynamic> toJson() => {
        'label': label,
        'slug': JsonConverters.toJson(slug,'Parking',context!)
    };

    getTypeName() => "ParkingApiDto";
    TypeContext? context = _ctx;
}

class PaymentOptionApiDto implements IConvertible
{
    String? label;
    PaymentOption? slug;

    PaymentOptionApiDto({this.label,this.slug});
    PaymentOptionApiDto.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        label = json['label'];
        slug = JsonConverters.fromJson(json['slug'],'PaymentOption',context!);
        return this;
    }

    Map<String, dynamic> toJson() => {
        'label': label,
        'slug': JsonConverters.toJson(slug,'PaymentOption',context!)
    };

    getTypeName() => "PaymentOptionApiDto";
    TypeContext? context = _ctx;
}

class PriceMainDishApiDto implements IConvertible
{
    String? title;
    PriceMainDish? slug;

    PriceMainDishApiDto({this.title,this.slug});
    PriceMainDishApiDto.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        title = json['title'];
        slug = JsonConverters.fromJson(json['slug'],'PriceMainDish',context!);
        return this;
    }

    Map<String, dynamic> toJson() => {
        'title': title,
        'slug': JsonConverters.toJson(slug,'PriceMainDish',context!)
    };

    getTypeName() => "PriceMainDishApiDto";
    TypeContext? context = _ctx;
}

class TakeAwayApiDto implements IConvertible
{
    String? label;
    String? slug;

    TakeAwayApiDto({this.label,this.slug});
    TakeAwayApiDto.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        label = json['label'];
        slug = json['slug'];
        return this;
    }

    Map<String, dynamic> toJson() => {
        'label': label,
        'slug': slug
    };

    getTypeName() => "TakeAwayApiDto";
    TypeContext? context = _ctx;
}

class WearPriceProfileEsDto implements IConvertible
{
    String? slug;
    String? label;

    WearPriceProfileEsDto({this.slug,this.label});
    WearPriceProfileEsDto.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        slug = json['slug'];
        label = json['label'];
        return this;
    }

    Map<String, dynamic> toJson() => {
        'slug': slug,
        'label': label
    };

    getTypeName() => "WearPriceProfileEsDto";
    TypeContext? context = _ctx;
}

enum FeatureType
{
    BarSpeciality,
    BarType,
    Cuisine,
    SaveFoodAndMoney,
    MealType,
    Menu,
    OutdoorSeating,
    Parking,
    PaymentOptions,
    PriceMainDish,
    SubCategories,
    SubCategoriesAndBrands,
    EatingSuitabilities,
    TakeAway,
    WearPriceProfile,
    WheelChairAccessible,
    Wifi,
    WebShop,
    Filtering,
}

TypeContext _ctx = TypeContext(library: 'ConsumerApi', types: <String, TypeInfo> {
    'Parking': TypeInfo(TypeOf.Enum, enumValues:Parking.values),
    'PaymentOption': TypeInfo(TypeOf.Enum, enumValues:PaymentOption.values),
    'PriceMainDish': TypeInfo(TypeOf.Enum, enumValues:PriceMainDish.values),
    'DayOfWeek': TypeInfo(TypeOf.Enum, enumValues:DayOfWeek.values),
    'OpenAtTimeDto': TypeInfo(TypeOf.Class, create:() => OpenAtTimeDto()),
    'BarTypeEsDto': TypeInfo(TypeOf.Class, create:() => BarTypeEsDto()),
    'BarSpecialityEsDto': TypeInfo(TypeOf.Class, create:() => BarSpecialityEsDto()),
    'BrandApiDto': TypeInfo(TypeOf.Class, create:() => BrandApiDto()),
    'CuisineEsDto': TypeInfo(TypeOf.Class, create:() => CuisineEsDto()),
    'MealTypeApiDto': TypeInfo(TypeOf.Class, create:() => MealTypeApiDto()),
    'EatingSuitabilityApiDto': TypeInfo(TypeOf.Class, create:() => EatingSuitabilityApiDto()),
    'ParkingApiDto': TypeInfo(TypeOf.Class, create:() => ParkingApiDto()),
    'PaymentOptionApiDto': TypeInfo(TypeOf.Class, create:() => PaymentOptionApiDto()),
    'PriceMainDishApiDto': TypeInfo(TypeOf.Class, create:() => PriceMainDishApiDto()),
    'TakeAwayApiDto': TypeInfo(TypeOf.Class, create:() => TakeAwayApiDto()),
    'WearPriceProfileEsDto': TypeInfo(TypeOf.Class, create:() => WearPriceProfileEsDto()),
    'FeatureType': TypeInfo(TypeOf.Enum, enumValues:FeatureType.values),
});

Dart FindAvailableFilterRequest 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 /find/filtering HTTP/1.1 
Host: unstable-consumer-api.brovs.com 
Accept: application/xml
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length

<FindAvailableFilterResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/ConsumerApi.Dto">
  <BarSpecialities>
    <BarSpecialityCountDto>
      <Slug xmlns="http://schemas.datacontract.org/2004/07/Api.Dto">String</Slug>
      <Title xmlns="http://schemas.datacontract.org/2004/07/Api.Dto">String</Title>
      <Count>0</Count>
    </BarSpecialityCountDto>
  </BarSpecialities>
  <BarTypes>
    <BarTypeCountDto>
      <Slug xmlns="http://schemas.datacontract.org/2004/07/Api.Dto">String</Slug>
      <Title xmlns="http://schemas.datacontract.org/2004/07/Api.Dto">String</Title>
      <Count>0</Count>
    </BarTypeCountDto>
  </BarTypes>
  <Brands>
    <BrandCountDto>
      <Name xmlns="http://schemas.datacontract.org/2004/07/Api.Dto">String</Name>
      <Count>0</Count>
    </BrandCountDto>
  </Brands>
  <Categories>
    <CategoryFacetTreeDto>
      <AbsoluteSlug>String</AbsoluteSlug>
      <AllImageUrl>String</AllImageUrl>
      <Children>
        <CategoryFacetTreeDto>
          <AbsoluteSlug>String</AbsoluteSlug>
          <AllImageUrl>String</AllImageUrl>
          <Children>
            <CategoryFacetTreeDto>
              <AbsoluteSlug>String</AbsoluteSlug>
              <AllImageUrl>String</AllImageUrl>
              <Children i:nil="true" />
              <Count>0</Count>
              <FeatureTypes xmlns:d8p1="http://schemas.datacontract.org/2004/07/Entities.Database">
                <d8p1:FeatureType>BarSpeciality</d8p1:FeatureType>
              </FeatureTypes>
              <IconImageUrl>String</IconImageUrl>
              <ImageUrl>String</ImageUrl>
              <Name>String</Name>
              <Position>0</Position>
              <Slug>String</Slug>
              <Type>Parent</Type>
            </CategoryFacetTreeDto>
          </Children>
          <Count>0</Count>
          <FeatureTypes xmlns:d6p1="http://schemas.datacontract.org/2004/07/Entities.Database">
            <d6p1:FeatureType>BarSpeciality</d6p1:FeatureType>
          </FeatureTypes>
          <IconImageUrl>String</IconImageUrl>
          <ImageUrl>String</ImageUrl>
          <Name>String</Name>
          <Position>0</Position>
          <Slug>String</Slug>
          <Type>Parent</Type>
        </CategoryFacetTreeDto>
      </Children>
      <Count>0</Count>
      <FeatureTypes xmlns:d4p1="http://schemas.datacontract.org/2004/07/Entities.Database">
        <d4p1:FeatureType>BarSpeciality</d4p1:FeatureType>
      </FeatureTypes>
      <IconImageUrl>String</IconImageUrl>
      <ImageUrl>String</ImageUrl>
      <Name>String</Name>
      <Position>0</Position>
      <Slug>String</Slug>
      <Type>Parent</Type>
    </CategoryFacetTreeDto>
  </Categories>
  <Cuisines>
    <CuisineCountDto>
      <Label xmlns="http://schemas.datacontract.org/2004/07/Api.Dto">String</Label>
      <Slug xmlns="http://schemas.datacontract.org/2004/07/Api.Dto">String</Slug>
      <Count>0</Count>
    </CuisineCountDto>
  </Cuisines>
  <EatingSuitabilities>
    <EatingSuitabilityCountDto>
      <Label xmlns="http://schemas.datacontract.org/2004/07/Api.Dto">String</Label>
      <Slug xmlns="http://schemas.datacontract.org/2004/07/Api.Dto">String</Slug>
      <Count>0</Count>
    </EatingSuitabilityCountDto>
  </EatingSuitabilities>
  <MealType>
    <MealTypeCountDto>
      <Label xmlns="http://schemas.datacontract.org/2004/07/Api.Dto">String</Label>
      <Slug xmlns="http://schemas.datacontract.org/2004/07/Api.Dto">String</Slug>
      <Count>0</Count>
    </MealTypeCountDto>
  </MealType>
  <Parkings>
    <ParkingCountDto>
      <Label xmlns="http://schemas.datacontract.org/2004/07/Api.Dto">String</Label>
      <Slug xmlns="http://schemas.datacontract.org/2004/07/Api.Dto">StreetParking</Slug>
      <Count>0</Count>
    </ParkingCountDto>
  </Parkings>
  <PaymentOptions>
    <PaymentOptionCountDto>
      <Label xmlns="http://schemas.datacontract.org/2004/07/Api.Dto">String</Label>
      <Slug xmlns="http://schemas.datacontract.org/2004/07/Api.Dto">Visa</Slug>
      <Count>0</Count>
    </PaymentOptionCountDto>
  </PaymentOptions>
  <PriceMainDishes>
    <PriceMainDishCountDto>
      <Slug xmlns="http://schemas.datacontract.org/2004/07/Api.Dto">Value</Slug>
      <Title xmlns="http://schemas.datacontract.org/2004/07/Api.Dto">String</Title>
      <Count>0</Count>
    </PriceMainDishCountDto>
  </PriceMainDishes>
  <TakeAways>
    <TakeAwayCountDto>
      <Label xmlns="http://schemas.datacontract.org/2004/07/Api.Dto">String</Label>
      <Slug xmlns="http://schemas.datacontract.org/2004/07/Api.Dto">String</Slug>
      <Count>0</Count>
    </TakeAwayCountDto>
  </TakeAways>
  <WearPriceProfiles>
    <WearPriceProfileCountDto>
      <Label xmlns="http://schemas.datacontract.org/2004/07/Api.Dto">String</Label>
      <Slug xmlns="http://schemas.datacontract.org/2004/07/Api.Dto">String</Slug>
      <Count>0</Count>
    </WearPriceProfileCountDto>
  </WearPriceProfiles>
</FindAvailableFilterResponse>