Defillama Mcp Server

io.github.friendlygeorge由 GitHub 帳號 friendlygeorge 發布v1.0.0更新於 Oct 24, 2026

MCP server for DeFi Llama — free DeFi TVL, yields, stablecoins, bridges, DEX, and fee data for AI...

已驗證STDIO僅桌面金融資料與分析

概覽

AI 產生的概覽

本機 MCP 伺服器,讓助理以唯讀方式存取 DeFi Llama 的免費公開資料:協議 TVL、收益率、穩定幣、跨鏈橋、DEX 交易量與費用

可以做什麼
搜尋協議,並依協議或鏈讀取 TVL 明細,包含鏈上分布與歷史。依鏈、專案、最低 TVL 與資產類型篩選收益率與 APY 池。讀取穩定幣市值與排名、跨鏈橋 TVL 與交易量、DEX 交易量,以及協議費用與收入資料。結果以 Markdown 形式回傳,方便在對話中閱讀。
適用情境
適合在對話中進行 DeFi 研究:比較各鏈上的協議 TVL、篩選收益池、追蹤穩定幣流動性、監控跨鏈橋,或比較協議費用收入,不必開啟各種儀表板。
執行需求
透過 stdio 在本機執行,通常以 npx 從 npm 套件 defillama-mcp-server 啟動。需要 Node.js 18+,並能連線至 DeFi Llama 的公開 API 端點。不需要 API 金鑰或帳號。
安裝前請注意
唯讀:僅取得公開資料,不寫入、不修改,也不存取本機檔案。查詢內容與協議名稱會傳送至 DeFi Llama 的公開 API。較大的端點會被限流至約每秒兩次呼叫,部分查詢需一至兩秒。資料來自第三方,不應視為投資建議。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 Defillama Mcp Server,將其新增到工作區。
  2. 為需要使用其工具的對話啟用該服務。

Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。

其他 MCP 客戶端

參照 儲存庫 中的啟動說明。

README

DeFi Llama MCP Server

An MCP server for DeFi Llama — connect any MCP-compatible client to free DeFi protocol data.

[npm version] [npm downloads] [License: MIT] [MCP Compatible] [TypeScript] [Claude Desktop] [Cursor]

What is this?

An MCP (Model Context Protocol) server that gives AI assistants and agents access to DeFi Llama's free DeFi data API — protocol TVL, chain TVL, yield pools, stablecoins, cross-chain bridges, DEX volumes, and protocol fees — through natural language.

Use it with Claude Desktop, Cursor, Windsurf, Cline, Continue, or any MCP-compatible client to ask questions about DeFi protocols, track TVL movements, compare yields, and explore the on-chain economy.

Why use this?

  • No API key required — DeFi Llama is a free public API
  • 8 built-in tools — covers the most common DeFi data queries
  • Clean markdown output — results read naturally in chat
  • Rate-limited automatically — polite 500ms throttle across all endpoints

Tools

ToolDescription
search_protocolsSearch DeFi protocols by name — returns top results with TVL, chains, category
get_protocol_tvlGet detailed TVL breakdown for a specific protocol (chain distribution, history, description)
get_tvl_by_chainGet total TVL for a specific chain (Ethereum, Arbitrum, Base, Solana, etc.)
get_yieldsGet yield/APY data for lending pools and staking, filter by chain / project / min TVL
get_stablecoinsGet stablecoin market cap data and rankings
get_bridgesGet cross-chain bridge TVL and volume data
get_dex_volumesGet DEX trading volumes across chains
get_protocol_feesGet protocol fee and revenue data

Quick Start

1. Add to your MCP client

Add this to your MCP client config (e.g. claude_desktop_config.json):

json
{  "mcpServers": {    "defillama": {      "command": "npx",      "args": ["-y", "defillama-mcp-server"]    }  }}

That's it. npx downloads and runs it automatically. No API key, no install step.

2. Use it

Ask your AI assistant things like:

  • "What are the top DeFi protocols by TVL on Ethereum?"
  • "Search for Aave and show me the chain breakdown"
  • "What's the total TVL on Arbitrum?"
  • "Show me the highest yield stablecoin pools on Base with at least $10M TVL"
  • "List the top 5 stablecoins by market cap"
  • "Which bridges have the most TVL?"
  • "Show me DEX trading volumes for the last 24h"
  • "What are the protocols with the most fees?"

Example Output

search_protocols

Top 5 protocols matching "aave" (by TVL):
- **Aave** (AAVE) — TVL: $12.45B | Category: Lending | Chains: Ethereum, Arbitrum, Polygon, Base, Optimism, +6 | Slug: `aave`- **Aave v2** (AAVE) — TVL: $4.20B | Category: Lending | Chains: Ethereum, Polygon, Avalanche | Slug: `aave-v2`- **Aave v3** (AAVE) — TVL: $8.10B | Category: Lending | Chains: Ethereum, Arbitrum, Polygon, Base, Optimism | Slug: `aave-v3`

