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.
The pipeline supports ten EVM networks. Each network has a dedicated set of payment addresses, token addresses, reward caps, and Dune identifiers derived from the Network enum in src/config.py.
Network enum
class Network(Enum):
"""Network class for networks supported by the accounting."""
MAINNET = "mainnet"
BASE = "base"
ARBITRUM_ONE = "arbitrum"
BNB = "bnb"
AVALANCHE = "avalanche"
POLYGON = "polygon"
GNOSIS = "gnosis"
LINEA = "linea"
PLASMA = "plasma"
INK = "ink"
The string value of each variant is what the NETWORK environment variable must be set to.
Per-network reference table
| Network | Enum value | Dune blockchain | Native token | EthereumNetwork |
|---|
| Ethereum mainnet | mainnet | ethereum | ETH | MAINNET |
| Gnosis Chain | gnosis | gnosis | xDAI | GNOSIS |
| Arbitrum One | arbitrum | arbitrum | ETH | ARBITRUM_ONE |
| Base | base | base | ETH | BASE |
| Avalanche C-Chain | avalanche | avalanche_c | AVAX | AVALANCHE_C_CHAIN |
| Polygon | polygon | polygon | POL | POLYGON |
| BNB Smart Chain | bnb | bnb | BNB | BNB_SMART_CHAIN_MAINNET |
| Linea | linea | linea | ETH | LINEA |
| Plasma | plasma | plasma | XPL | PLASMA_MAINNET |
| Ink | ink | ink | ETH | INK |
Minimum transfer thresholds
To avoid dust payments, transfers below these amounts are filtered out.
| Network | Min native token transfer | Min COW transfer |
|---|
| Mainnet | 0.001 ETH (10¹⁵ wei) | 10 COW (10 × 10¹⁸ atoms) |
| Gnosis | 0.01 xDAI (10¹⁶ wei) | 1 COW (10¹⁸ atoms) |
| Arbitrum One | 0.0001 ETH (10¹⁴ wei) | 1 COW (10¹⁸ atoms) |
| Base | 0.0001 ETH (10¹⁴ wei) | 1 COW (10¹⁸ atoms) |
| Avalanche | 0.0001 AVAX (10¹⁴ wei) | 1 COW (10¹⁸ atoms) |
| Polygon | 0.0001 POL (10¹⁴ wei) | 1 COW (10¹⁸ atoms) |
| BNB | 0.0001 BNB (10¹⁴ wei) | 1 COW (10¹⁸ atoms) |
| Linea | 0.0001 ETH (10¹⁴ wei) | 1 COW (10¹⁸ atoms) |
| Plasma | 0.0001 XPL (10¹⁴ wei) | 1 COW (10¹⁸ atoms) |
| Ink | 0.0001 ETH (10¹⁴ wei) | 1 COW (10¹⁸ atoms) |
Quote reward cap (native token)
The per-quote reward paid to solvers is capped at the lower of the COW reward (quote_reward_cow, uniform at 6 × 10¹⁸ atoms) and the native-token equivalent cap below.
| Network | quote_reward_cap_native (atoms) | Human-readable |
|---|
| Mainnet | 7 × 10¹⁴ | 0.0007 ETH |
| Gnosis | 15 × 10¹⁶ | 0.15 xDAI |
| Arbitrum One | 24 × 10¹³ | 0.00024 ETH |
| Base | 24 × 10¹³ | 0.00024 ETH |
| Avalanche | 6 × 10¹⁵ | 0.006 AVAX |
| Polygon | 6 × 10¹⁷ | 0.6 POL |
| BNB | 1 × 10¹⁵ | 0.001 BNB |
| Linea | 3 × 10¹³ | 0.00003 ETH |
| Plasma | 6 × 10¹⁷ | 0.6 XPL |
| Ink | 3 × 10¹³ | 0.00003 ETH |
Wrapped token addresses
Each network has two wrapped-token addresses tracked in PaymentConfig:
wrapped_native_token_address — the canonical wrapped version of the network’s native gas token (e.g. WETH on mainnet).
wrapped_eth_address — the address of wrapped ETH on that network. On Ethereum and Arbitrum these are the same; on Avalanche, Polygon, BNB, Plasma, and others they differ.
| Network | wrapped_native_token_address | wrapped_eth_address |
|---|
| Mainnet | 0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2 (WETH) | same |
| Gnosis | 0xe91d153e0b41518a2ce8dd3d7944fa863463a97d (WXDAI) | 0x6a023ccd1ff6f2045c3309768ead9e68f978f6e1 |
| Arbitrum One | 0x82af49447d8a07e3bd95bd0d56f35241523fbab1 (WETH) | same |
| Base | 0x4200000000000000000000000000000000000006 (WETH) | same |
| Avalanche | 0xB31f66AA3C1e785363F0875A1B74E27b85FD66c7 (WAVAX) | 0x49D5c2BdFfac6CE2BFdB6640F4F80f226bc10bAB |
| Polygon | 0x0d500B1d8E8eF31E21C99d1Db9A6444d3ADf1270 (WPOL) | 0x7ceB23fD6bC0adD59E62ac25578270cFf1b9f619 |
| BNB | 0xbb4CdB9CBd36B01bD1cBaEBF2De08d9173bc095c (WBNB) | 0x4db5a66e937a9f4473fa95b1caf1d1e1d62e29ea |
| Linea | 0xe5d7c2a44ffddf6b295a15c148167daaaf5cf34f (WETH) | same |
| Plasma | 0x6100e367285b01f48d07953803a2d8dca5d19873 (WXPL) | 0x9895d81bb462a195b4922ed7de0e3acd007c32cb |
| Ink | 0x4200000000000000000000000000000000000006 (WETH) | same |
Orderbook database names
OrderbookConfig maps each network to a database name in the analytics PostgreSQL instance:
| Network | network_db_name |
|---|
| Mainnet | mainnet |
| Gnosis | xdai |
| Arbitrum One | arbitrum-one |
| Base | base |
| Avalanche | avalanche |
| Polygon | polygon |
| BNB | bnb |
| Linea | linea |
| Plasma | plasma |
| Ink | ink |
All networks use the dbt schema.
Nonce modifier system
Because COW token rewards for every network are paid from the same mainnet Safe, the pipeline must queue one transaction per network without nonce conflicts. It achieves this by adding a per-network integer offset to the current Safe nonce.
The default offsets are computed by reversing the Network enum declaration order and assigning indices starting at 0:
nonce_modifier_dict = {
network: idx
for idx, network in enumerate(reversed(list(Network)), start=0)
}
This produces the following default offsets (order may shift if new networks are added):
| Network | Default nonce offset |
|---|
MAINNET | 9 |
BASE | 8 |
ARBITRUM_ONE | 7 |
BNB | 6 |
AVALANCHE | 5 |
POLYGON | 4 |
GNOSIS | 3 |
LINEA | 2 |
PLASMA | 1 |
INK | 0 |
Override the automatic offset by setting the NONCE_MODIFIER environment variable when running the pipeline manually.
AccountingConfig.from_network() factory
AccountingConfig is the root configuration object that aggregates all sub-configs. It is constructed by calling the from_network() factory with the resolved Network enum value:
@staticmethod
def from_network(network: Network) -> AccountingConfig:
return AccountingConfig(
payment_config=PaymentConfig.from_network(network),
orderbook_config=OrderbookConfig.from_network(network),
dune_config=DuneConfig.from_network(network),
node_config=NodeConfig.from_env(),
reward_config=RewardConfig.from_network(network),
protocol_fee_config=ProtocolFeeConfig.from_network(network),
buffer_accounting_config=BufferAccountingConfig.from_network(),
io_config=IOConfig.from_env(),
overdraft_config=OverdraftConfig.from_network(network),
)
The NETWORK environment variable is read inside IOConfig.from_env() and drives the Network enum resolution used by all other sub-config factories.