Hello there,
For our international orders, we’d need to add a custom tax rate (custom duties and excises) in our orders’ line items.
Is there any way to interact with orders’ tax lines programmatically? Is building a Tax App something everyone can do, or is it reserved? There doesn’t seem to be any documentation around this topic.
Thanks!
HI Alberto,
If you create an order with the orderCreate mutation, you should be able to specify the taxLines rate:
I don’t believe there is a limited API for tax apps, but I’m not super familiar with that area.
Thanks @Liam-Shopify!
But does this mean that it’s only doable for orders created programmatically? How can I add custom tax rates to my customers’ orders, created via the online store?
It should be possible for existing orders too. When you edit an existing order, you should be able to change fields on the calculatedOrder object, which has a field for taxLines.
Thanks Liam.
Editing an existing line item is not in the list of available edits, though:
The only thing that seems to be editable is the line item quantity, unless this is a non-documented type of edit.
Hi again - checking with the orders team to see if this is possible. If not, as a workaround, could you add a custom line item to apply a tax charge?
I’ve confirmed that it’s not possible to edit the taxLines of existing orders via the API.
Thanks for the confirmation Liam.
So, getting back to the original question. How can we change the tax amount of line item before the order is placed? I guess that’s what existing Tax Apps like Avalara are doing, so there might be some APIs to interact with the line items’ taxes, or is this possibility reserved to those services only?
Thanks in advance
Hi again Alberto,
The only way I can see how the taxLine would be defined/changed, would be with the orderCreate mutation. It does seem that the taxAppConfigure mutation is limited to apps with specific scopes and permissions.
Yes, this part is a bit obscure:
The caller must be a tax calculations app
Any light on what that means? I found some posts on the community forum (eg this one) but nothing official.
It does appear that this is a closed API only for Tax Partners, which is an invite-only program.
Got it. Thanks for your support, Liam!