Richemont.Booster2.PublicApi

<back to all web services

GetAddressTypes

Requires Authentication
The following routes are available for this service:
GET/addressTypesGet all available address types
import 'package:servicestack/servicestack.dart';

class AddressType implements IConvertible
{
    /**
    * Booster Address Type
    */
    // @ApiMember(Description="Booster Address Type", IsRequired=true)
    String? addressType;

    /**
    * Address type description translation
    */
    // @ApiMember(Description="Address type description translation", IsRequired=true)
    String? translation;

    AddressType({this.addressType,this.translation});
    AddressType.fromJson(Map<String, dynamic> json) { fromMap(json); }

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

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

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

class GetAddressTypesResponse extends ListBase<AddressType> implements IConvertible
{
    final List<AddressType> l = [];
    set length(int newLength) { l.length = newLength; }
    int get length => l.length;
    AddressType operator [](int index) => l[index];
    void operator []=(int index, AddressType value) { l[index] = value; }
    GetAddressTypesResponse();
    GetAddressTypesResponse.fromJson(Map<String, dynamic> json) : super();
    fromMap(Map<String, dynamic> json) {
        return this;
    }

    Map<String, dynamic> toJson() => {};
    getTypeName() => "GetAddressTypesResponse";
    TypeContext? context = _ctx;
}

class GetAddressTypes implements IConvertible
{
    GetAddressTypes();
    GetAddressTypes.fromJson(Map<String, dynamic> json) : super();
    fromMap(Map<String, dynamic> json) {
        return this;
    }

    Map<String, dynamic> toJson() => {};
    getTypeName() => "GetAddressTypes";
    TypeContext? context = _ctx;
}

TypeContext _ctx = TypeContext(library: 'dev_api_booster.richemont.com', types: <String, TypeInfo> {
    'AddressType': TypeInfo(TypeOf.Class, create:() => AddressType()),
    'GetAddressTypesResponse': TypeInfo(TypeOf.Class, create:() => GetAddressTypesResponse()),
    'GetAddressTypes': TypeInfo(TypeOf.Class, create:() => GetAddressTypes()),
});

Dart GetAddressTypes 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 /addressTypes HTTP/1.1 
Host: dev-api-booster.richemont.com 
Accept: application/xml
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length

<ArrayOfAddressType xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Richemont.Booster2.PublicApi.CRM.ServiceModel" />