Forum Discussion

Nocturnal's avatar
Nocturnal
Cover User
7 months ago

Recently created or updated records

Hi,

 

I am looking for a way to get the recently created or updated record via API but looks like only Sale Invoice and Order on have a "LastModified" record on it, is there anyone found a way to filter other record based on time stamp when it was created or updated?

 

To give you idea what i am trying to achieve, I have a background tools thats pulls out all the data from MYOB API then store it on local database for faster processing. The flow is loop thru all record then compare it with locally stored data to see if the data is recently created or updated. It is completely working fine but as time goes, more and more data are being created and it is taking longer and longer to process. As a fix to this, I need to look for a timestamp to be able to compare with the latest stored on database and only process the recently created or updated but other end points doesnt that kind of data, thats where the LastModifed timestamp will be a really great help for this.

 

If this needs to be requested from the development team of MYOB, may we know how to file this request? Thank you in advance.

    • Nocturnal's avatar
      Nocturnal
      Cover User

      Hi JeremyF ,

       

      Yup, I can do this on Sales Invoice and Orders because they have the LastModified data available on those end points, but for Purchase Orders and Bills I cant do this because they dont have the same columns and they are returning empty dataset when addind that filter (see image below).

       

      Looks like LastModified data needed to be added on Purchases endpoints.

      • Mike_James's avatar
        Mike_James
        Ultimate Cover User

        Hi Nocturnal , the Rowversion value can also be stored and compared. We do this where lastmodified is not available.

         

        We also find that larger files generally take longer to process, although the API's performance is usually very good. We did find it necessary to compress the API result in one endpoint (item purchases), due to a case where the client had very lengthy purchases.