Route Response Schema

When you call POST https://v2.api.squidrouter.com/v2/route, the API returns a route response containing the optimal path, estimated output, and (if quoteOnly is false) the transaction data needed for execution.

Top-Level Structure

{
  "route": {
    "estimate": { ... },           // Route pricing, actions, fees, and gas costs
    "transactionRequest": { ... }, // Transaction data for on-chain execution (empty when quoteOnly: true)
    "params": { ... },             // Echo of your original request parameters
    "quoteId": "string"            // Unique quote identifier — required for Squid Intents status tracking
  }
}

route.estimate

The estimate object contains all pricing information, the ordered list of actions, and cost breakdowns.

Field
Type
Description

actions

Action[]

Ordered array of steps the route will take (swaps, bridges, wraps)

fromAmount

string

Input amount in the token's smallest unit

toAmount

string

Estimated output amount in the token's smallest unit

toAmountMin

string

Minimum output after accounting for slippage

exchangeRate

string

Overall exchange rate between source and destination tokens

aggregatePriceImpact

string

Total price impact across all steps (e.g. "0.0", "-0.02")

fromAmountUSD

string

USD value of the input amount

toAmountUSD

string

USD value of the estimated output

toAmountMinUSD

string

USD value of the minimum output

aggregateSlippage

number

Total slippage percentage across the route

fromToken

Token

Full source token object

toToken

Token

Full destination token object

feeCosts

FeeCost[]

Breakdown of fees (bridging fees, boost fees)

gasCosts

GasCost[]

Breakdown of gas costs

estimatedRouteDuration

number

Estimated total time in seconds


Action Object

Each action represents one step in the route. Actions are executed in order, with stage: 0 for source chain actions and stage: 1 for destination chain actions.

Field
Type
Description

type

string

Type of action: "bridge", "swap", or "wrap"

chainType

string

Chain ecosystem (e.g. "evm", "cosmos")

data

object

Provider-specific data (varies by action type — see below)

fromChain

string

Chain ID where this action starts

toChain

string

Chain ID where this action ends

fromToken

Token

Input token for this step

toToken

Token

Output token for this step

fromAmount

string

Input amount for this step

toAmount

string

Estimated output for this step

toAmountMin

string

Minimum output after slippage for this step

exchangeRate

string

Exchange rate for this step

priceImpact

string

Price impact for this step

stage

number

0 = source chain, 1 = destination chain

provider

string

Provider name (e.g. "Axelar", "Uniswap V3", "Pancakeswap V3")

logoURI

string

Provider logo URL

description

string

Human-readable description (e.g. "Swap USDC to WETH")

estimatedDuration

number

(Bridges only) Estimated duration in seconds

Action Type: bridge

Cross-chain bridge step. The data object contains:

Action Type: swap

DEX swap step. The data object contains:

Action Type: wrap

Native token wrap or unwrap step. The data object contains:


route.transactionRequest

When quoteOnly: false, this object contains the transaction data needed for on-chain execution. The structure depends on the Transaction Type.

For EVM ON_CHAIN_EXECUTION transactions:

Field
Type
Description

routeType

string

Route type (e.g. "CALL_BRIDGE_CALL", "EVM_ONLY")

target

string

Contract address to call

data

string

Encoded calldata

value

string

Native token value to send (wei)

gasLimit

string

Recommended gas limit

gasPrice

string

Current gas price

maxFeePerGas

string

EIP-1559 max fee

maxPriorityFeePerGas

string

EIP-1559 priority fee

For DEPOSIT_ADDRESS_WITH_SIGNATURE transactions (Hedera):

Field
Type
Description

routeType

string

"DEPOSIT_ADDRESS_WITH_SIGNATURE"

depositAddress

string

Address to send funds to

signatureRequired

object

Contains orderHash that must be signed

When quoteOnly: true, transactionRequest is an empty object {}. This is useful for showing users estimated outputs before they commit to executing the swap.


route.params

An echo of your original request parameters, returned for reference:


FeeCost Object

Field
Type
Description

name

string

Fee name (e.g. "Gas receiver fee", "Boost fee")

description

string

Human-readable description

amount

string

Fee amount in token's smallest unit

amountUsd

string

Fee amount in USD

token

Token

Token used for the fee

gasLimit

string

Gas limit (if applicable)

gasMultiplier

number

Gas multiplier (if applicable)


GasCost Object

Field
Type
Description

type

string

Gas cost type (e.g. "executeCall")

token

Token

Token used for gas

amount

string

Gas cost in token's smallest unit

gasLimit

string

Gas limit

amountUsd

string

Gas cost in USD


Token Object

Token objects appear throughout the response (in estimate, actions, feeCosts, etc.):

Field
Type
Description

address

string

Token contract address

chainId

string

Chain ID

symbol

string

Token symbol (e.g. "USDC")

name

string

Full token name

decimals

number

Token decimal places

logoURI

string

Token logo URL

usdPrice

number

Current USD price

coingeckoId

string

CoinGecko identifier

type

string

Chain type (e.g. "evm")


Example: Native Token Swap

An ETH swap from Arbitrum → Base produces a multi-step route:

  1. Wrap (stage 0): Wrap ETH → WETH on Arbitrum

  2. Swap (stage 0): Swap WETH → USDC via Uniswap V3

  3. Swap (stage 0): Swap USDC → USDC.axl via Pancakeswap V3

  4. Bridge (stage 0→1): Bridge USDC.axl via Axelar to Base

  5. Swap (stage 1): Swap USDC.axl → USDC on Base

  6. Swap (stage 1): Swap USDC → WETH via Uniswap V3

  7. Unwrap (stage 1): Unwrap WETH → ETH on Base

Last updated