/* Options: Date: 2025-01-08 03:13:45 Version: 8.53 Tip: To override a DTO option, remove "//" prefix before updating BaseUrl: https://blazordiffusion.com //GlobalNamespace: //AddServiceStackTypes: True //AddResponseStatus: False //AddImplicitVersion: //AddDescriptionAsComments: True IncludeTypes: QueryApiProviders.* //ExcludeTypes: //DefaultImports: package:servicestack/servicestack.dart */ import 'package:servicestack/servicestack.dart'; class ApiProviderModel implements IConvertible { String? model; String? apiModel; ApiProviderModel({this.model,this.apiModel}); ApiProviderModel.fromJson(Map json) { fromMap(json); } fromMap(Map json) { model = json['model']; apiModel = json['apiModel']; return this; } Map toJson() => { 'model': model, 'apiModel': apiModel }; getTypeName() => "ApiProviderModel"; TypeContext? context = _ctx; } enum AiProvider { OpenAiProvider, GoogleAiProvider, } class ApiType implements IConvertible { int? id; AiProvider? provider; String? name; String? website; String? apiBaseUrl; String? heartbeatUrl; String? icon; Map? apiModels = {}; ApiType({this.id,this.provider,this.name,this.website,this.apiBaseUrl,this.heartbeatUrl,this.icon,this.apiModels}); ApiType.fromJson(Map json) { fromMap(json); } fromMap(Map json) { id = json['id']; provider = JsonConverters.fromJson(json['provider'],'AiProvider',context!); name = json['name']; website = json['website']; apiBaseUrl = json['apiBaseUrl']; heartbeatUrl = json['heartbeatUrl']; icon = json['icon']; apiModels = JsonConverters.toStringMap(json['apiModels']); return this; } Map toJson() => { 'id': id, 'provider': JsonConverters.toJson(provider,'AiProvider',context!), 'name': name, 'website': website, 'apiBaseUrl': apiBaseUrl, 'heartbeatUrl': heartbeatUrl, 'icon': icon, 'apiModels': apiModels }; getTypeName() => "ApiType"; TypeContext? context = _ctx; } class ApiProvider implements IConvertible { int? id; String? name; String? apiBaseUrl; int? apiTypeId; String? apiKeyVar; String? apiKey; String? apiKeyHeader; String? heartbeatUrl; int? concurrency; int? priority; bool? enabled; DateTime? offlineDate; DateTime? createdDate; List? models = []; ApiType? apiType; // @ignore() List? selectedModels = []; ApiProvider({this.id,this.name,this.apiBaseUrl,this.apiTypeId,this.apiKeyVar,this.apiKey,this.apiKeyHeader,this.heartbeatUrl,this.concurrency,this.priority,this.enabled,this.offlineDate,this.createdDate,this.models,this.apiType,this.selectedModels}); ApiProvider.fromJson(Map json) { fromMap(json); } fromMap(Map json) { id = json['id']; name = json['name']; apiBaseUrl = json['apiBaseUrl']; apiTypeId = json['apiTypeId']; apiKeyVar = json['apiKeyVar']; apiKey = json['apiKey']; apiKeyHeader = json['apiKeyHeader']; heartbeatUrl = json['heartbeatUrl']; concurrency = json['concurrency']; priority = json['priority']; enabled = json['enabled']; offlineDate = JsonConverters.fromJson(json['offlineDate'],'DateTime',context!); createdDate = JsonConverters.fromJson(json['createdDate'],'DateTime',context!); models = JsonConverters.fromJson(json['models'],'List',context!); apiType = JsonConverters.fromJson(json['apiType'],'ApiType',context!); selectedModels = JsonConverters.fromJson(json['selectedModels'],'List',context!); return this; } Map toJson() => { 'id': id, 'name': name, 'apiBaseUrl': apiBaseUrl, 'apiTypeId': apiTypeId, 'apiKeyVar': apiKeyVar, 'apiKey': apiKey, 'apiKeyHeader': apiKeyHeader, 'heartbeatUrl': heartbeatUrl, 'concurrency': concurrency, 'priority': priority, 'enabled': enabled, 'offlineDate': JsonConverters.toJson(offlineDate,'DateTime',context!), 'createdDate': JsonConverters.toJson(createdDate,'DateTime',context!), 'models': JsonConverters.toJson(models,'List',context!), 'apiType': JsonConverters.toJson(apiType,'ApiType',context!), 'selectedModels': JsonConverters.toJson(selectedModels,'List',context!) }; getTypeName() => "ApiProvider"; TypeContext? context = _ctx; } class QueryApiProviders extends QueryDb implements IReturn>, IConvertible, IGet { String? name; QueryApiProviders({this.name}); QueryApiProviders.fromJson(Map json) { fromMap(json); } fromMap(Map json) { super.fromMap(json); name = json['name']; return this; } Map toJson() => super.toJson()..addAll({ 'name': name }); createResponse() => QueryResponse(); getResponseTypeName() => "QueryResponse"; getTypeName() => "QueryApiProviders"; TypeContext? context = _ctx; } TypeContext _ctx = TypeContext(library: 'blazordiffusion.com', types: { 'ApiProviderModel': TypeInfo(TypeOf.Class, create:() => ApiProviderModel()), 'AiProvider': TypeInfo(TypeOf.Enum, enumValues:AiProvider.values), 'ApiType': TypeInfo(TypeOf.Class, create:() => ApiType()), 'ApiProvider': TypeInfo(TypeOf.Class, create:() => ApiProvider()), 'List': TypeInfo(TypeOf.Class, create:() => []), 'QueryResponse': TypeInfo(TypeOf.Class, create:() => QueryResponse()), 'QueryApiProviders': TypeInfo(TypeOf.Class, create:() => QueryApiProviders()), 'List': TypeInfo(TypeOf.Class, create:() => []), });