web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Small and medium business | Business Central, N...
Suggested Answer

Invoice / Purchase Order APIs TAX issue when mixed with NOTAX and TAX line items

(1) ShareShare
ReportReport
Posted on by 2

This happens for some of the environment

### Purchase Order Header Endpoint
PAYLOAD: {"orderDate":"2026-08-18","number":"03893","vendorId":"2a1117b5-3122-eb11-bf6a-000d3a6a363f","vendorNumber":"WOOL","pricesIncludeTax":true}
RESPONSE: {"@odata.context":"https://api.businesscentral.dynamics.com/v2.0/GUID/ENV/api/v2.0/$metadata#companies(company)/purchaseOrders/$entity","@odata.etag":"W/JzIwOzE3NTg1OTEyNDY4MjIyNzAwODk0MTswMDsn","id":"9a530799-619b-f111-8072-70a8a55698e4","number":"03893","orderDate":"2026-08-18","postingDate":"2026-08-19","vendorId":"2a1117b5-3122-eb11-bf6a-000d3a6a363f","vendorNumber":"WOOL","vendorName":"Woolworths ","payToName":"Woolworths ","payToVendorId":"2a1117b5-3122-eb11-bf6a-000d3a6a363f","payToVendorNumber":"WOOL","shipToName":"","shipToContact":"","buyFromAddressLine1":"Sydney Street","buyFromAddressLine2":"","buyFromCity":"SYDNEY","buyFromCountry":"AU","buyFromState":"NSW","buyFromPostCode":"2000","payToAddressLine1":"Cnr Sydney & NSW Street","payToAddressLine2":"","payToCity":"SYDNEY","payToCountry":"AU","payToState":"NSW","payToPostCode":"2000","shipToAddressLine1":"Sydney Street","shipToAddressLine2":"","shipToCity":"SYDNEY","shipToCountry":"AU","shipToState":"NSW","shipToPostCode":"2000","shortcutDimension1Code":"C261","shortcutDimension2Code":"","currencyId":"00000000-0000-0000-0000-000000000000","currencyCode":"AUD","pricesIncludeTax":true,"paymentTermsId":"1942ba86-dee0-ea11-aa60-000d3acaf30d","shipmentMethodId":"00000000-0000-0000-0000-000000000000","purchaser":"","requestedReceiptDate":"0001-01-01","discountAmount":0,"discountAppliedBeforeTax":false,"totalAmountExcludingTax":0,"totalTaxAmount":0,"totalAmountIncludingTax":0,"fullyReceived":false,"status":"Draft","lastModifiedDateTime":"2026-08-19T00:04:51.707Z"}
##########################################################################################

### Purchase Order Line Endpoint - Line 1
PAYLOAD: {"description":"c","directUnitCost":30,"taxCode":"GSTFREE","quantity":1,"accountId":"48f5b98c-dee0-ea11-aa60-000d3acaf30d"}
RESPONSE: {"@odata.context":"https://api.businesscentral.dynamics.com/v2.0/GUID/ENV/api/v2.0/$metadata#companies(company_GUID)/purchaseOrders(9a530799-619b-f111-8072-70a8a55698e4)/purchaseOrderLines/$entity","@odata.etag":"W/JzIwOzE4MjkyMTM1OTA4ODI0MDUzMTY5MTswMDsn","id":"9c530799-619b-f111-8072-70a8a55698e4","documentId":"9a530799-619b-f111-8072-70a8a55698e4","sequence":10000,"itemId":"00000000-0000-0000-0000-000000000000","accountId":"48f5b98c-dee0-ea11-aa60-000d3acaf30d","lineType":"Account","lineObjectNumber":"4501","description":"c","description2":"","unitOfMeasureId":"00000000-0000-0000-0000-000000000000","unitOfMeasureCode":"","quantity":1,"directUnitCost":27.27273,"discountAmount":0,"discountPercent":0,"discountAppliedBeforeTax":false,"amountExcludingTax":27.27,"taxCode":"GSTFREE","taxPercent":0,"totalTaxAmount":0,"amountIncludingTax":27.27,"invoiceDiscountAllocation":0,"netAmount":27.27,"netTaxAmount":0,"netAmountIncludingTax":27.27,"expectedReceiptDate":"2026-08-19","receivedQuantity":0,"invoicedQuantity":0,"invoiceQuantity":1,"receiveQuantity":1,"itemVariantId":"00000000-0000-0000-0000-000000000000","locationId":"00000000-0000-0000-0000-000000000000"}
##########################################################################################

