Hello,
I'm making the following AJAX request and I get a JSON object of all available products along with all the relevant details for every variant of every product :
jQuery.ajax({
url: "//xxxxxxx.myshopify.com/products.json?limit=250",
success: function(response)
{
window.products = response.products;
}
});
However, there is one very essential bit of information missing for every variant of every product and that is the available quantity.
I get a variant.is_available which I guess tells me whether the variant quantity is at least 1.
But, I need to know the exact available quantity for this variant.
What if the customer selects (from the quantity dropdown I've built..) a quantity equal to 5 but the actual available quantity is 3 ??
Thank you in advance for your help!