MCP server
by edkdev
DeFi Trading Agent enables autonomous trading, real-time analysis, and seamless execution across 17+ blockchains with ga
Turns AI assistants into autonomous crypto trading agents that can execute DeFi trades across 17+ blockchains with real-time market analysis and portfolio management. Supports gasless trading and memecoin scanning.
DeFi Trading Agent is a community-built MCP server published by edkdev that provides AI assistants with tools and capabilities via the Model Context Protocol. DeFi Trading Agent enables autonomous trading, real-time analysis, and seamless execution across 17+ blockchains with ga It is categorized under finance, developer tools.
You can install DeFi Trading Agent in your AI client of choice. Use the install panel on this page to get one-click setup for Cursor, Claude Desktop, VS Code, and other MCP-compatible clients. This server runs locally on your machine via the stdio transport.
MIT
DeFi Trading Agent is released under the MIT license. This is a permissive open-source license, meaning you can freely use, modify, and distribute the software.
Add new capabilities to Claude beyond text generation
Example
Access external data sources, execute code, interact with tools and services
Transform Claude from chatbot to action-taking agent
Provide Claude with access to relevant context and data
Example
Load project documentation, access knowledge bases, query databases
Get more accurate, context-aware responses
Automate multi-step workflows combining AI and external tools
Example
Research → Summarize → Create document → Send notification
Complete complex tasks end-to-end without manual steps
Share your MCP server with the developer community
I recommend DeFi Trading Agent for teams standardizing on MCP; the explainx.ai page compares cleanly with sibling servers.
We wired DeFi Trading Agent into a staging workspace; the listing’s GitHub and npm pointers saved time versus hunting across READMEs.
We evaluated DeFi Trading Agent against two servers with overlapping tools; this profile had the clearer scope statement.
Useful MCP listing: DeFi Trading Agent is the kind of server we cite when onboarding engineers to host + tool permissions.
I recommend DeFi Trading Agent for teams standardizing on MCP; the explainx.ai page compares cleanly with sibling servers.
DeFi Trading Agent reduced integration guesswork — categories and install configs on the listing matched the upstream repo.
DeFi Trading Agent has been reliable for tool-calling workflows; the MCP profile page is a good permalink for internal docs.
DeFi Trading Agent is a well-scoped MCP server in the explainx.ai directory — install snippets and categories matched our Claude Code setup.
According to our notes, DeFi Trading Agent benefits from clear Model Context Protocol framing — fewer ambiguous “AI plugin” claims.
Strong directory entry: DeFi Trading Agent surfaces stars and publisher context so we could sanity-check maintenance before adopting.
showing 1-10 of 43
Transform your AI assistant into an autonomous crypto trading agent with real-time market analysis, portfolio management, and seamless trade execution across 17+ blockchains.
Get me a quote for 0.1 eth to usdc on Base chain.
Get me a quote for 0.1 eth on ethereum chain and execute the swap.
"Scan for newly launched memecoins on Base with >$100K liquidity, pick one or two tokens and analyze the best entry opportunities"
Advanced Analysis Process:
get_new_pools to find tokens launched in last 24hExample AI Analysis:
"Found 3 promising new tokens:
🚀 $ROCKET (0x123...): 2M volume, bullish OHLCV pattern, 85% liquidity locked
📈 Entry: $0.0001 (current support level)
💰 Size: 2% portfolio allocation
🛡️ Stop: $0.000085 (-15%)
🎯 Target: $0.00015 (+50%)
Executing gasless swap now..."
"Monitor my portfolio and alert me if any position drops more than 15%"
Agent Actions:
npm install -g defi-trading-mcp
npx defi-trading-mcp --create-wallet
This generates a new wallet with private key and address for secure trading.
💰 Need crypto? See our guide: How to Load Crypto into Your Wallet
USER_PRIVATE_KEY: Your private key (for signing transactions locally, stays local, never transmitted)USER_ADDRESS: Your Ethereum wallet addressCOINGECKO_API_KEY: CoinGecko API key for market data (How to get your CoinGecko API key)ALCHEMY_API_KEY: Add an Alchemy API key to use your own RPCs, otherwise public rpcs will be used.Your ALCHEMY_API_KEY automatically enables premium RPCs for:
Step 1: Install the MCP
npm install -g defi-trading-mcp
Add to ~/.kiro/settings/mcp.json:
{
"mcpServers": {
"defi-trading": {
"command": "npx",
"args": ["defi-trading-mcp"],
"env": {
"USER_PRIVATE_KEY": "your_private_key_here",
"USER_ADDRESS": "0xYourWalletAddress",
"COINGECKO_API_KEY": "CG-your_coingecko_api_key",
"ALCHEMY_API_KEY": "your_alchemy_api_key"
}
}
}
}
Add the MCP to Claude Code using the command line:
Step 1: Install the MCP
npm install -g defi-trading-mcp
Step 2: Add to Claude Code - Replace the placeholders with your environment variables
For macOS/Linux/WSL:
claude mcp add defi-trading \
-e USER_PRIVATE_KEY=your_private_key_here \
-e USER_ADDRESS=0xYourWalletAddress \
-e COINGECKO_API_KEY=CG-your_coingecko_api_key \
-e ALCHEMY_API_KEY=your_alchemy_api_key \
-- npx defi-trading-mcp
For Windows (native, not WSL):
claude mcp add defi-trading \
-e USER_PRIVATE_KEY=your_private_key_here \
-e USER_ADDRESS=0xYourWalletAddress \
-e COINGECKO_API_KEY=CG-your_coingecko_api_key \
-e ALCHEMY_API_KEY=your_alchemy_api_key \
-- cmd /c npx defi-trading-mcp
Windows Note: The
cmd /cwrapper is required on native Windows to prevent "Connection closed" errors when using npx.
Step 3: Verify the MCP is added
claude mcp list
Step 4: Update wallet details (if needed) If you need to update your private key or wallet address after initial setup:
# Remove existing configuration
claude mcp remove defi-trading
# Add back with updated wallet details
claude mcp add defi-trading \
-e USER_PRIVATE_KEY=your_new_private_key \
-e USER_ADDRESS=0xYourNewWalletAddress \
-e COINGECKO_API_KEY=CG-your_coingecko_api_key \
-e ALCHEMY_API_KEY=your_alchemy_api_key \
-- npx defi-trading-mcp
Step 5: Start using the trading agent Open Claude Code and start trading. Example Prompt:
"Check my portfolio across all chains and find trending memecoins on Base"
Step 1: Install the MCP
npm install -g defi-trading-mcp
Open Claude Desktop. Click the top left menu with the three dashes. Click Developer. Then click Open App Config File. Your config file will open. Then add the following.
{
"mcpServers": {
"defi-trading": {
"command": "npx",
"args": ["defi-trading-mcp"],
"env": {
"USER_PRIVATE_KEY": "your_private_key_here",
"USER_ADDRESS": "0xYourWalletAddress",
"COINGECKO_API_KEY": "CG-your_coingecko_api_key",
"ALCHEMY_API_KEY": "your_alchemy_api_key"
}
}
}
}
Quick Setup (2 Steps)
Step 1: Install the package
npm install -g defi-trading-mcp
Step 2: Add to Cursor (One-Click)
Click the button below to automatically configure the MCP in Cursor:
Important: The deeplink only configures Cursor - you must install the npm package first!
Manual Setup
Step 1: Install the MCP
npm install -g defi-trading-mcp
Step 2: Add to Cursor Configuration
{
"defi-trading": {
"command": "npx",
"args": ["defi-trading-mcp"],
"env": {
"USER_PRIVATE_KEY": "your_private_key_here",
"USER_ADDRESS": "0xYourWalletAddress",
"COINGECKO_API_KEY": "CG-your_coingecko_api_key",
"ALCHEMY_API_KEY": "your_alchemy_api_key"
}
}
}
Step 3: Configure Environment Variables
Replace the placeholder values with your actual credentials:
USER_PRIVATE_KEY: Your wallet's private keyUSER_ADDRESS: Your wallet addressCOINGECKO_API_KEY: Your CoinGecko API key (Get one here)ALCHEMY_API_KEY: Your Alchemy API key (optional)Step 4: Start Trading
Open Cursor and start using the DeFi Trading Agent:
"Get me a quote for 0.1 ETH to USDC on Base chain"
For other MCP clients like Github Copilot(mcp.json), Gemini Cli (settings.json), find equivalent file and use the same pattern with environment variables:
{
"mcpServers": {
"defi-trading": {
"command": "npx",
"args": ["defi-trading-mcp"],
"env": {
"USER_PRIVATE_KEY": "your_private_key_here",
"USER_ADDRESS": "0xYourWalletAddress",
"COINGECKO_API_KEY": "CG-your_coingecko_api_key",
"ALCHEMY_API_KEY": "your_alchemy_api_key"
}
}
}
}
get_portfolio_tokens - Multi-chain portfolio analysis with prices and metadataget_portfolio_balances - Fast balance checking across all chainsget_portfolio_transactions - Complete transaction history analysisget_trending_pools - Identify hot trading opportunities with volume metricsget_new_pools - Discover newly launched tokens and liquidity poolsget_pool_ohlcv - Technical analysis with OHLCV candlestick dataget_pool_trades - Analyze recent trading activity and whale movementsget_token_price - Real-time pricing with 24h change indicatorsget_token_data - Deep token research with metadata and social linksget_token_info - Comprehensive token analysis including descriptionssearch_pools - Find specific pools by token symbol or contract addressget_swap_price - Get best prices across all DEXesget_swap_quote - Get executable quotes with transaction dataexecute_swap - Execute trades with optimal routingget_supported_chains - List all 17+ supported blockchainsget_gasless_price - Get prices for gas-free tradesPrerequisites
Time Estimate
15-60 minutes depending on server complexity
Steps
Troubleshooting
✓ Do
✗ Don't
💡 Pro Tips
Architecture
Model Context Protocol standardizes how AI hosts (Claude, Cursor) communicate with external tools and data sources through server implementations.
Protocols
Compatibility
✓ Use when
Use when you need Claude to access external data, execute actions, or integrate with tools. Best for extending AI capabilities beyond conversation.
✗ Avoid when
Avoid when native integrations exist (use official APIs directly), for real-time critical systems, or when security/compliance requires zero external dependencies.