Bot Orchestration

Deploy V2 Script

Deploy a new Hummingbot instance with a V2 script.

Creates a new Docker container running Hummingbot configured with a specified script and optional script configuration. The container is automatically started and begins executing the trading strategy.

This is the primary method for deploying custom scripts. For controller-based strategies, use deploy-v2-controllers instead.

The deployment process:

  1. Creates a new Docker container from the specified Hummingbot image
  2. Mounts necessary volumes (configs, credentials, scripts)
  3. Sets up MQTT communication for bot control
  4. Creates a bot run record in the database for tracking
  5. Starts the container with the specified script (if auto-start enabled)
post/bot-orchestration/deploy-v2-script

Request body

instance_namestring required

Unique name for the bot instance. This becomes the Docker container name and is used to identify the bot in all subsequent operations. Use descriptive names like 'btc-maker' or 'eth-arb'. Avoid special characters except hyphens.

credentials_profilestring required

Name of the exchange credentials profile to use. The profile must exist in the credentials directory (credentials/{profile_name}.yml). Contains API keys and secrets for exchange authentication.

imagestring

Docker image to use for the Hummingbot instance. Use 'latest' for the most recent version or specify a tag for version pinning (recommended for production). Custom images can also be used if they're based on the official Hummingbot image.

scriptstring nullable

Name of the Python script to run (without .py extension). The script must exist in the scripts directory. If not specified, the bot starts without running a script and must be started manually via the start-bot endpoint.

script_configstring nullable

Name of the script configuration file (without .yml extension). Must exist in conf/scripts/ directory. Contains strategy-specific parameters like trading pairs, order sizes, and spread settings. Required if the script needs configuration.

headlessboolean

When True, runs the bot without the terminal UI. Reduces resource usage but removes the ability to interact with the bot directly via terminal. Recommended for production deployments that are fully managed via API.

Example request

{
  "instance_name": "my-scalping-bot",
  "credentials_profile": "binance_main",
  "image": "hummingbot/hummingbot:latest",
  "script": "v2_with_controllers",
  "script_config": "dman_maker_config"
}

Response

Successful Response

object required

Changes