Question

I've been trying to update the inventory_level based on the SKU name, but never been successful, would you be able to help to point which part I did wrong?

curl --request PUT -H "Content-Type: application/json" -u "myadminlogin:mykey" -d '{"inventory_level":"25"}' https://mystorehash.mybigcommerce.com/api/v2/products/skus.json?sku=SKU-381D364D

Here's the error result:

[{"status":404,"message":"The requested resource was not found."}]
Was it helpful?

Solution

If you want to filter based on the SKU you need to include the Product ID for the SKU you are referencing.

`/api/v2/products/{product_id}/skus?sku={value}`

Here is a link to the documentation: https://developer.bigcommerce.com/api/stores/v2/products/skus#update-product-sku

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top