set_trading_stop
Set take profit, stop loss, or trailing stop for a trading position on Bybit. Manage risk by defining exit conditions with price types and order sizes.
Instructions
Set take profit, stop loss, or trailing stop for a position (MEDIUM risk).
Args:
category: Product type - linear, inverse
symbol: Symbol name
takeProfit: Take profit price
stopLoss: Stop loss price
trailingStop: Trailing stop distance
tpTriggerBy: TP trigger price type - LastPrice, MarkPrice, IndexPrice
slTriggerBy: SL trigger price type
tpSize: TP order quantity
slSize: SL order quantity
positionIdx: Position index (0: one-way, 1: hedge buy, 2: hedge sell)
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| slSize | No | ||
| symbol | Yes | ||
| tpSize | No | ||
| category | Yes | ||
| stopLoss | No | ||
| takeProfit | No | ||
| positionIdx | No | ||
| slTriggerBy | No | ||
| tpTriggerBy | No | ||
| trailingStop | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |