When I create a new product it's a minefield. I think the documentation should be more clear on what aspects you can POST on creation of a product, perhaps it would be clearer if you have a different table for fields you can set. For instance I tried defining a static.
public static inline var inventoryManagement = 'shopify';
Then but if set that on my Variant when creating a product it 422, I understand you default it but why am I not allowed to set on creation?
I am now going through manually checking which fields I can setup on creation and which will result in a 422 and then adjusting my typedef to make them optional and commenting them, it's not fun as I have to try each field, also with options it's really weird because I need some variants for them to be accepted. It feels like only the examples provided work anything else and it's likely to fail. I am thinking maybe I have two typedef one for creation and one for update that is an extension.
if I set images up it allows me to use image without 422.
I am gathering I need to do two calls to get a product quantity up with the REST api this is rather ugly yet to implement futures so it's kind of messy.
Is there a better place I can look at for documentation... ideally source code! :)
Solved! Go to the solution
Have updated hxTShopify library witten in Haxe language, with example demo of product creation and product migration of 7 products between stores, includes Images, Variants, Options and Quanities.
I am looking for work and have customised some liquid, based in the UK probably be back as I iron out more details.