Data Warehouse ItemShops timeStamp

JanneDeVosJanneDeVos Member Posts: 41
edited May 3 in Development

Hi,

In the past I have created Data Warehouses for Lightspeed Retail customers. With this Data Warehouse I can create custom reports like Sell Through reports and so on.

At this point, I'm trying make my requests as efficient as possible. This is important because I want to update my Data Warehouses multiple times a day. Now I'm encountering the following problem. I only want to make requests for updated values in the Lightspeed Retail API. For the most endpoints I can use the timeStamp value, but have some problems with Items.

I need to get the qoh from the ItemShops relation from Items, but can't use timeStamp value of Item. The ItemShops relation has it own timeStamp, but ItemShops isn't a Lightspeed Retail Endpoint itself. So if the qoh of an item changes, this won't effect the timeStamp of the Item Endpoint. Does anybody know a solution for only updating Items where the qoh in the ItemShops relations is changed?

Tags:

4 comments

  • JanneDeVosJanneDeVos Member Posts: 41
  • JanneDeVosJanneDeVos Member Posts: 41

    @Ali_Masoumie maybe you can help me?

  • Ali_MasoumieAli_Masoumie Moderator, Lightspeed Staff Posts: 147 moderator

    Hi,

    You can do a GET on the Item endpoint with the ItemShops as a relation incl. the timestamp. Example:

    /Item.json?load_relations=["ItemShops"]&ItemShops.timeStamp=>,2021-05-14T00:00:00
    

    With the given response, you can update these items.

  • JanneDeVosJanneDeVos Member Posts: 41

    Hi @Ali_Masoumie,

    Thank you for your response. I have an additional question about this topic. Is it possible to combine Item timeStamp and ItemShop timeStamp? I want to receive Items which changed and Items with changed ItemShops.

Sign In or Register to comment.