Magento – REST API Order including a configurable product

apimagento2rest

When I get a order which includes a configurable product there seems to always be two order items for it. The first being the configurable product with price set to zero and the second being the simple product that the customer has selected with the correct price. The second one references the first one with the field parentItemId.

My question then is: when I export the order items to our internal order system, is it safe to always just ignore items which are of product type configurable and export the one of product type simple as I would with a regular simple product? Or is there anything else I need to keep in mind?

Best Answer

This is correct, the simple product is basically the product you want. However, price and quantity are stored in the configurable product.

So take the SKU of the simple product but qty and price of the configurable product and you should be fine.

Related Topic