Skip to main content

A cryptocurrency market data MCP tool using CoinGecko API

Project description

Crypto Trader MCP Tool for Claude Desktop

An MCP (Model Context Protocol) tool that provides cryptocurrency market data using the CoinGecko API, specifically designed for Claude Desktop.

Tutorial

For a detailed guide on setting up and using this tool, check out our Medium tutorial: Tutorial: Using Claude Desktop with Crypto Trader MCP Tool to Get Real-Time Cryptocurrency Data

Features

  • Real-time cryptocurrency price data
  • Detailed market information for cryptocurrencies
  • Historical price charts
  • Cryptocurrency search functionality
  • Trending cryptocurrencies tracking
  • Global market statistics

Setup

  1. Ensure you have Python 3.10 or higher installed

  2. Install dependencies:

pip install -r requirements.txt

Integration with Claude Desktop

  1. Configure your MCP settings in Claude Desktop by adding the following to your MCP configuration:
{
  "mcpServers": {
    "crypto-trader": {
      "command": "py",
      "args": ["-3.13", "C:\\Path\\To\\Your\\Crypto-Trader-MCP-ClaudeDesktop\\main.py"]
    }
  }
}
  1. Replace the path with the full path to your main.py file
  2. Run the server using:
py -3.13 main.py
  1. Keep the server running while using Claude Desktop

Available Tools

1. get_crypto_price

Get real-time cryptocurrency price information:

{
    "symbol": "BTC",
    "name": "bitcoin",
    "price": 65423.12,
    "change_24h": 2.5,
    "volume_24h": 28345678901,
    "market_cap": 1234567890123,
    "timestamp": "2025-03-15T10:30:00"
}

2. get_crypto_market_data

Get detailed market information for a cryptocurrency:

{
    "symbol": "ETH",
    "name": "Ethereum",
    "market_cap_rank": 2,
    "current_price": 3521.48,
    "market_cap": 423456789012,
    "total_volume": 15834567890,
    "high_24h": 3580.25,
    "low_24h": 3475.62,
    "price_change_24h": 45.86,
    "price_change_percentage_24h": 1.32,
    "circulating_supply": 120283456,
    "total_supply": 120283456,
    "max_supply": null,
    "ath": 4878.26,
    "ath_date": "2021-11-10T14:24:11.849Z",
    "atl": 0.432979,
    "atl_date": "2015-10-20T00:00:00.000Z"
}

3. get_crypto_historical_data

Get historical price data for a cryptocurrency:

{
    "symbol": "BTC",
    "name": "bitcoin",
    "days": 30,
    "prices": [
        {
            "date": "2025-02-15T00:00:00",
            "price": 62150.23
        },
        {
            "date": "2025-02-16T00:00:00",
            "price": 63421.15
        }
        // ... more data points
    ]
}

4. search_crypto

Search for cryptocurrencies:

{
    "results": [
        {
            "id": "bitcoin",
            "symbol": "BTC",
            "name": "Bitcoin"
        },
        {
            "id": "bitcoin-cash",
            "symbol": "BCH",
            "name": "Bitcoin Cash"
        }
        // ... more results
    ]
}

5. get_trending_crypto

Get trending cryptocurrencies:

{
    "trending_coins": [
        {
            "id": "pendle",
            "name": "Pendle",
            "symbol": "PENDLE",
            "market_cap_rank": 85,
            "price_btc": 0.00002356
        }
        // ... more trending coins
    ]
}

6. get_global_crypto_data

Get global cryptocurrency market data:

{
    "active_cryptocurrencies": 12875,
    "markets": 892,
    "total_market_cap_usd": 2347890123456,
    "total_volume_usd": 89723456789,
    "market_cap_percentage": {
        "BTC": 52.4,
        "ETH": 18.2
        // ... more cryptocurrencies
    },
    "updated_at": "2025-03-15T10:30:00"
}

Sample Queries

You can ask Claude Desktop questions like:

  • "What's the current price of Bitcoin?"
  • "Show me detailed market data for Ethereum"
  • "What's the price history of Dogecoin for the last 30 days?"
  • "Search for cryptocurrencies related to 'sol'"
  • "Which cryptocurrencies are trending today?"
  • "What's the total cryptocurrency market capitalization right now?"

Error Handling

All tools include proper error handling and will return an error message if something goes wrong:

{
    "error": "Failed to fetch price for INVALID_SYMBOL"
}

Troubleshooting

If the MCP server is not working in Claude Desktop:

  1. Make sure the server is running - you should see output when you start the script
  2. Verify the path in your settings is correct and absolute
  3. Make sure Python 3.10+ is in your system PATH
  4. Check that all dependencies are installed
  5. Try restarting Claude Desktop
  6. Check logs for any error messages

Rate Limits

This tool uses the free CoinGecko API which has rate limits. Please be aware that very frequent requests may be throttled by the API.

License

MIT License

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

File details

Details for the file iflow_mcp_saintdoresh_crypto_trader_mcp_claudedesktop-1.0.0.tar.gz.

File metadata

  • Download URL: iflow_mcp_saintdoresh_crypto_trader_mcp_claudedesktop-1.0.0.tar.gz
  • Upload date:
  • Size: 5.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.28 {"installer":{"name":"uv","version":"0.9.28","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Debian GNU/Linux","version":"13","id":"trixie","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for iflow_mcp_saintdoresh_crypto_trader_mcp_claudedesktop-1.0.0.tar.gz
Algorithm Hash digest
SHA256 c690169a54242b0f343e3c10b9497fce229af4858c94ff9dcc7ffae4dbf95e5c
MD5 62054a51347b59797a6dc16bebac4d33
BLAKE2b-256 708093d7c7ab2cd2067a494af2ec4b55565a3efbc5673ed6c8155c28b3ce6f22

See more details on using hashes here.

File details

Details for the file iflow_mcp_saintdoresh_crypto_trader_mcp_claudedesktop-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: iflow_mcp_saintdoresh_crypto_trader_mcp_claudedesktop-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 13.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.28 {"installer":{"name":"uv","version":"0.9.28","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Debian GNU/Linux","version":"13","id":"trixie","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for iflow_mcp_saintdoresh_crypto_trader_mcp_claudedesktop-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 a7efa687a4a512aeb04a709b8bb2ed844296aac258eea8f378dac36bfa85fbde
MD5 325c3ab6e3aa2e735169952e53c33745
BLAKE2b-256 0932adeced062e0a75d459cd26a9fdee95c561a5d1c766126a787e053bbdeba8

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page