Odyssee Mobile

API User Guide

This chapter describes the logic used to make this integration.

Sync ERP to Odyssee

The table Customer contains a datetime field (name=”updated”).

Each time a record is added or updated (CustomerAdd,CustomerUpdate) the ERP Layer ensure that the field is updated with a GETDATE().

To synchronize the data from MyERP to Odyssee, the following steps are executed

  • 1) Get the highest last proceeded ERP.Customer.updated field
  • 2) List all ERP.Customer that have been created or updated AFTER this date field (using milliseconds)
  • 3) Foreach of these records, it serialize the “ERP.Customer” to an object and verify on the sync_cache that he is well modified (Imagine that you have a field on your ERP that is not Sync. In this case, modify this field doesn’t mean you need to sync a new time this object to Odyssee).
    • 4) If modified (not in the sync_cache or serialized object is different), it verify if this object has been already sent to Odyssee (to know if a POST or PUT is needed)
    • 5) It send the object to Odyssee and store the Odyssee Guid on his cache
  • 6) When all data are proceeded, it stores the new highest “ERP.Customer.updated” field



Sync Odyssee to ERP

To synchronize the data from Odyssee to MyERP, the following steps are executed

  • 1) Get the highest last proceeded Odyssee.Company.modified_dateutc field
  • 2) List all Odyssee.Company have been created or updated AFTER this date field (using milliseconds)
  • 3) Foreach of these records
    • 4) it verify if the Odyssee.Company.code is filled
    • 5)Odyssee.Company.code empty : it add it on MyERP, receive the new ERP.Customer.id and make an API update on Odyssee.Company.code and add it on my sync_cache
    • 6)Odyssee.Company.code filled : this customer comes from MyERP. Need to see if the value of the field “name” is different than on my ERP.
      • 7)If different, update on MyERP and update my sync_cache
    • 8) When all data are proceeded, it stores the new highest “Odyssee.Company.modified_dateutc” field