Controls calculation of taxed prices for Line Items, Custom Line Items, and Shipping Methods as explained in Cart tax calculation.

interface ExternalTaxRateDraft {
    amount?: number;
    country: string;
    includedInPrice?: boolean;
    name: string;
    state?: string;
    subRates?: SubRate[];
}

Properties

amount?: number

Percentage in the range of 0-1.

- If no `subRates` are specified, a value must be defined.
- If `subRates` are specified, this can be omitted or its value must be the sum of all `subRates` amounts.
country: string

Country for which the tax applies.

includedInPrice?: boolean
  • If set to false, the related price is considered the net price and the provided amount is applied to calculate the gross price.
    • If set to true, the related price is considered the gross price, and the provided amount is applied to calculate the net price.
name: string

Name of the Tax Rate.

state?: string

State within the specified country.

subRates?: SubRate[]

For countries (such as the US) where the total tax is a combination of multiple taxes (such as state and local taxes).

Generated using TypeDoc