diff --git a/docs/cow-protocol/reference/core/auctions/schema.md b/docs/cow-protocol/reference/core/auctions/schema.md index 3d14cc29b..16ccbafbb 100644 --- a/docs/cow-protocol/reference/core/auctions/schema.md +++ b/docs/cow-protocol/reference/core/auctions/schema.md @@ -119,7 +119,7 @@ An example Fill-or-Kill user limit buy order that sells 1000 [COW](https://ether } ``` -The above entry should be interpreted as follows. It is a Fill-or-Kill order since the flag `partiallyFillable` is set to `false`. Moreover, it is a sell order since its `kind` is set to `sell`. Finally, this is a `limit` order, meaning that it has a zero-signed fee, which implies that the solver is free to choose an appropriate fee to cover its execution cost. This means that, if executed, the user will send a total of 1000000000000000000000 COW atoms to the settlement contract, and the user has signed for a minimum of 284138335 USDC atoms (`fullBuyAmount`). The order also carries a 2 bps volume fee, which the driver will deduct from the buy side once the trade settles. Since the order has not been partially filled, `sellAmount` still equals `fullSellAmount`, but `buyAmount` is scaled up from `fullBuyAmount` to net out that fee: `buyAmount` = `fullBuyAmount` / (1 - 0.0002) = 284138335 / 0.9998 ≈ 284195174.03, rounded down to 284195174. Solvers can then route on `sellAmount`/`buyAmount` while ignoring fees entirely, and once the driver charges its 2 bps cut of the 284195174 USDC bought (≈56839 USDC atoms), the user is left with exactly the signed minimum of 284138335 USDC atoms — so the original limit is never violated. This is the usual case in practice: on most chains essentially every order carries some volume-based protocol or partner fee, so `buyAmount`/`sellAmount` differ from `fullBuyAmount`/`fullSellAmount` even without any partial fill; the two only coincide when there is no such fee, which is rare. +The above entry should be interpreted as follows. It is a Fill-or-Kill order since the flag `partiallyFillable` is set to `false`. Moreover, it is a sell order since its `kind` is set to `sell`. Finally, this is a `limit` order, meaning that it has a zero-signed fee, which implies that the solver is free to choose an appropriate fee to cover its execution cost. This means that, if executed, the user will send a total of 1000000000000000000000 COW atoms to the settlement contract, and the user has signed for a minimum of 284138335 USDC atoms (`fullBuyAmount`). The order also carries a 2 bps volume fee, which the driver will deduct from the buy side once the trade settles. Since the order has not been partially filled, `sellAmount` still equals `fullSellAmount`, but `buyAmount` is scaled up from `fullBuyAmount` to net out that fee: `buyAmount` = `fullBuyAmount` / (1 - 0.0002) = 284138335 / 0.9998 ≈ 284195174.03, rounded down to 284195174. Solvers can then route on `sellAmount`/`buyAmount` while ignoring fees entirely, and once the driver charges its 2 bps cut of the 284195174 USDC bought (≈56839 USDC atoms), the user is left with exactly the signed minimum of 284138335 USDC atoms — so the original limit is never violated. This is the usual case in practice: on most chains, orders between uncorrelated tokens carry a volume-based protocol fee and many orders carry a partner fee, so `buyAmount`/`sellAmount` differ from `fullBuyAmount`/`fullSellAmount` even without any partial fill; the two only coincide when there is no such fee, e.g. for an order between correlated tokens (which are not charged a protocol volume fee) without a partner fee. ### `deadline` diff --git a/docs/governance/fees/fees.md b/docs/governance/fees/fees.md index 8ef1aae2f..21591e6f2 100644 --- a/docs/governance/fees/fees.md +++ b/docs/governance/fees/fees.md @@ -30,19 +30,19 @@ The purpose of this page is to let users know which fee models are active at any > > **Fee calculation:** quote improvement \* 0.5 **OR** volume \* 0.0098 [whichever number is lower] -### Volume Fee +### Protocol volume fee > **Definition:** A tiered fee based on the total volume of the order, adjusted by asset type > -> **Eligible orders:** all orders +> **Eligible orders:** all orders, except orders between correlated assets (e.g. stablecoin to stablecoin), which are currently not charged a volume fee > > **Fee structure:** > - **Standard Assets:** 2 basis points (bps) -> - **Correlated Assets (Stables/RWAs):** 0.3 basis points (bps) -> +> - **Correlated Assets (Stables/RWAs):** 0 basis points (bps) +> > **Fee calculation:** > - **Standard**: Volume * 0.0002 -> - **Correlated:** Volume * 0.00003 +> - **Correlated:** no protocol volume fee :::note