Skip to main content

Modify Order

Modify Order

Description​

Support modifying orders using either the order ID (orderId) or a custom order ID (clientOid).

  • Only orders that have not been fully filled can be modified. If an order has been completely filled, it cannot be modified through this interface.
  • After submitting a modification request and before receiving the result, repeated modification requests cannot be submitted.

HTTP Request​

  • POST /api/v3/trade/modify-order
  • Rate limit: 10/sec/UID
  • Permission: UTA trade
Request
curl -X POST "https://api.bitget.com/api/v3/trade/modify-order" \
-H "ACCESS-KEY:your apiKey" \
-H "ACCESS-SIGN:*" \
-H "ACCESS-PASSPHRASE:*" \
-H "ACCESS-TIMESTAMP:1659076670000" \
-H "locale:zh-CN" \
-H "Content-Type: application/json" \
-d '{ "orderId": "1","qty": "123", "price": "123", "autoCancel": "no" }'

Request Parameters​

ParametersTypeRequiredDescription
orderIdStringNoOrder ID
Either orderId or clientOid must be provided
If both orderId and clientOid are provided simultaneously, orderId takes higher priority
clientOidStringNoClient order ID
Either orderId or clientOid must be provided
If both orderId and clientOid are provided simultaneously, orderId takes higher priority
qtyStringNoOrder quantity
Base coin
Either qty or price must be provided
priceStringNoOrder price
Either qty or price must be provided
autoCancelStringNoWill the original order be canceled if the order modification fails
yes: Cancel
no: Not cancel(default)
When set to yes: if the matching engine fails to modify the order, the order is cancelled immediately; after cancellation, the counter will reject any further modification requests for that order (including in-flight and new requests).
symbolStringNoSymbol name
e.g.,BTCUSDT
categoryStringNoProduct type
SPOT Spot trading
MARGIN Margin trading
USDT-FUTURES USDT futures
COIN-FUTURES Coin-M futures
USDC-FUTURES USDC futures
tpTriggerByStringNoPreset Take-Profit Trigger Type
market Market price
mark Mark price
Defaults to market price if not specified
Only valid for futures: USDT-FUTURES, COIN-FUTURES, USDC-FUTURES
If not provided or empty, the existing value remains unchanged
slTriggerByStringNoPreset Stop-Loss Trigger Type
market Market price
mark Mark price
Defaults to market price if not specified
Only valid for futures: USDT-FUTURES, COIN-FUTURES, USDC-FUTURES
If not provided or empty, the existing value remains unchanged
takeProfitStringNoPreset Take-Profit Trigger Price
If not provided or empty, the existing value remains unchanged
Pass "0" to cancel take-profit
stopLossStringNoPreset Stop-Loss Trigger Price
If not provided or empty, the existing value remains unchanged
Pass "0" to cancel stop-loss
tpOrderTypeStringNoTake-Profit Strategy Order Type
limit Limit order
market Market order
slOrderTypeStringNoStop-Loss Strategy Order Type
limit Limit order
market Market order
tpLimitPriceStringNoTake-Profit Strategy Order Execution Price
Only valid for limit orders (tpOrderType=limit); ignored for market orders
If not provided or empty, the existing value remains unchanged
slLimitPriceStringNoStop-Loss Strategy Order Execution Price
Only valid for limit orders (slOrderType=limit); ignored for market orders
If not provided or empty, the existing value remains unchanged
Response
{
"code": "00000",
"data": {
"orderId": "121212121212",
"clientOid": "BITGET#1627293504612"
},
"msg": "success",
"requestTime": 1627293504612
}

Response Parameters​

ParameterTypeComments
orderIdStringOrder ID
clientOidStringClient order ID

How was your Reading Experience with us?

★
★
★
★
★