---
title: "Discussion on \"Multi-Region Tax Logic in TypeScript — GST (India), HST by Province (Canada), VAT (UK), and EU Reverse Charge in One Invoice Engine\" | Hashnode"
description: "Discussion on \"Multi-Region Tax Logic in TypeScript — GST (India), HST by Province (Canada), VAT (UK), and EU Reverse Charge in One Invoice Engine\". The Problem\nBuilding an invoice generator that works correctly for multiple regions means handling tax rules that differ not just by country, but by sub-region (Canadian provinces), transaction type (India domestic vs interstate), and B2B context (EU..."
url: "https://hashnode.com/posts/multi-region-tax-logic-in-typescript-gst-india-hst-by-province-canada-vat-uk-and-eu-reverse-charge-in-one-invoice-engine/6a02b2d6760bde2ee4567a49"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [Multi-Region Tax Logic in TypeScript — GST (India), HST by Province (Canada), VAT (UK), and EU Reverse Charge in One Invoice Engine](https://ultimatetools.hashnode.dev/multi-region-tax-logic-in-typescript-gst-india-hst-by-province-canada-vat-uk-and-eu-reverse-charge-in-one-invoice-engine?utm_source=hashnode&utm_medium=feed)

The Problem Building an invoice generator that works correctly for multiple regions means handling tax rules that differ not just by country, but by sub-region (Canadian provinces), transaction type (India domestic vs interstate), and B2B context (EU...

May 12 · 6 min read · ultimatetools.hashnode.dev  
Read the article

-   [#javascript](https://hashnode.com/tag/javascript)
-   [#reactjs](https://hashnode.com/tag/reactjs)
-   [#tutorial](https://hashnode.com/tag/tutorial)
-   [#webdev](https://hashnode.com/tag/webdev)

## Written by

[Shaishav Patel](https://hashnode.com/@shaishavap)

@shaishavap · Mumbai, India

  
[View profile](https://hashnode.com/@shaishavap)

## Responses 1

Markdown supported · ⌘↵ to post

[TrueNorth API](https://hashnode.com/@m1s4gh)

[Oct 6](https://hashnode.com/posts/multi-region-tax-logic-in-typescript-gst-india-hst-by-province-canada-vat-uk-and-eu-reverse-charge-in-one-invoice-engine/6a02b2d6760bde2ee4567a49/comment/6ac540ed5449017c582ecfe3)

Good breakdown. For the Canada leg there is one gotcha worth calling out: the tax follows the buyer's province, not the seller's, so your province lookup is only as good as the address you resolve it from. A second one is product categories. Manitoba charges 5 percent GST only on groceries but 5 percent GST plus 7 percent RST on general merchandise, so the same buyer in the same province gets two different totals depending on what is on the invoice. And Quebec's 9.975 percent QST is calculated on the price before GST is applied, not on the GST inclusive amount. If you want to offload the Canada portion instead of maintaining that table yourself, TrueNorth API has a calculate tax endpoint covering all 13 provinces and territories with 41 product tax categories, plus an address validation endpoint for the buyer location part.
