Product Cost from API - Verify

New Member
11 0 0

Hi Shopify Team,


Could you please confirm if the API calls made below are correct for getting the Product Cost. While comparing the product cost extracted from the calls below to the "Cost" field in the Shopify UI, they are not aligning.


Please the urls of the calls made for getting cost currently


Call 1 - "/admin/api/2019-04/orders.json "   -  We get the product id and variant id from this call at line item level


Call 2 - "/admin/api/2019-04/products.json" –  We make this call using the productid. Then once we receive json object, we extract inventory id using variant id.


Call3 - " /admin/api/2019-04/inventory_items/{inventory_item_id}.json"  We make this call using the inventory item id, and extract cost.


Is there something wrong with this approach ?


Shopify Partner
926 96 149

Hey there,


Why wouldn't you just get the cost you have at the line item level (you also have discounts and tax information)? Would you shed some light on what you are trying to achieve.

Sergiu Svinarciuc | CTO @
- Was my reply helpful? Click Like to let me know!
- Was your question answered? Mark it as an Accepted Solution!
- To learn more about the awesome stuff we do head over to or our blog


New Member
1 1 0



I am not able to see any "cost" present with lineItem's object. But, there is "price" present with lineItem. So, is this "price" same as the "cost" which we get from