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

Properties

amount: number

Tax rate. If subrates are used, the amount is the sum of all rates in subRates.

country: string

Country in which the tax rate is applied in ISO 3166-1 alpha-2 format.

id?: string

Present if the TaxRate is part of a TaxCategory. Absent for external TaxRates in LineItem, CustomLineItem, and ShippingInfo.

includedInPrice: boolean

If true, tax is included in Embedded Prices or Standalone Prices, and the taxedPrice is present on LineItems. In this case, the totalNet price on TaxedPrice includes the TaxRate.

key?: string

User-defined unique identifier of the TaxRate. Present when set using TaxRateDraft. Not available for external TaxRates created using ExternalTaxRateDraft.

name: string

Name of the TaxRate.

state?: string

State within the country, such as Texas in the United States.

subRates?: SubRate[]

Used when the total tax is a combination of multiple taxes (for example, local, state/provincial, and/or federal taxes). The total of all subrates must equal the TaxRate amount. These subrates are used to calculate the taxPortions field of a Cart or Order and the taxedPrice field of LineItems, CustomLineItems, and ShippingInfos.