Skip to main content

LimitOrderEscrow Contract

The LimitOrderEscrow contract enables users to create automated limit orders that execute when market conditions meet specified criteria. It integrates seamlessly with the EMPXRouter for optimal trade execution.

Order Types

The contract supports distinct order types for buying and selling, ensuring clarity in execution logic and intent.

Partial Fill Modes

The contract supports five partial fill modes, allowing users to choose their execution strategy based on market conditions and personal preferences:

  1. No Partial Fill
  2. Split 3
  3. Split 5
  4. Split 10
  5. Flexible

Fee Structure

The limit order system implements a sophisticated dual-fee model with dynamic router fees based on token volatility.

Protocol Fees

  • Protocol Fee: Flat fee charged on all order executions, paid to the protocol’s fee collector.
  • Bot Fee: Incentive fee paid to authorized bots for executing orders, paid to the bot collector.

Total protocol + bot fees are capped at 100% (10,000 basis points) of the order amount.

Dynamic Router Fees

  • Volatile Router Fee: Applied when both tokens in the pair are volatile (e.g., WETH/WBTC).
  • Stable Router Fee: Applied when either token in the pair is a stablecoin (e.g., WETH/USDC).

This dynamic structure allows for optimized fee collection based on the risk profile of the trading pair.