From 98cf9655a15e937ab77b8f34a5d2878f6c8b1c9c Mon Sep 17 00:00:00 2001 From: William Date: Thu, 25 Apr 2024 16:33:47 +0200 Subject: [PATCH] Adds `WSExecutionEventV5` and `WSExecutionV5` interfaces --- src/types/websocket.events.ts | 43 +++++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) diff --git a/src/types/websocket.events.ts b/src/types/websocket.events.ts index b55d964..bf0a7f4 100644 --- a/src/types/websocket.events.ts +++ b/src/types/websocket.events.ts @@ -1,6 +1,8 @@ import { CategoryV5, + ExecTypeV5, OCOTriggerTypeV5, + OrderCreateTypeV5, OrderRejectReasonV5, OrderSMPTypeV5, OrderSideV5, @@ -96,3 +98,44 @@ export interface WSAccountOrderEventV5 { creationTime: number; data: WSAccountOrderV5[]; } + +export interface WSExecutionV5 { + category: CategoryV5; + symbol: string; + isLeverage: string; + orderId: string; + orderLinkId: string; + side: OrderSideV5; + orderPrice: string; + orderQty: string; + leavesQty: string; + createType: OrderCreateTypeV5; + orderType: OrderTypeV5; + stopOrderType: StopOrderTypeV5; + execFee: string; + execId: string; + execPrice: string; + execQty: string; + execType: ExecTypeV5; + execValue: string; + execTime: string; + isMaker: boolean; + feeRate: string; + tradeIv: string; + markIv: string; + markPrice: string; + indexPrice: string; + underlyingPrice: string; + blockTradeId: string; + closedSize: string; + seq: number; + marketUnit: string; +} + +export interface WSExecutionEventV5 { + id: string; + topic: 'execution'; + creationTime: number; + data: WSExecutionV5[]; + wsKey: WsKey; +} \ No newline at end of file