CryptoPortfolioMCPServer
Read-only cryptocurrency portfolio management MCP server for Binance, Coinbase, and Kraken
claude mcp add --transport stdio lev-corrupted-cryptoportfoliomcpserver python -m src.server \ --env MOCK_MODE="false" \ --env KRAKEN_API_KEY="your_kraken_api_key" \ --env BINANCE_API_KEY="your_binance_api_key" \ --env COINBASE_API_KEY="your_coinbase_api_key" \ --env KRAKEN_API_SECRET="your_kraken_secret" \ --env BINANCE_API_SECRET="your_binance_secret" \ --env COINBASE_API_SECRET="your_coinbase_secret" \ --env PRICE_CACHE_DURATION="30" \ --env BALANCE_CACHE_DURATION="60"
How to use
CryptoPortfolioMCPServer provides read-only access to your cryptocurrency holdings across Binance, Coinbase, and Kraken through the MCP (Model Context Protocol). The server aggregates balances, values, and market data, and offers analytic tools for portfolio performance, risk metrics, and market intelligence. Clients such as Claude Desktop or any MCP-compatible frontend can query the server to fetch real-time prices, diversification scores, risk assessments, and alerts without executing trades. To get started, ensure your environment variables are set with read-only API keys for each exchange, then run the server. Once running, you can invoke tools like get_total_portfolio_value, get_portfolio_allocation, get_biggest_movers, get_diversification_score, and check_arbitrage_opportunities to build dashboards or natural language queries that summarize your portfolio.
How to install
Prerequisites:
- Python 3.10 or higher
- Internet access
- Read-only API keys for Binance, Coinbase, and Kraken
- Git
Installation steps:
- Clone the repository and navigate into it:
git clone https://github.com/lev-corrupted/CryptoPortfolioMCPServer.git
cd CryptoPortfolioMCPServer
- Create and activate a virtual environment (recommended):
python -m venv venv
source venv/bin/activate # on macOS/Linux
venv\Scripts\activate # on Windows
- Install dependencies:
pip install -r requirements.txt
- Copy example environment file and populate credentials:
cp .env.example .env
# Edit .env with your actual keys if you prefer environment-based configuration
- Test the configuration (optional):
python test_config.py
- Run the MCP server (according to the configured mcp_config):
python -m src.server
Notes:
- The server runs in read-only mode; no trading actions are performed.
- External dependencies are installed via requirements.txt; ensure network access during installation.
- If you use Claude Desktop, configure the Claude MCP integration as shown in the Claude Desktop configuration section of the README.
Additional notes
Tips and common issues:
- Ensure all exchange API keys have read-only permissions to avoid accidental trading permissions.
- Keep your .env or environment variables secure and never commit them to version control.
- If you run into authentication errors, double-check that API keys are valid and not restricted by IP or permission scope.
- The server caches prices and balances (30s and 60s by default) for performance; adjust via environment variables if needed.
- Logs are typically found under logs/crypto_mcp.log; review for diagnostics if the server fails to initialize.
- When using Claude Desktop, you can phrase queries in natural language, for example: "What is my total portfolio value?", "Show me my portfolio allocation", or "Are there any arbitrage opportunities?"
Related MCP Servers
mcp -tree-sitter
MCP Server for Tree-sitter
mcp-n8n-workflow-builder
AI-powered n8n workflow automation through natural language. MCP server enabling Claude AI & Cursor IDE to create, manage, and monitor workflows via Model Context Protocol. Multi-instance support, 17 tools, comprehensive docs. Build workflows conversationally without manual JSON editing.
mcp-simple-timeserver
Simple MCP to give Claude ability to check current time as well as know when holidays are, what is the time distance between dates etc.
mcp-chain-of-draft
Chain of Draft Server is a powerful AI-driven tool that helps developers make better decisions through systematic, iterative refinement of thoughts and designs. It integrates seamlessly with popular AI agents and provides a structured approach to reasoning, API design, architecture decisions, code reviews, and implementation planning.
Claude-Code -Manager
A comprehensive tool to manage Model Context Protocol (MCP) configurations for Claude code
mcp -amazon
🛍📦 Unofficial Amazon Model Context Protocol Server (MCP) - Search products and purchase directly from Claude AI! ✨