chain-data
Enables AI agents to fetch live multi-chain portfolio, token info, gas prices, and token prices across Ethereum, Base, Polygon, Arbitrum, and Optimism with a single call. No API key required.
README
chain-data ๐
Live multi-chain on-chain data, aggregated in ONE call โ built for AI agents.
Give it a wallet and get its whole portfolio across Ethereum, Base, Polygon, Arbitrum and Optimism โ native balances + top ERC-20 holdings, each priced in USD โ in a single response. Plus token/contract facts, live gas and prices. All read straight from public RPCs and DefiLlama; no API key, no node.
Available as an MCP server (free) and a pay-per-call x402 API ($0.10 USDC on Base, no sign-up).
Why
An agent that wants a wallet's multi-chain net worth would otherwise have to:
fan out N JSON-RPC calls to N chains โ ABI-encode balanceOf/decimals/symbol โ batch them โ join against a price feed โ repeat per chain. chain-data does all of that server-side and returns one fresh JSON object per call. That convenience on live data is the point โ agents pay for the aggregation, not for a static answer they could cache.
Tools (MCP)
| Tool | What it does |
|---|---|
wallet_portfolio |
Native + ERC-20 balances with live USD value, across 5 chains, in one call |
token_info |
symbol, name, decimals, total supply, is-contract, EIP-1967 proxy + implementation, price |
gas_prices |
base fee / gas price / priority fee / latest block, per chain or all at once |
token_price |
live USD price by chain+address, CoinGecko id, or symbol |
Use as an MCP server (free)
{
"mcpServers": {
"chain-data": { "command": "npx", "args": ["-y", "chain-data-mcp"] }
}
}
Or over HTTP: POST https://chain-data.vercel.app/mcp.
Free HTTP API
GET /portfolio?wallet=0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045
GET /token?chain=base&address=0x833589fcd6edb6e08f4c7c32d4f71b54bda02913
GET /gas
GET /price?chain=ethereum&address=0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2
Rate-limited to 30 requests/hour/IP.
Pay-per-call (x402)
The /pro/* routes are gated by x402. Your agent pays $0.10 USDC per call automatically โ no sign-up, no API key. Settles on-chain (Base) to the operator wallet. No rate limit.
GET /pro/portfolio?wallet=0x...
GET /pro/token?chain=base&address=0x...
GET /pro/gas
GET /pro/price?chain=ethereum&address=0x...
Supported chains
Ethereum ยท Base ยท Polygon ยท Arbitrum One ยท OP Mainnet โ all via public, key-free RPCs with automatic failover.
Data sources
- Balances / token info / gas: public JSON-RPC endpoints (
mainnet.base.org,eth.llamarpc.com,polygon-rpc.com, โฆ). - Prices: DefiLlama coins API (free) / CoinGecko ids.
No credentials are stored or required. The server holds no private key โ payTo is a public receiving address only.
Local dev
npm install
npm run build
npm run test:engine # live smoke test against real RPCs
npm run dev:http # local HTTP server on :8080 (payments off unless X402_* set)
npm run dev:mcp # local stdio MCP server
License
MIT
Recommended Servers
playwright-mcp
A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.
Magic Component Platform (MCP)
An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.
Audiense Insights MCP Server
Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
graphlit-mcp-server
The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.
Kagi MCP Server
An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.
E2B
Using MCP to run code via e2b.
Neon Database
MCP server for interacting with Neon Management API and databases
Exa Search
A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.