Purchase Invoice Taxes not working via API

I am trying to add purchase invoice from my C# app via Rest API. Everything else work flawlessly except taxes. My requirement is rather simple, My C# app does all the tax calculation, I just want erpnext to simply use my provided tax figures, don’t try to calculate it.

If i add taxes as “Actual” it distributes all taxes among all line items. Even though tax will not be applied on some items.

Is there any neat way to force erpnext to use my tax figures.