/* Options: Date: 2025-09-22 22:15:35 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: CreatePurchaseOrder.* //ExcludeTypes: //DefaultImports: package:servicestack/servicestack.dart */ import 'package:servicestack/servicestack.dart'; class PurchaseOrderItemDto implements IConvertible { int? id; int? purchaseOrderId; String? productId; String? productName; int? quantity; double? price; String? discountDescription; String? discountSource; double? discount; DateTime? createdDate; PurchaseOrderItemDto({this.id,this.purchaseOrderId,this.productId,this.productName,this.quantity,this.price,this.discountDescription,this.discountSource,this.discount,this.createdDate}); PurchaseOrderItemDto.fromJson(Map json) { fromMap(json); } fromMap(Map json) { id = json['id']; purchaseOrderId = json['purchaseOrderId']; productId = json['productId']; productName = json['productName']; quantity = json['quantity']; price = JsonConverters.toDouble(json['price']); discountDescription = json['discountDescription']; discountSource = json['discountSource']; discount = JsonConverters.toDouble(json['discount']); createdDate = JsonConverters.fromJson(json['createdDate'],'DateTime',context!); return this; } Map toJson() => { 'id': id, 'purchaseOrderId': purchaseOrderId, 'productId': productId, 'productName': productName, 'quantity': quantity, 'price': price, 'discountDescription': discountDescription, 'discountSource': discountSource, 'discount': discount, 'createdDate': JsonConverters.toJson(createdDate,'DateTime',context!) }; getTypeName() => "PurchaseOrderItemDto"; TypeContext? context = _ctx; } class BillingInformationDto implements IConvertible { String? cardNumber; String? cardType; int? expireMonth; int? expireYear; String? cvv2; String? firstName; String? lastName; String? city; String? countryCode; String? line1; String? postalCode; String? state; BillingInformationDto({this.cardNumber,this.cardType,this.expireMonth,this.expireYear,this.cvv2,this.firstName,this.lastName,this.city,this.countryCode,this.line1,this.postalCode,this.state}); BillingInformationDto.fromJson(Map json) { fromMap(json); } fromMap(Map json) { cardNumber = json['cardNumber']; cardType = json['cardType']; expireMonth = json['expireMonth']; expireYear = json['expireYear']; cvv2 = json['cvv2']; firstName = json['firstName']; lastName = json['lastName']; city = json['city']; countryCode = json['countryCode']; line1 = json['line1']; postalCode = json['postalCode']; state = json['state']; return this; } Map toJson() => { 'cardNumber': cardNumber, 'cardType': cardType, 'expireMonth': expireMonth, 'expireYear': expireYear, 'cvv2': cvv2, 'firstName': firstName, 'lastName': lastName, 'city': city, 'countryCode': countryCode, 'line1': line1, 'postalCode': postalCode, 'state': state }; getTypeName() => "BillingInformationDto"; TypeContext? context = _ctx; } class Details implements IConvertible { String? code; String? field; String? issue; Details({this.code,this.field,this.issue}); Details.fromJson(Map json) { fromMap(json); } fromMap(Map json) { code = json['code']; field = json['field']; issue = json['issue']; return this; } Map toJson() => { 'code': code, 'field': field, 'issue': issue }; getTypeName() => "Details"; TypeContext? context = _ctx; } class PurchaseOrderDto implements IConvertible { int? id; String? userId; DateTime? createdDate; String? paymentType; bool? Void; bool? paid; String? transactionIdentifier; String? couponCode; List? orderItems; String? payer; String? billingAddressLine1; String? billingAddressCity; String? billingAddressState; String? billingAddressPostalCode; String? billingAddressCountryCode; PurchaseOrderDto({this.id,this.userId,this.createdDate,this.paymentType,this.Void,this.paid,this.transactionIdentifier,this.couponCode,this.orderItems,this.payer,this.billingAddressLine1,this.billingAddressCity,this.billingAddressState,this.billingAddressPostalCode,this.billingAddressCountryCode}); PurchaseOrderDto.fromJson(Map json) { fromMap(json); } fromMap(Map json) { id = json['id']; userId = json['userId']; createdDate = JsonConverters.fromJson(json['createdDate'],'DateTime',context!); paymentType = json['paymentType']; Void = json['void']; paid = json['paid']; transactionIdentifier = json['transactionIdentifier']; couponCode = json['couponCode']; orderItems = JsonConverters.fromJson(json['orderItems'],'List',context!); payer = json['payer']; billingAddressLine1 = json['billingAddressLine1']; billingAddressCity = json['billingAddressCity']; billingAddressState = json['billingAddressState']; billingAddressPostalCode = json['billingAddressPostalCode']; billingAddressCountryCode = json['billingAddressCountryCode']; return this; } Map toJson() => { 'id': id, 'userId': userId, 'createdDate': JsonConverters.toJson(createdDate,'DateTime',context!), 'paymentType': paymentType, 'void': Void, 'paid': paid, 'transactionIdentifier': transactionIdentifier, 'couponCode': couponCode, 'orderItems': JsonConverters.toJson(orderItems,'List',context!), 'payer': payer, 'billingAddressLine1': billingAddressLine1, 'billingAddressCity': billingAddressCity, 'billingAddressState': billingAddressState, 'billingAddressPostalCode': billingAddressPostalCode, 'billingAddressCountryCode': billingAddressCountryCode }; getTypeName() => "PurchaseOrderDto"; TypeContext? context = _ctx; } class CreatePurchaseOrderResponse implements IConvertible { String? message; HttpStatusCode? status; PurchaseOrderDto? purchaseOrder; List
? details; CreatePurchaseOrderResponse({this.message,this.status,this.purchaseOrder,this.details}); CreatePurchaseOrderResponse.fromJson(Map json) { fromMap(json); } fromMap(Map json) { message = json['message']; status = JsonConverters.fromJson(json['status'],'HttpStatusCode',context!); purchaseOrder = JsonConverters.fromJson(json['purchaseOrder'],'PurchaseOrderDto',context!); details = JsonConverters.fromJson(json['details'],'List
',context!); return this; } Map toJson() => { 'message': message, 'status': JsonConverters.toJson(status,'HttpStatusCode',context!), 'purchaseOrder': JsonConverters.toJson(purchaseOrder,'PurchaseOrderDto',context!), 'details': JsonConverters.toJson(details,'List
',context!) }; getTypeName() => "CreatePurchaseOrderResponse"; TypeContext? context = _ctx; } // @Route("/purchaseorders", "POST") class CreatePurchaseOrder implements IReturn, IConvertible { String? userId; String? userEmail; DateTime? createdDate; bool? Void; String? couponCode; List? orderItems; String? paymentType; BillingInformationDto? billingInformationDto; CreatePurchaseOrder({this.userId,this.userEmail,this.createdDate,this.Void,this.couponCode,this.orderItems,this.paymentType,this.billingInformationDto}); CreatePurchaseOrder.fromJson(Map json) { fromMap(json); } fromMap(Map json) { userId = json['userId']; userEmail = json['userEmail']; createdDate = JsonConverters.fromJson(json['createdDate'],'DateTime',context!); Void = json['void']; couponCode = json['couponCode']; orderItems = JsonConverters.fromJson(json['orderItems'],'List',context!); paymentType = json['paymentType']; billingInformationDto = JsonConverters.fromJson(json['billingInformationDto'],'BillingInformationDto',context!); return this; } Map toJson() => { 'userId': userId, 'userEmail': userEmail, 'createdDate': JsonConverters.toJson(createdDate,'DateTime',context!), 'void': Void, 'couponCode': couponCode, 'orderItems': JsonConverters.toJson(orderItems,'List',context!), 'paymentType': paymentType, 'billingInformationDto': JsonConverters.toJson(billingInformationDto,'BillingInformationDto',context!) }; createResponse() => CreatePurchaseOrderResponse(); getResponseTypeName() => "CreatePurchaseOrderResponse"; getTypeName() => "CreatePurchaseOrder"; TypeContext? context = _ctx; } TypeContext _ctx = TypeContext(library: 'accounts.dev.healthmonix.com', types: { 'PurchaseOrderItemDto': TypeInfo(TypeOf.Class, create:() => PurchaseOrderItemDto()), 'BillingInformationDto': TypeInfo(TypeOf.Class, create:() => BillingInformationDto()), 'Details': TypeInfo(TypeOf.Class, create:() => Details()), 'PurchaseOrderDto': TypeInfo(TypeOf.Class, create:() => PurchaseOrderDto()), 'List': TypeInfo(TypeOf.Class, create:() => []), 'PurchaseOrderItem': TypeInfo(TypeOf.Class, create:() => PurchaseOrderItem()), 'CreatePurchaseOrderResponse': TypeInfo(TypeOf.Class, create:() => CreatePurchaseOrderResponse()), 'HttpStatusCode': TypeInfo(TypeOf.Class, create:() => HttpStatusCode()), 'List
': TypeInfo(TypeOf.Class, create:() =>
[]), 'CreatePurchaseOrder': TypeInfo(TypeOf.Class, create:() => CreatePurchaseOrder()), 'List': TypeInfo(TypeOf.Class, create:() => []), });