Skip to main content
Glama
3commas-mcp

3commas-mcp

by severity1

3Commas MCP Server

A Model Context Protocol (MCP) server that integrates AI assistants with the 3Commas cryptocurrency trading platform API. Manage your DCA bots and trading strategies through natural conversation with any MCP-supporting platform including Claude, Claude Code CLI, Claude Desktop, Cursor, and Copilot Studio.

Version Python Implementation Type Checking Code Quality


Available Tools

Account Management ✅

  • health_check() - Test API connectivity and authentication status

  • get_account_info(account_id) - Get account details, balance, profit metrics (summary or specific account)

  • get_connected_exchanges_and_wallets() - View all connected exchanges with permissions and status

  • get_balance_history_data(date_from, account_id) - Historical balance changes with profit tracking

Market Data ✅

  • get_supported_markets() - List supported trading markets and exchanges

  • get_all_market_pairs(market_code) - Get available trading pairs for any exchange

  • get_currency_rates_and_limits(market_code, pair) - Current rates, limits, and precision for currency pairs

DCA Bot Management ✅

  • get_dca_bot_list() - Get all DCA bots with status, configuration, and performance overview

  • get_dca_bot_details(bot_id) - Comprehensive bot configuration, deals, and performance data

  • get_available_strategy_list() - Available DCA bot trading strategies with configuration options

  • get_dca_bot_profit_data(bot_id) - Daily profit analytics with BTC/USD amounts and timestamps

  • get_blacklist_of_pairs() - Get blacklisted trading pairs with restrictions and configurations

Implementation Status: 10 of 29 planned GET APIs completed (34.5%) - Read-only operations only for trading safety

All tools include response_filter parameter ("display" for essential data, "full" for complete response).

See docs/tools/ for detailed function documentation and docs/API_REFERENCES.md for complete API status.


Related MCP server: ctrader-mcp-server

Installation & Setup

Prerequisites

  • Python 3.12+

  • uv package manager (recommended) or pip

  • 3Commas account with API access

Install

git clone https://github.com/your-username/3commas-mcp.git
cd 3commas-mcp

# Setup environment
uv venv && source .venv/bin/activate
uv sync && uv pip install -e .

Configure for Claude Code CLI

claude mcp add -e 3COMMAS_API_KEY=your_api_key -e 3COMMAS_SECRET_KEY=your_secret_key -e 3COMMAS_ENABLE_DESTRUCTIVE=false -s user threecommas-mcp -- "threecommas-mcp"

Configure for Claude Desktop

Add to claude_desktop_config.json:

{
  "mcpServers": {
    "threecommas-mcp": {
      "command": "/path/to/uv",
      "args": ["--directory", "/path/to/3commas-mcp", "run", "threecommas-mcp"],
      "env": {
        "3COMMAS_API_KEY": "your_api_key",
        "3COMMAS_SECRET_KEY": "your_secret_key", 
        "3COMMAS_ENABLE_DESTRUCTIVE": "false"
      }
    }
  }
}

Config file locations:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json

  • Windows: %APPDATA%\Claude\claude_desktop_config.json


Usage Examples

"Show me all my connected exchanges and their status"
"List all my DCA bots and their current status"
"What trading pairs are available on Binance?"

See docs/conversations/ for comprehensive usage examples and scenarios.


Architecture & Security

Read-only operations only - Current implementation has zero trading risk with secure HMAC-SHA256 authentication and comprehensive error handling.

See docs/DEVELOPMENT.md for technical architecture and security details.


Development

# Run quality checks
uv run -m black . && uv run -m ruff format . && uv run -m ruff check . && uv run -m mypy .

See docs/CONTRIBUTING.md for contribution guidelines and docs/DEVELOPMENT.md for setup details.


Documentation


License & Disclaimer

MIT License - see LICENSE file for details.

Trading Disclaimer: This software is for educational purposes. Cryptocurrency trading involves substantial risk. Always review configurations carefully and never trade more than you can afford to lose. Authors are not responsible for trading losses.


Support

Built with FastMCP and comprehensive safety-first design patterns.

Available Tools

12 tools
get_account_infoA

Get account information for a specific account or aggregated summary.

Args: account_id: Account ID (integer) or 'summary' for aggregated data response_filter: Response detail level ("full" or "display")

Returns: Account information including settings, balance, profit metrics, and trading permissions.

Inputs: account_id, response_filter. Returns: object

get_all_market_pairsA

Get all available trading pairs across markets.

Args: market_code: Optional market filter (e.g., "binance", "okx") response_filter: Response detail level ("full" or "display")

Returns: List of trading pairs with symbols, availability, and trading parameters.

Inputs: market_code, response_filter. Returns: object

get_available_strategy_listB

Get all available DCA bot trading strategies.

Args: response_filter: Response detail level ("full" or "display")

Returns: Complete catalog of available strategies with configuration options and compatibility.

