- Get Started
- Product
- Resources
- Tools & SDKs
- Framework
- Reference
Menu
- Get Started
- Product
- Resources
- Tools & SDKs
- Framework
- Reference
createTaxRates - Tax Module Reference
This documentation provides a reference to the createTaxRates
method. This belongs to the Tax Module.
Note: You should only use this methods when implementing complex customizations. For common cases, check out available workflows instead.
createTaxRates(data, sharedContext?): Promise<TaxRateDTO[]>#
This method creates tax rates.
Example#
1const taxRates = await taxModuleService.createTaxRates([2 {3 tax_region_id: "txreg_123",4 name: "Default rate",5 rate: 10,6 },7 {8 tax_region_id: "txreg_123",9 name: "Custom rate",10 rate: 15,11 rules: [12 {13 reference: "product_type",14 reference_id: "ptyp_1",15 },16 {17 reference: "product",18 reference_id: "prod_123",19 },20 ],21 },22])
Parameters#
data
CreateTaxRateDTO[]The tax rates to be created.
data
CreateTaxRateDTO[]Returns#
Promise
Promise<TaxRateDTO[]>The created tax rates.
Promise
Promise<TaxRateDTO[]>createTaxRates(data, sharedContext?): Promise<TaxRateDTO>#
This method creates a tax rate.
Example#
Parameters#
data
CreateTaxRateDTOThe tax rate to be created.
data
CreateTaxRateDTOReturns#
Promise
Promise<TaxRateDTO>The created tax rate.
Promise
Promise<TaxRateDTO>Was this page helpful?