The data sync script uploads CoW Protocol order data for the current month to Dune Analytics. This data powers the solver rewards dashboard used to cross-check payout computations each week.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/cowprotocol/solver-rewards/llms.txt
Use this file to discover all available pages before exploring further.
Running the sync
BARN_DB_URL, PROD_DB_URL, ANALYTICS_DB_URL) and pushes the result to your Dune account via the Dune API.
When to run
Run the data sync once per month, before running the weekly payout analysis. Because the solver rewards dashboard queries data that has been uploaded to Dune, the payout validation step (cross-checking against the dashboard) depends on the data being current.The data sync is separate from the payout computation. The payout script (
src.fetch.transfer_file) queries both the orderbook database and Dune directly. The data sync script specifically refreshes the Dune-hosted copy of order data that the dashboard visualizes.Prerequisites
The same.env configuration used for payout generation applies here. Ensure the following are set:
Relationship to payout computation
The payout pipeline has two data paths:Dune Analytics
Used for on-chain data queries: trade events, block ranges, solver activity. The
order_data table synced by this script feeds the solver rewards dashboard at dune.com/cowprotocol/cow-solver-rewards.Orderbook database
Used for off-chain data: order details, settlement data from the CoW Protocol backend. Queried directly by the payout script via
ANALYTICS_DB_URL, BARN_DB_URL, and PROD_DB_URL.data_sync step keeps the Dune-hosted copy of order data fresh so that the dashboard reflects the latest trades. Without a recent sync, the dashboard totals shown during payout validation may lag behind the orderbook.
