Our Partner & Developer boards on the community are moving to a brand new home: the .dev community forums! While you can still access past discussions here, for all your future app and storefront building questions, head over to the new forums.

Variants are saved in Shopify incorrectly when uploaded via Custom App

Variants are saved in Shopify incorrectly when uploaded via Custom App

mahicks11
Tourist
6 0 3

Store Name: Sole Priorities

App Name: SPISMS

 

We created a custom app called SPISMS to help manage inventory and sales in Shopify. The app uses the following endpoints in the order specified to upload variants.

 

Upload Variant

 

/products/$productID/variants.json

 

Set Variant Cost

 

/inventory_items/$inventory_item_id.json

Set Product Quantity Cost

 

 

inventory_levels/set.json

We noticed on multiple occasions that the 1st call to upload the variant uploads the wrong variant result the cost and quantity to be set on incorrect variants. Below are instances of incorrect uploads along with date and time of entry.

 

Variant Uploaded by SPISMS Variant Saved By ShopifyDate/Time of EntryStore Location
Nike Air Force 1 Low Supreme Baroque Brown sz.8.5Nike Air Force 1 Low Supreme Baroque Brown sz.4Y2023-11-08 11:32:11Sole Priorities CLT
Jordan 11 Retro Cap and Gown sz.10.5Jordan 11 Retro Cap and Gown sz.10.5 (Pre-Owned)2023-11-08 17:45:09Sole Priorities CLT
Nike Dunk Low Red Panda sz. 9Nike Dunk Low Red Panda sz. 42023-11-02 13:37:40Sole Priorities CLT

Cactus Plant Flea Market x Air Flea 2 'Faded Spruce'

sz.10M 

Cactus Plant Flea Market x Air Flea 2 'Faded Spruce'

sz.4Y
2023-10-29 15:11:12Sole Priorities CLT

 

Can you look into why these variants were uploaded as the wrong size?

Reply 1 (1)

mahicks11
Tourist
6 0 3

We did some additional investigation and noticed that this happens with variants without a SKU.