POST

/api/v1/bots/grid

Permission: BOTS_WRITESecurity: SIGNED

Creates a new manual Grid Bot with custom price boundaries, grid level counts, order volume allocations, stop-loss rules, and trailing options.

If successful, the response returns the created Grid Bot entity.
Grid Bot Entity

Body Parameters

28
namestring required

Grid Bot name specified by the user (1 to 40 characters). If not specified, the system will generate a default name automatically.

account_idinteger required

ID of the exchange account entity where the Grid Bot is created.

pairstring required

Trading pair in Quentrade format (e.g. USDT_ETH). Use the All market pairs endpoint to retrieve supported pairs.

upper_pricenumber required

The maximum price of the trading range, above which the bot will not place sell orders.

lower_pricenumber / string required

The minimum price of the trading range, below which the bot will not place buy orders.

grids_quantitynumber required

The number of grid levels distributed between the upper and lower price boundaries.

quantity_per_gridnumber required

Quantity of the asset allocated per Grid Bot level order.

grid_typestring
default: arithmetic

Type of Grid Bot configuration: geometric (percentage step) or arithmetic (fixed dollar step).

order_currency_typestring
default: quote

The currency type used for placing orders: base or quote.

profit_currency_typestring
default: quote

The currency in which the bot will generate profit: base or quote.

upper_stop_loss_enabledboolean
default: false

Indicates if upper stop-loss settings are enabled (true) or not (false).

upper_stop_loss_actionstring
default: stop_bot

The action to perform if asset price reaches or exceeds upper stop-loss: stop_bot, stop_bot_and_buy, or stop_bot_and_close_position.

upper_stop_loss_pricenumber

The price level that triggers the upper stop-loss action.

lower_stop_loss_enabledboolean
default: false

Indicates if lower stop-loss settings are enabled (true) or not (false).

lower_stop_loss_actionstring
default: stop_bot

The action to perform if asset price reaches or falls below lower stop-loss: stop_bot, stop_bot_and_sell, or stop_bot_and_close_position.

lower_stop_loss_pricenumber

The price level that triggers the lower stop-loss action.

leverage_typestring
default: not_specified

Type of leverage applied: cross (uses account collateral), isolated (limits margin to position), or not_specified.

leverage_custom_valuenumber

Custom leverage multiplier value set for the Grid Bot.

modestring

Grid strategy mode: long (price increase), short (price decrease), or reversal (trend reversal trading).

max_active_sell_linesinteger

Maximum number of active sell orders that can be placed simultaneously.

trailing_up_enabledboolean
default: false

Indicates if the trailing-up feature is enabled (true) or not (false).

trailing_down_enabledboolean
default: false

Indicates if the trailing-down feature is enabled (true) or not (false).

expansion_down_enabledboolean
default: false

Indicates if grid expansion downwards is enabled (true) or not (false).

expansion_down_stop_pricenumber

The price at which downward grid expansion stops. Required when expansion_down_enabled is true.

expansion_up_enabledboolean
default: false

Indicates if grid expansion upwards is enabled (true) or not (false).

expansion_up_stop_pricenumber

The price at which upward grid expansion stops. Required when expansion_up_enabled is true.

ignore_warningsboolean
default: false

Ignores configuration warnings and forces the creation of the Grid Bot (true / false).

notestring

Optional user-defined note for the Grid Bot (1 to 300 characters).

Strategy & Risk Configuration Guide

Grid Types

Arithmetic grids space lines at fixed dollar intervals. Geometric grids space lines at fixed percentage intervals, ensuring identical profit margin per grid step.

Stop Loss Actions

Configure automated bot shutdown, liquidation into quote currency (stop_bot_and_sell), base accumulation (stop_bot_and_buy), or futures position closing (stop_bot_and_close_position).

Trailing & Expansion

Trailing shifts the entire grid corridor dynamically. Grid expansion adds new grid lines upward or downward until designated stop prices are reached.

Example Request

create_grid_bot_manual_request.json
POST /api/v1/bots/grid
{
  "account_id": 12345678,
  "pair": "USDT_ETH",
  "name": "Test GRID",
  "upper_price": 1.1,
  "lower_price": 0.56,
  "quantity_per_grid": 40,
  "grids_quantity": 28,
  "max_active_buy_lines": 28,
  "max_active_sell_lines": 28,
  "order_currency_type": "base",
  "profit_currency_type": "base",
  "ignore_warnings": false,
  "trailing_up_enabled": false,
  "trailing_down_enabled": true,
  "grid_type": "arithmetic",
  "expansion_down_enabled": false,
  "expansion_up_enabled": true,
  "expansion_up_stop_price": 1.57
}

Example Responses

If successful, returns HTTP 201 with the created Grid Bot entity representation.

create_grid_bot_manual_201.json
201 Created
{
  "id": 2291723,
  "account_id": 73223,
  "account_name": "binance",
  "is_enabled": false,
  "grids_quantity": "50",
  "created_at": "2024-07-17T14:46:46.414Z",
  "updated_at": "2024-07-17T14:46:46.505Z",
  "strategy_type": "manual",
  "upper_stop_loss_enabled": true,
  "lower_stop_loss_enabled": true,
  "note": "Example bot",
  "editable": true,
  "lower_price": "56000.0",
  "lower_stop_loss_price": "50000.0",
  "lower_stop_loss_action": "stop_bot_and_sell",
  "upper_price": "72000.0",
  "upper_stop_loss_price": "75000.0",
  "upper_stop_loss_action": "stop_bot",
  "quantity_per_grid": "15.0",
  "leverage_type": "not_specified",
  "leverage_custom_value": null,
  "name": "USDT_BTC EXAMPLE",
  "pair": "USDT_BTC",
  "start_price": null,
  "grid_price_step": "326.530612244897959183673469387755102041",
  "current_profit": "0.0",
  "current_profit_usd": "0.0",
  "total_profits_count": "0",
  "bought_volume": "0.0",
  "sold_volume": "0.0",
  "profit_percentage": "0.0",
  "current_price": "65229.37",
  "max_active_buy_lines": "50",
  "max_active_sell_lines": "50",
  "order_currency_type": "quote",
  "profit_currency_type": "quote",
  "trailing_up_enabled": "true",
  "grid_type": "arithmetic",
  "investment_base_currency": "0.0",
  "investment_quote_currency": "0.0",
  "unrealized_profit_loss": "0",
  "current_profit_loss": null,
  "current_profit_loss_percent": null,
  "orderbook_price_currency": "USDT",
  "expansion_down_enabled": "true",
  "expansion_down_stop_price": "54000.0",
  "grid_lines": [
    {
      "id": 253750214,
      "price": "65142.86",
      "side": null,
      "order_placed": false
    },
    {
      "id": 253750235,
      "price": "72000.0",
      "side": "sell",
      "order_placed": false
    },
    {
      "id": 253750213,
      "price": "64816.33",
      "side": "buy",
      "order_placed": false
    }
  ],
  "mode": null
}