Line Item Pricing API Mappings

In Admin, when you view an order, you can view the specific pricing details for each line item in the order, including spreaded order level pricing, such as manual order level adjustments, discounts, tax, and shipping.

Refer to Line Item Pricing Details for more information about line item pricing details.

Each field in the line item pricing details in Admin to a corresponding property in the API. Refer to the following tables for the mappings between line item level pricing details and order level pricing details, respectively.

The corresponding API resource for all mapped properties is: commerce/orders

Line Item Level Pricing Mappings

The following table maps each line item pricing field in Admin to its corresponding API property.

Admin FieldAPI Property
Base price of line itemOrder.items.UnitPrice (listAmount or saleAmount) - Order.items.product.bundledProducts.deltaPrice (The sum of the order price)
Manual adjustment on base priceOrder.items.UnitPrice.overrideAmount
ExtrasOrder.items.product.bundledProducts.deltaPrice
QuantityOrder.items.quantity
Weighted order adjustmentOrder.item.weightedOrderAdjustment
Weighted order discountOrder.item.weightedOrderDiscount. This property only stores the discount's value. Order.orderDiscounts.discount.name stores the discount's name.
Adjusted line item subtotalOrder.item.adjustedLineItemSubtotal
Line item taxOrder.item.itemTaxTotal or
Order.item.weightedOrderTax
Line item totalOrder.item.totalWithoutWeightedShippingandHandling
Weighted order shipping feeOrder.item.weightedOrderShipping
Weighted order shipping discountOrder.item.weightedOrderShippingDiscount
Line item shipping feeOrder.item.ShippingAmountBeforeDiscountAndAdjustments
Line item shipping discountOrder.item.shippingDiscounts.discount.discount (id, name, and amount)
Shipping taxOrder.item.shippingTax
Line item order handling feeOrder.item.handlingAmount
Weighted order handling feeOrder.item.weightedOrderHandlingFee
Handling taxOrder.item.weightedOrderHandlingFeeTax
Weighted order handling discountOrder.item.weightedOrderHandlingFeeDiscount
Weighted order dutyOrder.item.weightedOrderDuty
Line item total w/ shipping and handlingOrder.item.totalWithWeightedShippingandHandling

Order Level Pricing Mappings

The following table maps each order level pricing field in Admin to its corresponding API property.

Admin FieldAPI Property
Order adjustmentsSum of all manual adjustments + all order discounts. Order discounts is a calculated value of all order level discounts.
Manual adjustmentOrder.adjustment
Order discountsOrder.orderDiscounts (id, name, and amount)
Order subtotalOrder.lineItemSubtotalsWithOrderAdjustments
Order shipping feesOrder.shippingAmountBeforeDiscountsAndAdjustments
Order shipping discountsOrder.shippingDiscounts
Order handling feesOrder.handlingSubtotal
Order handling discountsOrder.handlingDiscounts
Shipping taxOrder.shippingTaxTotal
Handling taxOrder.handlingTaxTotal
Order taxOrder.itemTaxTotal
DutyOrder.dutyTotal
ShippingSum of order shipping fees + order shipping discounts + line item shipping fees + line item shipping discounts
HandlingSum of order handling fees + order handling discounts + line item handling fees + line item handling discounts
TaxSum of order tax + shipping tax + handling tax + duty
Order totalOrder.total