Hey Sean,
The problem is that you are passing in a product_id for the order line_items instead of a variant_id. Since inventory is tied to variants, you need to specify the variant_id in order for the inventory behaviour to execute properly.
Issue: Inventory was not decreasing when creating orders via the REST API using the inventory_behaviour parameter.
Key findings and fixes:
Expected behavior:
Support/debugging:
Current status:
Notes: The shared JSON payloads are central to understanding the issue and resolution.
Hey Sean,
The problem is that you are passing in a product_id for the order line_items instead of a variant_id. Since inventory is tied to variants, you need to specify the variant_id in order for the inventory behaviour to execute properly.