etherscan-mcp-skill
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseEtherscan MCP Skill
Etherscan MCP 技能
Use this skill to run Etherscan MCP operations through .
uxcReuse the skill for shared protocol discovery, output parsing, and generic auth/binding flows.
uxc使用本技能通过执行Etherscan MCP操作。
uxc复用技能以实现共享协议发现、输出解析以及通用认证/绑定流程。
uxcPrerequisites
前提条件
- is installed and available in
uxc.PATH - Network access to .
https://mcp.etherscan.io/mcp - An Etherscan API key is available for authenticated calls.
- 已安装且可在
uxc中访问。PATH - 可访问网络地址。
https://mcp.etherscan.io/mcp - 拥有Etherscan API密钥以进行认证调用。
Core Workflow
核心工作流
- Confirm endpoint and protocol with help-first probing:
uxc https://mcp.etherscan.io/mcp -h- expected unauthenticated behavior today:
401 Unauthorized
- Configure credential/binding for repeatable auth:
uxc auth credential set etherscan-mcp --auth-type bearer --secret-env ETHERSCAN_API_KEYuxc auth credential set etherscan-mcp --auth-type bearer --secret-op op://Engineering/etherscan/api-keyuxc auth binding add --id etherscan-mcp --host mcp.etherscan.io --path-prefix /mcp --scheme https --credential etherscan-mcp --priority 100
- Use fixed link command by default:
command -v etherscan-mcp-cli- If missing, create it:
uxc link etherscan-mcp-cli https://mcp.etherscan.io/mcp etherscan-mcp-cli -h
- Inspect operation schema before execution:
etherscan-mcp-cli balance -hetherscan-mcp-cli tokenTopHolders -hetherscan-mcp-cli getContractAbi -hetherscan-mcp-cli transaction -h
- Prefer read operations first, then any workflow that could trigger heavy data pulls or follow-up automation.
- 通过优先查看帮助的方式确认端点和协议:
uxc https://mcp.etherscan.io/mcp -h- 当前预期未认证行为:
401 Unauthorized
- 配置凭证/绑定以实现可重复认证:
uxc auth credential set etherscan-mcp --auth-type bearer --secret-env ETHERSCAN_API_KEYuxc auth credential set etherscan-mcp --auth-type bearer --secret-op op://Engineering/etherscan/api-keyuxc auth binding add --id etherscan-mcp --host mcp.etherscan.io --path-prefix /mcp --scheme https --credential etherscan-mcp --priority 100
- 默认使用固定链接命令:
command -v etherscan-mcp-cli- 若缺失,创建链接:
uxc link etherscan-mcp-cli https://mcp.etherscan.io/mcp etherscan-mcp-cli -h
- 执行前检查操作模式:
etherscan-mcp-cli balance -hetherscan-mcp-cli tokenTopHolders -hetherscan-mcp-cli getContractAbi -hetherscan-mcp-cli transaction -h
- 优先执行读取操作,再执行可能触发大量数据拉取或后续自动化的工作流。
Capability Map
能力映射
- Address investigation:
balancetokenHoldingsfundedBygetAddressMetadata
- Token holder analysis:
balanceERC20balanceERC20HistoricaltokenTopHoldersgetTokenInfo
- Transaction investigation:
txListinternalTxsByAddresserc20Transferserc721Transferserc1155TransferstransactioncheckTransaction
- Contract research:
getContractAbigetContractSourceCodegetContractCreation
- Verification:
verifySourceCodecheckVerifyStatus
Inspect after auth setup for the current full tool list. Etherscan can expand MCP tools independently of this wrapper skill.
etherscan-mcp-cli -h- 地址调查:
- (余额)
balance - (代币持仓)
tokenHoldings - (资金来源)
fundedBy - (获取地址元数据)
getAddressMetadata
- 代币持有者分析:
- (ERC20余额)
balanceERC20 - (ERC20历史余额)
balanceERC20Historical - (代币顶级持有者)
tokenTopHolders - (获取代币信息)
getTokenInfo
- 交易调查:
- (交易列表)
txList - (按地址查询内部交易)
internalTxsByAddress - (ERC20转账记录)
erc20Transfers - (ERC721转账记录)
erc721Transfers - (ERC1155转账记录)
erc1155Transfers - (交易详情)
transaction - (核查交易)
checkTransaction
- 合约研究:
- (获取合约ABI)
getContractAbi - (获取合约源代码)
getContractSourceCode - (获取合约创建信息)
getContractCreation
- 验证:
- (验证源代码)
verifySourceCode - (核查验证状态)
checkVerifyStatus
完成认证设置后,可通过查看当前完整工具列表。Etherscan可独立于本封装技能扩展MCP工具。
etherscan-mcp-cli -hRecommended Usage Pattern
推荐使用模式
- Start from a read-only investigation goal:
- balance or holdings for an address
- holder concentration for a token
- transaction inspection for a hash
- source/metadata lookup for a contract
- Run on the specific tool before the first real call.
-h - Prefer one chain/address/token at a time before broadening the scope.
- Parse the JSON envelope first, then inspect .
data
- 从只读调查目标开始:
- 地址的余额或持仓
- 代币的持有者集中度
- 交易哈希的交易核查
- 合约的源代码/元数据查询
- 在首次实际调用前,运行特定工具的命令查看帮助。
-h - 优先一次处理一条链/一个地址/一种代币,再扩大范围。
- 先解析JSON包,再查看字段。
data
Guardrails
防护规则
- Keep automation on JSON output envelope; do not rely on .
--text - Parse stable fields first: ,
ok,kind,protocol,data.error - Use as default command path.
etherscan-mcp-cli - is equivalent to
etherscan-mcp-cli <operation> ....uxc https://mcp.etherscan.io/mcp <operation> ... - If unauthenticated probe or runtime call returns :
401 Unauthorized- confirm auth binding matches endpoint with
uxc auth binding match https://mcp.etherscan.io/mcp - confirm credential shape with
uxc auth credential info etherscan-mcp - reset credential as bearer if needed:
uxc auth credential set etherscan-mcp --auth-type bearer --secret-env ETHERSCAN_API_KEY
- confirm auth binding matches endpoint with
- Use only for simple scalar inputs.
key=value - Prefer positional JSON when an operation accepts nested objects, arrays, or optional flags that may evolve.
- Do not assume tool argument names from memory; inspect first because Etherscan may revise MCP schemas independently of this skill.
<operation> -h - Some MCP tools are tier-gated by Etherscan plan. Today can return
getTokenInfowith an API Pro upgrade message on non-Pro keys.NOTOK - Treat as a write-like action requiring explicit user confirmation.
verifySourceCode
- 仅对JSON输出包进行自动化处理;不要依赖格式。
--text - 优先解析稳定字段:、
ok、kind、protocol、data。error - 使用作为默认命令路径。
etherscan-mcp-cli - 等价于
etherscan-mcp-cli <operation> ...。uxc https://mcp.etherscan.io/mcp <operation> ... - 若未认证探测或运行时调用返回:
401 Unauthorized- 使用确认认证绑定与端点匹配
uxc auth binding match https://mcp.etherscan.io/mcp - 使用确认凭证格式
uxc auth credential info etherscan-mcp - 如有需要,重置Bearer类型凭证:
uxc auth credential set etherscan-mcp --auth-type bearer --secret-env ETHERSCAN_API_KEY
- 使用
- 仅对简单标量输入使用格式。
key=value - 当操作接受嵌套对象、数组或可能演变的可选标志时,优先使用位置JSON格式。
- 不要凭记忆假设工具参数名称;先查看,因为Etherscan可能独立于本技能修订MCP模式。
<operation> -h - 部分MCP工具受Etherscan套餐等级限制。目前,非Pro密钥调用可能返回
getTokenInfo及API Pro升级提示信息。NOTOK - 将视为需要用户明确确认类的写入操作。
verifySourceCode
References
参考资料
- Invocation patterns:
references/usage-patterns.md
- 调用模式:
references/usage-patterns.md