Give Your AI Agent DeFi Superpowers: Introducing the LeoKit MCP Server
LeoKit's MCP server gives AI agents like Claude the ability to execute cross-chain DeFi swaps across 30+ blockchains. One npm command, five tools, 0.10% fees, non-custodial. Here's how it works and how to get started in 60 seconds.
Category: product 8 min readWhat if you could tell Claude to swap your ETH for USDC on the cheapest route across six DEX protocols — and it just worked? No dApp hopping, no bridge hunting, no manual route optimization. Just a sentence.
That's exactly what the LeoKit MCP server does. It's a production-grade MCP server that gives AI agents like Claude the ability to execute cross-chain DeFi swaps across 30+ blockchains. One npm command to install, five tools to control everything, and a 0.10% swap fee that undercuts every aggregator I know of.
If you just want to get started:
npx -y @leodex/leokit-mcp
For those who want the full picture — what MCP is, how it works, what you can build with it — keep reading.
flowchart LR
subgraph before ["Without MCP"]
direction TB
B1["Find DEX"] --> B2["Compare routes"]
B2 --> B3["Switch chains"]
B3 --> B4["Approve tokens"]
B4 --> B5["Execute swap"]
end before ~~~ after
subgraph after ["With LeoKit MCP"]
direction TB
A1["Tell your AI what you want"] --> A2["Approve & sign"]
end
What Is an MCP Server (and Why Does DeFi Need One)?
The Model Context Protocol (MCP) is an open standard originally developed by Anthropic and now governed by the Agentic AI Foundation under the Linux Foundation. It standardizes how AI assistants connect to external tools and data sources — think of it as a USB-C port for AI capabilities.
Here's the problem: AI assistants like Claude and ChatGPT are incredibly capable at reasoning, but they can't natively interact with blockchains. They can't fetch live token prices, execute swaps, check wallet balances, or track transactions. They're blind to DeFi.
An MCP server solves this by giving AI agents structured, safe access to real-world capabilities. A DeFi MCP server specifically gives AI agents the ability to trade crypto. LeoKit's MCP server is, as far as I know, the only production-grade option covering 30+ blockchains via 6 DEX protocols (THORChain, MAYAChain, Chainflip, Relay, NEAR Intents, and Rango).
With it, your AI assistant can:
- Get real-time swap quotes across 30+ chains
- Generate unsigned transactions for cross-chain swaps
- Track swap status from deposit to delivery
- Check wallet balances across multiple blockchains
- Search 20,000+ supported tokens
How It Works: From Natural Language to On-Chain Transaction
Let me walk through a real swap flow. Say you open Claude Desktop and type:
> "Swap 0.5 ETH to USDC on the best route"
Step 1 — You ask. Claude receives your natural language request and recognizes it as a swap intent. It calls the leokit_get_quote tool with the right parameters.
Step 2 — LeoKit quotes. Our server queries all 6 DEX protocols simultaneously — THORChain, MAYAChain, Chainflip, Relay, NEAR Intents, and Rango — across 107+ DEXes. It returns the cheapest route, showing you the expected output amount, network fees, protocol fees, and estimated completion time.
Step 3 — You review. Claude presents the quote in plain language. You see exactly how much USDC you'll receive, what the fee breakdown looks like, and which route was selected. Nothing happens until you approve.
Step 4 — You sign. When you confirm, Claude calls leokit_create_deposit to generate an unsigned transaction. Your private keys never touch our servers. You sign in your own wallet.
Here's what the actual tool call flow looks like:
You: "Swap 0.5 ETH to USDC, best route"Claude → leokit_get_quote({
from_asset: "ETH.ETH",
to_asset: "ETH.USDC-0xA0b8...",
amount: "500000000000000000"
})
LeoKit → Returns: Best route via Chainflip
Output: 1,247.83 USDC
Fee: 0.10% ($0.62)
Time: ~3 minutes
Claude: "I found a route via Chainflip. You'll receive
1,247.83 USDC for 0.5 ETH with a $0.62 fee.
Want me to proceed?"
You: "Yes"
Claude → leokit_create_deposit({...})
→ Returns unsigned transaction for your wallet
flowchart LR
subgraph yours ["Your Device"]
You["You"]
W["Your Wallet"]
end subgraph cloud ["Cloud"]
AI["AI + LeoKit"]
end
You -->|"Swap 0.5 ETH to USDC"| AI
AI -->|Unsigned transaction| W
W -->|You sign & send| BC["Blockchain"]
> Your Keys Stay With You. LeoKit is fully non-custodial. We only generate unsigned transactions — raw transaction data that does nothing until you sign it with your own private key, in your own wallet. Your keys never leave your device. Period.
What Can You Build With It?
The MCP server is a building block. Here are some real things developers are building or can build with it: AI-Powered Portfolio Rebalancing. Tell your AI assistant: "Rebalance my portfolio to 50% BTC, 30% ETH, 20% stables across all my wallets." It checks your balances, calculates the trades needed, quotes the optimal routes, and presents you with a batch of unsigned transactions to approve. Cross-Chain Arbitrage Detection. Your AI agent monitors price discrepancies for the same token across different chains and protocols. When it spots an opportunity, it presents it to you with the exact route and expected profit — no execution without your approval. Natural Language Token Swaps. Build an AI-powered app where end users swap tokens by describing what they want: "Move half my SOL to ETH." The AI handles asset identification, chain routing, and transaction creation behind the scenes. Multi-Chain Balance Dashboard. "Show me all my balances across Ethereum, Solana, and Cosmos." One query, one answer. No more switching between block explorers or connecting to five different dApps. DeFi Research Assistant. Before making any trades, ask your AI to compare available routes, check fee structures, and analyze liquidity across protocols. It pulls live data from LeoKit's aggregator and gives you an informed summary.
Getting Started in 60 Seconds
Step 1 — Get Your Free API Key
Head to dash.leokit.dev and create a free account. No credit card required, no subscription. Copy your API key from the dashboard.
Step 2 — Install the MCP Server
You have two options: Option A: Local install via npx (recommended)
npx -y @leodex/leokit-mcp
This downloads and runs the MCP server locally. Your AI client communicates with it over stdio — everything stays on your machine. Option B: Remote HTTP transport (no install needed)
If you don't want to install anything, point your AI client to our hosted endpoint:
{
"mcpServers": {
"leokit": {
"url": "https://mcp.leokit.dev/mcp",
"headers": {
"Api-Key": "YOUR_API_KEY"
}
}
}
}
Step 3 — Configure Your AI Client
Add LeoKit to your Claude Desktop configuration:
macOS/Linux: ~/.claude/claude_desktop_config.json
Windows: %APPDATA%\Claude\claude_desktop_config.json
{
"mcpServers": {
"leokit": {
"command": "npx",
"args": ["-y", "@leodex/leokit-mcp"],
"env": {
"LEOKIT_API_KEY": "YOUR_API_KEY"
}
}
}
}
Restart Claude Desktop and you're live.
Step 4 — Try Your First Swap
Open Claude and try these starter prompts:
- "Get me a quote for swapping 1 ETH to USDC"
- "What tokens are available on Arbitrum?"
- "Show my wallet balances across all chains"
- "Compare swap routes for 0.1 BTC to ETH"
Under the Hood: 5 MCP Tools
LeoKit's MCP server exposes five tools that cover the full DeFi lifecycle:
| Tool | What It Does | Example Prompt |
|------|-------------|----------------|
| leokit_get_quote | Finds the cheapest swap route across 6 DEX protocols and 30+ chains | "Get me a quote for swapping 1 ETH to USDC" |
| leokit_create_deposit | Generates an unsigned swap transaction ready for signing | "Create a swap for 0.5 BTC to ETH" |
| leokit_check_status | Tracks a swap from deposit detection to final delivery | "Check the status of my last swap" |
| leokit_get_assets | Searches 20,000+ supported tokens across all chains | "What tokens are on Arbitrum?" |
| leokit_get_balances | Checks wallet balances across multiple blockchains | "Show my balances on ETH and SOL" |
Each tool is designed to map naturally to how people talk about DeFi. You don't need to know asset identifiers or chain IDs — the AI figures that out from your natural language request.
How LeoKit's MCP Server Compares
There are other MCP servers touching crypto, but most are limited to a single chain or rely on centralized exchanges. Here's how LeoKit stacks up:
| Feature | LeoKit MCP | Single-Chain Servers | CEX-Only Servers | Generic DeFi Tools | |---------|-----------|---------------------|-----------------|-------------------| | Chains | 30+ | 1–3 | N/A (centralized) | 5–10 | | DEX Protocols | 6 | 1 | N/A | 1–2 | | Tokens | 20,000+ | Varies | Exchange-listed only | Varies | | Swap Fee | 0.10% | Varies | 0.1–0.5% | 0.3%+ | | Non-Custodial | Yes | Varies | No | Varies | | Setup Time | 30 seconds | Minutes to hours | Minutes | Hours | | Remote Transport | Yes | Rarely | Sometimes | No | | Production Dashboard | Yes | No | Sometimes | No |
LeoKit is the only production-grade, cross-chain, non-custodial MCP server that offers both local stdio and remote HTTP transport. We built it this way because AI agents need flexibility — some developers want everything local, others want a hosted solution they can call from anywhere.
Supported Chains and Protocols
EVM Chains: Ethereum, Arbitrum, Avalanche, Base, BNB Chain, Polygon, Optimism, Fantom UTXO Chains: Bitcoin, Litecoin, Dogecoin, Bitcoin Cash, Dash, Zcash Cosmos Chains: THORChain, MAYAChain, Cosmos Hub, Kujira Other: Solana, NEAR, XRP, Tron, Cardano, Polkadot Protocols: THORChain, MAYAChain, Chainflip, Relay, NEAR Intents, RangoNew chains and protocols get added regularly. Use leokit_get_assets to see the latest supported tokens and chains at any time.
Pricing — Transparent and Simple
LeoKit is free to integrate. No subscription, no upfront cost, no credit card at signup.
When end users execute swaps, the fee is 0.10% per swap (10 basis points). That's it. For context, typical DEX aggregator fees range from 0.3% to 1.7%, so LeoKit's fee is roughly 3x–17x lower than the industry average.
For B2B partners building on top of LeoKit, swap fees are customizable between 0 and 1000 basis points via the dashboard. You set your own margin.
Frequently Asked Questions
What is the LeoKit MCP Server?LeoKit's MCP server is a production-grade tool that gives AI assistants like Claude the ability to execute cross-chain token swaps across 30+ blockchains. It implements the Model Context Protocol standard and aggregates liquidity from 6 DEX protocols — THORChain, MAYAChain, Chainflip, Relay, NEAR Intents, and Rango — covering 20,000+ tokens. Is the LeoKit MCP Server free?
Yes. LeoKit is free to integrate with no subscription or credit card required. When end users swap tokens, the fee is just 0.10% (10 basis points) — the lowest in DeFi. Developers pay nothing to build with it. Does the AI agent have access to my private keys?
Never. LeoKit only generates unsigned transactions — raw transaction data that requires your private key to execute. Your keys never leave your wallet. The AI assistant can prepare and present transactions, but it cannot sign or submit them without you. Which AI clients are supported?
Any MCP-compatible AI client works with LeoKit. This includes Claude Desktop, Claude Code, Cursor, Windsurf, and Cline. Both local (stdio) and remote (HTTP) transport modes are supported. What blockchains are supported?
Over 30 blockchains including Bitcoin, Ethereum, Solana, Cosmos, Arbitrum, Avalanche, Base, BNB Chain, Polygon, Optimism, and more. Liquidity is aggregated across 6 DEX protocols and 107+ individual DEXes. How is this different from using a DEX directly?
Instead of manually connecting to a dApp, selecting tokens, comparing routes, and switching chains, you describe what you want in plain English. Your AI assistant handles asset identification, route optimization across all available protocols, and transaction preparation. You just review and sign.
The DeFi + AI intersection is early. Most crypto MCP servers today are fragmented — limited to one chain, one protocol, or one centralized exchange. We built LeoKit's MCP server to be the cross-chain layer that AI agents need to actually be useful in DeFi.
Try it now: get your free API key at dash.leokit.dev, check out the full docs, or explore the live demo on our MCP page.