import { AutoEncoder } from '@simonbackx/simple-encoding'; import { Address } from '../addresses/Address.js'; import { File } from '../files/File.js'; import { STInvoiceItem } from './STInvoiceItem.js'; export declare class STInvoiceMeta extends AutoEncoder { /** * Date the invoice was valid and given a number. */ date?: Date; /** * Only set if the invoice is officially generated and send */ pdf?: File; /** * Only set if the invoice is officially generated and send + company has VAT number */ xml?: File; /** * Has this been charged automatically via outstanding amount? */ backgroundCharge: boolean; /** * VATPercentage should be zero in countries outside Belgium in EU */ VATPercentage: number; items: STInvoiceItem[]; /** * Sometimes we need to calculate an invoice in reverse when we have a fixed price including VAT, * but need to calculatle the price excluding VAT. */ areItemsIncludingVAT: boolean; companyName: string; companyContact: string; companyEmail: string | null; companyAddress: Address; companyVATNumber: string | null; companyNumber: string | null; ipAddress: string | null; userAgent: string | null; stripeAccountId: string | null; /** * @deprecated * Depending on areItemsIncludingVAT, this can either be including or excluding VAT */ private get itemPrice(); includingVATToExcludingVAT(price: number): number; excludingVATToIncludingVAT(price: number): number; getVATOnIncludingVATAmount(price: number): number; getVATOnExcludingVATAmount(price: number): number; get useLegacyRounding(): boolean | undefined; get priceWithoutVAT(): number; get VAT(): number; get priceWithVAT(): number; /** * How much to add or remove to priceWithVAT to get to the payable amount. We can get a rounding error of 1 cent positive or negative if we calculate from a given price inclusive VAT. * * 1 cent if we need to add 1 cent * -1 cent if we need to remove 1 cent from the priceWithVAT to get to the payable amount */ get payableRoundingAmount(): number; get totalPrice(): number; } //# sourceMappingURL=STInvoiceMeta.d.ts.map