### Purchase Order Line Endpoint - Line 2
PAYLOAD: {"description":"d","directUnitCost":44,"taxCode":"GST10","quantity":1,"accountId":"48f5b98c-dee0-ea11-aa60-000d3acaf30d"}
RESPONSE: {"@odata.context":"https://api.businesscentral.dynamics.com/v2.0/GUID/ENV/api/v2.0/$metadata#companies(company_GUID)/purchaseOrders(9a530799-619b-f111-8072-70a8a55698e4)/purchaseOrderLines/$entity","@odata.etag":"W/JzE5OzE4ODY0Njk3OTY4OTI3NTUxOTIxOzAwOyc=","id":"9d530799-619b-f111-8072-70a8a55698e4","documentId":"9a530799-619b-f111-8072-70a8a55698e4","sequence":20000,"itemId":"00000000-0000-0000-0000-000000000000","accountId":"48f5b98c-dee0-ea11-aa60-000d3acaf30d","lineType":"Account","lineObjectNumber":"4501","description":"d","description2":"","unitOfMeasureId":"00000000-0000-0000-0000-000000000000","unitOfMeasureCode":"","quantity":1,"directUnitCost":44,"discountAmount":0,"discountPercent":0,"discountAppliedBeforeTax":false,"amountExcludingTax":40.00,"taxCode":"GST10","taxPercent":10,"totalTaxAmount":4.00,"amountIncludingTax":44,"invoiceDiscountAllocation":0,"netAmount":40,"netTaxAmount":4,"netAmountIncludingTax":44,"expectedReceiptDate":"2026-08-19","receivedQuantity":0,"invoicedQuantity":0,"invoiceQuantity":1,"receiveQuantity":1,"itemVariantId":"00000000-0000-0000-0000-000000000000","locationId":"00000000-0000-0000-0000-000000000000"}
##########################################################################################

### In our software
Line 1: c / $30 (excl GST) / $0 GST / GST Free
Line 2: d / $40 (excl GST) / $4 GST / GST 10%
Total $74.00 (incl GST), $4 GST
##########################################################################################

### In Dynamics DBC
Line 1: c / $27.27 (incl GST) / $0 GST / GST Free
Line 2: d / $44 (incl GST) / $4 GST / GST 10%
Total $71.27 (incl GST), $4 GST
##########################################################################################

### Summary ###
a. Not Matching between our software and Dynamics
b. "pricesIncludeTax":true during sync for purchase order Header
c. "directUnitCost" within line items for purchase order line item sync includes tax
d. TAX code supplied at the end purchase order line item
e. Issue Observed for line item 1 Sync: Response from Dynamics end point indicates - "amountIncludingTax":27.27, but payload amount from our software is "directUnitCost":30. Dynamics respected the TaxCode our software Sent "taxCode":"GSTFREE", but there's an override process after our software Synced the TAXFREE line and considering 10% tax disregard of our software indicating this is a TAX FREE line.
f. Not Issue Observed for line item 2 Sync

I have the same question (0)
  • Suggested answer
    YUN ZHU Profile Picture
    102,972 Super User 2026 Season 2 on at

    You could try setting "Prices Including VAT" to "false" at the Purchase Header level first.

     

    Thanks.

    ZHU

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Women in Power Builds Momentum

Expanding mentorship, skilling, and AI innovation

Congratulations to the July Top 10 Community Leaders

These are the community rock stars!

Leaderboard > Small and medium business | Business Central, NAV, RMS

#1
OussamaSabbouh Profile Picture

OussamaSabbouh 621 Super User 2026 Season 2

#2
YUN ZHU Profile Picture

YUN ZHU 380 Super User 2026 Season 2

#3
Grigorios Mavrogeorgis Profile Picture

Grigorios Mavrogeorgis 341 Super User 2026 Season 2

Last 30 days Overall leaderboard

Featured topics

Microsoft Training Manuals

Product updates

Dynamics 365 release plans