I am working on some code that makes a call to some azure functions that sync product data to our CRM / Inventory system. One thing that magento does when an admin user makes a change to a configurable product and saves it is that it fires the save event for the configurable product, as well as all of the child products.
We have configurable products AND simple single products in our store. I want to avoid making 5 or more calls per product by consolidating the json.
Long story short, is there any built-in way to get if a product is part of a configurable product, and also, is there a way to get if a product is NOT part of a configurable.
My goal is to load all the children of the configurable, combine the json, and make one call to Azure. At the same time I still want those single simple products that aren't configurable to still be able to send.
For instance, I can't filter on
$product->getTypeId() !="configurable" or something like that.
FYI I'm using PhpStorm + xdebug to get the job done.
The data I was looking for is found here in this link. Its not the same question though.