Tax
You configure tax per business, and tmbilling computes it per invoice line.
Place of supply
The place of supply decides where a sale is taxed: your customer's country, and their state or province where the regime is sub-national, read against where you are registered.
That is why a customer's address is a tax input rather than a shipping detail.
Configure a tax region
A region is a country you have made taxable:
/v1/businesses/{biz}/tax_regions/v1/businesses/{biz}/tax_regionsEach region holds its regime, whether your prices are inclusive or exclusive, your registration, and the gates that switch tax off entirely — reverse charge, export and special economic zones.
Set the component vector
A region's tax is a vector of components, not a single percentage. A domestic Indian sale carries CGST and SGST as separate components, while an inter-state sale carries IGST instead. Both print separately, because that is what the document has to show.
/v1/businesses/{biz}/tax_regions/{txg}/componentsSets the component vector for one state scope.
/v1/businesses/{biz}/tax_regions/{txg}/state_registrationsRecords your registration in one state — in India, that state's GSTIN — for your own records.
The domestic and inter-state split comes from the region's home state compared with the buyer's
billing state. The GSTIN printed on an invoice is the business's tax_registration_number (or the
organization's, when the organization issues invoices). See
India GST invoices.
Create a tax profile
/v1/businesses/{biz}/tax_profilesA profile holds the rates for one class of product, which is how a digital service and a physical
good get taxed differently in the same region. Give each product a tax_code to select its
profile.
Select inclusive or exclusive pricing
Set tax_behavior on each price:
| Behaviour | amount_minor means | Your customer pays |
|---|---|---|
exclusive | the net amount | More than the list price — tmbilling calculates tax and adds it. |
inclusive | the total amount | Exactly the list price — tmbilling extracts the tax from it, and the net is what remains. |
Handle withholding
Some jurisdictions require your buyer to withhold tax and remit it directly.
Set withholding_rate_bps on the customer. It reduces what they pay you without reducing what
they owe: the invoice records the full amount and the withheld portion separately, so the
difference is explained rather than looking like a short payment.
Apply exemptions
Set tax_exempt on a customer to switch tax off for them.
vat_number drives reverse charge where the regime provides for it: tmbilling zero-rates the sale
and the obligation moves to your buyer. Validate the number rather than trusting it:
/v1/businesses/{biz}/customers/{cus}/validate_vatExpect each invoice to snapshot its tax context
When tmbilling issues an invoice, it snapshots your registration, the place of supply and the rates that applied.
So changing a customer's address, or a region's rates, does not re-tax a document that already exists. New invoices use your new configuration.
Related
Credits
Work with three separate customer balances, learn the order they are spent in, and see why every balance comes from an append-only, double-entry ledger.
Entitlements
Turn what a customer bought into what your application lets them do, with features, plan grants and per-subscription overrides that one API call can check.