/* Options: Date: 2024-06-17 05:43:34 Version: 8.23 Tip: To override a DTO option, remove "//" prefix before updating BaseUrl: https://testapi.bokamera.se //GlobalNamespace: //MakePropertiesOptional: False //AddServiceStackTypes: True //AddResponseStatus: False //AddImplicitVersion: //AddDescriptionAsComments: True IncludeTypes: CreateInvoice.* //ExcludeTypes: //DefaultImports: */ export interface IReturn { createResponse(): T; } export interface ICompany { CompanyId?: string; } // @DataContract export class ResponseError { // @DataMember(Order=1) public ErrorCode: string; // @DataMember(Order=2) public FieldName: string; // @DataMember(Order=3) public Message: string; // @DataMember(Order=4) public Meta: { [index: string]: string; }; public constructor(init?: Partial) { (Object as any).assign(this, init); } } // @DataContract export class ResponseStatus { // @DataMember(Order=1) public ErrorCode: string; // @DataMember(Order=2) public Message: string; // @DataMember(Order=3) public StackTrace: string; // @DataMember(Order=4) public Errors: ResponseError[]; // @DataMember(Order=5) public Meta: { [index: string]: string; }; public constructor(init?: Partial) { (Object as any).assign(this, init); } } export class InvoiceAddress { public CorporateIdentityNumber: string; public InvoiceAddress1: string; public InvoiceAddress2: string; public InvoiceCity: string; public InvoicePostalCode: string; public InvoiceCountryCode: string; public constructor(init?: Partial) { (Object as any).assign(this, init); } } export enum RotPropertyTypes { Apartment = 1, Property = 2, } export enum RotReducedInvoicingTypes { Normal = 'Normal', Rot = 'Rot', Rut = 'Rut', } export enum EAccountingInvoiceSendTypes { None = 'None', AutoInvoiceElectronic = 'AutoInvoiceElectronic', AutoInvoicePrint = 'AutoInvoicePrint', AutoInvoiceB2C = 'AutoInvoiceB2C', } export class InvoiceQueryResponse { public InvoiceId: string; public CreatedDate: string; public TotalAmount: number; public TotalVatAmount: number; public CustomerId: string; public Rows: InvoiceLineQueryResponse[]; public VatSpecification: VatSpecificationQueryResponse[]; public InvoiceDate: string; public DueDate: string; public DeliveryDate?: string; public Persons: Person[]; public InvoiceCustomerName: string; public InvoiceAddress: InvoiceAddress; public CustomerIsPrivatePerson: boolean; public TermsOfPaymentId: string; public TermsOfPaymentData: EAccountingTermsOfPaymentQueryResponse; public CustomerEmail: string; public InvoiceNumber: number; public CustomerNumber: string; public Notes: NoteQueryResponse[]; public NoteIds: string[]; public CreatedUtc: string; public ModifiedUtc: string; public IncludesVat: boolean; public SendType?: EAccountingInvoiceSendTypes; public IsSold: boolean; public PaymentDate?: string; public PaymentStatus: PaymentStatus; public PaymentStatusTitle: string; public CreditedBy: CreditedBy[]; public PriceSign: string; public BookingId: string; public constructor(init?: Partial) { (Object as any).assign(this, init); } } export class CreateInvoiceQueryResponse { public Invoice: InvoiceQueryResponse; public InvoiceUri: string; public ResponseStatus: ResponseStatus; public constructor(init?: Partial) { (Object as any).assign(this, init); } } // @Route("/eaccounting/invoice", "POST") export class CreateInvoice extends InvoiceAddress implements IReturn, ICompany { /** @description The booking id, to be used to create the customer. */ // @ApiMember(Description="The booking id, to be used to create the customer.", IsRequired=true) public BookingId: number; /** @description The Term of payment Id, to be used to create the invoice. */ // @ApiMember(Description="The Term of payment Id, to be used to create the invoice.", IsRequired=true) public TermsOfPaymentId: string; /** @description Note id's to add to this invoice */ // @ApiMember(Description="Note id's to add to this invoice") public Notes: string[]; /** @description Invoice Customer name */ // @ApiMember(Description="Invoice Customer name") public InvoiceCustomerName: string; /** @description Used for sending the invoice via Auto-invoice Default:None, 0 = None, 1 = AutoInvoiceElectronic, 2 = AutoInvoicePrint, 3 = AutoInvoiceB2C = ['0', '1', '2', '3']. */ // @ApiMember(Description="Used for sending the invoice via Auto-invoice Default:None, 0 = None, 1 = AutoInvoiceElectronic, 2 = AutoInvoicePrint, 3 = AutoInvoiceB2C = ['0', '1', '2', '3'].", IsRequired=true) public SendType: EAccountingInvoiceSendTypes; /** @description 1 = Apartment, 2 = Property Leave blank or set to null if you do not intend to use ROT or Green Technology functionality. */ // @ApiMember(Description="1 = Apartment, 2 = Property Leave blank or set to null if you do not intend to use ROT or Green Technology functionality.", IsRequired=true) public RotPropertyType: RotPropertyTypes; /** @description 0 = Normal, 1 = Rot, 2 = Rut = ['0', '1', '2'] */ // @ApiMember(Description="0 = Normal, 1 = Rot, 2 = Rut = ['0', '1', '2']", IsRequired=true) public RotReducedInvoicingType: RotReducedInvoicingTypes; /** @description 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.") public CompanyId?: string; public constructor(init?: Partial) { super(init); (Object as any).assign(this, init); } public getTypeName() { return 'CreateInvoice'; } public getMethod() { return 'POST'; } public createResponse() { return new CreateInvoiceQueryResponse(); } }