Integration points for tax computation in Sterling Order Management System Software

Sterling™ Order Management System Software already uses some user exits to facilitate tax computation. Sterling Order Management System Software expects both user exits to return both tax amount and tax percentage used for calculation.

The following user exits are used by Sterling Order Management System Software to facilitate tax computation:
  • YFSRecalculateHeaderTaxUE - This user exit is used to recalculate the tax for an order at the header level. This user exit is called at Change Price order modification, when the shipping address changes, when invoicing, and during calculation of release costs.
    The changeOrder API calls the YFSRecalculateHeaderTaxUE user exit when one of the following conditions is met:
    • If the HeaderTax element is not passed and pricing is affected.
    • If the TAX_EXEMPT_FLAG flag value changes on the order header and the HeaderTax element is not passed.
    • The YFSOrderRepricingUE user exit is invoked and returns HeaderCharges, but not HeaderTaxes.
    • The ship to address changes.
    Implementations have to enable the YFSRecalculateHeaderTaxUE user exit and implement the recalculateHeaderTax method to compute tax. For more information about com.yantra.yfs.japi.ue.YFSRecalculateHeaderTaxUE interface, see the Javadoc.
  • YFSRecalculateLineTaxUE - This user exit is used to recalculate tax for an order at the line level. This user exit is called on Change Price order modification when the shipping address changes, when invoicing, and during calculation of release costs. It is also invoked when the settled quantity of an order line changes in the order to compute SettledAmount. These taxes are not stored separately, and are only rolled up into SettledAmount.
    The changeOrder API calls the YFSRecalculateLineTaxUE user exit when one of the following conditions is met:
    • If the LineTax element is not passed or it has not changed since last called to API.
    • If the TAX_EXEMPT_FLAG flag value changes on the order header and the LineTax element is not passed.
    • The YFSOrderRepricingUE user exit is invoked and does not return LineTaxes.
    • The ship to address changes.
  • Implementations have to enable the YFSRecalculateLineTaxUE user exit and implement the recalculateLineTax method to compute tax. For more information about com.yantra.yfs.japi.ue.YFSRecalculateLineTaxUE interface, see the Javadoc.

    If YFSRecalculateLineTaxUE is not implementing, ChargeCategory, Tax, and TaxPercentage are required for the default repricing logic.

A user exit implementation makes a call to the tax provider system with the product details of the items in the cart or order along with the shipping method (freight charge) details. The tax provider system calculates the tax based on the shipping method and the ship from address. Usually, the order capturing application defaults these values. When a shopper chooses a different shipping method and/or modifies the Ship From address, Sterling Order Management System Software recalculates the tax accordingly.

It is not quite often that the tax on a particular item changes between the time that the shopper placed the order and the time that the order is shipped. If there is a change in the taxation rate either through a state or provincial tax rate change, or tax holiday, it is often charged as the tax rate on the day of shipping. There are other possible scenarios such as changes in quantity of goods or the ship to address. Each implementation can decide whether to consider tax changes for all these scenarios or consider a few scenarios such as the changes in ship from address and tax rates. In case of tax rates, all the other attributes are assumed to be unchanged during the order fulfillment cycle.