Graph Aave Mcp

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

AAVE V2/V3 lending & governance MCP — 7 chains via The Graph subgraphs

發布方自己的服務:Aave MCP

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

概覽

AI 產生的概覽

針對 Aave V2/V3/V4 的唯讀 MCP 伺服器,涵蓋 7 條鏈,提供 57 個工具查詢市場、部位、清算風險、治理與 V4 資料。

可以做什麼
  • 查詢支援的鏈、子圖 ID 與 GraphQL schema
  • 檢視借貸市場:儲備資產、TVL、存借利率、LTV、清算門檻與利率歷史
  • 查詢錢包部位、健康因子、價格衝擊模擬,以及跨鏈風險輪廓、風險警示與健康因子趨勢
  • 瀏覽協議事件:借款、存款、還款、清算、閃電貸與風險等級變化
  • 讀取治理提案與逐投票人明細
  • 查詢 Aave V4 的 hub、spoke、儲備、匯率、價格、使用者投資組合、活動、獎勵與兌換報價,以及 V4 hub 資金流、國庫事件與設定歷史
適用情境
適合讓助理直接回答 Aave 市場、錢包部位、清算風險或治理相關問題,不必自行撰寫 GraphQL,也適合跨鏈比較與 V2/V3/V4 利率對照。
執行需求
透過 npx 在本機執行(需 Node.js)。所有子圖與 Omnigraph 工具都需要 GRAPH_API_KEY;V4 Aave API 工具不需金鑰。選用的 ETHEREUM_RPC_URL 及各鏈 RPC 變數(BASE_、ARBITRUM_、POLYGON_、OPTIMISM_、AVALANCHE_)可改善兩個鏈上即時工具。另有 AAVE_V4_API_URL 等選用覆寫項。
安裝前請注意
GRAPH_API_KEY 是密鑰,會傳送給 The Graph 閘道,且多數工具都依賴它;免費額度為每月 10 萬次查詢。部分工具預設回傳量很大(以太坊上的 get_aave_reserves 約 2.8 萬 token),需用篩選參數縮小。原始 GraphQL 工具可對任意鏈執行任意查詢。所述工具皆為唯讀,不會簽署或送出交易。

安裝

在 SourceWeft 中

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

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

其他 MCP 客戶端

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

README

graph-aave-mcp

[npm version] [MCP Registry] [smithery badge] [License: MIT]

[圖片]

