/* Options: Date: 2024-12-23 11:20:24 Version: 8.0 Tip: To override a DTO option, remove "//" prefix before updating BaseUrl: https://consumer-api.brovs.com //GlobalNamespace: ConsumerApi //AddServiceStackTypes: True //AddResponseStatus: False //AddImplicitVersion: //AddDescriptionAsComments: True IncludeTypes: ReferBusinessLinkUsedRequest.* //ExcludeTypes: //DefaultImports: package:servicestack/servicestack.dart */ library ConsumerApi; import 'package:servicestack/servicestack.dart'; class ReferBusinessUser implements IConvertible { String? firstName; String? lastName; String? profilePhotoUrl; ReferBusinessUser({this.firstName,this.lastName,this.profilePhotoUrl}); ReferBusinessUser.fromJson(Map json) { fromMap(json); } fromMap(Map json) { firstName = json['firstName']; lastName = json['lastName']; profilePhotoUrl = json['profilePhotoUrl']; return this; } Map toJson() => { 'firstName': firstName, 'lastName': lastName, 'profilePhotoUrl': profilePhotoUrl }; getTypeName() => "ReferBusinessUser"; TypeContext? context = _ctx; } class ReferredPlace implements IConvertible { int? id; String? guid; String? name; String? logoUrl; String? imageUrl; ReferredPlace({this.id,this.guid,this.name,this.logoUrl,this.imageUrl}); ReferredPlace.fromJson(Map json) { fromMap(json); } fromMap(Map json) { id = json['id']; guid = json['guid']; name = json['name']; logoUrl = json['logoUrl']; imageUrl = json['imageUrl']; return this; } Map toJson() => { 'id': id, 'guid': guid, 'name': name, 'logoUrl': logoUrl, 'imageUrl': imageUrl }; getTypeName() => "ReferredPlace"; TypeContext? context = _ctx; } enum ReferBusinessState { SignInToSee, Available, CanNotReferYourself, AlreadyClaimedByYou, AlreadyClaimedBySomeoneElse, Expired, } class ReferBusinessLinkUsedResponse implements IConvertible { ReferBusinessUser? referringUser; ReferredPlace? referredPlace; DateTime? expiresAt; ReferBusinessState? state; ReferBusinessLinkUsedResponse({this.referringUser,this.referredPlace,this.expiresAt,this.state}); ReferBusinessLinkUsedResponse.fromJson(Map json) { fromMap(json); } fromMap(Map json) { referringUser = JsonConverters.fromJson(json['referringUser'],'ReferBusinessUser',context!); referredPlace = JsonConverters.fromJson(json['referredPlace'],'ReferredPlace',context!); expiresAt = JsonConverters.fromJson(json['expiresAt'],'DateTime',context!); state = JsonConverters.fromJson(json['state'],'ReferBusinessState',context!); return this; } Map toJson() => { 'referringUser': JsonConverters.toJson(referringUser,'ReferBusinessUser',context!), 'referredPlace': JsonConverters.toJson(referredPlace,'ReferredPlace',context!), 'expiresAt': JsonConverters.toJson(expiresAt,'DateTime',context!), 'state': JsonConverters.toJson(state,'ReferBusinessState',context!) }; getTypeName() => "ReferBusinessLinkUsedResponse"; TypeContext? context = _ctx; } // @Route("/share/refer-business-link-used", "POST") class ReferBusinessLinkUsedRequest implements IReturn, IPost, IConvertible { String? referBusinessToken; ReferBusinessLinkUsedRequest({this.referBusinessToken}); ReferBusinessLinkUsedRequest.fromJson(Map json) { fromMap(json); } fromMap(Map json) { referBusinessToken = json['referBusinessToken']; return this; } Map toJson() => { 'referBusinessToken': referBusinessToken }; createResponse() => ReferBusinessLinkUsedResponse(); getResponseTypeName() => "ReferBusinessLinkUsedResponse"; getTypeName() => "ReferBusinessLinkUsedRequest"; TypeContext? context = _ctx; } TypeContext _ctx = TypeContext(library: 'ConsumerApi', types: { 'ReferBusinessUser': TypeInfo(TypeOf.Class, create:() => ReferBusinessUser()), 'ReferredPlace': TypeInfo(TypeOf.Class, create:() => ReferredPlace()), 'ReferBusinessState': TypeInfo(TypeOf.Enum, enumValues:ReferBusinessState.values), 'ReferBusinessLinkUsedResponse': TypeInfo(TypeOf.Class, create:() => ReferBusinessLinkUsedResponse()), 'ReferBusinessLinkUsedRequest': TypeInfo(TypeOf.Class, create:() => ReferBusinessLinkUsedRequest()), });