diff --git a/src/futures-client.ts b/src/futures-client.ts index 1cd2e48..f1a9a84 100644 --- a/src/futures-client.ts +++ b/src/futures-client.ts @@ -25,6 +25,7 @@ import { FuturesPlanType, FuturesKlineInterval, FuturesHistoricPositions, + ModifyFuturesOrder, } from './types'; import { REST_CLIENT_TYPE_ENUM } from './util'; import BaseRestClient from './util/BaseRestClient'; @@ -388,6 +389,11 @@ export class FuturesClient extends BaseRestClient { }); } + /** Modify Order */ + modifyOrder(params: ModifyFuturesOrder): Promise> { + return this.postPrivate('/api/mix/v1/order/modifyOrder', params); + } + /** * Cancel all futures orders for a symbol */ diff --git a/src/types/request/futures.ts b/src/types/request/futures.ts index 865c234..ce316e6 100644 --- a/src/types/request/futures.ts +++ b/src/types/request/futures.ts @@ -88,6 +88,17 @@ export interface NewBatchFuturesOrder { clientOid?: string; } +export interface ModifyFuturesOrder { + symbol: string; + orderId?: string; + clientOid?: string; + newClientOid?: string; + size?: string; + price?: string; + presetTakeProfitPrice?: string; + presetStopLossPrice?: string; +} + export interface FuturesHistoricPositions { startTime: string; endTime: string;