Skip to main content

Modify Order

Modify the price or quantity of an unfilled perpetual futures order (cancel old order + place new order).

API Information

Request Parameters

ParameterLocationTypeRequiredDescription
idpathstringYesOriginal order ID

Body

ParameterTypeRequiredDescription
pricestringYesNew price
qtystringYesNew quantity
resp_typeintegerNoResponse type: 1=ACK, 2=RESULT, 3=FULL (default 2)

Request Example

PUT /fapi/v1/orders/1234567890123456789
{
"price": "68600.00",
"qty": "0.2",
"resp_type": 2
}

Response Fields

Returns the modified order information (same as order detail).

FieldTypeDescription
codeintegerStatus code
messagestringResponse message
data.idstringNew order ID
data.client_order_idstringClient order ID
data.symbolstringTrading pair
data.statusintegerOrder status
data.pricestringOrder price
data.qtystringOrder quantity
data.updated_atintegerUpdate time (milliseconds)

Response Example

{
"code": 0,
"message": "success",
"data": {
"id": "1234567890123456790",
"symbol": "BTC_USDT",
"client_order_id": "my-order-001",
"status": 1,
"price": "68600.00",
"qty": "0.2",
"filled_qty": "0",
"filled_quote": "0",
"avg_price": "0",
"side": 1,
"type": 1,
"leverage": 10,
"margin_mode": 1,
"position_action": 1,
"position_side": 1,
"created_at": 1711929800000,
"updated_at": 1711929800000,
"user_id": "user123"
}
}