关于 Evmscope
Evmscope 是面向 AI Agent 开发者、交易者和研究者的 EVM 链数据工具,可通过命令行或 MCP 查询 7 条 EVM 链。它提供只读链上分析,涵盖价格、钱包、DeFi 与安全检查,无需 API 密钥或初始配置。
主要功能
- 01查询代币价格、余额与投资组合
- 02比较 Gas、获取兑换及跨链路线
- 03查看收益率、TVL 与巨鲸转账
- 04检查蜜罐风险并模拟交易
- 05查询 NFT、治理提案与区块信息
- 06命令行与 MCP 双模式,只读操作
适用场景
- 01为 AI Agent 增加实时链上数据查询
- 02从终端研究代币、钱包和 DeFi 协议
- 03兑换前比较报价或检查代币风险
MCP 相关
作为 MCP 服务,向 AI 客户端提供 7 条 EVM 链上的 26 种只读链上工具。无需 API 密钥即可连接使用。
配置
本地服务的配置在各客户端中通用,复制后粘贴到客户端的 MCP 配置文件即可。
工具
26收录的工具列表 · 更新于 3 周前
| 参数 | 类型 | 必填 | 说明 |
|---|---|---|---|
| token | string | 是 | 代币符号(ETH、USDC)或 contract address |
| chain | enum | 否 | EVM 链ethereum | polygon | arbitrum | base | optimism | avalanche | bsc |
详细介绍
evmscope
한국어 | 中文 | 日本語 | Español | Русский
EVM 区块链情报工具包。覆盖 7 条链的 26 个工具,可作为 CLI 或 MCP 服务使用。代币价格、Gas 费对比、兑换报价、收益率、蜜罐检测、跨链桥路由、交易模拟、NFT 查询、治理提案、投资组合追踪等。
为什么选择 evmscope?
Claude 和 GPT 等 AI Agent 无法访问实时区块链数据。询问“ETH 的价格是多少?”或“显示这个钱包的余额”,得到的只会是“我无法访问实时数据”。
evmscope 通过 MCP 协议让 AI Agent 直接使用 26 个链上工具,解决了这个问题——包括代币价格、钱包余额、DeFi 收益、巨鲸追踪、蜜罐检测等。无需 API 密钥,无需设置,连接即可使用。
适用对象
| 用户 | 使用场景 |
|---|---|
| AI Agent 开发者 | 作为 MCP 服务连接,为 AI 提供链上分析能力 |
| 加密货币交易者和研究人员 | 直接在终端查询代币、钱包和协议 |
| DeFi 用户 | 安全工具——蜜罐检测、授权状态检查、巨鲸追踪 |
功能
- 26 个工具 — 价格、Gas 费对比、兑换报价、收益率、蜜罐检测、跨链桥路由、交易模拟、事件日志、代币持有者、授权状态、TVL、巨鲸追踪、余额、代币信息、ENS、交易状态、交易解码、ABI 查询、地址识别、NFT 信息、NFT 元数据、治理提案、区块信息、代币转账、投资组合
- 7 条 EVM 链 — Ethereum、Polygon、Arbitrum、Base、Optimism、Avalanche、BSC
- 49 种内置代币 — ETH、USDC、USDT、WETH、LINK、UNI、AAVE、ARB、OP、PEPE 等
- 30+ 个带标签的地址 — 交易所、DeFi 协议、跨链桥、巨鲸钱包
- 零配置 — 无需 API 密钥。开箱即用,使用免费的公共 API
- 只读 — 不执行交易,资金损失风险为零
- 双模式 — CLI 用于直接在终端中使用,MCP 服务用于集成 AI Agent
快速开始
CLI
npx evmscope price ETH
npx evmscope gas
npx evmscope balance 0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045
npx evmscope portfolio 0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045
npx evmscope compare-gas
npx evmscope tvl Aave
npx evmscope swap ETH USDC 1.0
npx evmscope block latest
npx evmscope transfers 0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045
npx evmscope honeypot 0x...
运行 npx evmscope --help 查看全部 22 个命令。添加 --json 可输出原始 JSON。
MCP 服务
作为 MCP 服务启动(不带参数):
npx evmscope
Claude Code
claude mcp add evmscope -- npx -y evmscope
Claude Desktop
添加到 claude_desktop_config.json:
{
"mcpServers": {
"evmscope": {
"command": "npx",
"args": ["-y", "evmscope"]
}
}
}
Cursor
添加到 .cursor/mcp.json:
{
"mcpServers": {
"evmscope": {
"command": "npx",
"args": ["-y", "evmscope"]
}
}
}
工具
getTokenPrice
获取当前代币价格、24 小时涨跌幅、市值和交易量。
// Input
{ "token": "ETH", "chain": "ethereum" }
// Output
{
"success": true,
"data": {
"symbol": "ETH",
"name": "Ethereum",
"priceUsd": 1929.20,
"change24h": -2.34,
"marketCap": 232000000000,
"volume24h": 12500000000
}
}
getGasPrice
获取当前 Gas 价格,分为慢速/普通/快速档,并提供美元估算。
// Input
{ "chain": "ethereum" }
// Output
{
"success": true,
"data": {
"slow": { "maxFeePerGas": "18.5", "maxPriorityFeePerGas": "1.2", "estimatedCostUsd": 0.75 },
"normal": { "maxFeePerGas": "20.0", "maxPriorityFeePerGas": "1.5", "estimatedCostUsd": 0.81 },
"fast": { "maxFeePerGas": "22.5", "maxPriorityFeePerGas": "2.25", "estimatedCostUsd": 0.91 },
"baseFee": "17.3",
"lastBlock": 19234567
}
}
getBalance
获取原生代币和 ERC-20 代币余额及其美元价值。
// Input
{ "address": "0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045", "chain": "ethereum" }
// Output
{
"success": true,
"data": {
"address": "0xd8dA...",
"nativeBalance": { "symbol": "ETH", "balanceFormatted": "1.234", "valueUsd": 2382.50 },
"tokenBalances": [
{ "symbol": "USDC", "balanceFormatted": "1.0", "valueUsd": 1.00 }
],
"totalValueUsd": 2383.50
}
}
getTokenInfo
获取 ERC-20 代币元数据(名称、符号、小数位数、总供应量)。
// Input
{ "token": "USDC", "chain": "ethereum" }
// Output
{
"success": true,
"data": {
"address": "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48",
"name": "USD Coin",
"symbol": "USDC",
"decimals": 6,
"totalSupply": "26000000000"
}
}
resolveENS
解析 ENS 名称以获取地址,或反向解析地址以获取 ENS 名称(仅限 Ethereum 主网)。
// Input
{ "nameOrAddress": "vitalik.eth" }
// Output
{
"success": true,
"data": {
"name": "vitalik.eth",
"address": "0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045",
"avatar": "https://...",
"resolved": "name_to_address"
}
}
getTxStatus
获取交易状态、收据、确认数和 Gas 用量。
// Input
{ "txHash": "0xabc...def", "chain": "ethereum" }
// Output
{
"success": true,
"data": {
"hash": "0xabc...def",
"status": "success",
"blockNumber": 19234567,
"confirmations": 42,
"from": "0x1234...",
"to": "0x5678...",
"value": "1.5",
"gasUsed": "21000",
"effectiveGasPrice": "20.0",
"timestamp": 1741521600
}
}
decodeTx
将交易解码为结构化 JSON——函数名称、参数、事件日志。
// Input
{ "txHash": "0xabc...def", "chain": "ethereum" }
// Output
{
"success": true,
"data": {
"hash": "0xabc...def",
"from": "0x1234...",
"to": "0x7a250d5630B4cF539739dF2C5dAcb4c659F2488D",
"value": "1.0",
"status": "success",
"function": {
"name": "swapExactETHForTokens",
"signature": "swapExactETHForTokens(uint256,address[],address,uint256)",
"args": { "amountOutMin": "1000000", "path": ["0xC02a...", "0xA0b8..."] }
},
"events": [
{ "name": "Transfer", "address": "0xA0b8...", "args": { "from": "0x...", "to": "0x...", "value": "1000000" } }
],
"gasUsed": "150000",
"gasPrice": "20.0"
}
}
getContractABI
查询已验证合约的 ABI(先查 Etherscan,失败时回退至 Sourcify)。
// Input
{ "address": "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48", "chain": "ethereum" }
// Output
{
"success": true,
"data": {
"address": "0xA0b8...",
"abi": [...],
"source": "etherscan",
"contractName": "FiatTokenV2_2",
"isContract": true,
"functionCount": 42,
"eventCount": 8
}
}
identifyAddress
识别地址——交易所、DeFi 协议、巨鲸钱包或 EOA。
// Input
{ "address": "0x28C6c06298d514Db089934071355E5743bf21d60", "chain": "ethereum" }
// Output
{
"success": true,
"data": {
"address": "0x28C6...",
"label": "Binance Hot Wallet",
"category": "exchange",
"protocol": null,
"isContract": false,
"tags": ["cex", "binance"]
}
}
compareGas
一次性对比全部 7 条 EVM 链的 Gas 费,并按费用从低到高排序。
// Input
{}
// Output
{
"success": true,
"data": {
"chains": [
{ "chain": "base", "baseFeeGwei": "0.01", "estimatedCostUsd": 0.0001 },
{ "chain": "arbitrum", "baseFeeGwei": "0.1", "estimatedCostUsd": 0.004 },
{ "chain": "optimism", "baseFeeGwei": "0.05", "estimatedCostUsd": 0.002 },
{ "chain": "polygon", "baseFeeGwei": "30.0", "estimatedCostUsd": 0.01 },
{ "chain": "ethereum", "baseFeeGwei": "20.0", "estimatedCostUsd": 0.81 }
],
"cheapest": "base",
"mostExpensive": "ethereum"
}
}
getApprovalStatus
检查 ERC-20 代币的授权(allowance)状态。自动检查主要 DeFi 协议,并评估风险等级。
// Input
{ "owner": "0xd8dA...", "token": "USDC", "chain": "ethereum" }
// Output
{
"success": true,
"data": {
"owner": "0xd8dA...",
"token": "USDC",
"tokenAddress": "0xA0b8...",
"approvals": [
{ "protocol": "Uniswap V3 (router)", "spender": "0xE592...", "allowance": "unlimited", "isUnlimited": true }
],
"riskLevel": "moderate"
}
}
getProtocolTVL
通过 DefiLlama 获取 DeFi 协议 TVL(总锁仓价值)——包括链上明细和 24 小时/7 天变化。
// Input
{ "protocol": "Aave" }
// Output
{
"success": true,
"data": {
"protocol": "Aave",
"slug": "aave",
"totalTvlUsd": 12000000000,
"change24h": 1.5,
"change7d": -3.2,
"chainBreakdown": [
{ "chain": "Ethereum", "tvlUsd": 8000000000, "percentage": 66.67 },
{ "chain": "Polygon", "tvlUsd": 2000000000, "percentage": 16.67 }
]
}
}
getWhaleMovements
追踪大额代币转账(巨鲸动向)。识别转入交易所或从交易所转出的方向。
// Input
{ "token": "USDC", "chain": "ethereum", "minValueUsd": 100000, "limit": 10 }
// Output
{
"success": true,
"data": {
"token": "USDC",
"tokenAddress": "0xA0b8...",
"movements": [
{ "txHash": "0xabc...", "from": "0x1234...", "to": "0x28C6...", "fromLabel": null, "toLabel": "Binance Hot Wallet", "value": "500000.00", "valueUsd": 500000, "direction": "exchange_deposit", "timestamp": 1710000000 }
],
"summary": { "totalMovements": 1, "totalValueUsd": 500000, "netExchangeFlow": 500000 }
}
}
getSwapQuote
通过 ParaSwap 获取 DEX 兑换报价——最优路由、Gas 成本,并自动将 ETH 转换为 WETH。
// Input
{ "tokenIn": "ETH", "tokenOut": "USDC", "amountIn": "1.0", "chain": "ethereum" }
// Output
{
"success": true,
"data": {
"tokenIn": { "symbol": "ETH", "address": "0xEeee...", "amount": "1.000000" },
"tokenOut": { "symbol": "USDC", "address": "0xA0b8...", "amount": "1929.200000" },
"exchangeRate": 1929.2,
"priceImpact": null,
"source": "UniswapV3",
"estimatedGasUsd": "3.50"
}
}
getYieldRates
从 DefiLlama 获取 DeFi 收益率(APY)。可按协议、链和最低 TVL 筛选。
// Input
{ "protocol": "aave-v3", "chain": "Ethereum", "minTvl": 1000000 }
// Output
{
"success": true,
"data": {
"pools": [
{ "project": "aave-v3", "symbol": "USDC", "chain": "Ethereum", "apy": 5.2, "tvlUsd": 500000000, "stablecoin": true }
],
"count": 10
}
}
getContractEvents
获取合约事件日志,并自动解码 ABI。
// Input
{ "address": "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48", "chain": "ethereum", "limit": 5 }
// Output
{
"success": true,
"data": {
"events": [
{ "name": "Transfer", "args": { "from": "0x...", "to": "0x...", "value": "1000000" }, "txHash": "0x...", "blockNumber": 19234567 }
],
"count": 5,
"fromBlock": 19233567,
"toBlock": 19234567
}
}
getTokenHolders
获取代币持有者排名。Ethereum 使用 Ethplorer,其他链则根据 Etherscan 转账记录汇总。
// Input
{ "token": "USDC", "chain": "ethereum", "limit": 10 }
// Output
{
"success": true,
"data": {
"token": "0xA0b8...",
"holders": [
{ "address": "0x...", "balance": "1000000", "share": 15.5 }
],
"totalHolders": 12345
}
}
simulateTx
通过 eth_call + estimateGas 模拟交易。返回以 USD 计价的 Gas 估算值,以及失败时的回退原因。
// Input
{ "from": "0x1234...", "to": "0x5678...", "data": "0xa9059cbb...", "chain": "ethereum" }
// Output
{
"success": true,
"data": {
"success": true,
"gasEstimate": "65000",
"gasEstimateUsd": 2.50,
"returnData": "0x0000...0001",
"error": null
}
}
checkHoneypot
通过 Honeypot.is 检测貔貅盘(骗局)代币。返回买入/卖出税率、风险级别和标记。
// Input
{ "token": "0x...", "chain": "ethereum" }
// Output
{
"success": true,
"data": {
"isHoneypot": false,
"riskLevel": "safe",
"buyTax": 0,
"sellTax": 0,
"flags": [],
"tokenName": "USD Coin",
"tokenSymbol": "USDC"
}
}
getBridgeRoutes
通过 LI.FI 获取跨链桥接路线,并比较费用、耗时和输出金额。
// Input
{ "fromChain": "ethereum", "toChain": "arbitrum", "token": "USDC", "amount": "100" }
// Output
{
"success": true,
"data": {
"routes": [
{ "bridge": "Stargate", "estimatedTime": 60, "feeUsd": 0.50, "gasCostUsd": 2.10, "amountOut": "99.50", "amountOutUsd": 99.50 }
],
"bestRoute": { "bridge": "Stargate", "..." : "..." }
}
}
getNFTInfo
获取钱包的 ERC-721 NFT 余额和代币列表。
// Input
{ "address": "0xd8dA...", "contractAddress": "0x...", "chain": "ethereum" }
// Output
{
"success": true,
"data": {
"chain": "ethereum",
"contractAddress": "0x...",
"owner": "0xd8dA...",
"totalBalance": 3,
"nfts": [
{ "tokenId": "1234", "tokenURI": "ipfs://..." }
]
}
}
getNFTMetadata
获取特定 NFT 代币的元数据(名称、图片、属性)。
// Input
{ "contractAddress": "0x...", "tokenId": "1234", "chain": "ethereum" }
// Output
{
"success": true,
"data": {
"contractAddress": "0x...",
"tokenId": "1234",
"tokenURI": "ipfs://...",
"metadata": {
"name": "Cool NFT #1234",
"description": "A very cool NFT",
"image": "ipfs://...",
"attributes": [
{ "trait_type": "Background", "value": "Blue" }
]
}
}
}
getGovernanceProposals
获取 Snapshot 治理提案(进行中、已结束或全部)。
// Input
{ "protocol": "uniswap", "state": "active" }
// Output
{
"success": true,
"data": {
"space": "uniswapgovernance.eth",
"state": "active",
"proposals": [
{
"title": "Proposal Title",
"state": "active",
"author": "0x1234...",
"start": "2025-01-01",
"end": "2025-01-07",
"votes": 1500,
"quorum": 1000,
"choices": ["For", "Against"],
"scores": [75.5, 24.5]
}
]
}
}
getBlockInfo
按区块编号或最新区块查询区块详情(时间戳、Gas、交易、验证者)。
// Input
{ "blockNumber": 19234567, "chain": "ethereum" }
// Output
{
"success": true,
"data": {
"number": 19234567,
"timestamp": 1741521600,
"gasUsed": "12345678",
"gasLimit": "30000000",
"baseFeePerGas": "20.0",
"transactionCount": 150,
"miner": "0x1234..."
}
}
getTokenTransfers
查询钱包地址近期的 ERC-20 代币转账记录。
// Input
{ "address": "0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045", "chain": "ethereum", "limit": 5 }
// Output
{
"success": true,
"data": {
"transfers": [
{ "token": "USDC", "from": "0x1234...", "to": "0xd8dA...", "value": "1000.00", "direction": "in", "txHash": "0xabc...", "timestamp": 1741521600 }
],
"count": 5
}
}
getPortfolio
获取完整的钱包投资组合,包括原生代币和 ERC-20 余额及 USD 价值。
// Input
{ "address": "0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045", "chain": "ethereum" }
// Output
{
"success": true,
"data": {
"address": "0xd8dA...",
"native": { "symbol": "ETH", "balance": "1.234", "valueUsd": 2382.50 },
"tokens": [
{ "symbol": "USDC", "balance": "1000.00", "valueUsd": 1000.00, "percentage": 29.6 }
],
"totalValueUsd": 3382.50
}
}
支持的链
| 链 | Chain ID | 原生代币 |
|---|---|---|
| Ethereum | 1 | ETH |
| Polygon | 137 | POL |
| Arbitrum | 42161 | ETH |
| Base | 8453 | ETH |
| Optimism | 10 | ETH |
| Avalanche | 43114 | AVAX |
| BSC | 56 | BNB |
环境变量(可选)
所有环境变量都是可选的。evmscope 无需任何配置即可运行。
| 变量 | 用途 | 默认值 |
|---|---|---|
EVMSCOPE_RPC_URL | 自定义 RPC 端点(所有链) | 公共 RPC |
EVMSCOPE_RPC_URL_ETHEREUM | Ethereum 专用 RPC 端点 | 回退至 RPC_URL |
EVMSCOPE_RPC_URL_POLYGON | Polygon 专用 RPC 端点 | 回退至 RPC_URL |
EVMSCOPE_RPC_URL_ARBITRUM | Arbitrum 专用 RPC 端点 | 回退至 RPC_URL |
EVMSCOPE_RPC_URL_BASE | Base 专用 RPC 端点 | 回退至 RPC_URL |
EVMSCOPE_RPC_URL_OPTIMISM | Optimism 专用 RPC 端点 | 回退至 RPC_URL |
EVMSCOPE_RPC_URL_AVALANCHE | Avalanche 专用 RPC 端点 | 回退至 RPC_URL |
EVMSCOPE_RPC_URL_BSC | BSC 专用 RPC 端点 | 回退至 RPC_URL |
EVMSCOPE_COINGECKO_KEY | CoinGecko API 密钥(更高的速率限制) | 免费版 |
EVMSCOPE_ETHERSCAN_KEY | Etherscan API 密钥(更高的速率限制) | 免费版 |
EVMSCOPE_POLYGONSCAN_KEY | Polygonscan API 密钥 | 回退至 ETHERSCAN_KEY |
EVMSCOPE_ARBISCAN_KEY | Arbiscan API 密钥 | 回退至 ETHERSCAN_KEY |
EVMSCOPE_BASESCAN_KEY | Basescan API 密钥 | 回退至 ETHERSCAN_KEY |
EVMSCOPE_OPTIMISTIC_KEY | Optimistic Etherscan API 密钥 | 回退至 ETHERSCAN_KEY |
EVMSCOPE_SNOWTRACE_KEY | Snowtrace API 密钥(Avalanche) | 回退至 ETHERSCAN_KEY |
EVMSCOPE_BSCSCAN_KEY | BscScan API 密钥(BSC) | 回退至 ETHERSCAN_KEY |
EVMSCOPE_ETHPLORER_KEY | Ethplorer API 密钥(代币持有者) | freekey |
EVMSCOPE_LIFI_KEY | LI.FI API 密钥(桥接路线) | 公共访问 |
EVMSCOPE_DEBUG | 启用调试日志(设为 1) | 已禁用 |
内置数据库
| 数据库 | 内容 |
|---|---|
tokens.json | 49 种主要代币,包含多链地址和 CoinGecko ID |
signatures.json | 36 种常见函数签名(ERC-20、DEX、借贷、NFT) |
labels.json | 30 个带标签的地址(交易所、桥接服务、巨鲸钱包) |
protocols.json | 10 个 DeFi 协议,包含多链合约地址 |
路线图
- v0.1(已完成)— 5 个工具:价格、交易手续费、余额、代币信息、ENS
- v0.5(已完成)— +4 个工具:decodeTx、getTxStatus、getContractABI、identifyAddress
- v1.0(已完成)— +5 个工具:compareGas、getApprovalStatus、getProtocolTVL、getWhaleMovements、getSwapQuote
- v1.5(已完成)— +6 个工具:simulateTx、getYieldRates、getTokenHolders、getContractEvents、checkHoneypot、getBridgeRoutes
- v1.5.1(已完成)— 代码质量与安全重构:7 个新的共享模块、按链配置 RPC URL、缓存大小限制、统一地址验证、CLI 模块化
- v1.6.0(已完成)— +3 个工具:getNFTInfo、getNFTMetadata、getGovernanceProposals。+2 条链:Avalanche、BSC
- v1.7.0(已完成)— +3 个工具:getBlockInfo、getTokenTransfers、getPortfolio。安全加固(v1.6.1)
许可证
评论
一个开放协议,规定了 AI 应用如何以统一方式连接外部工具与数据源。客户端负责与模型对话,MCP 服务负责提供工具、资源和提示模板,两者通过标准消息通信,同一个服务可以被不同客户端复用。