get_yields

Top 5 yield pools (chain: Ethereum | min TVL: $10.00M | min APY: 0%):
- **Lido** — stETH on Ethereum 🟢 | APY: 3.42% (3.42% base) | TVL: $23.45B- **Aave v3** — USDC on Ethereum 🟢 | APY: 4.85% (1.50% base + 3.35% reward) | TVL: $1.85B- **Compound v3** — USDC on Ethereum 🟢 | APY: 5.12% (3.20% base + 1.92% reward) | TVL: $890.45M

get_tvl_by_chain

Ethereum — Chain TVL
- **Total TVL:** $115.32B- **Native Token:** ETH- **CoinGecko ID:** ethereum
### Top Tokens by TVL- **ETH** (Ether): $67.23B- **USDC** (USD Coin): $4.12B- **USDT** (Tether): $3.45B- **WBTC** (Wrapped BTC): $2.89B- **WSTETH** (Wrapped stETH): $2.34B

Use Cases

DeFi Research

"Search for Aave and show me the chain breakdown" — find protocols, compare TVL across chains, and understand where value is concentrated. Works with any protocol in DeFi Llama's database of 3,000+ projects.

Yield Optimization

"Show me the highest yield stablecoin pools on Base with at least $10M TVL" — filter yield opportunities by chain, project, minimum TVL, and asset type. Find safe yields without hunting through dashboards.

Chain Analysis

"What's the total TVL on Arbitrum?" — get chain-level stats including top tokens by TVL. Useful for understanding where liquidity is flowing and which chains are growing.

Stablecoin Intelligence

"List the top 5 stablecoins by market cap" — track stablecoin market caps, circulating supply, and price deviations. Essential for understanding DeFi's dollar-denominated liquidity.

Cross-Chain Monitoring

"Which bridges have the most TVL?" — monitor cross-chain bridge activity and volume. Track which bridges are gaining or losing share.

Protocol Revenue Tracking

"What are the protocols with the most fees?" — analyze protocol fee generation and revenue. Useful for fundamental analysis and comparing protocol economics.

Security

  • No API key required — uses DeFi Llama's free public API. No authentication needed.
  • Read-only — only fetches public DeFi data from DeFi Llama's API. No writes, no mutations.
  • No local file access — does not read or write any files on your machine.
  • No shell access — does not execute commands or spawn processes.
  • Rate-limited — automatically caps requests to be a polite API citizen.
  • Open source — MIT licensed. Inspect the code at GitHub.

Troubleshooting

"Protocol not found" errors

Use search_protocols first to find the correct DeFi Llama slug. Protocol slugs are lowercase with hyphens (e.g. aave-v3, lido), not ticker symbols.

Slow responses

DeFi Llama's /protocols and /pools endpoints return multi-MB responses. The server throttles to ~2 calls/second. For large queries, results may take 1-2 seconds.

Server won't start

Make sure Node.js 18+ is installed: node --version. If using npx, ensure npm is up to date: npm install -g npm@latest.

MCP client can't connect

Verify the config path is correct. Claude Desktop uses ~/Library/Application Support/Claude/claude_desktop_config.json on macOS and %APPDATA%\Claude\claude_desktop_config.json on Windows. Restart the client after config changes.

Requirements

  • Node.js 18+
  • No API key needed (DeFi Llama is a free public API)

Rate Limits

DeFi Llama doesn't publish hard rate limits, but the server automatically throttles requests to ~2 calls/second (500ms minimum interval) to be a polite citizen. The /protocols and /pools endpoints are large (multi-MB), so the throttle also helps avoid unnecessary load.

Data Sources

  • Protocols & TVL: https://api.llama.fi
  • Yields: https://yields.llama.fi
  • Stablecoins: https://stablecoins.llama.fi

All endpoints are free and require no authentication. Full API documentation: https://defillama.com/docs/api

Development

bash
git clone https://github.com/nova/defillama-mcp-server.gitcd defillama-mcp-servernpm installnpm run buildnpm start

License

MIT

來源:README.md,提交 3771ae0

工具

0
SourceWeft 尚未在沙箱中啟動過該軟體包,因此其工具未知。

版本歷史

1
  1. v1.0.0最新Sep 16, 2026

評分

已滿足適用檢查項的 50%

該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。

  • 近 30 天內可連通25 分

    請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。

  • 已宣告認證方式10 分

    請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。

  • 已列出工具15 分

    請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。

  • 描述必需15 分
  • 圖示10 分
  • 文件15 分
  • 授權條款10 分