Get products updated, added or deleted in last 3 days using REST API

user072319
Shopify Partner
128 0 15

Hi there,

 

We are developing an app. 

 

Using REST API  how can I get the product data for the below 3 requirements:

 

1. Get all products and collection products that are updated in last 3 days 

2. Get all products and collection products that are created in last 3 days 

3. Get all products and collection products that are deleted in last 3 days 

 

Any help would be appreciated

Reply 1 (1)

garyrgilbert
Shopify Partner
397 40 162

Hello,

 

For the first two requirements you can use the created_at_max, created_at_min, and updated_at_max, updated_at_min paramters to the orders.json endpoint

 

For the last one, its not possible to get which orders were deleted in the past days since they no longer exist. For that you can use the webhook orders/delete which will trigger when an order is deleted, the you can store that information in your own database.

 

Cheers,

 

Gary

- Was my reply helpful? Click Like to let me know!
- Was your question answered? Mark it as an Accepted Solution