/* Options: Date: 2025-09-22 22:23:54 Version: 6.21 Tip: To override a DTO option, remove "//" prefix before updating BaseUrl: https://accounts.dev.healthmonix.com/api/ //GlobalNamespace: //AddServiceStackTypes: True //AddResponseStatus: False //AddImplicitVersion: //AddDescriptionAsComments: True IncludeTypes: CreateCoupon.* //ExcludeTypes: //DefaultImports: package:servicestack/servicestack.dart */ import 'package:servicestack/servicestack.dart'; class CreateCouponResponse implements IConvertible { String? message; HttpStatusCode? status; CreateCouponResponse({this.message,this.status}); CreateCouponResponse.fromJson(Map json) { fromMap(json); } fromMap(Map json) { message = json['message']; status = JsonConverters.fromJson(json['status'],'HttpStatusCode',context!); return this; } Map toJson() => { 'message': message, 'status': JsonConverters.toJson(status,'HttpStatusCode',context!) }; getTypeName() => "CreateCouponResponse"; TypeContext? context = _ctx; } // @Route("/coupons", "POST") class CreateCoupon implements IReturn, IConvertible { String? name; String? code; String? description; DateTime? effectiveDate; String? discountType; Map? productDiscounts; CreateCoupon({this.name,this.code,this.description,this.effectiveDate,this.discountType,this.productDiscounts}); CreateCoupon.fromJson(Map json) { fromMap(json); } fromMap(Map json) { name = json['name']; code = json['code']; description = json['description']; effectiveDate = JsonConverters.fromJson(json['effectiveDate'],'DateTime',context!); discountType = json['discountType']; productDiscounts = JsonConverters.fromJson(json['productDiscounts'],'Map',context!); return this; } Map toJson() => { 'name': name, 'code': code, 'description': description, 'effectiveDate': JsonConverters.toJson(effectiveDate,'DateTime',context!), 'discountType': discountType, 'productDiscounts': JsonConverters.toJson(productDiscounts,'Map',context!) }; createResponse() => CreateCouponResponse(); getResponseTypeName() => "CreateCouponResponse"; getTypeName() => "CreateCoupon"; TypeContext? context = _ctx; } TypeContext _ctx = TypeContext(library: 'accounts.dev.healthmonix.com', types: { 'CreateCouponResponse': TypeInfo(TypeOf.Class, create:() => CreateCouponResponse()), 'HttpStatusCode': TypeInfo(TypeOf.Class, create:() => HttpStatusCode()), 'CreateCoupon': TypeInfo(TypeOf.Class, create:() => CreateCoupon()), 'Map': TypeInfo(TypeOf.Class, create:() => Map()), });