SetTimeOfLastSync

Some integrations have processes which run on a schedule. For instance, your integration may consist of two processes:

  • The first process runs every hour and sends over new orders to Ongoing WMS.
  • The second process runs once every night and compares the stock balance in Ongoing WMS with the stock balance in your system.
For debugging purposes, it might be advantageous to know the last time a process run. You can use this function to store this time in Ongoing WMS. You can store one time per process, using IntegrationType to differentiate between them.

If you want to read back the last sync time for a process, use GetLastTimeOfSync.

Tags: SetTimeOfLastSync

Request XML

POST /xxx/Service.asmx HTTP/1.1
Host: api.ongoingsystems.se
Content-Type: text/xml; charset=utf-8
Content-Length: length
SOAPAction: "http://ongoingsystems.se/WSI/SetTimeOfLastSync"

<?xml version="1.0" encoding="utf-8" ?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  <soap:Body>
    <SetTimeOfLastSync xmlns="http://ongoingsystems.se/WSI">
      <UserName>string</UserName>
      <Password>string</Password>
      <GoodsOwnerId>int</GoodsOwnerId>
      <IntegrationType>string</IntegrationType>
      <syncTime>dateTime</syncTime>
    </SetTimeOfLastSync>
  </soap:Body>
</soap:Envelope>

Request specification

SetTimeOfLastSync
UserName string(50) Req. Your username
Password string(50) Req. Your password
GoodsOwnerId int Req. The id of your client
IntegrationType string Req. The name of your integration (free text).
syncTime dateTime Req. The time when you made the call.

Response XML

<?xml version="1.0" encoding="utf-8" ?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  <soap:Body>
    <SetTimeOfLastSyncResponse xmlns="http://ongoingsystems.se/WSI" />
  </soap:Body>
</soap:Envelope>

Response specification

If the call fails, it will return an HTTP error code other than 200.