How to track new sale in Lightspeed

renjithmbrenjithmb Posts: 14Member

Is there is way to track new sale in Lightspeed through API. Please advice.


  • Adrian SamuelAdrian Samuel moderator Posts: 545Moderator, Lightspeed Staff moderator

    Hey @renjithmb, we the best thing would be to run a cron-job to check for new sales every X minute(s). If you persist the data of the count, you can use that to compare new sales.

    It would go something like this:

    Every 60 Seconds:

    Make a request to the Retail API, check the ["@attributes"].count value and store it in a database.

    In the next iteration (i.e.) in the next 60 seconds, check to see if the count is greater than the previously stored count value, and then grab the details from the difference.

    Hope this helps!

    Adrian Samuel

    API Integrations Consultant - Strategic Solutions

    Lightspeed HQ

  • renjithmbrenjithmb Posts: 14Member
Sign In or Register to comment.