I think I already know the answer here, but is there a way to query individual warehouse availability for products on the frontend without using Admin API or expose API keys/secrets?
We have a client that is wanting to add a QTY selector to PDPs, but the problem is that they can’t ship across country lines (US/CA), but have inventory for single products in both locations (two warehouses). If we query something like variant.inventory_quantity, I’ll get the count for both warehouses which is a poor experience when we only have 1 in stock in CA, but like 600 in the US. A Canadian user would add multiple just fine, get to checkout to find that they can only actually purchase 1…
Any ideas? I really wish we had like a variant.warehouses[0].inventory_quantity property or something…
Regarding this, you could enable pickup for them to be available in the storefront API (I thought that object only contains true/false availability and not specific quantities? edit: that was the correspondig liquid object) and then use Functions (checkout blocks/buddy can do) to hide the pickup shipping methods.