The API stopped showing data on saturday september 25th 1:45AM

sartipsartip Member Posts: 4

On Saturday september 25th, 1:45AM the API stopped responding our requests with data. Before that, everything was working correctly.

We also got our token revoked so we had to go to the webpage with our email and password to get a new oAuth token. It seems related that this problem heppened at the exacto same time.

This is the GET we are using:

curl --location --request GET 'https://lightspeedapis.com/resto/rest/financial/receipt?from=2021-09-20T00:00:00.000&to=2021-09-27T00:00:00.000&receiptId=43342916' \
--header 'Authorization: Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXJ2ZXIiOiJuYWUyLnBvc2lvcy5jb20iLCJzdWIiOiIxMzg3NzMiLCJhdWQiOiJ1c2VyYWRtaW4iLCJndHAiOiJhdXRob3JpemF0aW9uX2NvZGUiLCJpc3MiOiJMaWdodHNwZWVkIiwiZXhwIjoxNjMyNjg3MDkyLCJpYXQiOjE2MzI2ODM0OTIsImRpZCI6ImFwaSIsImNsaWVudF9pZCI6IlRzODh4QUplQTdTVVpYcFJ6RUx4WGZKRnl3WE1WVjlKIiwianRpIjoiNzBmNTVkZWItOTI2MS00OTY1LTlkMzUtN2JlZTFmNTMzMTNiIiwiY2lkIjo0MjY4MX0.pe4-NtdJsGETPyvDjrFQh_Ja30FRcZEDFPYeh9dNGLs'
  • the bearer token already expired (it is just to see the call we made to the API)

We always get this result:

{ "results": [], "amount": 0, "offset":50}

We need to get the data from the API in order to comply with local regulations ASAP.

The email we are using to login to the oAuth for the API is [email protected], if you send me your personal email, I can send my password too.

Help please

3 comments

  • LucienVersendaalLucienVersendaal Moderator, Lightspeed Staff Posts: 878 moderator
    edited September 29

    Hi @sartip,

    Thank you for contacting us.

    What I don't understand is that you are using a date range and also looking for a specific receiptID. You can make your query more efficient by using only the receiptId param. So your request will look like

    GET https://lightspeedapis.com/resto/rest/financial/receipt?receiptId=43342916
    


    I hope this helps.

  • sartipsartip Member Posts: 4

    Thanks Lucien, but it didn't work.

    There is no data in your server, these are all the queries to the API that we are sending and none of them is returning anything.

    curl --location --request GET 'https://lightspeedapis.com/resto/rest/financial/receipt?from=2021-09-23T00:00:00.000&to=2021-09-30T00:00:00.000' \
    --header 'Authorization: Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXJ2ZXIiOiJuYWUyLnBvc2lvcy5jb20iLCJzdWIiOiIxMzg3NzMiLCJhdWQiOiJ1c2VyYWRtaW4iLCJndHAiOiJhdXRob3JpemF0aW9uX2NvZGUiLCJpc3MiOiJMaWdodHNwZWVkIiwiZXhwIjoxNjMzMDE0OTAwLCJpYXQiOjE2MzMwMTEzMDAsImRpZCI6ImFwaSIsImNsaWVudF9pZCI6IlRzODh4QUplQTdTVVpYcFJ6RUx4WGZKRnl3WE1WVjlKIiwianRpIjoiODJiYzA4ZjItYTkxZC00NjAzLWFjNmMtNDVkNzkyMjZmODcwIiwiY2lkIjo0MjY4MX0.0hfXXRPN4wmtlS7mmBmaTR2WgHjOtIhYt7kXBu2HccI'
    

    this doesn't return anything

    curl --location --request GET 'https://lightspeedapis.com/resto/rest/financial/receipt?receiptId=43342916' \
    --header 'Authorization: Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXJ2ZXIiOiJuYWUyLnBvc2lvcy5jb20iLCJzdWIiOiIxMzg3NzMiLCJhdWQiOiJ1c2VyYWRtaW4iLCJndHAiOiJhdXRob3JpemF0aW9uX2NvZGUiLCJpc3MiOiJMaWdodHNwZWVkIiwiZXhwIjoxNjMzMDE0OTAwLCJpYXQiOjE2MzMwMTEzMDAsImRpZCI6ImFwaSIsImNsaWVudF9pZCI6IlRzODh4QUplQTdTVVpYcFJ6RUx4WGZKRnl3WE1WVjlKIiwianRpIjoiODJiYzA4ZjItYTkxZC00NjAzLWFjNmMtNDVkNzkyMjZmODcwIiwiY2lkIjo0MjY4MX0.0hfXXRPN4wmtlS7mmBmaTR2WgHjOtIhYt7kXBu2HccI'
    

    this doesn't return anything neither

    curl --location --request GET 'https://lightspeedapis.com/resto/rest/financial/receipt?date=2021-09-28' \
    --header 'Authorization: Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXJ2ZXIiOiJuYWUyLnBvc2lvcy5jb20iLCJzdWIiOiIxMzg3NzMiLCJhdWQiOiJ1c2VyYWRtaW4iLCJndHAiOiJhdXRob3JpemF0aW9uX2NvZGUiLCJpc3MiOiJMaWdodHNwZWVkIiwiZXhwIjoxNjMzMDE0OTAwLCJpYXQiOjE2MzMwMTEzMDAsImRpZCI6ImFwaSIsImNsaWVudF9pZCI6IlRzODh4QUplQTdTVVpYcFJ6RUx4WGZKRnl3WE1WVjlKIiwianRpIjoiODJiYzA4ZjItYTkxZC00NjAzLWFjNmMtNDVkNzkyMjZmODcwIiwiY2lkIjo0MjY4MX0.0hfXXRPN4wmtlS7mmBmaTR2WgHjOtIhYt7kXBu2HccI'
    

    this neither


    Helppppp

  • LucienVersendaalLucienVersendaal Moderator, Lightspeed Staff Posts: 878 moderator

    Hi @sartip,

    Are you sure you're having the right account here. Because when I'm looking at the token, it tells me that this is company 42681 on NAE2 server when using this tool https://jwt.io/ to check the access token.


    Now when I look in the actual account and select the date range, the same as in your request, I don't see any sales here. So it seems to be correct that you see any data, because there is no data.


Sign In or Register to comment.