Odosswap routing: single and multi-token execution
Odos used smart order routing to combine liquidity paths for single-token and atomic multi-token swaps. Router V2 constrained input transfers and enforced minimum output amounts for single swaps and a minimum combined output value for multi-swaps, while its single and multi-swap functions collected revenue differently. Its hosted trading and API services shut down in July 2026.
UpdatedNetwork and execution requirements
A route depended on liquidity for its selected tokens and network. Router V2 had network-specific deployments, including Ethereum, Optimism, Base and Arbitrum. Deployment across several networks didn't, by itself, establish that a particular route could bridge assets between them.
For ERC-20 inputs, valid token-transfer authorization was a prerequisite. The router constrained transfers to the specified input amounts during swap execution and checked the output minimum for the selected swap function. Those contract checks bounded acceptable execution; the routing algorithm determined how liquidity sources and intermediate tokens were combined.
Liquidity paths and transaction costs
Odos could combine paths through intermediate tokens and split trade flow across liquidity sources. This let the router consider combinations beyond a direct exchange through one pool. Gas costs also influenced optimization, so a larger gross token output wasn't sufficient to establish a better result after execution costs.
Router V2's compact entry points reduced the calldata needed to describe a swap. Its release described transaction-cost savings on layer 2 networks including Optimism, Arbitrum and Base. Compact and ordinary entry points called the same internal swap functions, preserving their execution checks while changing how the transaction data was encoded.
Single-swap and multi-swap functions
- Single-to-single execution
-
The internal
_swapfunction handled one input token and one output token. It collected positive slippage when output after any referral fee exceeded quoted output, with the excess forming router revenue. - Multi-token execution
-
The internal
_swapMultifunction supported atomic swaps with multiple inputs, outputs or both. It charged the configuredswapMultiFeeon each output amount instead of collecting positive slippage. Router V2 allowed its owner to set that percentage up to 0.5%; the ceiling doesn't establish the rate a particular deployment charged.
Multiple inputs or outputs made the multi-swap path relevant to portfolio rebalancing. A single-to-single function couldn't express that whole basket in one call. Atomic execution combined the operation into one transaction. The router compared the sum of each output amount after applicable fees multiplied by its supplied relative value against one minimum. It didn't enforce a separate minimum for each output token.
The product could also determine the execution path. Odos Zaps used
swapMulti
for liquidity operations. Odos's
December 6, 2023 Zaps announcement
stated a 0.01% multi-swap fee with no positive-slippage collection. That dated product rate doesn't establish the configured fee for every Router V2 deployment.
Referral fees were a separate addition
A registered referral code could track usage without adding a fee. When a code included a fee, Router V2 charged it on the swap outputs, sent 80% of the collected fee to the configured beneficiary and retained 20% as router revenue. A route's single-swap or multi-swap revenue treatment therefore didn't, on its own, describe every possible deduction.
Example: Execution below the quoted output
All amounts and assumed route conditions in this example are hypothetical. A Router V2 single-to-single swap has valid input authorization, an executable route on a supported network and no referral fee. Its quoted output is 286 units, its minimum output is 276 units and execution produces 281 units, all measured in the same output token.
The executed amount clears the minimum by
281 - 276 = 5
units. It satisfies the minimum-output requirement, although overall swap success still depends on the remaining contract checks. Execution is also 5 units below the quote, so there's no positive slippage for
_swap
to collect. With that executed amount unchanged, raising the minimum above 281 units would make the output fail the minimum requirement.
Hosted routing after the shutdown
Odos's July 23, 2026 wind-down announcement set July 27 for the app's move to read-only mode and July 30, 2026 for the end of company-operated services. The team also said development, support and maintenance would end. A published router implementation or an existing contract deployment doesn't establish that fresh Odos quotes, hosted transaction assembly or a maintained integration remain available.