Quote any token pair (Polygon, Base, Ethereum; aggregator)
blazar_any_quoteQuote ANY token pair on Polygon (default), Base or Ethereum (chain param; symbol from the chain's curated or KyberSwap verified list, or any 0x address) through KyberSwap and LI.FI (same-chain only, compared; best output wins), with Velora (ParaSwap) as automatic fallback. compared[] shows which aggregators answered. Covers Uniswap V3/V4, QuickSwap V3, Aerodrome and 100+ venues. Returns amountOut, USD in/out, usdLossBps, gas, venues and the router. Use for non-BZB pairs such as USDC->WETH; for BZB or BBY use blazar_quote (fee router, trading rewards). Read-only; quotes cached ~8 s.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"tokenIn": "<tokenIn>",
"tokenOut": "<tokenOut>",
"amount": "<amount>"
},
"name": "blazar_any_quote"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| chain | No | Chain: "polygon" (default, chain 137), "base" (8453) or "ethereum" (1). BZB / BlazarSwap tools are Polygon only. | |
| amount | Yes | Amount of tokenIn in HUMAN units, not wei: "1.5" = 1.5 POL, "250" = 250 BZB. Set amountIsBaseUnits=true to pass wei/base units instead. | |
| tokenIn | Yes | Token to sell: a symbol (USDC, WETH, AAVE, LINK...; resolved only via the chain's curated list or an exact unique KyberSwap-verified match) or any 0x token address on the chosen chain. Native coin: "POL" on Polygon, "ETH" on Base / Ethereum. | |
| provider | No | auto (default): KyberSwap and LI.FI compared, best output wins; Velora as fallback. Same-chain swaps only. | |
| tokenOut | Yes | Token to buy: a symbol (USDC, WETH, AAVE, LINK...; resolved only via the chain's curated list or an exact unique KyberSwap-verified match) or any 0x token address on the chosen chain. Native coin: "POL" on Polygon, "ETH" on Base / Ethereum. | |
| amountIsBaseUnits | No | If true, amount is in base units (wei for 18-decimal tokens; 6 decimals for USDC). Default false. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| chain | No | ||
| route | No | ||
| cached | No | ||
| gasUsd | No | ||
| router | No | ||
| venues | No | ||
| chainId | No | ||
| spender | No | ||
| summary | No | ||
| tokenIn | No | ||
| amountIn | No | ||
| compared | No | ||
| gasUnits | No | ||
| provider | No | ||
| quotedAt | No | ||
| tokenOut | No | ||
| warnings | No | ||
| amountOut | No | ||
| routeGuide | No | ||
| usdLossBps | No | ||
| amountInUsd | No | ||
| amountOutUsd | No | ||
| tokenInSource | No | ||
| tokenOutSource | No | ||
| rewardsEligible | No | ||
| amountInFormatted | No | ||
| amountOutFormatted | No | ||
| quoteMaxAgeSeconds | No |