DEX Aggregator Route Optimization Executor
Free to download on every platform. Comes pre-installed on BotFone, BotPad and BotFlip — with extra free apps included.
About this app
WHAT IT DOES
This tool enables DeFi traders and users to execute optimized swap routes through a DEX aggregator. DEX aggregators scan multiple decentralized exchanges (Uniswap, Curve, Balancer, etc.) to find the best price for a token swap, splitting orders across multiple DEXs and using multi-hop paths to minimize slippage and maximize output. It connects to your wallet and reads the aggregator contract address, input token address, output token address, input amount, available DEXs, route quotes, slippage tolerance, gas price, route history, and timestamps. The tool signs and submits transactions to execute optimized swap routes, multi-hop trades, update route parameters, record route metadata, and emit route events.
HOW TO USE
1. Connect your wallet using the wallet bridge (supports MetaMask, WalletConnect, and other EVM-compatible wallets).
2. Select the target network that matches your aggregator contract deployment.
3. Enter the aggregator contract address and click "load contract" to initialize the connection.
4. Click "fetch aggregator status" to retrieve the route history and verify the contract is working.
5. Enter the input token address (use 0x0 for native token), output token address, input amount, and slippage tolerance.
6. Optionally specify available DEXs to limit the search (comma-separated).
7. Click "optimize route" to query the aggregator for the best route and estimated output.
8. Review the optimized route, estimated output, and slippage tolerance before executing.
9. Click "execute swap" to sign and submit the transaction that executes the optimized route.
TECHNICAL MECHANISM
The tool uses ethers.js v5.7.2 to interact with any EVM-compatible DEX aggregator contract that implements a standard interface (getQuote(address, address, uint256) view returns (uint256, bytes), executeSwap(bytes, uint256, uint256) external payable, getRouteHistory(address) view). The getQuote function returns the estimated output amount and the encoded route data (including the DEX paths and split percentages). The executeSwap function executes the route data, validating the minimum output amount (calculated from slippage tolerance) and transferring the swapped tokens to the user. The contract typically uses a combination of direct swaps, multi-hop paths, and split routes to optimize the price. The getRouteHistory view provides a full audit trail of executed routes. Transaction handling follows EIP-1559 gas price calculations using receipt.effectiveGasPrice for accurate cost reporting. Route metadata is recorded both in the contract's history and locally for the user's reference.
WHAT IT CANNOT SEE
This tool operates purely on-chain and cannot verify off-chain price accuracy — it does not check whether the quoted prices are accurate or based on reliable data sources. It cannot predict slippage outcomes — the tool cannot forecast how much slippage will occur during execution. It cannot detect front-running — the tool cannot identify attempts to front-run the transaction. It cannot ensure optimal route selection — while the aggregator selects the best route based on available data, market conditions may change. The tool also cannot guarantee execution price — the actual execution price may differ from the quoted price due to market movements, transaction ordering, or other factors.
PLEASE NOTE
This tool works exclusively with EVM-compatible blockchain networks (Ethereum, Polygon, Arbitrum, Optimism, Base, etc.). It requires the aggregator contract to implement the interface described above. All transactions incur gas fees paid by the connected wallet. The tool maintains no persistent storage — all state is refreshed from the blockchain on each session. DEX aggregators provide best execution but do not guarantee prices — always verify the estimated output and slippage tolerance before executing. Consider the gas costs relative to the trade size — small trades may not be cost-effective due to gas fees. Always test with small amounts on a testnet first to verify the route optimization and execution.