Hummingbot MCP: Trading Agent

Hummingbot MCP: Trading Agent

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

15 Tools

Requires Configuration
Requires Secrets
Add to Docker Desktop

Version 4.43 or later needs to be installed to add the server automatically

Use cases

About

Hummingbot MCP: 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

Image Building InfoDockerfile|https://github.com/hummingbot/mcp/blob/main/Dockerfile

Docker Image built by|hummingbot Docker Scout Health Score|Not available Verify Signature|Not available Licence|Apache License 2.0

Available Tools (15)

Tools provided by this ServerShort Description
deploy_bot_with_controllersDeploy a bot with specified controller configurations.
explore_controllersExplore and understand controllers and their configs.
get_active_bots_statusGet the status of all active bots.
get_candlesGet the real-time candles for a trading pair on a specific exchange connector.
get_funding_rateGet the latest funding rate for a trading pair on a specific exchange connector.
get_order_bookGet 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_ordersGet the orders manged by the connected accounts.
get_portfolio_balancesGet portfolio balances and holdings across all connected exchanges.
get_positionsGet the positions managed by the connected accounts.
get_pricesGet the latest prices for the specified trading pairs on a specific exchange connector.
modify_controllersCreate, update, or delete controllers and their configurations.
place_orderPlace a buy or sell order (supports USD values by adding at the start of the amount $).
set_account_position_mode_and_leverageSet position mode and leverage for an account on a specific exchange.
setup_connectorSetup a new exchange connector for an account with credentials using progressive disclosure.
stop_bot_or_controllersStop and archive a bot forever or stop the execution of a controller of a runnning bot.

Tools Details

Tool: deploy_bot_with_controllers

Deploy a bot with specified controller configurations.

ParametersTypeDescription
bot_namestringName of the bot to deploy
controllers_configarrayList of controller configs to use for the bot deployment.
account_namestringoptionalAccount name to use for the bot (default: master_account)
imagestringoptionalDocker image to use for the bot (default: "hummingbot/hummingbot:latest")
max_controller_drawdown_quotestringoptionalMaximum drawdown per controller in quote currency (optional) defaults to None.
max_global_drawdown_quotestringoptionalMaximum 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
ParametersTypeDescription
actionstring"list" to list controllers or "describe" to show details of a specific controller or config.
config_namestringoptionalName of the config to describe (optional, only required for describe specific config).
controller_namestringoptionalName of the controller to describe (optional, only required for describe specific controller).
controller_typestringoptionalType of controller to filter by (optional, e.g., 'directional_trading', 'market_making', 'generic').

Tool: get_active_bots_status

Get the status of all active bots. Including the unrealized PnL, realized PnL, volume traded, latest logs, etc.

Tool: get_candles

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

ParametersTypeDescription
connector_namestringExchange connector name (e.g., 'binance', 'binance_perpetual')
trading_pairstringTrading pair to get candles for (e.g., 'BTC-USDT')
daysintegeroptionalNumber of days of historical data to retrieve (default: 30).
intervalstringoptionalCandle 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.

ParametersTypeDescription
connector_namestringExchange connector name (e.g., 'binance_perpetual', 'hyperliquid_perpetual')
trading_pairstringTrading 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

