LabStore
← All labs

Hummingbot: Trading Agent

by docker ✓ verified ✓ Packaged by Docker

Hummingbot MCP is an open-source toolset that lets you control and monitor your Hummingbot trading bots through AI-powered commands and automation.

MCP server installable needs setup network: on runtime: sysbox

Finance & Accounting MCP Servers

Hummingbot: Trading Agent MCP Server

Hummingbot MCP is an open-source toolset that lets you control and monitor your Hummingbot trading bots through AI-powered commands and automation.

What is an MCP Server?

MCP Info

Attribute Details
Docker Image hummingbot/hummingbot-mcp
Author hummingbot
Repository https://github.com/hummingbot/mcp

Image Building Info

Attribute Details
Dockerfile https://github.com/hummingbot/mcp/blob/ad24846aa3d62706265fdb28833e721debdb0df0/Dockerfile
Commit ad24846aa3d62706265fdb28833e721debdb0df0
Docker Image built by hummingbot
Docker Scout Health Score Not available
Verify Signature Not available
Licence Apache License 2.0

Available Tools (21)

Tools provided by this Server Short Description
configure_api_servers Configure API servers using progressive disclosure.
deploy_bot_with_controllers Deploy a bot with specified controller configurations.
explore_controllers Explore and understand controllers and their configs.
explore_gateway_clmm_pools Explore Gateway CLMM pools: list pools and get pool information.
get_active_bots_status Get the status of all active bots.
get_bot_logs Get detailed logs for a specific bot with filtering options.
get_candles Get the real-time candles for a trading pair on a specific exchange connector.
get_funding_rate Get the latest funding rate for a trading pair on a specific exchange connector.
get_order_book Get order book data for a trading pair on a specific exchange connector, if the query type is different than snapshot, you need to provide query_value and is_buy
get_portfolio_overview Get a unified portfolio overview with balances, perpetual positions, LP positions, and active orders.
get_prices Get the latest prices for the specified trading pairs on a specific exchange connector.
manage_bot_execution Manage bot and controller execution states.
manage_gateway_clmm_positions Manage Gateway CLMM positions: open, close, collect fees, and get positions.
manage_gateway_config Manage Gateway configuration for chains, networks, tokens, connectors, pools, and wallets.
manage_gateway_container Manage Gateway container lifecycle operations.
manage_gateway_swaps Manage Gateway swap operations: quote, execute, search swaps.
modify_controllers Create, update, or delete controllers and their configurations.
place_order Place a buy or sell order on a OrderBook Exchange (supports USD values by adding at the start of the amount $).
search_history Search historical data from the backend database.
set_account_position_mode_and_leverage Set position mode and leverage for an account on a specific exchange.
setup_connector Setup a new exchange connector for an account with credentials using progressive disclosure.

Tools Details

Tool: configure_api_servers

Configure API servers using progressive disclosure.

This tool helps you manage multiple Hummingbot API servers with a simple flow:
1. No parameters → List all configured servers
2. action="add" + name + (optional host/port/username/password) → Add a new server
3. action="modify" + name + (host/port/username/password) → Modify existing server (partial updates supported)
4. action="set_default" + name → Set a server as default (reconnects client)
5. action="remove" + name → Remove a server
Parameters Type Description
action string optional Action to perform ('add', 'modify', 'set_default', 'remove'). Leave empty to list servers.
host string optional API host (optional, defaults to 'localhost' for 'add'. Examples: 'localhost', 'host.docker.internal', '72.212.424.42')
name string optional Server name (required for all actions)
password string optional API password (optional for 'add', defaults to 'admin'; optional for 'modify')
port string optional API port (optional, defaults to 8000 for 'add')
username string optional API username (optional for 'add', defaults to 'admin'; optional for 'modify')

Tool: deploy_bot_with_controllers

Deploy a bot with specified controller configurations.

