UNPKG

node-zugferd

Version:

A Node.js library for creating ZUGFeRD/Factur-X compliant documents. Generating XML and embedding it into PDF/A files, enabling seamless e-invoicing and digital document compliance.

356 lines (354 loc) 11 kB
// src/codelists/index.ts var getByPath = (obj, path) => path.split(".").reduce((acc, key) => acc?.[key], obj); var createEnum = (data, options) => { return Object.fromEntries( data.map((item) => [ getByPath(item, options.keyProp), getByPath(item, options.valueProp) ]) ); }; // src/codelists/vat-cat.gen.ts var VAT_CAT = [ { key: "PETROLEUM_TAX", name: "Petroleum tax", value: "AAA", description: "A tax levied on the volume of petroleum being transacted." }, { key: "PROVISIONAL_COUNTERVAILING_DUTY_CASH", name: "Provisional countervailing duty cash", value: "AAB", description: "Countervailing duty paid in cash prior to a formal finding of subsidization by Customs." }, { key: "PROVISIONAL_COUNTERVAILING_DUTY_BOND", name: "Provisional countervailing duty bond", value: "AAC", description: "Countervailing duty paid by posting a bond during an investigation period prior to a formal decision on subsidization by Customs." }, { key: "TOBACCO_TAX", name: "Tobacco tax", value: "AAD", description: "A tax levied on tobacco products." }, { key: "ENERGY_FEE", name: "Energy fee", value: "AAE", description: "General fee or tax for the use of energy." }, { key: "COFFEE_TAX", name: "Coffee tax", value: "AAF", description: "A tax levied specifically on coffee products." }, { key: "HARMONISED_SALES_TAX_CANADIAN", name: "Harmonised sales tax, Canadian", value: "AAG", description: "A harmonized sales tax consisting of a goods and service tax, a Canadian provincial sales tax and, as applicable, a Quebec sales tax which is recoverable." }, { key: "QUEBEC_SALES_TAX", name: "Quebec sales tax", value: "AAH", description: "A sales tax charged within the Canadian province of Quebec which is recoverable." }, { key: "CANADIAN_PROVINCIAL_SALES_TAX", name: "Canadian provincial sales tax", value: "AAI", description: "A sales tax charged within Canadian provinces which is non-recoverable." }, { key: "TAX_ON_REPLACEMENT_PART", name: "Tax on replacement part", value: "AAJ", description: "A tax levied on a replacement part, where the original part is returned." }, { key: "MINERAL_OIL_TAX", name: "Mineral oil tax", value: "AAK", description: "Tax that is levied specifically on products containing mineral oil." }, { key: "SPECIAL_TAX", name: "Special tax", value: "AAL", description: "To indicate a special type of tax." }, { key: "INSURANCE_TAX", name: "Insurance tax", value: "AAM", description: "A tax levied specifically on insurances." }, { key: "PROVINCIAL_CANNABIS_TAX", name: "Provincial Cannabis Tax", value: "AAO", description: "A tax levied on Cannabis products" }, { key: "OUTSTANDING_DUTY_INTEREST", name: "Outstanding duty interest", value: "AAP", description: "Fee levied due to outstanding duties to be paid" }, { key: "ANTI_DUMPING_DUTY", name: "Anti-dumping duty", value: "ADD", description: "Duty applied to goods ruled to have been dumped in an import market at a price lower than that in the exporter's domestic market." }, { key: "STAMP_DUTY_IMPOSTA_DI_BOLLO", name: "Stamp duty (Imposta di Bollo)", value: "BOL", description: "Tax required in Italy, which may be fixed or graduated in various circumstances (e.g. VAT exempt documents or bank receipts)." }, { key: "AGRICULTURAL_LEVY", name: "Agricultural levy", value: "CAP", description: "Levy imposed on agricultural products where there is a difference between the selling price between trading countries." }, { key: "CAR_TAX", name: "Car tax", value: "CAR", description: "A tax that is levied on the value of the automobile." }, { key: "PAPER_CONSORTIUM_TAX_ITALY", name: "Paper consortium tax (Italy)", value: "COC", description: "Italian Paper consortium tax." }, { key: "COMMODITY_SPECIFIC_TAX", name: "Commodity specific tax", value: "CST", description: "Tax related to a specified commodity, e.g. illuminants, salts." }, { key: "CUSTOMS_DUTY", name: "Customs duty", value: "CUD", description: "Duties laid down in the Customs tariff, to which goods are liable on entering or leaving the Customs territory (CCC)." }, { key: "COUNTERVAILING_DUTY", name: "Countervailing duty", value: "CVD", description: "A duty on imported goods applied for compensate for subsidies granted to those goods in the exporting country." }, { key: "ENVIRONMENTAL_TAX", name: "Environmental tax", value: "ENV", description: "Tax assessed for funding or assuring environmental protection or clean-up." }, { key: "EXCISE_DUTY", name: "Excise duty", value: "EXC", description: "Customs or fiscal authorities code to identify a specific or ad valorem levy on a specific commodity, applied either domestically or at time of importation." }, { key: "AGRICULTURAL_EXPORT_REBATE", name: "Agricultural export rebate", value: "EXP", description: "Monetary rebate given to the seller in certain circumstances when agricultural products are exported." }, { key: "FEDERAL_EXCISE_TAX", name: "Federal excise tax", value: "FET", description: "Tax levied by the federal government on the manufacture of specific items." }, { key: "FREE", name: "Free", value: "FRE", description: "No tax levied." }, { key: "GENERAL_CONSTRUCTION_TAX", name: "General construction tax", value: "GCN", description: "General tax for construction." }, { key: "GOODS_AND_SERVICES_TAX", name: "Goods and services tax", value: "GST", description: "Tax levied on the final consumption of goods and services throughout the production and distribution chain." }, { key: "ILLUMINANTS_TAX", name: "Illuminants tax", value: "ILL", description: "Tax of illuminants." }, { key: "IMPORT_TAX", name: "Import tax", value: "IMP", description: "Tax assessed on imports." }, { key: "INDIVIDUAL_TAX", name: "Individual tax", value: "IND", description: "A tax levied based on an individual's ability to pay." }, { key: "BUSINESS_LICENSE_FEE", name: "Business license fee", value: "LAC", description: "Government assessed charge for permit to do business." }, { key: "LOCAL_CONSTRUCTION_TAX", name: "Local construction tax", value: "LCN", description: "Local tax for construction." }, { key: "LIGHT_DUES_PAYABLE", name: "Light dues payable", value: "LDP", description: "Fee levied on a vessel to pay for port navigation lights." }, { key: "LOCAL_SALES_TAX", name: "Local sales tax", value: "LOC", description: "Assessment charges on sale of goods or services by city, borough country or other taxing authorities below state or provincial level." }, { key: "LUST_TAX", name: "Lust tax", value: "LST", description: "Tax imposed for clean-up of leaky underground storage tanks." }, { key: "MONETARY_COMPENSATORY_AMOUNT", name: "Monetary compensatory amount", value: "MCA", description: "Levy on Common Agricultural Policy (European Union) goods used to compensate for fluctuating currencies between member states." }, { key: "MISCELLANEOUS_CASH_DEPOSIT", name: "Miscellaneous cash deposit", value: "MCD", description: "Duty paid and held on deposit, by Customs, during an investigation period prior to a final decision being made on any aspect related to imported goods (except valuation) by Customs." }, { key: "OTHER_TAXES", name: "Other taxes", value: "OTH", description: "Unspecified, miscellaneous tax charges." }, { key: "PROVISIONAL_DUTY_BOND", name: "Provisional duty bond", value: "PDB", description: "Anti-dumping duty paid by posting a bond during an investigation period prior to a formal decision on dumping by Customs." }, { key: "PROVISIONAL_DUTY_CASH", name: "Provisional duty cash", value: "PDC", description: "Anti-dumping duty paid in cash prior to a formal finding of dumping by Customs." }, { key: "PREFERENCE_DUTY", name: "Preference duty", value: "PRF", description: "Duties laid down in the Customs tariff, to which goods are liable on entering or leaving the Customs territory falling under a preferential regime such as Generalised System of Preferences (GSP)." }, { key: "SPECIAL_CONSTRUCTION_TAX", name: "Special construction tax", value: "SCN", description: "Special tax for construction." }, { key: "SHIFTED_SOCIAL_SECURITIES", name: "Shifted social securities", value: "SSS", description: "Social securities share of the invoice amount to be paid directly to the social securities collector." }, { key: "STATEPROVINCIAL_SALES_TAX", name: "State/provincial sales tax", value: "STT", description: "All applicable sale taxes by authorities at the state or provincial level, below national level." }, { key: "SUSPENDED_DUTY", name: "Suspended duty", value: "SUP", description: "Duty suspended or deferred from payment." }, { key: "SURTAX", name: "Surtax", value: "SUR", description: "A tax or duty applied on and in addition to existing duties and taxes." }, { key: "SHIFTED_WAGE_TAX", name: "Shifted wage tax", value: "SWT", description: "Wage tax share of the invoice amount to be paid directly to the tax collector(s office)." }, { key: "ALCOHOL_MARK_TAX", name: "Alcohol mark tax", value: "TAC", description: "A tax levied based on the type of alcohol being obtained." }, { key: "TOTAL", name: "Total", value: "TOT", description: "The summary amount of all taxes." }, { key: "TURNOVER_TAX", name: "Turnover tax", value: "TOX", description: "Tax levied on the total sales/turnover of a corporation." }, { key: "TONNAGE_TAXES", name: "Tonnage taxes", value: "TTA", description: "Tax levied based on the vessel's net tonnage." }, { key: "VALUATION_DEPOSIT", name: "Valuation deposit", value: "VAD", description: "Duty paid and held on deposit, by Customs, during an investigation period prior to a formal decision on valuation of the goods being made." }, { key: "VALUE_ADDED_TAX", name: "Value added tax", value: "VAT", description: "A tax on domestic or imported goods applied to the value added at each stage in the production/distribution cycle." } ]; var vatCatCode = VAT_CAT.map(({ value }) => value); var VatCat = createEnum(VAT_CAT, { keyProp: "key", valueProp: "value" }); export { VAT_CAT, VatCat, vatCatCode };