ParametersTypeDescription
connector_namestringConnector name (e.g., 'binance', 'binance_perpetual')
query_typestringOrder book query type ('snapshot', 'volume_for_price', 'price_for_volume', 'quote_volume_for_price',
trading_pairstringTrading pair (e.g., BTC-USDT)
is_buybooleanoptionalOnly required if query_type is not 'snapshot'. Is important to see what orders of the book analyze.
query_valuestringoptionalOnly required if query_type is not 'snapshot'. The value to query against the order book.

Tool: get_orders

Get the orders manged by the connected accounts.

ParametersTypeDescription
account_namesstringoptionalList of account names to filter by (optional). If empty, returns all accounts.
connector_namesstringoptionalList of connector names to filter by (optional). If empty, returns all connectors.
cursorstringoptionalCursor for pagination (optional, should be used if another request returned a cursor).
end_timestringoptionalEnd time (in seconds) to filter by (optional).
limitstringoptionalNumber of orders to return defaults to 500, maximum is 1000.
start_timestringoptionalStart time (in seconds) to filter by (optional).
statusstringoptionalOrder status to filter by can be OPEN, PARTIALLY_FILLED, FILLED, CANCELED, FAILED (is optional).
trading_pairsstringoptionalList of trading pairs to filter by (optional). If empty, returns all trading pairs.

Tool: get_portfolio_balances

Get portfolio balances and holdings across all connected exchanges.

Returns detailed token balances, values, and available units for each account. Use this to check your portfolio,
see what tokens you hold, and their current values. If passing accounts and connectors it will only return the
filtered accounts and connectors, leave it empty to return all accounts and connectors.
You can also get the portfolio distribution by setting `as_distribution` to True, which will return the distribution
of tokens and their values across accounts and connectors and the percentage of each token in the portfolio.
ParametersTypeDescription
account_namesstringoptionalList of account names to filter by (optional). If empty, returns all accounts.
as_distributionbooleanoptionalIf True, returns the portfolio distribution as a percentage of each token in the portfolio and
connector_namesstringoptionalList of connector names to filter by (optional). If empty, returns all connectors.

Tool: get_positions

Get the positions managed by the connected accounts.

ParametersTypeDescription
account_namesstringoptionalList of account names to filter by (optional). If empty, returns all accounts.
connector_namesstringoptionalList of connector names to filter by (optional). If empty, returns all connectors.
limitstringoptionalNumber of positions to return defaults to 100, maximum is 1000.

Tool: get_prices

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

ParametersTypeDescription
connector_namestringExchange connector name (e.g., 'binance', 'binance_perpetual')
trading_pairsarrayList of trading pairs to get prices for (e.g., ['BTC-USDT', 'ETH-USD'])

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.
ParametersTypeDescription
actionstring"upsert" (create/update) or "delete"
targetstring"controller" (template) or "config" (instance)
bot_namestringoptional
config_datastringoptionalFor config creation, MUST contain all required controller parameters. Use explore_controllers first!
config_namestringoptional
confirm_overridebooleanoptionalRequired True if overwriting existing
controller_codestringoptional
controller_namestringoptional
controller_typestringoptional

Tool: place_order

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

ParametersTypeDescription
amountstringOrder amount (is always in base currency, if you want to use USD values, add a dollar sign at the start, e.g., '$100')
connector_namestringExchange connector name (e.g., 'binance', 'binance_perpetual')
trade_typestringOrder side ('BUY' or 'SELL')
trading_pairstringTrading pair (e.g., BTC-USDT, ETH-USD)
account_namestringoptionalAccount name (default: master_account)
order_typestringoptionalOrder type ('MARKET' or 'LIMIT')
position_actionstringoptionalPosition action ('OPEN', 'CLOSE'). Defaults to 'OPEN' and is useful for perpetuals with HEDGE mode where you
pricestringoptionalPrice for limit orders (required for limit orders)

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.

ParametersTypeDescription
account_namestringAccount name (default: master_account)
connector_namestringExchange connector name (e.g., 'binance_perpetual')
leveragestringoptionalLeverage to set (optional, required for HEDGE mode)
position_modestringoptionalPosition mode ('HEDGE' or 'ONE-WAY')
trading_pairstringoptionalTrading 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)
ParametersTypeDescription
accountstringoptionalAccount name to add credentials to. If not provided, prompts for account selection.
confirm_overridestringoptionalExplicit confirmation to override existing connector. Required when connector already exists.
connectorstringoptionalExchange connector name (e.g., 'binance', 'binance_perpetual'). Leave empty to list available connectors.
credentialsstringoptionalCredentials object with required fields for the connector. Leave empty to see required fields first.

Tool: stop_bot_or_controllers

Stop and archive a bot forever or stop the execution of a controller of a runnning bot. If the controllers to stop are not specified, it will stop the bot execution and archive it forever, if they are specified, will only stop the execution of those controllers and the bot will still be running with the rest of the controllers.

ParametersTypeDescription
bot_namestringName of the bot to stop
controller_namesstringoptionalList of controller names to stop (optional, if not provided will stop the bot execution)

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?

Manual installation

You can install the MCP server using:

Installation for

Related servers