Exact Online sync APIs

What are Exact Online Sync APIs?

Exact Online offers so-called “Sync APIs”: Sync APIs target easy one-way synchronization from Exact Online to local replicas (announcement).

Sync APIs are similar to the Bulk APIs in that they return 1.000 rows per API request. However, OData server-side filtering is only available on an ever incrementing transaction counter.

An Exact Online Sync API assumes the application downloads the data from Exact Online and memorizes the highest transaction counter value. On the next synchronization, the possible updated and/or added data is downloading starting of at the memorized value. Deleted rows are available through a special API which lists primary key and transaction counter value of all deleted rows.

Invantive SQL includes tables for all Exact Online Sync APIs. They can be recognized by a name postfix of “Incremental“ such as “TransactionLinesIncremental“. They are available even when Invantive Data Replicator is not licensed, offering cost savings in several scenarios.

What are differences between Exact Online webhooks and Sync APIs?

The differences between Exact Online webhooks and sync APIs are:

  • Exact Online webhooks have better latency.
  • Exact Online Sync APIs scale better.
  • Exact Online Sync APIs are more reliable.
  • Exact Online webhooks leave no holes in history.

Webhooks outperform Sync APIs in terms of latency. Webhooks are delivered within minutes after a change using a push strategy. The sync APIs are only accessible using a pull strategy. A pull allows for a lower latency, but at cost of resource use. So in general a webhook can deliver change information faster with comparable resource use.

Sync APIs scale better on large volumes of changed records. At least one webhook message is generated for every change, but when pulling the data using the sync API, changed records are batched in groups of 1.000.

Sync APIs build upon the scalable and reliable synchroneous REST APIs of Exact Online. The REST APIs have a low mean time between failures (1:1.000.000) and easy detection of the need for recovery. The current webhook implementation of Exact Online webhooks was designed without essential features for data integrity which are exagerated by it’s asynchroneous nature. It is a common problem that changes get lost during the process. Given that integrity of financial data is essential, it has driven many users away back to full replication. The limited robustness of the Exact Online webhooks is in general not considered a problem for marketing data.

The use of webhooks enables registration of multiple changes occurring between the replication interval. The Exact Online webhook message does not contain the actual details disabling a full audit trail, but still signal the number of changes. However, with the Sync APIs all intermediate changes on row level can almost never be detected even with advanced mathematics.