forked from singlesly/bingx-api
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtrade-order.interface.ts
More file actions
71 lines (64 loc) · 1.78 KB
/
Copy pathtrade-order.interface.ts
File metadata and controls
71 lines (64 loc) · 1.78 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
import { OrderSideEnum } from 'bingx-api/bingx/enums/order-side.enum';
import { OrderTypeEnum } from 'bingx-api/bingx/enums/order-type.enum';
import { OrderPositionSideEnum } from 'bingx-api/bingx/enums/order-position-side.enum';
/**
* @deprecated
*/
export interface TradeOrderInterface {
symbol: string;
type: OrderTypeEnum;
side: OrderSideEnum;
positionSide?: OrderPositionSideEnum;
clientOrderID?: string;
price?: string; //float64
quantity?: string; //float64
stopPrice?: string; //float64
timestamp?: string; //int64
recvWindow?: string; //int64
timeInForce?: string;
}
export interface BingxTradeOrderInterface {
symbol: string;
type: OrderTypeEnum;
side: OrderSideEnum;
positionSide?: OrderPositionSideEnum;
price?: string;
quantity?: string;
stopPrice?: string;
clientOrderID?: string;
timestamp?: string;
recvWindow?: string;
timeInForce?: string;
}
export interface BingxLimitTradeOrderInterface
extends BingxTradeOrderInterface {
type: OrderTypeEnum.LIMIT;
quantity: string;
price: string;
}
export interface BingxMarketTradeOrderInterface
extends BingxTradeOrderInterface {
type: OrderTypeEnum.MARKET;
quantity: string;
}
export interface BingxTriggerLimitTradeOrderInterface
extends BingxTradeOrderInterface {
type: OrderTypeEnum.TRIGGER_LIMIT;
quantity: string;
stopPrice: string;
price: string;
}
export interface BingxTriggeredTradeOrderInterface
extends BingxTradeOrderInterface {
type:
| OrderTypeEnum.STOP_MARKET
| OrderTypeEnum.TAKE_PROFIT_MARKET
| OrderTypeEnum.TRIGGER_MARKET;
stopPrice: string;
price: string;
}
export type BingxCreateTradeOrderInterface =
| BingxLimitTradeOrderInterface
| BingxMarketTradeOrderInterface
| BingxTriggerLimitTradeOrderInterface
| BingxTriggeredTradeOrderInterface;