
MCP Server exposing coincap rest api for use by AI Agents
概览
A Model Context Protocol (MCP) server that exposes the CoinCap.io api as tools. This server can run in multiple modes to integrate with different MCP clients including Claude Desktop and MCP Inspector. - : Automatically loads all available CoinCap endpoints from their Swagger specification - : Works with stdio (Claude Desktop) or streamable HTTP (MCP Inspector) - : Access to assets, markets, exchanges, technical analysis, conversion rates & everything else in the api https://pro.coincap.io/api-docs/ - Node.js ≥ 18 - Yarn package manager - Auth, either of: - A CoinCap API key (get one free at https://pro.coincap.io), - An x402 wallet — an EVM private key holding USDC on Base — for keyless pay-per-call access to the agentFriendly tools (see Keyless x402 payments) 1. Download the latest built .dxt file here: https://github.com/CC3-0/coincap-mcp-server/raw/refs/heads/main/coincap-mcp-clean.
README
以下为原文 README 节选,完整内容请查看原文。
CoinCap MCP Server
A Model Context Protocol (MCP) server that exposes the CoinCap.io api as tools. This server can run in multiple modes to integrate with different MCP clients including Claude Desktop and MCP Inspector.
Features
- Dynamic API Loading: Automatically loads all available CoinCap endpoints from their Swagger specification
- Multiple Transport Modes: Works with stdio (Claude Desktop) or streamable HTTP (MCP Inspector)
- Comprehensive Coverage: Access to assets, markets, exchanges, technical analysis, conversion rates & everything else in the api https://pro.coincap.io/api-docs/
Prerequisites
- Node.js ≥ 18
- Yarn package manager
- Auth, either of:
- A CoinCap API key (get one free at https://pro.coincap.io), or
- An x402 wallet — an EVM private key holding USDC on Base — for keyless pay-per-call access to the
agentFriendlytools (see Keyless x402 payments)
Installation
Option 1: Using Claude Desktop Extension (.dxt) File
- Download the latest built .dxt file here: https://github.com/CC3-0/coincap-mcp-server/raw/refs/heads/main/coincap-mcp-clean.dxt and open with claude desktop
Option 2: Using npx
# Run directly without installation
npx coincap-mcp-server
# For HTTP mode
npx coincap-mcp-server --port=3001
Option 3: Clone and Build
# Clone the repository
git clone https://github.com/CC3-0/coincap-mcp-server
cd coincap-mcp-server
# Install dependencies
yarn install
# Build the project
yarn build
Keyless x402 payments
The 10 agentFriendly tools can be used without a CoinCap account: set
X402_PRIVATE_KEY to an EVM private key whose wallet holds USDC on Base, and
the server pays per call ($0.002–$0.01 USDC) via the
x402 protocol. Payment is signed off-chain
(EIP-3009) — the wallet needs no ETH for gas, only USDC.
{
"mcpServers": {
"crypto-prices": {
"command": "npx",
"args": ["coincap-mcp-server"],
"env": {
"X402_PRIVATE_KEY": "0x_your_wallet_private_key"
}
}
}
}
Notes:
- Use a dedicated, low-balance wallet. Fund it with a few dollars of USDC on Base — never reuse a wallet holding significant funds.
- Per-call spend is capped at 100000 atomic USDC ($0.10) regardless of what a server asks for; override with
X402_MAX_PAYMENT_ATOMIC_USDC. - If both
COINCAP_API_KEYandX402_PRIVATE_KEYare set, the API key is used (no payment is made). - Non-
agentFriendlytools always require an API key.
Usage
Option 1: Claude Desktop Extension File
This is the easiest way to use the CoinCap MCP Server. Requires the Claude Desktop app.
- Download the latest built Desktop Extension file here: https://github.com/CC3-0/coincap-mcp-server/raw/refs/heads/main/coincap-mcp-clean.dxt
- Locate the ‘coincap-mcp-clean.dxt file on your computer and right-click on the file.
- Select: Open With > Claude
安装
npx coincap-mcp-server配置
{
"mcpServers": {
"crypto-prices": {
"command": "npx",
"args": ["coincap-mcp-server"],
"env": {
"X402_PRIVATE_KEY": "0x_your_wallet_private_key"
}
}
}
}