Inputs: response_filter. Returns: object

get_balance_history_dataA

Get account balance history over time.

Args: date_from: Start date in ISO 8601 format (YYYY-MM-DDTHH:MM:SS.sssZ) account_id: Account ID (integer) or 'summary' for aggregated data date_to: End date in ISO 8601 format (optional) response_filter: Response detail level ("full" or "display")

Returns: Balance history data with timestamps, USD/BTC values, and deposit amounts.

Inputs: date_from (required), account_id, date_to, response_filter. Returns: object

get_blacklist_of_pairsA

Get blacklisted trading pairs for DCA bots.

Args: response_filter: Response detail level ("full" or "display")

Returns: List of blacklisted trading pairs with restrictions and configurations.

Inputs: response_filter. Returns: object

get_connected_exchanges_and_walletsA

Get all connected exchange accounts and wallets.

Args: response_filter: Response detail level ("full" or "display")

Returns: List of connected exchanges with account details, permissions, and status.

Inputs: response_filter. Returns: object

get_currency_rates_and_limitsA

Get current exchange rates and trading limits for a currency pair.

Args: market_code: Exchange market code pair: Trading pair (e.g., "BTC_USDT") limit_type: Optional limit type (bot or smart_trade) response_filter: Response detail level ("full" or "display")

Returns: Exchange rates, trading limits, precision, and fee information.

Inputs: market_code (required), pair (required), limit_type, response_filter. Returns: object

get_dca_bot_detailsA

Get comprehensive details for a specific DCA bot.

Args: bot_id: DCA bot unique identifier include_events: Include related events (default: False) response_filter: Response detail level ("full" or "display")

Returns: Bot configuration, active deals, trading parameters, and performance metrics.

Inputs: bot_id (required), include_events, response_filter. Returns: object

get_dca_bot_listB

Get list of DCA bots with optional filtering and sorting.

Args: account_id: Exchange account ID (0 = all accounts) strategy: Trading strategy filter (long/short) order_direction: Sort order ("ASC" or "DESC") limit: Maximum bots to return (1-1000) offset: Pagination offset from_date: Filter bots created from date (ISO format) scope: Filter scope for bot selection sort_by: Field to sort by quote: Filter by quote currency response_filter: Response detail level ("full" or "display")

Returns: List of DCA bots with configuration, status, deals, and performance data.

Inputs: account_id, strategy, order_direction, limit, +6 more. Returns: object

get_dca_bot_profit_dataA

Get daily profit data for a specific DCA bot.

Args: bot_id: DCA bot unique identifier days: Number of days for profit data (default: 30) response_filter: Response detail level ("full" or "display")

Returns: Daily profit analytics with BTC/USD amounts and timestamps.

Inputs: bot_id (required), days, response_filter. Returns: object

get_supported_marketsA

Get all supported trading markets and exchanges.

Args: response_filter: Response detail level ("full" or "display")

Returns: List of supported markets with names, features, and compatibility information.

Inputs: response_filter. Returns: object

health_checkA

Perform a health check by testing API connectivity.

Inputs: no named parameters. Returns: object

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A3.6/5.0

    Scored across 12 tools

    Disambiguation4/5

    Most tools have distinct purposes, but 'get_all_market_pairs' and 'get_supported_markets' could cause confusion as both relate to markets. Otherwise clear separation.

    Naming Consistency4/5

    All tools use a consistent 'get_' prefix except 'health_check', which breaks the pattern. Naming is otherwise uniform with snake_case.

    Tool Count4/5

    12 tools is a reasonable count for a trading API wrapper, providing a balanced set of information retrieval endpoints without being overwhelming.

    Completeness2/5

    The tool set lacks essential CRUD operations for DCA bots (no create, update, delete) and no trading actions (open/close deals), leaving significant gaps for a trading server.

    Maintenance

    ActivityInactive
    ResponsivenessOutdated data

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      D
      maintenance
      A Model Context Protocol server that enables LLMs to interact with cryptocurrency exchanges through CCXT, allowing for tasks like fetching balances, market data, creating orders, and trading operations in a standardized way.
      8
      MIT
    • F
      license
      Not graded
      quality
      D
      maintenance
      A standalone Model Context Protocol (MCP) server that enables AI assistants to interact with the cTrader trading platform.
      15
      -
    • A
      license
      Not graded
      quality
      D
      maintenance
      A Model Context Protocol (MCP) server for the Hyperliquid decentralized exchange, enabling AI assistants to perform trading operations, manage accounts, and retrieve market data.
      38 PyPI
      3
      MIT
    • A
      license
      Not graded
      quality
      D
      maintenance
      MCP server for cryptocurrency trading across multiple exchanges (Bybit, Binance, KuCoin, etc.) with real-time price data, comparison, and natural language query support. Integrates with AI assistants via the Model Context Protocol.
      MIT