MCP server for AAVE V2, V3, and V4 — 57 tools across 17 Graph subgraphs + the Aave V4 API + V4 Omnigraph (for data the REST API doesn't expose).

Covers lending markets, user positions, health factors, cross-chain liquidation risk monitoring, liquidations, flash loans, governance, V4 hubs/spokes, exchange rates, swap quotes, rewards, and protocol history.

Published to the MCP Registry as io.github.PaulieB14/graph-aave-mcp

Three Data Sources

SourceVersionWhat it providesAuth
The Graph subgraphsV2/V311 subgraphs across 7 chains — reserves, positions, events, governanceGRAPH_API_KEY (free)
Liquidation Risk subgraphsV35 chains — real-time health factors, risk scores, risk alerts, protocol risk statsGRAPH_API_KEY (free)
Aave V4 APIV4Hubs, spokes, reserves, exchange rates, user positions, activities, swap quotes, rewardsNone needed
V4 Omnigraph subgraphV4Hub↔Spoke flow events, per-user risk-premium history, liquidation post-mortems, treasury/fee/deficit accounting, spoke config governance trailGRAPH_API_KEY (free)

Quick Start

bash
# Claude Codeclaude mcp add graph-aave -- npx -y graph-aave-mcp
# Set Graph API key for subgraph tools (V4 tools work without it)export GRAPH_API_KEY=your-key-here
# Optional but recommended: the two live on-chain tools read via RPC, and the# unconfigured public fallback is rate-limited or blocked on many networks.export ETHEREUM_RPC_URL=https://your-endpoint
Claude Desktop / Cursor config
json
{  "mcpServers": {    "graph-aave": {      "command": "npx",      "args": ["-y", "graph-aave-mcp"],      "env": {        "GRAPH_API_KEY": "your-api-key-here"      }    }  }}

Free Graph API key: thegraph.com/studio (100K queries/month free tier).

Hosted deployment (no install): Fronteir AI


V2/V3 Tools (The Graph Subgraphs)

15 tools + 1 raw query escape hatch. Requires GRAPH_API_KEY.

Response size. get_aave_reserves returns every active reserve by default — on Ethereum that is 67 reserves, ~28k tokens. Pass symbols: ["USDC"] for one asset (~675 tokens), compact: true for rates only, or limit to cap the rows. get_v4_reserves takes the same three options.

Discovery

ToolDescription
list_aave_chainsAll supported chains with subgraph IDs, versions, 30d query volumes
get_aave_schemaFull GraphQL schema introspection for any chain

Lending Markets

ToolDescription
get_aave_reservesAll active markets — TVL, supply/borrow APY, LTV, liquidation thresholds
get_aave_reserveDeep detail on one asset: lifetime stats, config, token addresses
get_reserve_rate_historyHistorical APY, utilization, TVL snapshots

User Positions

ToolDescription
get_aave_user_positionWallet's supplied/borrowed assets, collateral flags, e-mode
simulate_health_factorSimulate price changes on a user's health factor

Protocol Events

ToolDescription
get_recent_borrowsRecent borrows — filter by user or asset
get_recent_suppliesRecent supplies/deposits (auto-handles V2 vs V3 schema)
get_aave_repaysRecent repayments
get_aave_liquidationsRecent liquidations — filter by user or liquidator
get_aave_flash_loansRecent flash loans with fees

Governance

ToolDescription
get_governance_proposalsProposals with titles, states, vote counts
get_proposal_votesPer-voter breakdown by voting power

Advanced

ToolDescription
query_aave_subgraphRaw GraphQL — execute any query against any chain

Supported Chains (V2/V3)

ChainVersion30d Queries
EthereumV321.6M
BaseV35.6M
ArbitrumV35.6M
PolygonV32.0M
OptimismV31.8M
AvalancheV31.2M
EthereumV2701K
PolygonV2216K
AvalancheV2133K
FantomV3 (Messari)13K
EthereumGovernance V3486K

Liquidation Risk Tools (NEW)

8 tools powered by dedicated risk subgraphs across 5 chains. Requires GRAPH_API_KEY.

Real-time liquidation risk monitoring with health factors, risk scores (0–100), risk level classifications (safe/warning/danger/critical), and cross-chain risk summaries.

Risk Monitoring

ToolDescription
get_at_risk_positionsPositions at risk of liquidation — filter by risk level, sorted by risk score
get_user_risk_profileFull risk profile for a wallet — all positions with health factors and risk scores
get_protocol_risk_statsAggregate stats: total positions, danger/warning/critical counts
get_cross_chain_risk_summaryRisk overview across all 5 chains in one call

Risk Events

ToolDescription
get_risk_alertsRisk level transitions — when positions move between safe/warning/danger/critical
get_risk_liquidationsLiquidation events with collateral/debt assets, amounts, and tx hashes
get_health_factor_historyHealth factor trend over time for a specific wallet

Discovery

ToolDescription
list_risk_chainsAvailable liquidation risk chains with subgraph IDs and query volumes

Supported Chains (Liquidation Risk)

Chain30d QueriesSignal
Ethereum21.1K20.2K GRT
Arbitrum19.3K35.7K GRT
Base16.2K15.2K GRT
Polygon13.2K—
Optimism13.0K—

V4 Tools (Aave API)

17 tools powered by api.v4.aave.com/graphql. No API key needed. (api.aave.com/graphql is an alias for the same schema; override either with AAVE_V4_API_URL.)

Note: the V4 Omnigraph tools (next section) cover gaps the REST API doesn't expose and require GRAPH_API_KEY. The 16 tools listed below remain key-free.

Liquidity Model

ToolDescription
get_v4_hubsLiquidity hubs (Core, Plus, Prime) with TVL and utilization
get_v4_spokesCross-chain spokes (Main, Bluechip, Kelp, Lido, Ethena, EtherFi, Forex, Gold, Lombard)
get_v4_reservesPer-spoke reserves with supply/borrow APYs, risk params, caps
get_v4_chainsSupported V4 chains
get_v4_assetCross-hub asset summary with average APYs and price
get_v4_exchange_rateAny token price via Chainlink oracles (ERC-20, native, or fiat)
get_v4_asset_price_historyHistorical token prices
get_v4_protocol_historyTotal deposits/borrows over time

User Data

ToolDescription
get_v4_user_positionsCross-chain positions — health factor, collateral, debt, borrowing power
get_v4_user_summaryAggregated portfolio: total positions, net balance, net APY
get_v4_user_suppliesSupply positions with principal and interest
get_v4_user_borrowsBorrow positions with debt breakdown
get_v4_user_balancesCross-chain token holdings with best APYs per token
get_v4_user_activitiesTransaction history: supplies, borrows, repays, liquidations, swaps
get_v4_claimable_rewardsClaimable Merkl and points rewards
get_v4_swap_quoteRead-only swap pricing via CoW Protocol (MEV-protected)

V4 Omnigraph Tools (subgraph — fills gaps the Aave API doesn't expose)

5 tools powered by the aave-v-4 subgraph (QmcKrCRSPrMABEfQjyPF6DqhbY7zzcEj6h5QxQmKLcHFSs). Requires GRAPH_API_KEY (the same free key used by V2/V3 subgraph tools).

These cover what api.aave.com/graphql structurally can't return: Hub↔Spoke flow events, per-user risk-premium trajectories, liquidation post-mortems with full premium-delta context, treasury/fee/deficit accounting, and governance-trail snapshots.

ToolDescription
get_v4_hub_flowsHub↔Spoke routing events (Add, Remove, Draw, Restore, RefreshPremium, ReportDeficit, TransferShares) with AaveKit-joined spoke names and asset symbols
get_v4_user_risk_trajectoryPer-user risk-premium snapshot history — every RefreshPremium event for a user, plus the latest premium and the spoke it was set on
get_v4_liquidation_postmortemFull liquidation event by tx hash or user — collateral/debt amounts, liquidator, premium-share / offset-ray / restored-premium deltas
get_v4_treasury_flowsMerged stream of FeeMint / Sweep / Reclaim / DeficitEliminated events ordered by block desc, optionally filtered by hub (Core/Plus/Prime) and time window
get_v4_spoke_config_historySpoke liquidation-config governance trail — current and historical targetHealthFactor, healthFactorForMaxBonus, liquidationBonusFactor per spoke

V4 Subgraph Tools — Base (Coinbase tokenized stocks) + Ethereum

6 network-aware tools backed by the Aave V4 subgraph. Default network: "base" — the Coinbase Stocks hub on Base (subgraph 9x1tg7KX3RXspnK7R1mahAZsM5gTmFhLrmJSbkoBsDdq). Pass network: "ethereum" for Core/Plus/Prime. Requires GRAPH_API_KEY.

ToolDescription
get_v4_recent_liquidationsLiquidations newest-first, filter by liquidator / user / sinceHours; collateral seized, debt restored, shares, premium deltas, per-liquidator counts
get_v4_hub_assetsPer-asset borrow rate %, liquidity fee %, accrued protocol fees, fee receiver, IR strategy
get_v4_config_changesHub↔spoke cap snapshots, reserve config snapshots, liquidation-config snapshots, position-manager whitelist (optional spoke)
get_v4_hub_daily_flowsDaily supplied/withdrawn/borrowed/repaid/deficit per hub asset, optional raw flow events
get_v4_user_activityUser risk premium + history, liquidations suffered, supply/withdraw/borrow/repay/collateral activity
get_v4_treasury_eventsMerged FeeMint / Sweep / Reclaim / DeficitEliminated / ReportDeficit stream

Example: "Who's liquidating tokenized stocks on Aave V4 Base?" → get_v4_recent_liquidations. "What's the USDC borrow rate and fees on the Base stocks hub?" → get_v4_hub_assets (≈2.1%, 10% liquidity fee).

V4 Architecture

Hubs (Core, Plus, Prime)  └── Assets (WETH, USDC, GHO, cbBTC, etc.)       └── Spokes (Main, Bluechip, Kelp, Lido, Ethena, ...)            └── Reserves (per-spoke lending markets)                 └── User Positions (health factor, collateral, debt)

V4 enables cross-chain lending: supply on one spoke, borrow on another. Hubs aggregate liquidity across spokes.


Guided Prompts

7 pre-built workflows that guide agents through multi-step analysis:

PromptDescription
analyze_aave_userFull wallet analysis: positions, health factor, liquidation risk
aave_chain_overviewProtocol overview: top markets, rates, recent activity
compare_aave_ratesCompare APY for one asset across all chains
aave_liquidation_analysisLiquidation patterns, top liquidators, at-risk markets
aave_governance_overviewRecent proposals, voting results, active decisions
aave_full_stack_analysisCross-version comparison: V2 vs V3 vs V4 rates and positions
cross_chain_risk_monitorNEW — Cross-chain liquidation risk: riskiest positions, alerts, protocol health

Example Questions

Liquidation Risk (new):

  • "Which Aave positions on Arbitrum are closest to liquidation?"
  • "Give me a cross-chain risk dashboard — which network has the most at-risk positions?"
  • "Is wallet 0x... at risk of liquidation on any chain?"
  • "Show me recent risk alerts — which positions just became critical?"
  • "How has this wallet's health factor changed over time on Base?"

V4:

  • "What are the Aave V4 hubs and their utilization?"
  • "Show me V4 reserves with the highest supply APY"
  • "What's the current ETH price on Aave V4?"
  • "Compare V3 vs V4 USDC supply rates"
  • "What spokes does Aave V4 have on Ethereum?"

V2/V3:

  • "What are the top AAVE markets on Ethereum by TVL?"
  • "Compare WETH borrow rates across all V3 chains"
  • "Analyze the AAVE position for wallet 0x..."
  • "If ETH drops 30%, will address 0x... get liquidated?"
  • "Show me the last 20 liquidations on Ethereum"
  • "What AAVE governance proposals are active?"

Development

bash
git clone https://github.com/PaulieB14/graph-aave-mcp.gitcd graph-aave-mcpnpm installnpm run buildGRAPH_API_KEY=your-key node build/index.js

Tests

bash
npm test                                     # V4 tools onlyGRAPH_API_KEY=... ETHEREUM_RPC_URL=... npm test   # everything

test/smoke.mjs starts the server over stdio and calls every registered tool, failing if any returns an error or an unexpectedly empty collection. Tools whose backend is unavailable in the current environment (no Graph key, no reachable RPC) are skipped rather than failed, so the suite is meaningful without credentials and thorough with them.

It exists because get_v4_hub_flows shipped pointing at an undeployed subgraph and nobody noticed: Graph Studio answers a missing subgraph with HTTP 200 and {"message":"Not found"}, the client only checked for a GraphQL errors key, and the tool returned flows: [] — indistinguishable from "no activity on chain". Every backend call now fails loudly instead.

Environment variables

VariableNeeded forNotes
GRAPH_API_KEYall subgraph + Omnigraph toolsFree key. V4 AaveKit tools work without it.
ETHEREUM_RPC_URL (and BASE_, ARBITRUM_, POLYGON_, OPTIMISM_, AVALANCHE_)the two live on-chain toolsOptional but recommended — the unconfigured public fallback is rate-limited or blocked on many networks.
AAVE_V4_API_URLV4 AaveKit toolsDefaults to https://api.v4.aave.com/graphql.
AAVE_V4_OMNIGRAPH_DEPLOYMENT_IDOmnigraph toolsDefaults to the decentralized-network deployment.
AAVE_V4_BASE_SUBGRAPH_IDV4 subgraph tools (network: base)Defaults to 9x1tg7KX3RXspnK7R1mahAZsM5gTmFhLrmJSbkoBsDdq.
AAVE_V4_OMNIGRAPH_URLOmnigraph toolsSet only to bypass the gateway for a self-hosted/Studio deployment.

License

MIT

來源:README.md,提交 64a8167

工具

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

版本歷史

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

評分

已滿足適用檢查項的 50%

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

  • 近 30 天內可連通25 分

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

  • 已宣告認證方式10 分

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

  • 已列出工具15 分

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

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

其他 Aave 整合