question

eatcube avatar image
eatcube asked chanel Deactivated edited

Tax not appearing in receipt order created by API

details.png receipt.png

Hi-
We are creating Orders via API V3 in postman. I see Tax has been collected in details section but it is not appearing in customer receipt. I passed tax rate ID also to API.

When I researched, I saw we have to use objects associations for tax its
/v3/merchants/[Merchant ID]/tax_rate_items: tax rate to an item But I do not have an idea on how to use the same..

I dont mind using default tax rate of clover system either..Pls let me know what do i do.

Steps I am following
-1) Creating Open Order
{ {url}}/v3/merchants/{ {mId}}/orders with

{ "state": "open"}

2) { {url}}/v3/merchants/{ {mId}}/orders/{ {orderId}}/line_items
Add Line item
{ "name": "Veg Omlette", "price": 800}

3) Add Discount

4) { {url}}/v3/merchants/{ {mId}}/tenders?filter=label=External%20Payment
Get Payment Tender ID

5){ {url}}/v3/merchants/{ {mId}}/orders/{ {orderId}}/payments
Create Payment via Card .. here is where I was passing tax rate
"taxRates": [ { "taxableAmount": 450, "rate": 2300000, "id": "V9MMY9311RAG2" }

Am I doing something wrong?
REST APITaxes
details.png (83.3 KiB)
receipt.png (16.5 KiB)
10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

chanel avatar image
chanel Deactivated answered chanel Deactivated edited
Hi @eatcube . The tax rate should be added to the item itself when adding it to the order. So, in step 2, you'll want (for a $10 item at 8.875% tax rate)

{
  "name": "Custom Item",
  "price": 1000,
  "taxRates": {
    "elements": [
      {
            "id": {
                {taxRateID}},
            "name": "Tax Rate",
            "rate": 887500
      }
     ]
  }
}
10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Welcome to the
Clover Developer Community