crypto-mcp-server
Enables EVM blockchain operations through Alchemy RPC, including balance queries, contract interactions, transaction sending, and message signing, with multi-chain support across mainnets and testnets.
README
crypto-mcp-server
A Model Context Protocol server that lets any MCP client (Claude Desktop, Cursor, etc.) perform EVM blockchain operations — reading balances, reading/writing contracts, simulating and sending transactions, and signing messages — through Alchemy RPC, using a wallet derived from a mnemonic or private key.
Features
- Multi-chain across Alchemy-backed networks. The target network is
selectable per tool call (defaults to the configured
DEFAULT_NETWORK).- Mainnets:
ethereum,base,arbitrum,optimism,polygon - Testnets:
sepolia,base-sepolia,arbitrum-sepolia,optimism-sepolia,polygon-amoy
- Mainnets:
- Both transports: stdio (default, for local clients) and Streamable HTTP (for remote/hosted use).
- Tools:
- Reads:
get_native_balance,get_token_balance,get_gas_price,get_block,get_transaction,resolve_ens,read_contract - Writes:
send_native,send_token,write_contract - Pre-flight:
simulate_transaction(dry-run, never broadcasts) - Signing:
sign_message(EIP-191),sign_typed_data(EIP-712)
- Reads:
Prerequisites
- Node.js ≥ 18
- An Alchemy API key
- A wallet mnemonic or private key
Setup
npm install
cp .env.example .env # then fill in the values
npm run build
Environment variables
| Variable | Required | Description |
|---|---|---|
ALCHEMY_API_KEY |
yes | Your Alchemy API key. Used to build RPC endpoints for all chains. |
MNEMONIC |
one of | BIP-39 mnemonic phrase. Provide exactly one of this / key. |
PRIVATE_KEY |
one of | 0x-prefixed hex private key. Provide exactly one. |
DERIVATION_PATH |
no | HD path used with MNEMONIC (defaults to ethers' default path). |
DEFAULT_NETWORK |
no | Default chain when a call omits network (mainnet or testnet, e.g. polygon-amoy, sepolia). Default: ethereum. |
TRANSPORT |
no | stdio (default) or http. |
PORT |
no | Port for the HTTP transport. Default: 3000. |
The server fails to start (non-zero exit) if ALCHEMY_API_KEY is missing,
if neither key is provided, or if both keys are provided.
Running
stdio (default — most MCP clients launch the server this way):
npm run start
# or for development with reload:
npm run dev
Streamable HTTP:
TRANSPORT=http PORT=3000 npm run start
# MCP endpoint: http://localhost:3000/mcp
Using with an MCP client (stdio)
Add to your client's MCP config (e.g. Claude Desktop's
claude_desktop_config.json, or .cursor/mcp.json). See
examples/mcp-client-config.json.
{
"mcpServers": {
"crypto": {
"command": "node",
"args": ["/absolute/path/to/crypto-mcp-server/dist/index.js"],
"env": {
"ALCHEMY_API_KEY": "your-alchemy-key",
"PRIVATE_KEY": "0xyour-private-key",
"DEFAULT_NETWORK": "ethereum"
}
}
}
}
Security
This server can spend funds. It holds a mnemonic or private key in process memory and can sign and broadcast transactions.
- Secrets are read only from environment variables and are never logged, echoed, or returned in tool outputs or error messages.
- Prefer
simulate_transactionbefore anysend_*/write_contractcall to preview gas and catch reverts. - The HTTP transport exposes spend operations over the network. It performs
no authentication of its own — run it only behind a trusted network and/or an
authenticating proxy. For local single-user use, prefer
stdio. - Use a dedicated, low-value wallet. Never point this at a key holding significant funds without your own additional controls.
Development
npm run lint # type-check only (tsc --noEmit)
npm run test # vitest
npm run build # compile to dist/
推荐服务器
Baidu Map
百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
Audiense Insights MCP Server
通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
graphlit-mcp-server
模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。
Kagi MCP Server
一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。
e2b-mcp-server
使用 MCP 通过 e2b 运行代码。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。