• Login

Sync local database

Please open the Postman project to see this example.

Sync your local database with our master data.

Simply do the following for each endpoint you have access to:

  1. Request all data mutated since the most recent mutation time of the received data
  2. Do until no data is received:
    • repeat request
    • add 'number of received values' to $skip
  3. Store the max change_date_time of the received data to use the next time you sync your database

See the 'Pre-request scripts' in the only request of this folder. In this example we only sync our database with the products, but the same principle should be used in all endpoints. The highest frequency of mutations over all endpoints is 'daily', so it's no use to check each hour for changes.