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.

Do Shopify products have to be marked as "tracked by shopify" for api changes to reflect?

Solved

Do Shopify products have to be marked as "tracked by shopify" for api changes to reflect?

Loz86
Pathfinder
94 7 19

Hi guys 

As per the title...

 

Do Shopify products have to be marked as "tracked by shopify" for api changes to reflect?

Accepted Solution (1)
Sp1ke
Tourist
10 3 3

This is an accepted solution.

When creating new product, there is optional settings called "inventory_management" (possible values are: 'null' or 'shopify')

You will be able to update your inventory levels through API only in case "inventory_management"="shopify" for related product.

You can use following json code to update inventory_management for necessary product:

 

use PUT for related product_id on https://yourshop.myshopify.com/admin/api/2023-07/products/7815459321185.json

 

{"product":
{
"id": "7815459321185",
"variants": [{
"id": "43467836236481",
"inventory_management": "shopify"
}]
}
}

 

View solution in original post

Replies 5 (5)

topnewyork
Astronaut
1143 151 189

The "Tracked by Shopify" checkbox in product settings relates more to inventory management and tracking within the Shopify system itself. When a product is marked as "Tracked by Shopify," it means that Shopify will manage and track the inventory for that product. This feature helps with inventory management within the Shopify platform.

API changes and how data is reflected through the Shopify API are separate from this setting. Changes made via the Shopify API—such as product updates, inventory changes, pricing modifications, etc.—are typically reflected regardless of whether the product is marked as "Tracked by Shopify." As long as the API requests are properly authenticated and the correct endpoints are used, the changes should be reflected in your Shopify store's data.

So, to update or modify products using the Shopify API, you'll need the appropriate API endpoints and proper authentication methods, and the changes should reflect in your store's data regardless of whether the product is marked as "Tracked by Shopify.

 
 
Need a Shopify developer? Hire us at Top New York Web Design
Boost Your Store Sales with Volume/Tier Discount Try Big Bulk Discount
Create New Shopify Store For Just 1$/Month
Loz86
Pathfinder
94 7 19

Many thanks for the reply Topnewyork, that was the answer I was hoping for.

 

Do you have a link to any Shopify API documentation that specifies this? As I couldn't seem to find this mentioned anywhere when I looked.

Loz86
Pathfinder
94 7 19

Apparently it turns out they do have to be marked as tracked.

I have an app created which should update my stock inventory via API however it is returning this error...

Inventory item does not have inventory tracking enabled 

Sp1ke
Tourist
10 3 3

This is an accepted solution.

When creating new product, there is optional settings called "inventory_management" (possible values are: 'null' or 'shopify')

You will be able to update your inventory levels through API only in case "inventory_management"="shopify" for related product.

You can use following json code to update inventory_management for necessary product:

 

use PUT for related product_id on https://yourshop.myshopify.com/admin/api/2023-07/products/7815459321185.json

 

{"product":
{
"id": "7815459321185",
"variants": [{
"id": "43467836236481",
"inventory_management": "shopify"
}]
}
}

 

Loz86
Pathfinder
94 7 19

Thank you @Sp1ke, I managed to figure it out in the end 👍