estimate_fees
Estimate bridge or swap route fees without committing. Compare gas, relayer, and total costs to select the best route.
Instructions
Estimate the fees for a specific bridge or swap route without committing to execution. Returns a breakdown of gas fees, relayer fees, and total cost impact.
Use this for comparing route costs or showing users expected fees. For standalone token pricing (not route-specific), use get_token_price instead.
Amounts must be in the token's smallest unit (wei, satoshis, lamports). Examples: 1 ETH = "1000000000000000000" (18 decimals), 1 USDC = "1000000" (6 decimals), 1 BTC = "100000000" (8 decimals), 1 SOL = "1000000000" (9 decimals). Use convert_amount or get_supported_tokens to look up decimals. Chain IDs can be numbers (8453) or names ('base', 'ethereum', 'arb', 'bitcoin', 'solana').
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| amount | Yes | Amount in the origin token's smallest unit. | |
| sender | No | Sender wallet address. Optional — defaults to a zero address for estimation purposes. | |
| tradeType | No | EXACT_INPUT (default): you specify input amount, output varies. EXPECTED_OUTPUT: you specify desired output, input is calculated (allows slippage). EXACT_OUTPUT: you specify exact output required, fails if not deliverable. | EXACT_INPUT |
| originChainId | Yes | Source chain ID or name (e.g. 1, 'ethereum', 'eth'). | |
| originCurrency | Yes | Origin token address or symbol (e.g. "USDC", "ETH"). For native tokens use: EVM "0x0000000000000000000000000000000000000000", Solana "11111111111111111111111111111111", Bitcoin "bc1qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqmql8k8", Hyperliquid "0x00000000000000000000000000000000", Lighter "0". For other tokens, use the contract/mint address or look up via get_supported_tokens. | |
| destinationChainId | Yes | Destination chain ID or name (e.g. 8453, 'base'). | |
| destinationCurrency | Yes | Destination token address or symbol (e.g. "USDC", "ETH"). For native tokens use: EVM "0x0000000000000000000000000000000000000000", Solana "11111111111111111111111111111111", Bitcoin "bc1qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqmql8k8", Hyperliquid "0x00000000000000000000000000000000", Lighter "0". For other tokens, use the contract/mint address or look up via get_supported_tokens. |