/* Options: Date: 2025-05-05 01:29:35 Version: 8.71 Tip: To override a DTO option, remove "//" prefix before updating BaseUrl: https://team.evovoice.io //GlobalNamespace: //AddServiceStackTypes: True //AddResponseStatus: False //AddImplicitVersion: //AddDescriptionAsComments: True IncludeTypes: ListCustomers.* //ExcludeTypes: //DefaultImports: package:servicestack/servicestack.dart,dart:typed_data */ import 'package:servicestack/servicestack.dart'; import 'dart:typed_data'; class BillingItem implements IConvertible { double? baseCost; double? rawUnitMultiplier; double? unitCost; int? allowance; BillingItem({this.baseCost,this.rawUnitMultiplier,this.unitCost,this.allowance}); BillingItem.fromJson(Map json) { fromMap(json); } fromMap(Map json) { baseCost = JsonConverters.toDouble(json['baseCost']); rawUnitMultiplier = JsonConverters.toDouble(json['rawUnitMultiplier']); unitCost = JsonConverters.toDouble(json['unitCost']); allowance = json['allowance']; return this; } Map toJson() => { 'baseCost': baseCost, 'rawUnitMultiplier': rawUnitMultiplier, 'unitCost': unitCost, 'allowance': allowance }; getTypeName() => "BillingItem"; TypeContext? context = _ctx; } class BillingSettings implements IConvertible { BillingItem? base; BillingItem? localNumbers; BillingItem? tollFreeNumbers; BillingItem? inboundVoiceCalls; BillingItem? outboundVoiceCalls; BillingItem? inboundFaxes; BillingItem? outboundFaxes; BillingItem? inboundSmsMessages; BillingItem? outboundSmsMessages; BillingItem? aiInsights; BillingItem? aiLiveMinutes; BillingSettings({this.base,this.localNumbers,this.tollFreeNumbers,this.inboundVoiceCalls,this.outboundVoiceCalls,this.inboundFaxes,this.outboundFaxes,this.inboundSmsMessages,this.outboundSmsMessages,this.aiInsights,this.aiLiveMinutes}); BillingSettings.fromJson(Map json) { fromMap(json); } fromMap(Map json) { base = JsonConverters.fromJson(json['base'],'BillingItem',context!); localNumbers = JsonConverters.fromJson(json['localNumbers'],'BillingItem',context!); tollFreeNumbers = JsonConverters.fromJson(json['tollFreeNumbers'],'BillingItem',context!); inboundVoiceCalls = JsonConverters.fromJson(json['inboundVoiceCalls'],'BillingItem',context!); outboundVoiceCalls = JsonConverters.fromJson(json['outboundVoiceCalls'],'BillingItem',context!); inboundFaxes = JsonConverters.fromJson(json['inboundFaxes'],'BillingItem',context!); outboundFaxes = JsonConverters.fromJson(json['outboundFaxes'],'BillingItem',context!); inboundSmsMessages = JsonConverters.fromJson(json['inboundSmsMessages'],'BillingItem',context!); outboundSmsMessages = JsonConverters.fromJson(json['outboundSmsMessages'],'BillingItem',context!); aiInsights = JsonConverters.fromJson(json['aiInsights'],'BillingItem',context!); aiLiveMinutes = JsonConverters.fromJson(json['aiLiveMinutes'],'BillingItem',context!); return this; } Map toJson() => { 'base': JsonConverters.toJson(base,'BillingItem',context!), 'localNumbers': JsonConverters.toJson(localNumbers,'BillingItem',context!), 'tollFreeNumbers': JsonConverters.toJson(tollFreeNumbers,'BillingItem',context!), 'inboundVoiceCalls': JsonConverters.toJson(inboundVoiceCalls,'BillingItem',context!), 'outboundVoiceCalls': JsonConverters.toJson(outboundVoiceCalls,'BillingItem',context!), 'inboundFaxes': JsonConverters.toJson(inboundFaxes,'BillingItem',context!), 'outboundFaxes': JsonConverters.toJson(outboundFaxes,'BillingItem',context!), 'inboundSmsMessages': JsonConverters.toJson(inboundSmsMessages,'BillingItem',context!), 'outboundSmsMessages': JsonConverters.toJson(outboundSmsMessages,'BillingItem',context!), 'aiInsights': JsonConverters.toJson(aiInsights,'BillingItem',context!), 'aiLiveMinutes': JsonConverters.toJson(aiLiveMinutes,'BillingItem',context!) }; getTypeName() => "BillingSettings"; TypeContext? context = _ctx; } enum SortOrders { Ascend, Descend, } abstract class ListRequest implements IGet { /** * The page of data to retrieve */ // @ApiMember(Description="The page of data to retrieve") int? page; /** * If you want all objects to be returned. This should be used with care */ // @ApiMember(Description="If you want all objects to be returned. This should be used with care") bool? all; /** * The number per page to retrieve */ // @ApiMember(Description="The number per page to retrieve") int? countPerPage; /** * Specific IDs */ // @ApiMember(Description="Specific IDs") List? specificIds; /** * Specify a sort field */ // @ApiMember(Description="Specify a sort field") String? sortField; /** * Specify a sort order */ // @ApiMember(Description="Specify a sort order") SortOrders? sortOrder; /** * Disables total / page counts - improves performance. Returns only data. If there is no more data, Items will be empty array */ // @ApiMember(Description="Disables total / page counts - improves performance. Returns only data. If there is no more data, Items will be empty array") bool? simplifiedPaging; ListRequest({this.page,this.all,this.countPerPage,this.specificIds,this.sortField,this.sortOrder,this.simplifiedPaging}); ListRequest.fromJson(Map json) { fromMap(json); } fromMap(Map json) { page = json['page']; all = json['all']; countPerPage = json['countPerPage']; specificIds = JsonConverters.fromJson(json['specificIds'],'List',context!); sortField = json['sortField']; sortOrder = JsonConverters.fromJson(json['sortOrder'],'SortOrders',context!); simplifiedPaging = json['simplifiedPaging']; return this; } Map toJson() => { 'page': page, 'all': all, 'countPerPage': countPerPage, 'specificIds': JsonConverters.toJson(specificIds,'List',context!), 'sortField': sortField, 'sortOrder': JsonConverters.toJson(sortOrder,'SortOrders',context!), 'simplifiedPaging': simplifiedPaging }; getTypeName() => "ListRequest<$T>"; TypeContext? context = _ctx; } class Struct extends Map implements IConvertible { Struct(); Struct.fromJson(Map json) : super.fromJson(json); fromMap(Map json) { super.fromMap(json); return this; } Map toJson() => super.toJson(); getTypeName() => "Struct"; TypeContext? context = _ctx; } class Value implements IConvertible { bool? boolValue; String? stringValue; double? numberValue; List? listValue; Struct? structValue; Value({this.boolValue,this.stringValue,this.numberValue,this.listValue,this.structValue}); Value.fromJson(Map json) { fromMap(json); } fromMap(Map json) { boolValue = json['boolValue']; stringValue = json['stringValue']; numberValue = JsonConverters.toDouble(json['numberValue']); listValue = JsonConverters.fromJson(json['listValue'],'List',context!); structValue = JsonConverters.fromJson(json['structValue'],'Struct',context!); return this; } Map toJson() => { 'boolValue': boolValue, 'stringValue': stringValue, 'numberValue': numberValue, 'listValue': JsonConverters.toJson(listValue,'List',context!), 'structValue': JsonConverters.toJson(structValue,'Struct',context!) }; getTypeName() => "Value"; TypeContext? context = _ctx; } class AppSettings implements IConvertible { bool? enablePhoneNumberManagement; bool? enableDeviceManagement; bool? enableDialer; bool? enableCallHistory; bool? enableAssistants; bool? showFileNameInMessageCenter; String? chakraTheme; String? customCss; String? pageTitle; String? stringMappings; String? logoutUrl; String? portMyNumberUrl; AppSettings({this.enablePhoneNumberManagement,this.enableDeviceManagement,this.enableDialer,this.enableCallHistory,this.enableAssistants,this.showFileNameInMessageCenter,this.chakraTheme,this.customCss,this.pageTitle,this.stringMappings,this.logoutUrl,this.portMyNumberUrl}); AppSettings.fromJson(Map json) { fromMap(json); } fromMap(Map json) { enablePhoneNumberManagement = json['enablePhoneNumberManagement']; enableDeviceManagement = json['enableDeviceManagement']; enableDialer = json['enableDialer']; enableCallHistory = json['enableCallHistory']; enableAssistants = json['enableAssistants']; showFileNameInMessageCenter = json['showFileNameInMessageCenter']; chakraTheme = json['chakraTheme']; customCss = json['customCss']; pageTitle = json['pageTitle']; stringMappings = json['stringMappings']; logoutUrl = json['logoutUrl']; portMyNumberUrl = json['portMyNumberUrl']; return this; } Map toJson() => { 'enablePhoneNumberManagement': enablePhoneNumberManagement, 'enableDeviceManagement': enableDeviceManagement, 'enableDialer': enableDialer, 'enableCallHistory': enableCallHistory, 'enableAssistants': enableAssistants, 'showFileNameInMessageCenter': showFileNameInMessageCenter, 'chakraTheme': chakraTheme, 'customCss': customCss, 'pageTitle': pageTitle, 'stringMappings': stringMappings, 'logoutUrl': logoutUrl, 'portMyNumberUrl': portMyNumberUrl }; getTypeName() => "AppSettings"; TypeContext? context = _ctx; } enum TagColors { Magenta, Red, Volcano, Orange, Gold, Lime, Green, Cyan, Blue, GeekBlue, Purple, } class Tag implements IConvertible { String? id; String? name; TagColors? color; Tag({this.id,this.name,this.color}); Tag.fromJson(Map json) { fromMap(json); } fromMap(Map json) { id = json['id']; name = json['name']; color = JsonConverters.fromJson(json['color'],'TagColors',context!); return this; } Map toJson() => { 'id': id, 'name': name, 'color': JsonConverters.toJson(color,'TagColors',context!) }; getTypeName() => "Tag"; TypeContext? context = _ctx; } abstract class EntityInfo { /** * The ID of the object */ // @ApiMember(Description="The ID of the object") String? id; /** * The date the object was created */ // @ApiMember(Description="The date the object was created") String? dateCreated; /** * The date the object was last modified */ // @ApiMember(Description="The date the object was last modified") String? dateLastModified; /** * The user that created this object */ // @ApiMember(Description="The user that created this object") String? createdBy; /** * The user that last modified this object */ // @ApiMember(Description="The user that last modified this object") String? lastModifiedBy; EntityInfo({this.id,this.dateCreated,this.dateLastModified,this.createdBy,this.lastModifiedBy}); EntityInfo.fromJson(Map json) { fromMap(json); } fromMap(Map json) { id = json['id']; dateCreated = json['dateCreated']; dateLastModified = json['dateLastModified']; createdBy = json['createdBy']; lastModifiedBy = json['lastModifiedBy']; return this; } Map toJson() => { 'id': id, 'dateCreated': dateCreated, 'dateLastModified': dateLastModified, 'createdBy': createdBy, 'lastModifiedBy': lastModifiedBy }; getTypeName() => "EntityInfo"; TypeContext? context = _ctx; } class ListResponse implements IConvertible { /** * The items */ // @ApiMember(Description="The items") List? items; /** * The total number of items */ // @ApiMember(Description="The total number of items") int? totalCount; /** * The total number of pages */ // @ApiMember(Description="The total number of pages") int? totalPages; /** * Are there more pages of items? Used with simplified paging */ // @ApiMember(Description="Are there more pages of items? Used with simplified paging") bool? hasMorePages; ListResponse({this.items,this.totalCount,this.totalPages,this.hasMorePages}); ListResponse.fromJson(Map json) { fromMap(json); } fromMap(Map json) { items = JsonConverters.fromJson(json['items'],'List<${runtimeGenericTypeDefs(this,[0]).join(",")}>',context!); totalCount = json['totalCount']; totalPages = json['totalPages']; hasMorePages = json['hasMorePages']; return this; } Map toJson() => { 'items': JsonConverters.toJson(items,'List',context!), 'totalCount': totalCount, 'totalPages': totalPages, 'hasMorePages': hasMorePages }; getTypeName() => "ListResponse<$T>"; TypeContext? context = _ctx; } class CustomerBreadcrumb implements IConvertible { String? id; String? name; CustomerBreadcrumb({this.id,this.name}); CustomerBreadcrumb.fromJson(Map json) { fromMap(json); } fromMap(Map json) { id = json['id']; name = json['name']; return this; } Map toJson() => { 'id': id, 'name': name }; getTypeName() => "CustomerBreadcrumb"; TypeContext? context = _ctx; } class IntegrationData implements IConvertible { String? thirdPartyId; IntegrationData({this.thirdPartyId}); IntegrationData.fromJson(Map json) { fromMap(json); } fromMap(Map json) { thirdPartyId = json['thirdPartyId']; return this; } Map toJson() => { 'thirdPartyId': thirdPartyId }; getTypeName() => "IntegrationData"; TypeContext? context = _ctx; } class EntityIntegrationData extends Map implements IConvertible { EntityIntegrationData(); EntityIntegrationData.fromJson(Map json) : super.fromJson(json); fromMap(Map json) { super.fromMap(json); return this; } Map toJson() => super.toJson(); getTypeName() => "EntityIntegrationData"; TypeContext? context = _ctx; } class Schedule implements IConvertible { String? timeZoneId; bool? inherit; bool? forceClosed; List? rules; String? defaultState; Schedule({this.timeZoneId,this.inherit,this.forceClosed,this.rules,this.defaultState}); Schedule.fromJson(Map json) { fromMap(json); } fromMap(Map json) { timeZoneId = json['timeZoneId']; inherit = json['inherit']; forceClosed = json['forceClosed']; rules = JsonConverters.fromJson(json['rules'],'List',context!); defaultState = json['defaultState']; return this; } Map toJson() => { 'timeZoneId': timeZoneId, 'inherit': inherit, 'forceClosed': forceClosed, 'rules': JsonConverters.toJson(rules,'List',context!), 'defaultState': defaultState }; getTypeName() => "Schedule"; TypeContext? context = _ctx; } class CustomerInfo extends EntityInfo implements IConvertible { /** * The ID of the account associated with this customer */ // @ApiMember(Description="The ID of the account associated with this customer") String? accountId; /** * The parent customer ID for this customer */ // @ApiMember(Description="The parent customer ID for this customer") String? parentCustomerId; /** * The breadcrumb to this customer */ // @ApiMember(Description="The breadcrumb to this customer") List? breadcrumb; /** * The name of the account associated with this customer */ // @ApiMember(Description="The name of the account associated with this customer") String? accountName; /** * Is this customer staging or production? */ // @ApiMember(Description="Is this customer staging or production?") bool? isStaging; /** * The name of the company */ // @ApiMember(Description="The name of the company") String? name; /** * The reference ID for this company */ // @ApiMember(Description="The reference ID for this company") String? referenceId; /** * This customer's data values */ // @ApiMember(Description="This customer's data values") Struct? data; /** * The list of tags for this customer */ // @ApiMember(Description="The list of tags for this customer") List? tags; /** * This customer's schedule */ // @ApiMember(Description="This customer's schedule") Schedule? schedule; /** * Integration data for this customer */ // @ApiMember(Description="Integration data for this customer") EntityIntegrationData? integrationData; /** * Override this customer's billing settings? Otherwise inherits from parent */ // @ApiMember(Description="Override this customer's billing settings? Otherwise inherits from parent") bool? overrideBillingSettings; /** * Billing settings for this customer */ // @ApiMember(Description="Billing settings for this customer") BillingSettings? billingSettings; /** * Should this customer override the parent customer's app settings */ // @ApiMember(Description="Should this customer override the parent customer's app settings") bool? overrideAppSettings; /** * App / Portal settings for this customer */ // @ApiMember(Description="App / Portal settings for this customer") AppSettings? appSettings; CustomerInfo({this.accountId,this.parentCustomerId,this.breadcrumb,this.accountName,this.isStaging,this.name,this.referenceId,this.data,this.tags,this.schedule,this.integrationData,this.overrideBillingSettings,this.billingSettings,this.overrideAppSettings,this.appSettings}); CustomerInfo.fromJson(Map json) { fromMap(json); } fromMap(Map json) { super.fromMap(json); accountId = json['accountId']; parentCustomerId = json['parentCustomerId']; breadcrumb = JsonConverters.fromJson(json['breadcrumb'],'List',context!); accountName = json['accountName']; isStaging = json['isStaging']; name = json['name']; referenceId = json['referenceId']; data = JsonConverters.fromJson(json['data'],'Struct',context!); tags = JsonConverters.fromJson(json['tags'],'List',context!); schedule = JsonConverters.fromJson(json['schedule'],'Schedule',context!); integrationData = JsonConverters.fromJson(json['integrationData'],'EntityIntegrationData',context!); overrideBillingSettings = json['overrideBillingSettings']; billingSettings = JsonConverters.fromJson(json['billingSettings'],'BillingSettings',context!); overrideAppSettings = json['overrideAppSettings']; appSettings = JsonConverters.fromJson(json['appSettings'],'AppSettings',context!); return this; } Map toJson() => super.toJson()..addAll({ 'accountId': accountId, 'parentCustomerId': parentCustomerId, 'breadcrumb': JsonConverters.toJson(breadcrumb,'List',context!), 'accountName': accountName, 'isStaging': isStaging, 'name': name, 'referenceId': referenceId, 'data': JsonConverters.toJson(data,'Struct',context!), 'tags': JsonConverters.toJson(tags,'List',context!), 'schedule': JsonConverters.toJson(schedule,'Schedule',context!), 'integrationData': JsonConverters.toJson(integrationData,'EntityIntegrationData',context!), 'overrideBillingSettings': overrideBillingSettings, 'billingSettings': JsonConverters.toJson(billingSettings,'BillingSettings',context!), 'overrideAppSettings': overrideAppSettings, 'appSettings': JsonConverters.toJson(appSettings,'AppSettings',context!) }); getTypeName() => "CustomerInfo"; TypeContext? context = _ctx; } /** * Retrieve customers */ // @Route("/customers", "GET") // @Api(Description="Retrieve customers") class ListCustomers extends ListRequest implements IReturn>, IConvertible, IGet { /** * Filter by accounts */ // @ApiMember(Description="Filter by accounts") List? accountIds; /** * Filter by name */ // @ApiMember(Description="Filter by name") String? nameFilter; /** * The IDs of the parent customers you want to filter by */ // @ApiMember(Description="The IDs of the parent customers you want to filter by") List? parentCustomerIds; /** * If you want a shall parent customer filter (e.g. no deep children) */ // @ApiMember(Description="If you want a shall parent customer filter (e.g. no deep children)") bool? shallowParent; /** * The list of tag IDs to filter by (must contain all) */ // @ApiMember(Description="The list of tag IDs to filter by (must contain all)") List? tagIds; ListCustomers({this.accountIds,this.nameFilter,this.parentCustomerIds,this.shallowParent,this.tagIds}); ListCustomers.fromJson(Map json) { fromMap(json); } fromMap(Map json) { super.fromMap(json); accountIds = JsonConverters.fromJson(json['accountIds'],'List',context!); nameFilter = json['nameFilter']; parentCustomerIds = JsonConverters.fromJson(json['parentCustomerIds'],'List',context!); shallowParent = json['shallowParent']; tagIds = JsonConverters.fromJson(json['tagIds'],'List',context!); return this; } Map toJson() => super.toJson()..addAll({ 'accountIds': JsonConverters.toJson(accountIds,'List',context!), 'nameFilter': nameFilter, 'parentCustomerIds': JsonConverters.toJson(parentCustomerIds,'List',context!), 'shallowParent': shallowParent, 'tagIds': JsonConverters.toJson(tagIds,'List',context!) }); createResponse() => ListResponse(); getResponseTypeName() => "ListResponse"; getTypeName() => "ListCustomers"; TypeContext? context = _ctx; } TypeContext _ctx = TypeContext(library: 'team.evovoice.io', types: { 'BillingItem': TypeInfo(TypeOf.Class, create:() => BillingItem()), 'BillingSettings': TypeInfo(TypeOf.Class, create:() => BillingSettings()), 'SortOrders': TypeInfo(TypeOf.Enum, enumValues:SortOrders.values), 'ListRequest': TypeInfo(TypeOf.GenericDef,create:() => ListRequest()), 'Struct': TypeInfo(TypeOf.Class, create:() => Struct()), 'Value': TypeInfo(TypeOf.Class, create:() => Value()), 'List': TypeInfo(TypeOf.Class, create:() => []), 'AppSettings': TypeInfo(TypeOf.Class, create:() => AppSettings()), 'TagColors': TypeInfo(TypeOf.Enum, enumValues:TagColors.values), 'Tag': TypeInfo(TypeOf.Class, create:() => Tag()), 'EntityInfo': TypeInfo(TypeOf.AbstractClass), 'ListResponse': TypeInfo(TypeOf.GenericDef,create:() => ListResponse()), 'CustomerBreadcrumb': TypeInfo(TypeOf.Class, create:() => CustomerBreadcrumb()), 'IntegrationData': TypeInfo(TypeOf.Class, create:() => IntegrationData()), 'EntityIntegrationData': TypeInfo(TypeOf.Class, create:() => EntityIntegrationData()), 'Schedule': TypeInfo(TypeOf.Class, create:() => Schedule()), 'List': TypeInfo(TypeOf.Class, create:() => []), 'SchedulingRule': TypeInfo(TypeOf.Class, create:() => SchedulingRule()), 'CustomerInfo': TypeInfo(TypeOf.Class, create:() => CustomerInfo()), 'List': TypeInfo(TypeOf.Class, create:() => []), 'List': TypeInfo(TypeOf.Class, create:() => []), 'ListResponse': TypeInfo(TypeOf.Class, create:() => ListResponse()), 'ListCustomers': TypeInfo(TypeOf.Class, create:() => ListCustomers()), });