> ## Documentation Index
> Fetch the complete documentation index at: https://docs.li.fi/llms.txt
> Use this file to discover all available pages before exploring further.

# Available Tools

> Complete reference for all tools exposed by the LI.FI MCP Server

The LI.FI MCP Server exposes the following tools, organized by category. Each tool maps to a corresponding [LI.FI API](https://docs.li.fi/api-reference/introduction.md) endpoint.

## Token Information

### get-tokens

Retrieve all tokens supported by LI.FI. Use this to discover available tokens before requesting swaps.

| Parameter | Required | Description |
| - | - | - |
| `chains` | No | Comma-separated chain IDs (e.g., `"1,137"`) |
| `chainTypes` | No | Filter by chain type (e.g., `"EVM,SVM"`) |
| `minPriceUSD` | No | Minimum token price in USD |

### get-token

Get details about a specific token including price, decimals, and contract address.

| Parameter | Required | Description |
| - | - | - |
| `chain` | Yes | Chain ID or name (e.g., `"1"` or `"ethereum"`) |
| `token` | Yes | Token address or symbol (e.g., `"USDC"`) |

## Chain Information

### get-chains

List all supported blockchain networks. Returns chain IDs, names, RPC URLs, and block explorer links.

| Parameter | Required | Description |
| - | - | - |
| `chainTypes` | No | Filter by type (e.g., `"EVM"`) |

### get-chain-by-id

Look up a chain by its numeric ID.

| Parameter | Required | Description |
| - | - | - |
| `id` | Yes | Chain ID (e.g., `"1"` for Ethereum, `"137"` for Polygon) |

### get-chain-by-name

Look up a chain by name (case-insensitive).

| Parameter | Required | Description |
| - | - | - |
| `name` | Yes | Chain name (e.g., `"ethereum"`, `"polygon"`, `"arbitrum"`) |

## Quote & Swap

These are the primary tools for executing cross-chain transfers.

### get-quote

Get the best route for a swap. This is the **primary tool** for most use cases. It returns the optimal route, fees, estimated time, and a `transactionRequest` object ready for signing.

| Parameter | Required | Description |
| - | - | - |
| `fromChain` | Yes | Source chain ID or name |
| `toChain` | Yes | Destination chain ID or name |
| `fromToken` | Yes | Source token address or symbol |
| `toToken` | Yes | Destination token address or symbol |
| `fromAddress` | Yes | Sender wallet address |
| `fromAmount` | Yes | Amount in smallest unit (e.g., wei) |
| `toAddress` | No | Recipient address (defaults to `fromAddress`) |
| `slippage` | No | Max slippage as decimal (e.g., `"0.03"` for 3%) |
| `order` | No | Route preference: `RECOMMENDED`, `FASTEST`, `CHEAPEST`, `SAFEST` |
| `allowBridges` | No | Comma-separated bridge keys to include |
| `preferBridges` | No | Comma-separated bridge keys to prefer |
| `denyBridges` | No | Comma-separated bridge keys to exclude |
| `allowExchanges` | No | Comma-separated exchange keys to include |
| `preferExchanges` | No | Comma-separated exchange keys to prefer |
| `denyExchanges` | No | Comma-separated exchange keys to exclude |

> [!TIP]
>
> The response includes a `transactionRequest` object with `to`, `data`, `value`, `gasLimit`, and `chainId` fields, ready to sign and broadcast with any wallet.

### get-routes

Get multiple route options for comparison. Unlike `get-quote`, this returns several alternatives to choose from. Use with `get-step-transaction` to execute a specific route.

| Parameter | Required | Description |
| - | - | - |
| `fromChainId` | Yes | Source chain ID |
| `toChainId` | Yes | Destination chain ID |
| `fromTokenAddress` | Yes | Source token address |
| `toTokenAddress` | Yes | Destination token address |
| `fromAddress` | Yes | Sender wallet address |
| `fromAmount` | Yes | Amount in smallest unit |

### get-step-transaction

Convert a route step into an executable transaction.

| Parameter | Required | Description |
| - | - | - |
| `step` | Yes | Step object from a `get-routes` response |

### get-status

Track the progress of a cross-chain transfer.

| Parameter | Required | Description |
| - | - | - |
| `txHash` | Yes | Transaction hash from the source chain |
| `bridge` | No | Bridge name from the quote (speeds up lookup) |
| `fromChain` | No | Source chain ID |
| `toChain` | No | Destination chain ID |

### get-quote-with-calls

Get a quote with custom contract calls (Zaps). Execute complex DeFi operations like bridge + deposit/stake in a single transaction.

| Parameter | Required | Description |
| - | - | - |
| `fromChain` | Yes | Source chain ID or name |
| `toChain` | Yes | Destination chain ID or name |
| `fromToken` | Yes | Source token address or symbol |
| `toToken` | Yes | Destination token address or symbol |
| `fromAddress` | Yes | Sender wallet address |
| `fromAmount` | Yes | Amount in smallest unit |
| `contractCalls` | Yes | Array of contract call objects to execute after the swap |

## Discovery & Routing

### get-connections

Check available swap routes between chains. Use this to verify if a route exists before calling `get-quote`.

| Parameter | Required | Description |
| - | - | - |
| `fromChain` | Yes | Source chain ID |
| `toChain` | Yes | Destination chain ID |
| `fromToken` | No | Source token address |
| `toToken` | No | Destination token address |
| `chainTypes` | No | Filter by chain type |
| `allowBridges` | No | Filter by specific bridges |

### get-tools

List available bridges and DEXes. Returns both `key` values (for use in API calls) and `name` values (human-readable).

| Parameter | Required | Description |
| - | - | - |
| `chains` | No | Array of chain IDs to filter results |

> [!TIP]
>
> Use the `key` values returned by `get-tools` in `get-quote` with the `allowBridges` or `allowExchanges` parameters to filter routes to specific providers.

## Gas Information

### get-gas-prices

Get current gas prices for all supported chains. Returns fast, standard, and slow prices in gwei.

*No parameters required.*

### get-gas-suggestion

Get detailed gas parameters for a specific chain, including recommended gas amount in USD.

| Parameter | Required | Description |
| - | - | - |
| `chainId` | Yes | Chain ID to get gas suggestion for |

## Balance & Allowance Queries

### get-native-token-balance

Check the native token balance (ETH, MATIC, etc.) for a wallet address.

| Parameter | Required | Description |
| - | - | - |
| `chain` | Yes | Chain ID or name (e.g., `"1"` or `"ethereum"`) |
| `address` | Yes | Wallet address to check |
| `rpcUrl` | No | Custom RPC URL override |

### get-token-balance

Check an ERC20 token balance for a wallet address.

| Parameter | Required | Description |
| - | - | - |
| `chain` | Yes | Chain ID or name |
| `tokenAddress` | Yes | Token contract address |
| `walletAddress` | Yes | Wallet address to check |
| `rpcUrl` | No | Custom RPC URL override |

### get-allowance

Check token spending approval. Verify allowance before swaps. If insufficient, the user must approve tokens using their wallet before executing the transaction.

| Parameter | Required | Description |
| - | - | - |
| `chain` | Yes | Chain ID or name |
| `tokenAddress` | Yes | Token contract address |
| `ownerAddress` | Yes | Token owner's wallet address |
| `spenderAddress` | Yes | Spender address (use `estimate.approvalAddress` from the quote) |
| `rpcUrl` | No | Custom RPC URL override |

> [!WARNING]
>
> Always check allowance before executing ERC20 swaps. If the allowance is less than the swap amount, the transaction will fail. Native token transfers (ETH, MATIC, etc.) do not require approval.

## API Key & Health

### test-api-key

Verify that your API key is valid. Returns key status and rate limit information.

> [!NOTE]
>
> The API key must be provided via the `Authorization: Bearer` or `X-LiFi-Api-Key` header in your MCP client configuration.

### health-check

Check server health and version. Returns server status and version information.

*No parameters required.*

## Common Token Addresses

| Token | Chain | Address |
| - | - | - |
| ETH (native) | Ethereum (1) | `0x0000000000000000000000000000000000000000` |
| ETH (native) | Base (8453) | `0x0000000000000000000000000000000000000000` |
| USDC | Ethereum (1) | `0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48` |
| USDC | Base (8453) | `0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913` |
| USDC | Solana | `EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v` |
| SOL (native) | Solana | `11111111111111111111111111111111` |
| USDT | Ethereum (1) | `0xdAC17F958D2ee523a2206206994597C13D831ec7` |
| DAI | Ethereum (1) | `0x6B175474E89094C44Da98b954EedeAC495271d0F` |

> [!TIP]
>
> Use `get-token` with the symbol (e.g., `"USDC"`) to dynamically fetch the correct address for any chain instead of hardcoding addresses.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.