Lux Proposals
← All proposals
LP-0080Finaltreasuryfeewarpcross-chaincollection

LP-080: Cross-Chain Fee Collection via Warp

Abstract

Defines the cross-chain fee collection mechanism for Lux Network. Each L1 / L2 chain (Zoo, Hanzo, SPC, Pars, and future chains, per LP-018) collects transaction fees in its native gas token. The FeeCollector contract on each chain periodically sweeps accumulated fees to the C-Chain treasury via Warp messaging (LP-6022). The C-Chain treasury then routes fees through the fee splitter (LP-081).

Specification

Architecture


L1/L2 Chain (Zoo)                 C-Chain
  FeeCollector                      TreasuryV2
    |-- accumulates fees              |-- receives Warp transfers
    |-- sweep() triggers Warp  --->   |-- routes to FeeSplitter
    |-- configurable interval         |-- emits FeeReceived event

FeeCollector Contract

Deployed on each L1 / L2 chain (per LP-018):

| Function | Description |
|----------|-------------|
| sweep() | Sends accumulated fees to C-Chain TreasuryV2 via Warp |
| setInterval(uint256) | Minimum seconds between sweeps (default: 86400 = 1 day) |
| setMinAmount(uint256) | Minimum balance to trigger sweep (avoids dust transfers) |

Warp Message

The sweep sends a Warp message containing:

| Field | Type | Description |
|-------|------|-------------|
| sourceChain | bytes32 | Originating chain ID |
| amount | uint256 | Fee amount in native token |
| token | address | Token address (native = 0x0) |
| epoch | uint256 | Collection epoch number |

Fee Denomination

L1 / L2 chains may use different gas tokens. The TreasuryV2 contract on C-Chain accepts all Lux-native tokens and converts to LUX via the DEX precompile (LP-9010) before routing to the fee splitter.

Collection Schedule

| Parameter | Default | Governance Range |
|-----------|---------|-----------------|
| Sweep interval | 24 hours | 1 hour - 30 days |
| Minimum amount | 100 LUX equivalent | 1 - 10,000 LUX |
| Maximum per sweep | unlimited | configurable |

Security Considerations

1. Sweep is permissionless -- anyone can call it. No keeper dependency.

2. Warp message signatures are validated by BLS quorum (LP-075) on the destination chain.

3. The FeeCollector holds no admin keys. Parameters are set by governance timelock only.

4. Failed sweeps (Warp message rejected) retry on the next interval. Fees are never lost.

Reference

| Resource | Location |
|----------|----------|
| FeeCollector contract | github.com/luxfi/standard/contracts/treasury/FeeCollector.sol |
| TreasuryV2 contract | github.com/luxfi/standard/contracts/treasury/TreasuryV2.sol |
| Warp messaging | github.com/luxfi/evm/warp/ |

Copyright

Copyright (C) 2025-2026, Lux Partners Limited. All rights reserved.

Licensed under the MIT License.