How does the integration work?

A TaxCloud order total module can be enabled to replace the standard Tax order total module. This can be achieved using the Admin App under Modules >> Order Totals. Before saving the change, the module must be configured correctly as can be seen from the diagram below.

Configure TaxCloud Module

Configure TaxCloud Module

The TaxCloud Login Id and Key can be retrieved after registering with TaxCloud. The address information is the origin shipping address. Finally, the USPS user id (obtained from USPS) is used to do address verification lookups. If you already verify all customer addresses before saving them, you can edit the TaxCloud module to remove the address verification code so that this id is not required.

Whenever, the TaxCloud module is called by the KonaKart engine, it sends order information to the TaxCloud web service which returns the amount of tax due for each cart item in the order. To be able to calculate the correct tax and to determine whether there are exemptions, the TaxCloud service must know the tax classification for the products in the cart. It figures this out by reading the TIC (Taxability Information Code) applicable for each product. All product categories may have a TIC associated with them. i.e. The TIC for school supplies is "20070" and the TIC for computers is "30100" etc. Within KonaKart you must supply the correct TIC to each defined Tax Class object as shown below. Since every KonaKart product must have a Tax Class, it will automatically pick up the TIC from the Tax Class.

Configure Tax Class

Configure Tax Class

Reconciliation

In order for TaxCloud to prepare accurate monthly reports, KonaKart must confirm the actual amount of sales tax that was collected from the customer. This reconciliation event is done in the OrderIntegrationMgr whenever we detect that the order has been paid for.

By default, the method manageTax() in the OrderIntegrationMgr is commented out. If you decide to use TaxCloud, you must un-comment this method and re-compile the OrderIntegrationMgr as explained in another section of this guide (Building Customizable Source).

Points to Note

The TaxCloud order total module will throw an exception and not return an order total if a problem has occurred. It is advisable to modify the storefront application to detect that the Tax order total is missing and to take action. i.e. This could mean aborting the order or calling the standard Tax order total that calculates tax based on data present in the database.

The TaxCloud APIs use the SSL protocol and require you to have installed a valid SSL certificate. The test certificate present in the download kit is not accepted and an "unable to find valid certification path to requested target" exception is thrown by TaxCloud. For testing, the way to circumvent this problem is to add the TaxCloud server certificate to your trusted Java key store. There are programs freely available to help you to do this. A Google search for "InstallCert" will find many results.