/* Options: Date: 2026-04-01 02:31:17 Version: 10.05 Tip: To override a DTO option, remove "//" prefix before updating BaseUrl: https://api.bokamera.se //GlobalNamespace: //AddServiceStackTypes: True //AddResponseStatus: False //AddImplicitVersion: //AddDescriptionAsComments: True IncludeTypes: CreateSummarizedInvoice.* //ExcludeTypes: //DefaultImports: package:servicestack/servicestack.dart */ import 'package:servicestack/servicestack.dart'; abstract class ICompany { String? CompanyId; } enum EAccountingInvoiceSendTypes { None, AutoInvoiceElectronic, AutoInvoicePrint, AutoInvoiceB2C, } class SummarizedInvoiceJobResponse implements IConvertible { String SummarizedInvoiceId = ""; String CustomerId = ""; String CustomerName = ""; int BookingCount = 0; SummarizedInvoiceJobResponse({this.SummarizedInvoiceId,this.CustomerId,this.CustomerName,this.BookingCount}); SummarizedInvoiceJobResponse.fromJson(Map json) { fromMap(json); } fromMap(Map json) { SummarizedInvoiceId = json['SummarizedInvoiceId']; CustomerId = json['CustomerId']; CustomerName = json['CustomerName']; BookingCount = json['BookingCount']; return this; } Map toJson() => { 'SummarizedInvoiceId': SummarizedInvoiceId, 'CustomerId': CustomerId, 'CustomerName': CustomerName, 'BookingCount': BookingCount }; getTypeName() => "SummarizedInvoiceJobResponse"; TypeContext? context = _ctx; } class CreateSummarizedInvoiceResponse implements IConvertible { int TotalCustomersQueued = 0; List Jobs = []; ResponseStatus ResponseStatus; CreateSummarizedInvoiceResponse({this.TotalCustomersQueued,this.Jobs,this.ResponseStatus}); CreateSummarizedInvoiceResponse.fromJson(Map json) { fromMap(json); } fromMap(Map json) { TotalCustomersQueued = json['TotalCustomersQueued']; Jobs = JsonConverters.fromJson(json['Jobs'],'List',context!); ResponseStatus = JsonConverters.fromJson(json['ResponseStatus'],'ResponseStatus',context!); return this; } Map toJson() => { 'TotalCustomersQueued': TotalCustomersQueued, 'Jobs': JsonConverters.toJson(Jobs,'List',context!), 'ResponseStatus': JsonConverters.toJson(ResponseStatus,'ResponseStatus',context!) }; getTypeName() => "CreateSummarizedInvoiceResponse"; TypeContext? context = _ctx; } // @Route("/eaccounting/summarizedinvoice", "POST") // @ApiResponse(Description="You were unauthorized to call this service", StatusCode=401) // @ValidateRequest(Validator="IsAuthenticated") class CreateSummarizedInvoice implements IReturn, ICompany, IConvertible, IPost { /** * The company id, if empty will use the company id for the user you are logged in with. */ // @ApiMember(Description="The company id, if empty will use the company id for the user you are logged in with.") String? CompanyId; /** * Start date for the booking range to include. */ // @ApiMember(Description="Start date for the booking range to include.", IsRequired=true) DateTime DateFrom = DateTime(0); /** * End date for the booking range to include. */ // @ApiMember(Description="End date for the booking range to include.", IsRequired=true) DateTime DateTo = DateTime(0); /** * Optional customer id. If null, creates one summarized invoice per customer with eligible bookings. */ // @ApiMember(Description="Optional customer id. If null, creates one summarized invoice per customer with eligible bookings.") String? CustomerId; /** * Optional service/event id filter. Only include bookings for this service. */ // @ApiMember(Description="Optional service/event id filter. Only include bookings for this service.") int? ServiceId; /** * Optional list of booking status ids to include. If empty, all statuses are included. */ // @ApiMember(Description="Optional list of booking status ids to include. If empty, all statuses are included.") List? BookingStatusIds; /** * The terms of payment id from EAccounting. */ // @ApiMember(Description="The terms of payment id from EAccounting.", IsRequired=true) String TermsOfPaymentId = ""; /** * Invoice creation type: 'Draft' or 'Invoice'. Defaults to company's EAccounting DefaultCreateType. */ // @ApiMember(Description="Invoice creation type: 'Draft' or 'Invoice'. Defaults to company's EAccounting DefaultCreateType.") String? CreateType; /** * Send type for final invoices. 0 = None, 1 = AutoInvoiceElectronic, 2 = AutoInvoicePrint, 3 = AutoInvoiceB2C. */ // @ApiMember(Description="Send type for final invoices. 0 = None, 1 = AutoInvoiceElectronic, 2 = AutoInvoicePrint, 3 = AutoInvoiceB2C.") EAccountingInvoiceSendTypes? SendType; /** * Override corporate identity number for invoice address. */ // @ApiMember(Description="Override corporate identity number for invoice address.") String? CorporateIdentityNumber; /** * Override invoice address line 1. */ // @ApiMember(Description="Override invoice address line 1.") String? InvoiceAddress1; /** * Override invoice address line 2. */ // @ApiMember(Description="Override invoice address line 2.") String? InvoiceAddress2; /** * Override invoice city. */ // @ApiMember(Description="Override invoice city.") String? InvoiceCity; /** * Override invoice postal code. */ // @ApiMember(Description="Override invoice postal code.") String? InvoicePostalCode; /** * Override invoice country code. */ // @ApiMember(Description="Override invoice country code.") String? InvoiceCountryCode; CreateSummarizedInvoice({this.CompanyId,this.DateFrom,this.DateTo,this.CustomerId,this.ServiceId,this.BookingStatusIds,this.TermsOfPaymentId,this.CreateType,this.SendType,this.CorporateIdentityNumber,this.InvoiceAddress1,this.InvoiceAddress2,this.InvoiceCity,this.InvoicePostalCode,this.InvoiceCountryCode}); CreateSummarizedInvoice.fromJson(Map json) { fromMap(json); } fromMap(Map json) { CompanyId = json['CompanyId']; DateFrom = JsonConverters.fromJson(json['DateFrom'],'DateTime',context!); DateTo = JsonConverters.fromJson(json['DateTo'],'DateTime',context!); CustomerId = json['CustomerId']; ServiceId = json['ServiceId']; BookingStatusIds = JsonConverters.fromJson(json['BookingStatusIds'],'List',context!); TermsOfPaymentId = json['TermsOfPaymentId']; CreateType = json['CreateType']; SendType = JsonConverters.fromJson(json['SendType'],'EAccountingInvoiceSendTypes',context!); CorporateIdentityNumber = json['CorporateIdentityNumber']; InvoiceAddress1 = json['InvoiceAddress1']; InvoiceAddress2 = json['InvoiceAddress2']; InvoiceCity = json['InvoiceCity']; InvoicePostalCode = json['InvoicePostalCode']; InvoiceCountryCode = json['InvoiceCountryCode']; return this; } Map toJson() => { 'CompanyId': CompanyId, 'DateFrom': JsonConverters.toJson(DateFrom,'DateTime',context!), 'DateTo': JsonConverters.toJson(DateTo,'DateTime',context!), 'CustomerId': CustomerId, 'ServiceId': ServiceId, 'BookingStatusIds': JsonConverters.toJson(BookingStatusIds,'List',context!), 'TermsOfPaymentId': TermsOfPaymentId, 'CreateType': CreateType, 'SendType': JsonConverters.toJson(SendType,'EAccountingInvoiceSendTypes',context!), 'CorporateIdentityNumber': CorporateIdentityNumber, 'InvoiceAddress1': InvoiceAddress1, 'InvoiceAddress2': InvoiceAddress2, 'InvoiceCity': InvoiceCity, 'InvoicePostalCode': InvoicePostalCode, 'InvoiceCountryCode': InvoiceCountryCode }; createResponse() => CreateSummarizedInvoiceResponse(); getResponseTypeName() => "CreateSummarizedInvoiceResponse"; getTypeName() => "CreateSummarizedInvoice"; TypeContext? context = _ctx; } TypeContext _ctx = TypeContext(library: 'api.bokamera.se', types: { 'ICompany': TypeInfo(TypeOf.Interface), 'EAccountingInvoiceSendTypes': TypeInfo(TypeOf.Enum, enumValues:EAccountingInvoiceSendTypes.values), 'SummarizedInvoiceJobResponse': TypeInfo(TypeOf.Class, create:() => SummarizedInvoiceJobResponse()), 'CreateSummarizedInvoiceResponse': TypeInfo(TypeOf.Class, create:() => CreateSummarizedInvoiceResponse()), 'List': TypeInfo(TypeOf.Class, create:() => []), 'CreateSummarizedInvoice': TypeInfo(TypeOf.Class, create:() => CreateSummarizedInvoice()), });