Parameters Type Description
bot_name string Name of the bot to deploy
controllers_config array List of controller configs to use for the bot deployment.
account_name string optional Account name to use for the bot (default: master_account)
image string optional Docker image to use for the bot (default: "hummingbot/hummingbot:latest")
max_controller_drawdown_quote string optional Maximum drawdown per controller in quote currency (optional) defaults to None.
max_global_drawdown_quote string optional Maximum global drawdown in quote currency (optional) defaults to None.

Tool: explore_controllers

Explore and understand controllers and their configs.

Use this tool to discover what's available and understand how things work.

Progressive flow:
1. action="list" → List all controllers and their configs
2. action="list" + controller_type → List controllers of that type with config counts
3. action="describe" + controller_name → Show controller code + list its configs + explain parameters
4. action="describe" + config_name → Show specific config details + which controller it uses

Common Enum Values for Controller Configs:

Position Mode (position_mode):
- "HEDGE" - Allows holding both long and short positions simultaneously
- "ONEWAY" - Allows only one direction position at a time
- Note: Use as string value, e.g., position_mode: "HEDGE"

Trade Side (side):
- 1 or "BUY" - For long/buy positions
- 2 or "SELL" - For short/sell positions
- 3 - Other trade types
- Note: Numeric values are required for controller configs

Order Type (order_type, open_order_type, take_profit_order_type, etc.):
- 1 or "MARKET" - Market order
- 2 or "LIMIT" - Limit order
- 3 or "LIMIT_MAKER" - Limit maker order (post-only)
- 4 - Other order types
- Note: Numeric values are required for controller configs
Parameters Type Description
action string "list" to list controllers or "describe" to show details of a specific controller or config.
config_name string optional Name of the config to describe (optional, only required for describe specific config).
controller_name string optional Name of the controller to describe (optional, only required for describe specific controller).
controller_type string optional Type of controller to filter by (optional, e.g., 'directional_trading', 'market_making', 'generic').

Tool: explore_gateway_clmm_pools

Explore Gateway CLMM pools: list pools and get pool information.

Supports CLMM DEX connectors (Meteora, Raydium, Uniswap V3) for concentrated liquidity pools.

Actions:
- list_pools: Browse available CLMM pools with filtering and sorting
- get_pool_info: Get detailed information about a specific pool (requires network and pool_address)
Parameters Type Description
action string Action to perform ('list_pools' or 'get_pool_info')
connector string CLMM connector name (e.g., 'meteora', 'raydium', 'uniswap')
detailed boolean optional Return detailed table with more columns including mint addresses, fee percentages, and time-series metrics (default: False)
include_unknown boolean optional Include pools with unverified tokens (default: True)
limit integer optional Results per page for list_pools (default: 50, max: 100)
network string optional Network ID in 'chain-network' format (required for get_pool_info, e.g., 'solana-mainnet-beta')
order_by string optional Sort order ('asc' or 'desc')
page integer optional Page number for list_pools (default: 0)
pool_address string optional Pool contract address (required for get_pool_info)
search_term string optional Search term to filter pools by token symbols (e.g., 'SOL', 'USDC')
sort_key string optional Sort by field (volume, tvl, feetvlratio, etc.)

Tool: get_active_bots_status

Get the status of all active bots. Including the unrealized PnL, realized PnL, volume traded, latest logs, etc. Note: Both error logs and general logs are limited to the last 5 entries. Use get_bot_logs for more detailed log searching.

Tool: get_bot_logs

Get detailed logs for a specific bot with filtering options.

Parameters Type Description
bot_name string Name of the bot to get logs for
limit integer optional Maximum number of log entries to return (default: 50, max: 1000)
log_type string optional Type of logs to retrieve ('error', 'general', or 'all')
search_term string optional Optional search term to filter logs by message content

Tool: get_candles

Get the real-time candles for a trading pair on a specific exchange connector.

Parameters Type Description
connector_name string Exchange connector name (e.g., 'binance', 'binance_perpetual')
trading_pair string Trading pair to get candles for (e.g., 'BTC-USDT')
days integer optional Number of days of historical data to retrieve (default: 30).
interval string optional Candle interval (default: '1h'). Options include '1m', '5m', '15m', '30m', '1h', '4h', '1d'.

Tool: get_funding_rate

Get the latest funding rate for a trading pair on a specific exchange connector. Only works for perpetual connectors so the connector name must have _perpetual in it.

Parameters Type Description
connector_name string Exchange connector name (e.g., 'binance_perpetual', 'hyperliquid_perpetual')
trading_pair string Trading pair to get funding rate for (e.g., 'BTC-USDT')

Tool: get_order_book

Get order book data for a trading pair on a specific exchange connector, if the query type is different than snapshot, you need to provide query_value and is_buy

Parameters Type Description
connector_name string Connector name (e.g., 'binance', 'binance_perpetual')
query_type string Order book query type ('snapshot', 'volume_for_price', 'price_for_volume', 'quote_volume_for_price',
trading_pair string Trading pair (e.g., BTC-USDT)
is_buy boolean optional Only required if query_type is not 'snapshot'. Is important to see what orders of the book analyze.
query_value string optional Only required if query_type is not 'snapshot'. The value to query against the order book.

Tool: get_portfolio_overview

Get a unified portfolio overview with balances, perpetual positions, LP positions, and active orders.

This tool provides a comprehensive view of your entire portfolio by fetching data from multiple sources
in parallel. By default, it returns all four types of data, but you can filter to only include
specific sections.

Data Sources (fetched in parallel using asyncio.gather):
1. Token Balances - Holdings across all connected CEX/DEX exchanges
2. Perpetual Positions - Open perpetual futures positions from CEX
3. LP Positions (CLMM) - Real-time concentrated liquidity positions from blockchain DEXs
   - Queries database to find all pools user has interacted with
   - Calls get_positions() for each pool to fetch real-time blockchain data
   - Includes real-time fees and token amounts
4. Active Orders - Currently open orders across all exchanges

NOTE: This only shows ACTIVE/OPEN positions. For historical data, use search_history() instead.
Parameters Type Description
account_names string optional List of account names to filter by (optional). If empty, returns all accounts.
as_distribution boolean optional Show token balances as distribution percentages (default: False)
connector_names string optional List of connector names to filter by (optional). If empty, returns all connectors.
include_active_orders boolean optional Include active (open) orders in the overview (default: True)
include_balances boolean optional Include token balances in the overview (default: True)
include_lp_positions boolean optional Include LP (CLMM) positions in the overview (default: True)
include_perp_positions boolean optional Include perpetual positions in the overview (default: True)

Tool: get_prices

Get the latest prices for the specified trading pairs on a specific exchange connector.

Parameters Type Description
connector_name string Exchange connector name (e.g., 'binance', 'binance_perpetual')
trading_pairs array List of trading pairs to get prices for (e.g., ['BTC-USDT', 'ETH-USD'])

Tool: manage_bot_execution

Manage bot and controller execution states.

Actions:
- "stop_bot": Stop and archive the entire bot forever (controller_names not needed)
- "stop_controllers": Stop specific controllers by setting manual_kill_switch to True (requires controller_names)
- "start_controllers": Start/resume specific controllers by setting manual_kill_switch to False (requires controller_names)
Parameters Type Description
action string The action to perform ("stop_bot", "stop_controllers", or "start_controllers")
bot_name string Name of the bot to manage
controller_names string optional List of controller names (required for stop_controllers and start_controllers actions)

Tool: manage_gateway_clmm_positions

Manage Gateway CLMM positions: open, close, collect fees, and get positions.

Supports CLMM DEX connectors (Meteora, Raydium, Uniswap V3) for concentrated liquidity positions.

Actions:
- open_position: Create a new CLMM position with initial liquidity
- close_position: Close a position completely (removes all liquidity)
- collect_fees: Collect accumulated fees from a position
- get_positions: Get all positions owned by a wallet for a specific pool (fetches real-time data from blockchain)

Open Position Parameters (required for open_position):
    connector: CLMM connector name (e.g., 'meteora', 'raydium')
    network: Network ID in 'chain-network' format (e.g., 'solana-mainnet-beta')
    pool_address: Pool contract address
    lower_price: Lower price bound (e.g., '150')
    upper_price: Upper price bound (e.g., '250')
    base_token_amount: Amount of base token to provide (optional)
    quote_token_amount: Amount of quote token to provide (optional)
    slippage_pct: Maximum slippage percentage (default: 1.0)
    wallet_address: Wallet address (optional, uses default if not provided)
    extra_params: Additional connector-specific parameters (e.g., {"strategyType": 0} for Meteora)

Close/Collect Parameters (required for close_position and collect_fees):
    connector: CLMM connector name
    network: Network ID in 'chain-network' format
    position_address: Position NFT address
    wallet_address: Wallet address (optional)

Get Positions Parameters (required for get_positions):
    connector: CLMM connector name
    network: Network ID in 'chain-network' format
    pool_address: Pool contract address
    wallet_address: Wallet address (optional)
Parameters Type Description
action string
base_token_amount string optional Amount of base token to provide (optional)
connector string optional CLMM connector name (e.g., 'meteora', 'raydium')
extra_params string optional Additional connector-specific parameters (e.g., {"strategyType": 0} for Meteora)
lower_price string optional Lower price bound (e.g., '150')
network string optional Network ID in 'chain-network' format (e.g., 'solana-mainnet-beta')
pool_address string optional Pool contract address
position_address string optional Position NFT address
quote_token_amount string optional Amount of quote token to provide (optional)
slippage_pct string optional Maximum slippage percentage (default: 1.0)
upper_price string optional Upper price bound (e.g., '250')
wallet_address string optional Wallet address (optional, uses default if not provided)

Tool: manage_gateway_config

Manage Gateway configuration for chains, networks, tokens, connectors, pools, and wallets.

Resource Types:
- chains: Get all blockchain chains
- networks: List/get/update network configurations (format: 'chain-network')
- tokens: List/add/delete tokens per network
- connectors: List/get/update DEX connector configurations
- pools: List/add liquidity pools per connector/network
- wallets: Add/delete wallets for blockchain chains
Parameters Type Description
action string Action to perform on the resource
resource_type string Type of resource to manage
chain string optional Blockchain chain for wallet (e.g., 'solana', 'ethereum')
config_updates string optional Configuration updates as key-value pairs
connector_name string optional DEX connector name (e.g., 'meteora', 'raydium')
network string optional Network name (e.g., 'mainnet-beta') for pool operations
network_id string optional Network ID in format 'chain-network' (e.g., 'solana-mainnet-beta')
pool_address string optional Pool contract address
pool_base string optional Base token symbol for pool
pool_quote string optional Quote token symbol for pool
pool_type string optional Pool type (e.g., 'CLMM', 'AMM')
private_key string optional Private key for wallet (required for 'add' wallet action)
search string optional Search term to filter tokens
token_address string optional Token contract address
token_decimals string optional Token decimals (e.g., 6 for USDC)
token_name string optional Token name (optional)
token_symbol string optional Token symbol (e.g., 'USDC')
wallet_address string optional Wallet address (required for 'delete' wallet action)

Tool: manage_gateway_container

Manage Gateway container lifecycle operations.

Supports:
- get_status: Check Gateway container status
- start: Start Gateway with configuration
- stop: Stop Gateway container
- restart: Restart Gateway (optionally with new config)
- get_logs: Get container logs
Parameters Type Description
action string Action to perform on Gateway container
config string optional Gateway configuration (required for 'start', optional for 'restart').
tail string optional Number of log lines to retrieve (only for 'get_logs' action, default: 100, max: 200)

Tool: manage_gateway_swaps

Manage Gateway swap operations: quote, execute, search swaps.

Supports DEX router swaps via Jupiter (Solana) and 0x (Ethereum).

Actions:
- quote: Get price quote for a swap before executing
- execute: Execute a swap transaction on DEX
- search: Search swap history with filters
- get_status: Get status of a specific swap by transaction hash

Quote/Execute Parameters (required for quote/execute):
    connector: DEX router connector (e.g., 'jupiter', '0x')
    network: Network ID in 'chain-network' format (e.g., 'solana-mainnet-beta', 'ethereum-mainnet')
    trading_pair: Trading pair in BASE-QUOTE format (e.g., 'SOL-USDC', 'ETH-USDT')
    side: Trade side - 'BUY' (buy base with quote) or 'SELL' (sell base for quote)
    amount: Amount to swap (for BUY: base to receive, for SELL: base to sell)
    slippage_pct: Maximum slippage percentage (default: 1.0)
    wallet_address: Wallet address for execute (optional, uses default if not provided)

Get Status Parameters:
    transaction_hash: Transaction hash to check status

Search Parameters (all optional):
    search_connector: Filter by connector
    search_network: Filter by network
    search_wallet_address: Filter by wallet address
    search_trading_pair: Filter by trading pair
    status: Filter by status (SUBMITTED, CONFIRMED, FAILED)
    start_time: Start timestamp (unix seconds)
    end_time: End timestamp (unix seconds)
    limit: Max results (default: 50, max: 1000)
    offset: Pagination offset (default: 0)
Parameters Type Description
action string
amount string optional Amount to swap (for BUY: base to receive, for SELL: base to sell)
connector string optional DEX router connector (e.g., 'jupiter', '0x')
end_time string optional End timestamp (unix seconds)
limit string optional Max results (default: 50, max: 1000)
network string optional Network ID in 'chain-network' format (e.g., 'solana-mainnet-beta', 'ethereum-mainnet')
offset string optional Pagination offset (default: 0)
search_connector string optional Filter by connector
search_network string optional Filter by network
search_trading_pair string optional Filter by trading pair
search_wallet_address string optional Filter by wallet address
side string optional Trade side - 'BUY' (buy base with quote) or 'SELL' (sell base for quote)
slippage_pct string optional Maximum slippage percentage (default: 1.0)
start_time string optional Start timestamp (unix seconds)
status string optional Filter by status (SUBMITTED, CONFIRMED, FAILED)
trading_pair string optional Trading pair in BASE-QUOTE format (e.g., 'SOL-USDC', 'ETH-USDT')
transaction_hash string optional Transaction hash to check status
wallet_address string optional Wallet address for execute (optional, uses default if not provided)

Tool: modify_controllers

Create, update, or delete controllers and their configurations. If bot name is provided, it can only modify the config in the bot deployed with that name.

IMPORTANT: When creating a config without specifying config_data details, you MUST first use the explore_controllers tool
with action="describe" and the controller_name to understand what parameters are required. The config_data must include
ALL relevant parameters for the controller to function properly.

Controllers = are essentially strategies that can be run in Hummingbot.
Configs = are the parameters that the controller uses to run.
Parameters Type Description
action string "upsert" (create/update) or "delete"
target string "controller" (template) or "config" (instance)
bot_name string optional
config_data string optional For config creation, MUST contain all required controller parameters. Use explore_controllers first!
config_name string optional
confirm_override boolean optional Required True if overwriting existing
controller_code string optional
controller_name string optional
controller_type string optional

Tool: place_order

Place a buy or sell order on a OrderBook Exchange (supports USD values by adding at the start of the amount $).

Parameters Type Description
amount string Order amount (is always in base currency, if you want to use USD values, add a dollar sign at the start, e.g., '$100')
connector_name string Exchange connector name (e.g., 'binance', 'binance_perpetual')
trade_type string Order side ('BUY' or 'SELL')
trading_pair string Trading pair (e.g., BTC-USDT, ETH-USD)
account_name string optional Account name (default: master_account)
order_type string optional Order type ('MARKET' or 'LIMIT')
position_action string optional Position action ('OPEN', 'CLOSE'). Defaults to 'OPEN' and is useful for perpetuals with HEDGE mode where you
price string optional Price for limit orders (required for limit orders)

Tool: search_history

Search historical data from the backend database.

This tool is for historical analysis, reporting, and tax purposes.
For real-time current state, use get_portfolio_overview() instead.

Data Types:
- orders: Historical order data (filled, cancelled, failed)
- perp_positions: Perpetual positions (both open and closed)
- clmm_positions: CLMM LP positions (both open and closed)

Common Filters (apply to all data types):
    account_names: Filter by account names (optional)
    connector_names: Filter by connector names (optional)
    trading_pairs: Filter by trading pairs (optional)
    status: Filter by status (optional, e.g., 'OPEN', 'CLOSED', 'FILLED', 'CANCELED')
    start_time: Start timestamp in seconds (optional)
    end_time: End timestamp in seconds (optional)
    limit: Maximum number of results (default: 50, max: 1000)
    offset: Pagination offset (default: 0)

CLMM-Specific Filters:
    network: Network filter for CLMM positions (optional)
    wallet_address: Wallet address filter for CLMM positions (optional)
    position_addresses: Specific position addresses for CLMM (optional)

Examples:
- Search filled orders: search_history("orders", status="FILLED", limit=100)
- Search closed perp positions: search_history("perp_positions", status="CLOSED")
- Search all CLMM positions: search_history("clmm_positions", limit=100)
Parameters Type Description
data_type string
account_names string optional Filter by account names (optional)
connector_names string optional Filter by connector names (optional)
end_time string optional End timestamp in seconds (optional)
limit integer optional Maximum number of results (default: 50, max: 1000)
network string optional Network filter for CLMM positions (optional)
offset integer optional Pagination offset (default: 0)
position_addresses string optional Specific position addresses for CLMM (optional)
start_time string optional Start timestamp in seconds (optional)
status string optional Filter by status (optional, e.g., 'OPEN', 'CLOSED', 'FILLED', 'CANCELED')
trading_pairs string optional Filter by trading pairs (optional)
wallet_address string optional Wallet address filter for CLMM positions (optional)

Tool: set_account_position_mode_and_leverage

Set position mode and leverage for an account on a specific exchange. If position mode is not specified, will only set the leverage. If leverage is not specified, will only set the position mode.

Parameters Type Description
account_name string Account name (default: master_account)
connector_name string Exchange connector name (e.g., 'binance_perpetual')
leverage string optional Leverage to set (optional, required for HEDGE mode)
position_mode string optional Position mode ('HEDGE' or 'ONE-WAY')
trading_pair string optional Trading pair (e.g., ETH-USD) only required for setting leverage

Tool: setup_connector

Setup a new exchange connector for an account with credentials using progressive disclosure.

This tool guides you through the entire process of connecting an exchange with a four-step flow:
1. No parameters → List available exchanges
2. Connector only → Show required credential fields
3. Connector + credentials, no account → Select account from available accounts
4. All parameters → Connect the exchange (with override confirmation if needed)
Parameters Type Description
account string optional Account name to add credentials to. If not provided, prompts for account selection.
confirm_override string optional Explicit confirmation to override existing connector. Required when connector already exists.
connector string optional Exchange connector name (e.g., 'binance', 'binance_perpetual'). Leave empty to list available connectors.
credentials string optional Credentials object with required fields for the connector. Leave empty to see required fields first.

Use this MCP Server

{
  "mcpServers": {
    "hummingbot-mcp": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "-e",
        "HUMMINGBOT_API_URL",
        "-e",
        "HUMMINGBOT_API_USERNAME",
        "-e",
        "HUMMINGBOT_API_PASSWORD",
        "hummingbot/hummingbot-mcp"
      ],
      "env": {
        "HUMMINGBOT_API_URL": "http://localhost:8000",
        "HUMMINGBOT_API_USERNAME": "admin",
        "HUMMINGBOT_API_PASSWORD": "password"
      }
    }
  }
}

Why is it safer to run MCP Servers with Docker?