zklighter-perps 1.0.4 → 1.0.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/apis/AccountApi.ts +12 -0
- package/apis/BlockApi.ts +6 -0
- package/apis/CandlestickApi.ts +4 -0
- package/apis/InfoApi.ts +8 -0
- package/apis/OrderApi.ts +18 -0
- package/apis/RelayerApi.ts +2 -0
- package/apis/RootApi.ts +2 -0
- package/apis/TransactionApi.ts +26 -34
- package/apis/WsApi.ts +4 -0
- package/models/AccountMarketStats.ts +12 -18
- package/models/AccountPnL.ts +5 -7
- package/models/AccountPosition.ts +22 -33
- package/models/AccountStats.ts +10 -15
- package/models/Block.ts +27 -40
- package/models/Blocks.ts +5 -7
- package/models/Candlestick.ts +14 -21
- package/models/Candlesticks.ts +5 -7
- package/models/ContractAddress.ts +4 -6
- package/models/CurrentHeight.ts +2 -3
- package/models/DetailedAccount.ts +8 -11
- package/models/DetailedAccounts.ts +5 -7
- package/models/EnrichedTx.ts +6 -9
- package/models/ExchangeStats.ts +9 -13
- package/models/Funding.ts +8 -12
- package/models/Fundings.ts +5 -7
- package/models/L1ProviderInfo.ts +8 -12
- package/models/Layer1BasicInfo.ts +17 -24
- package/models/Layer2BasicInfo.ts +6 -9
- package/models/MainAccount.ts +6 -9
- package/models/MainAccounts.ts +5 -7
- package/models/MarketInfo.ts +22 -33
- package/models/MarketSig.ts +8 -12
- package/models/NextNonce.ts +2 -3
- package/models/Order.ts +32 -48
- package/models/OrderBook.ts +20 -30
- package/models/OrderBookDepth.ts +8 -11
- package/models/OrderBookDetail.ts +36 -54
- package/models/OrderBookDetails.ts +3 -4
- package/models/OrderBookOrders.ts +10 -14
- package/models/OrderBookStats.ts +12 -18
- package/models/OrderBooks.ts +3 -4
- package/models/Orders.ts +3 -4
- package/models/Permission.ts +2 -3
- package/models/PnLEntry.ts +4 -6
- package/models/PriceLevel.ts +4 -6
- package/models/ReqDoFaucet.ts +2 -3
- package/models/ReqGetAccount.ts +4 -6
- package/models/ReqGetAccountActiveOrders.ts +6 -9
- package/models/ReqGetAccountByL1Address.ts +2 -3
- package/models/ReqGetAccountInactiveOrders.ts +8 -12
- package/models/ReqGetAccountOrders.ts +6 -9
- package/models/ReqGetAccountPnL.ts +12 -18
- package/models/ReqGetBlock.ts +4 -6
- package/models/ReqGetBlockTxs.ts +4 -6
- package/models/ReqGetByAccount.ts +4 -6
- package/models/ReqGetCandlesticks.ts +10 -15
- package/models/ReqGetFundings.ts +10 -15
- package/models/ReqGetL1Tx.ts +2 -3
- package/models/ReqGetMarketSig.ts +6 -9
- package/models/ReqGetNextNonce.ts +4 -6
- package/models/ReqGetOrderBookDetails.ts +2 -3
- package/models/ReqGetOrderBookOrders.ts +4 -6
- package/models/ReqGetOrderBooks.ts +2 -3
- package/models/ReqGetPermission.ts +6 -9
- package/models/ReqGetRangeWithCursor.ts +2 -3
- package/models/ReqGetRangeWithIndex.ts +2 -3
- package/models/ReqGetRecentTrades.ts +4 -6
- package/models/ReqGetRollbacks.ts +6 -9
- package/models/ReqGetSubAccount.ts +6 -9
- package/models/ReqGetTrades.ts +8 -12
- package/models/ReqGetTx.ts +4 -6
- package/models/ReqSearch.ts +2 -3
- package/models/ResultCode.ts +2 -3
- package/models/Rollback.ts +8 -12
- package/models/Rollbacks.ts +5 -7
- package/models/Search.ts +2 -3
- package/models/SignBody.ts +2 -3
- package/models/SimpleOrder.ts +12 -18
- package/models/Status.ts +4 -6
- package/models/SubAccount.ts +16 -24
- package/models/SubAccounts.ts +9 -13
- package/models/Trade.ts +24 -36
- package/models/Trades.ts +3 -4
- package/models/Tx.ts +28 -42
- package/models/TxHash.ts +2 -3
- package/models/Txs.ts +3 -4
- package/models/ValidatorInfo.ts +4 -6
- package/openapi.json +192 -610
- package/package.json +1 -1
|
@@ -24,19 +24,19 @@ export interface ReqGetAccountInactiveOrders {
|
|
|
24
24
|
* @type {number}
|
|
25
25
|
* @memberof ReqGetAccountInactiveOrders
|
|
26
26
|
*/
|
|
27
|
-
accountIndex
|
|
27
|
+
accountIndex?: number;
|
|
28
28
|
/**
|
|
29
29
|
* NilSubAccountIndex
|
|
30
30
|
* @type {number}
|
|
31
31
|
* @memberof ReqGetAccountInactiveOrders
|
|
32
32
|
*/
|
|
33
|
-
subAccountIndex
|
|
33
|
+
subAccountIndex?: number;
|
|
34
34
|
/**
|
|
35
35
|
*
|
|
36
36
|
* @type {string}
|
|
37
37
|
* @memberof ReqGetAccountInactiveOrders
|
|
38
38
|
*/
|
|
39
|
-
filter
|
|
39
|
+
filter?: ReqGetAccountInactiveOrdersFilterEnum;
|
|
40
40
|
/**
|
|
41
41
|
*
|
|
42
42
|
* @type {number}
|
|
@@ -54,7 +54,7 @@ export interface ReqGetAccountInactiveOrders {
|
|
|
54
54
|
* @type {number}
|
|
55
55
|
* @memberof ReqGetAccountInactiveOrders
|
|
56
56
|
*/
|
|
57
|
-
limit
|
|
57
|
+
limit?: number;
|
|
58
58
|
}
|
|
59
59
|
|
|
60
60
|
|
|
@@ -72,10 +72,6 @@ export type ReqGetAccountInactiveOrdersFilterEnum = typeof ReqGetAccountInactive
|
|
|
72
72
|
* Check if a given object implements the ReqGetAccountInactiveOrders interface.
|
|
73
73
|
*/
|
|
74
74
|
export function instanceOfReqGetAccountInactiveOrders(value: object): value is ReqGetAccountInactiveOrders {
|
|
75
|
-
if (!('accountIndex' in value) || value['accountIndex'] === undefined) return false;
|
|
76
|
-
if (!('subAccountIndex' in value) || value['subAccountIndex'] === undefined) return false;
|
|
77
|
-
if (!('filter' in value) || value['filter'] === undefined) return false;
|
|
78
|
-
if (!('limit' in value) || value['limit'] === undefined) return false;
|
|
79
75
|
return true;
|
|
80
76
|
}
|
|
81
77
|
|
|
@@ -89,12 +85,12 @@ export function ReqGetAccountInactiveOrdersFromJSONTyped(json: any, ignoreDiscri
|
|
|
89
85
|
}
|
|
90
86
|
return {
|
|
91
87
|
|
|
92
|
-
'accountIndex': json['account_index'],
|
|
93
|
-
'subAccountIndex': json['sub_account_index'],
|
|
94
|
-
'filter': json['filter'],
|
|
88
|
+
'accountIndex': json['account_index'] == null ? undefined : json['account_index'],
|
|
89
|
+
'subAccountIndex': json['sub_account_index'] == null ? undefined : json['sub_account_index'],
|
|
90
|
+
'filter': json['filter'] == null ? undefined : json['filter'],
|
|
95
91
|
'marketId': json['market_id'] == null ? undefined : json['market_id'],
|
|
96
92
|
'cursor': json['cursor'] == null ? undefined : json['cursor'],
|
|
97
|
-
'limit': json['limit'],
|
|
93
|
+
'limit': json['limit'] == null ? undefined : json['limit'],
|
|
98
94
|
};
|
|
99
95
|
}
|
|
100
96
|
|
|
@@ -24,13 +24,13 @@ export interface ReqGetAccountOrders {
|
|
|
24
24
|
* @type {number}
|
|
25
25
|
* @memberof ReqGetAccountOrders
|
|
26
26
|
*/
|
|
27
|
-
accountIndex
|
|
27
|
+
accountIndex?: number;
|
|
28
28
|
/**
|
|
29
29
|
*
|
|
30
30
|
* @type {number}
|
|
31
31
|
* @memberof ReqGetAccountOrders
|
|
32
32
|
*/
|
|
33
|
-
marketId
|
|
33
|
+
marketId?: number;
|
|
34
34
|
/**
|
|
35
35
|
*
|
|
36
36
|
* @type {string}
|
|
@@ -42,16 +42,13 @@ export interface ReqGetAccountOrders {
|
|
|
42
42
|
* @type {number}
|
|
43
43
|
* @memberof ReqGetAccountOrders
|
|
44
44
|
*/
|
|
45
|
-
limit
|
|
45
|
+
limit?: number;
|
|
46
46
|
}
|
|
47
47
|
|
|
48
48
|
/**
|
|
49
49
|
* Check if a given object implements the ReqGetAccountOrders interface.
|
|
50
50
|
*/
|
|
51
51
|
export function instanceOfReqGetAccountOrders(value: object): value is ReqGetAccountOrders {
|
|
52
|
-
if (!('accountIndex' in value) || value['accountIndex'] === undefined) return false;
|
|
53
|
-
if (!('marketId' in value) || value['marketId'] === undefined) return false;
|
|
54
|
-
if (!('limit' in value) || value['limit'] === undefined) return false;
|
|
55
52
|
return true;
|
|
56
53
|
}
|
|
57
54
|
|
|
@@ -65,10 +62,10 @@ export function ReqGetAccountOrdersFromJSONTyped(json: any, ignoreDiscriminator:
|
|
|
65
62
|
}
|
|
66
63
|
return {
|
|
67
64
|
|
|
68
|
-
'accountIndex': json['account_index'],
|
|
69
|
-
'marketId': json['market_id'],
|
|
65
|
+
'accountIndex': json['account_index'] == null ? undefined : json['account_index'],
|
|
66
|
+
'marketId': json['market_id'] == null ? undefined : json['market_id'],
|
|
70
67
|
'cursor': json['cursor'] == null ? undefined : json['cursor'],
|
|
71
|
-
'limit': json['limit'],
|
|
68
|
+
'limit': json['limit'] == null ? undefined : json['limit'],
|
|
72
69
|
};
|
|
73
70
|
}
|
|
74
71
|
|
|
@@ -24,37 +24,37 @@ export interface ReqGetAccountPnL {
|
|
|
24
24
|
* @type {string}
|
|
25
25
|
* @memberof ReqGetAccountPnL
|
|
26
26
|
*/
|
|
27
|
-
by
|
|
27
|
+
by?: ReqGetAccountPnLByEnum;
|
|
28
28
|
/**
|
|
29
29
|
*
|
|
30
30
|
* @type {string}
|
|
31
31
|
* @memberof ReqGetAccountPnL
|
|
32
32
|
*/
|
|
33
|
-
value
|
|
33
|
+
value?: string;
|
|
34
34
|
/**
|
|
35
35
|
*
|
|
36
36
|
* @type {string}
|
|
37
37
|
* @memberof ReqGetAccountPnL
|
|
38
38
|
*/
|
|
39
|
-
resolution
|
|
39
|
+
resolution?: ReqGetAccountPnLResolutionEnum;
|
|
40
40
|
/**
|
|
41
41
|
*
|
|
42
42
|
* @type {number}
|
|
43
43
|
* @memberof ReqGetAccountPnL
|
|
44
44
|
*/
|
|
45
|
-
startTimestamp
|
|
45
|
+
startTimestamp?: number;
|
|
46
46
|
/**
|
|
47
47
|
*
|
|
48
48
|
* @type {number}
|
|
49
49
|
* @memberof ReqGetAccountPnL
|
|
50
50
|
*/
|
|
51
|
-
endTimestamp
|
|
51
|
+
endTimestamp?: number;
|
|
52
52
|
/**
|
|
53
53
|
*
|
|
54
54
|
* @type {number}
|
|
55
55
|
* @memberof ReqGetAccountPnL
|
|
56
56
|
*/
|
|
57
|
-
countBack
|
|
57
|
+
countBack?: number;
|
|
58
58
|
}
|
|
59
59
|
|
|
60
60
|
|
|
@@ -85,12 +85,6 @@ export type ReqGetAccountPnLResolutionEnum = typeof ReqGetAccountPnLResolutionEn
|
|
|
85
85
|
* Check if a given object implements the ReqGetAccountPnL interface.
|
|
86
86
|
*/
|
|
87
87
|
export function instanceOfReqGetAccountPnL(value: object): value is ReqGetAccountPnL {
|
|
88
|
-
if (!('by' in value) || value['by'] === undefined) return false;
|
|
89
|
-
if (!('value' in value) || value['value'] === undefined) return false;
|
|
90
|
-
if (!('resolution' in value) || value['resolution'] === undefined) return false;
|
|
91
|
-
if (!('startTimestamp' in value) || value['startTimestamp'] === undefined) return false;
|
|
92
|
-
if (!('endTimestamp' in value) || value['endTimestamp'] === undefined) return false;
|
|
93
|
-
if (!('countBack' in value) || value['countBack'] === undefined) return false;
|
|
94
88
|
return true;
|
|
95
89
|
}
|
|
96
90
|
|
|
@@ -104,12 +98,12 @@ export function ReqGetAccountPnLFromJSONTyped(json: any, ignoreDiscriminator: bo
|
|
|
104
98
|
}
|
|
105
99
|
return {
|
|
106
100
|
|
|
107
|
-
'by': json['by'],
|
|
108
|
-
'value': json['value'],
|
|
109
|
-
'resolution': json['resolution'],
|
|
110
|
-
'startTimestamp': json['start_timestamp'],
|
|
111
|
-
'endTimestamp': json['end_timestamp'],
|
|
112
|
-
'countBack': json['count_back'],
|
|
101
|
+
'by': json['by'] == null ? undefined : json['by'],
|
|
102
|
+
'value': json['value'] == null ? undefined : json['value'],
|
|
103
|
+
'resolution': json['resolution'] == null ? undefined : json['resolution'],
|
|
104
|
+
'startTimestamp': json['start_timestamp'] == null ? undefined : json['start_timestamp'],
|
|
105
|
+
'endTimestamp': json['end_timestamp'] == null ? undefined : json['end_timestamp'],
|
|
106
|
+
'countBack': json['count_back'] == null ? undefined : json['count_back'],
|
|
113
107
|
};
|
|
114
108
|
}
|
|
115
109
|
|
package/models/ReqGetBlock.ts
CHANGED
|
@@ -24,13 +24,13 @@ export interface ReqGetBlock {
|
|
|
24
24
|
* @type {string}
|
|
25
25
|
* @memberof ReqGetBlock
|
|
26
26
|
*/
|
|
27
|
-
by
|
|
27
|
+
by?: ReqGetBlockByEnum;
|
|
28
28
|
/**
|
|
29
29
|
*
|
|
30
30
|
* @type {string}
|
|
31
31
|
* @memberof ReqGetBlock
|
|
32
32
|
*/
|
|
33
|
-
value
|
|
33
|
+
value?: string;
|
|
34
34
|
}
|
|
35
35
|
|
|
36
36
|
|
|
@@ -48,8 +48,6 @@ export type ReqGetBlockByEnum = typeof ReqGetBlockByEnum[keyof typeof ReqGetBloc
|
|
|
48
48
|
* Check if a given object implements the ReqGetBlock interface.
|
|
49
49
|
*/
|
|
50
50
|
export function instanceOfReqGetBlock(value: object): value is ReqGetBlock {
|
|
51
|
-
if (!('by' in value) || value['by'] === undefined) return false;
|
|
52
|
-
if (!('value' in value) || value['value'] === undefined) return false;
|
|
53
51
|
return true;
|
|
54
52
|
}
|
|
55
53
|
|
|
@@ -63,8 +61,8 @@ export function ReqGetBlockFromJSONTyped(json: any, ignoreDiscriminator: boolean
|
|
|
63
61
|
}
|
|
64
62
|
return {
|
|
65
63
|
|
|
66
|
-
'by': json['by'],
|
|
67
|
-
'value': json['value'],
|
|
64
|
+
'by': json['by'] == null ? undefined : json['by'],
|
|
65
|
+
'value': json['value'] == null ? undefined : json['value'],
|
|
68
66
|
};
|
|
69
67
|
}
|
|
70
68
|
|
package/models/ReqGetBlockTxs.ts
CHANGED
|
@@ -24,13 +24,13 @@ export interface ReqGetBlockTxs {
|
|
|
24
24
|
* @type {string}
|
|
25
25
|
* @memberof ReqGetBlockTxs
|
|
26
26
|
*/
|
|
27
|
-
by
|
|
27
|
+
by?: ReqGetBlockTxsByEnum;
|
|
28
28
|
/**
|
|
29
29
|
*
|
|
30
30
|
* @type {string}
|
|
31
31
|
* @memberof ReqGetBlockTxs
|
|
32
32
|
*/
|
|
33
|
-
value
|
|
33
|
+
value?: string;
|
|
34
34
|
}
|
|
35
35
|
|
|
36
36
|
|
|
@@ -48,8 +48,6 @@ export type ReqGetBlockTxsByEnum = typeof ReqGetBlockTxsByEnum[keyof typeof ReqG
|
|
|
48
48
|
* Check if a given object implements the ReqGetBlockTxs interface.
|
|
49
49
|
*/
|
|
50
50
|
export function instanceOfReqGetBlockTxs(value: object): value is ReqGetBlockTxs {
|
|
51
|
-
if (!('by' in value) || value['by'] === undefined) return false;
|
|
52
|
-
if (!('value' in value) || value['value'] === undefined) return false;
|
|
53
51
|
return true;
|
|
54
52
|
}
|
|
55
53
|
|
|
@@ -63,8 +61,8 @@ export function ReqGetBlockTxsFromJSONTyped(json: any, ignoreDiscriminator: bool
|
|
|
63
61
|
}
|
|
64
62
|
return {
|
|
65
63
|
|
|
66
|
-
'by': json['by'],
|
|
67
|
-
'value': json['value'],
|
|
64
|
+
'by': json['by'] == null ? undefined : json['by'],
|
|
65
|
+
'value': json['value'] == null ? undefined : json['value'],
|
|
68
66
|
};
|
|
69
67
|
}
|
|
70
68
|
|
|
@@ -24,13 +24,13 @@ export interface ReqGetByAccount {
|
|
|
24
24
|
* @type {string}
|
|
25
25
|
* @memberof ReqGetByAccount
|
|
26
26
|
*/
|
|
27
|
-
by
|
|
27
|
+
by?: ReqGetByAccountByEnum;
|
|
28
28
|
/**
|
|
29
29
|
*
|
|
30
30
|
* @type {string}
|
|
31
31
|
* @memberof ReqGetByAccount
|
|
32
32
|
*/
|
|
33
|
-
value
|
|
33
|
+
value?: string;
|
|
34
34
|
}
|
|
35
35
|
|
|
36
36
|
|
|
@@ -48,8 +48,6 @@ export type ReqGetByAccountByEnum = typeof ReqGetByAccountByEnum[keyof typeof Re
|
|
|
48
48
|
* Check if a given object implements the ReqGetByAccount interface.
|
|
49
49
|
*/
|
|
50
50
|
export function instanceOfReqGetByAccount(value: object): value is ReqGetByAccount {
|
|
51
|
-
if (!('by' in value) || value['by'] === undefined) return false;
|
|
52
|
-
if (!('value' in value) || value['value'] === undefined) return false;
|
|
53
51
|
return true;
|
|
54
52
|
}
|
|
55
53
|
|
|
@@ -63,8 +61,8 @@ export function ReqGetByAccountFromJSONTyped(json: any, ignoreDiscriminator: boo
|
|
|
63
61
|
}
|
|
64
62
|
return {
|
|
65
63
|
|
|
66
|
-
'by': json['by'],
|
|
67
|
-
'value': json['value'],
|
|
64
|
+
'by': json['by'] == null ? undefined : json['by'],
|
|
65
|
+
'value': json['value'] == null ? undefined : json['value'],
|
|
68
66
|
};
|
|
69
67
|
}
|
|
70
68
|
|
|
@@ -24,31 +24,31 @@ export interface ReqGetCandlesticks {
|
|
|
24
24
|
* @type {number}
|
|
25
25
|
* @memberof ReqGetCandlesticks
|
|
26
26
|
*/
|
|
27
|
-
marketId
|
|
27
|
+
marketId?: number;
|
|
28
28
|
/**
|
|
29
29
|
*
|
|
30
30
|
* @type {string}
|
|
31
31
|
* @memberof ReqGetCandlesticks
|
|
32
32
|
*/
|
|
33
|
-
resolution
|
|
33
|
+
resolution?: ReqGetCandlesticksResolutionEnum;
|
|
34
34
|
/**
|
|
35
35
|
*
|
|
36
36
|
* @type {number}
|
|
37
37
|
* @memberof ReqGetCandlesticks
|
|
38
38
|
*/
|
|
39
|
-
startTimestamp
|
|
39
|
+
startTimestamp?: number;
|
|
40
40
|
/**
|
|
41
41
|
*
|
|
42
42
|
* @type {number}
|
|
43
43
|
* @memberof ReqGetCandlesticks
|
|
44
44
|
*/
|
|
45
|
-
endTimestamp
|
|
45
|
+
endTimestamp?: number;
|
|
46
46
|
/**
|
|
47
47
|
*
|
|
48
48
|
* @type {number}
|
|
49
49
|
* @memberof ReqGetCandlesticks
|
|
50
50
|
*/
|
|
51
|
-
countBack
|
|
51
|
+
countBack?: number;
|
|
52
52
|
}
|
|
53
53
|
|
|
54
54
|
|
|
@@ -70,11 +70,6 @@ export type ReqGetCandlesticksResolutionEnum = typeof ReqGetCandlesticksResoluti
|
|
|
70
70
|
* Check if a given object implements the ReqGetCandlesticks interface.
|
|
71
71
|
*/
|
|
72
72
|
export function instanceOfReqGetCandlesticks(value: object): value is ReqGetCandlesticks {
|
|
73
|
-
if (!('marketId' in value) || value['marketId'] === undefined) return false;
|
|
74
|
-
if (!('resolution' in value) || value['resolution'] === undefined) return false;
|
|
75
|
-
if (!('startTimestamp' in value) || value['startTimestamp'] === undefined) return false;
|
|
76
|
-
if (!('endTimestamp' in value) || value['endTimestamp'] === undefined) return false;
|
|
77
|
-
if (!('countBack' in value) || value['countBack'] === undefined) return false;
|
|
78
73
|
return true;
|
|
79
74
|
}
|
|
80
75
|
|
|
@@ -88,11 +83,11 @@ export function ReqGetCandlesticksFromJSONTyped(json: any, ignoreDiscriminator:
|
|
|
88
83
|
}
|
|
89
84
|
return {
|
|
90
85
|
|
|
91
|
-
'marketId': json['market_id'],
|
|
92
|
-
'resolution': json['resolution'],
|
|
93
|
-
'startTimestamp': json['start_timestamp'],
|
|
94
|
-
'endTimestamp': json['end_timestamp'],
|
|
95
|
-
'countBack': json['count_back'],
|
|
86
|
+
'marketId': json['market_id'] == null ? undefined : json['market_id'],
|
|
87
|
+
'resolution': json['resolution'] == null ? undefined : json['resolution'],
|
|
88
|
+
'startTimestamp': json['start_timestamp'] == null ? undefined : json['start_timestamp'],
|
|
89
|
+
'endTimestamp': json['end_timestamp'] == null ? undefined : json['end_timestamp'],
|
|
90
|
+
'countBack': json['count_back'] == null ? undefined : json['count_back'],
|
|
96
91
|
};
|
|
97
92
|
}
|
|
98
93
|
|
package/models/ReqGetFundings.ts
CHANGED
|
@@ -24,31 +24,31 @@ export interface ReqGetFundings {
|
|
|
24
24
|
* @type {number}
|
|
25
25
|
* @memberof ReqGetFundings
|
|
26
26
|
*/
|
|
27
|
-
marketId
|
|
27
|
+
marketId?: number;
|
|
28
28
|
/**
|
|
29
29
|
*
|
|
30
30
|
* @type {string}
|
|
31
31
|
* @memberof ReqGetFundings
|
|
32
32
|
*/
|
|
33
|
-
resolution
|
|
33
|
+
resolution?: ReqGetFundingsResolutionEnum;
|
|
34
34
|
/**
|
|
35
35
|
*
|
|
36
36
|
* @type {number}
|
|
37
37
|
* @memberof ReqGetFundings
|
|
38
38
|
*/
|
|
39
|
-
startTimestamp
|
|
39
|
+
startTimestamp?: number;
|
|
40
40
|
/**
|
|
41
41
|
*
|
|
42
42
|
* @type {number}
|
|
43
43
|
* @memberof ReqGetFundings
|
|
44
44
|
*/
|
|
45
|
-
endTimestamp
|
|
45
|
+
endTimestamp?: number;
|
|
46
46
|
/**
|
|
47
47
|
*
|
|
48
48
|
* @type {number}
|
|
49
49
|
* @memberof ReqGetFundings
|
|
50
50
|
*/
|
|
51
|
-
countBack
|
|
51
|
+
countBack?: number;
|
|
52
52
|
}
|
|
53
53
|
|
|
54
54
|
|
|
@@ -65,11 +65,6 @@ export type ReqGetFundingsResolutionEnum = typeof ReqGetFundingsResolutionEnum[k
|
|
|
65
65
|
* Check if a given object implements the ReqGetFundings interface.
|
|
66
66
|
*/
|
|
67
67
|
export function instanceOfReqGetFundings(value: object): value is ReqGetFundings {
|
|
68
|
-
if (!('marketId' in value) || value['marketId'] === undefined) return false;
|
|
69
|
-
if (!('resolution' in value) || value['resolution'] === undefined) return false;
|
|
70
|
-
if (!('startTimestamp' in value) || value['startTimestamp'] === undefined) return false;
|
|
71
|
-
if (!('endTimestamp' in value) || value['endTimestamp'] === undefined) return false;
|
|
72
|
-
if (!('countBack' in value) || value['countBack'] === undefined) return false;
|
|
73
68
|
return true;
|
|
74
69
|
}
|
|
75
70
|
|
|
@@ -83,11 +78,11 @@ export function ReqGetFundingsFromJSONTyped(json: any, ignoreDiscriminator: bool
|
|
|
83
78
|
}
|
|
84
79
|
return {
|
|
85
80
|
|
|
86
|
-
'marketId': json['market_id'],
|
|
87
|
-
'resolution': json['resolution'],
|
|
88
|
-
'startTimestamp': json['start_timestamp'],
|
|
89
|
-
'endTimestamp': json['end_timestamp'],
|
|
90
|
-
'countBack': json['count_back'],
|
|
81
|
+
'marketId': json['market_id'] == null ? undefined : json['market_id'],
|
|
82
|
+
'resolution': json['resolution'] == null ? undefined : json['resolution'],
|
|
83
|
+
'startTimestamp': json['start_timestamp'] == null ? undefined : json['start_timestamp'],
|
|
84
|
+
'endTimestamp': json['end_timestamp'] == null ? undefined : json['end_timestamp'],
|
|
85
|
+
'countBack': json['count_back'] == null ? undefined : json['count_back'],
|
|
91
86
|
};
|
|
92
87
|
}
|
|
93
88
|
|
package/models/ReqGetL1Tx.ts
CHANGED
|
@@ -24,14 +24,13 @@ export interface ReqGetL1Tx {
|
|
|
24
24
|
* @type {string}
|
|
25
25
|
* @memberof ReqGetL1Tx
|
|
26
26
|
*/
|
|
27
|
-
hash
|
|
27
|
+
hash?: string;
|
|
28
28
|
}
|
|
29
29
|
|
|
30
30
|
/**
|
|
31
31
|
* Check if a given object implements the ReqGetL1Tx interface.
|
|
32
32
|
*/
|
|
33
33
|
export function instanceOfReqGetL1Tx(value: object): value is ReqGetL1Tx {
|
|
34
|
-
if (!('hash' in value) || value['hash'] === undefined) return false;
|
|
35
34
|
return true;
|
|
36
35
|
}
|
|
37
36
|
|
|
@@ -45,7 +44,7 @@ export function ReqGetL1TxFromJSONTyped(json: any, ignoreDiscriminator: boolean)
|
|
|
45
44
|
}
|
|
46
45
|
return {
|
|
47
46
|
|
|
48
|
-
'hash': json['hash'],
|
|
47
|
+
'hash': json['hash'] == null ? undefined : json['hash'],
|
|
49
48
|
};
|
|
50
49
|
}
|
|
51
50
|
|
|
@@ -24,28 +24,25 @@ export interface ReqGetMarketSig {
|
|
|
24
24
|
* @type {number}
|
|
25
25
|
* @memberof ReqGetMarketSig
|
|
26
26
|
*/
|
|
27
|
-
marketId
|
|
27
|
+
marketId?: number;
|
|
28
28
|
/**
|
|
29
29
|
*
|
|
30
30
|
* @type {boolean}
|
|
31
31
|
* @memberof ReqGetMarketSig
|
|
32
32
|
*/
|
|
33
|
-
isAsk
|
|
33
|
+
isAsk?: boolean;
|
|
34
34
|
/**
|
|
35
35
|
*
|
|
36
36
|
* @type {number}
|
|
37
37
|
* @memberof ReqGetMarketSig
|
|
38
38
|
*/
|
|
39
|
-
baseAmount
|
|
39
|
+
baseAmount?: number;
|
|
40
40
|
}
|
|
41
41
|
|
|
42
42
|
/**
|
|
43
43
|
* Check if a given object implements the ReqGetMarketSig interface.
|
|
44
44
|
*/
|
|
45
45
|
export function instanceOfReqGetMarketSig(value: object): value is ReqGetMarketSig {
|
|
46
|
-
if (!('marketId' in value) || value['marketId'] === undefined) return false;
|
|
47
|
-
if (!('isAsk' in value) || value['isAsk'] === undefined) return false;
|
|
48
|
-
if (!('baseAmount' in value) || value['baseAmount'] === undefined) return false;
|
|
49
46
|
return true;
|
|
50
47
|
}
|
|
51
48
|
|
|
@@ -59,9 +56,9 @@ export function ReqGetMarketSigFromJSONTyped(json: any, ignoreDiscriminator: boo
|
|
|
59
56
|
}
|
|
60
57
|
return {
|
|
61
58
|
|
|
62
|
-
'marketId': json['market_id'],
|
|
63
|
-
'isAsk': json['is_ask'],
|
|
64
|
-
'baseAmount': json['base_amount'],
|
|
59
|
+
'marketId': json['market_id'] == null ? undefined : json['market_id'],
|
|
60
|
+
'isAsk': json['is_ask'] == null ? undefined : json['is_ask'],
|
|
61
|
+
'baseAmount': json['base_amount'] == null ? undefined : json['base_amount'],
|
|
65
62
|
};
|
|
66
63
|
}
|
|
67
64
|
|
|
@@ -24,21 +24,19 @@ export interface ReqGetNextNonce {
|
|
|
24
24
|
* @type {number}
|
|
25
25
|
* @memberof ReqGetNextNonce
|
|
26
26
|
*/
|
|
27
|
-
accountIndex
|
|
27
|
+
accountIndex?: number;
|
|
28
28
|
/**
|
|
29
29
|
*
|
|
30
30
|
* @type {number}
|
|
31
31
|
* @memberof ReqGetNextNonce
|
|
32
32
|
*/
|
|
33
|
-
subAccountIndex
|
|
33
|
+
subAccountIndex?: number;
|
|
34
34
|
}
|
|
35
35
|
|
|
36
36
|
/**
|
|
37
37
|
* Check if a given object implements the ReqGetNextNonce interface.
|
|
38
38
|
*/
|
|
39
39
|
export function instanceOfReqGetNextNonce(value: object): value is ReqGetNextNonce {
|
|
40
|
-
if (!('accountIndex' in value) || value['accountIndex'] === undefined) return false;
|
|
41
|
-
if (!('subAccountIndex' in value) || value['subAccountIndex'] === undefined) return false;
|
|
42
40
|
return true;
|
|
43
41
|
}
|
|
44
42
|
|
|
@@ -52,8 +50,8 @@ export function ReqGetNextNonceFromJSONTyped(json: any, ignoreDiscriminator: boo
|
|
|
52
50
|
}
|
|
53
51
|
return {
|
|
54
52
|
|
|
55
|
-
'accountIndex': json['account_index'],
|
|
56
|
-
'subAccountIndex': json['sub_account_index'],
|
|
53
|
+
'accountIndex': json['account_index'] == null ? undefined : json['account_index'],
|
|
54
|
+
'subAccountIndex': json['sub_account_index'] == null ? undefined : json['sub_account_index'],
|
|
57
55
|
};
|
|
58
56
|
}
|
|
59
57
|
|
|
@@ -24,7 +24,7 @@ export interface ReqGetOrderBookDetails {
|
|
|
24
24
|
* @type {string}
|
|
25
25
|
* @memberof ReqGetOrderBookDetails
|
|
26
26
|
*/
|
|
27
|
-
filter
|
|
27
|
+
filter?: ReqGetOrderBookDetailsFilterEnum;
|
|
28
28
|
/**
|
|
29
29
|
*
|
|
30
30
|
* @type {number}
|
|
@@ -48,7 +48,6 @@ export type ReqGetOrderBookDetailsFilterEnum = typeof ReqGetOrderBookDetailsFilt
|
|
|
48
48
|
* Check if a given object implements the ReqGetOrderBookDetails interface.
|
|
49
49
|
*/
|
|
50
50
|
export function instanceOfReqGetOrderBookDetails(value: object): value is ReqGetOrderBookDetails {
|
|
51
|
-
if (!('filter' in value) || value['filter'] === undefined) return false;
|
|
52
51
|
return true;
|
|
53
52
|
}
|
|
54
53
|
|
|
@@ -62,7 +61,7 @@ export function ReqGetOrderBookDetailsFromJSONTyped(json: any, ignoreDiscriminat
|
|
|
62
61
|
}
|
|
63
62
|
return {
|
|
64
63
|
|
|
65
|
-
'filter': json['filter'],
|
|
64
|
+
'filter': json['filter'] == null ? undefined : json['filter'],
|
|
66
65
|
'marketId': json['market_id'] == null ? undefined : json['market_id'],
|
|
67
66
|
};
|
|
68
67
|
}
|
|
@@ -24,21 +24,19 @@ export interface ReqGetOrderBookOrders {
|
|
|
24
24
|
* @type {number}
|
|
25
25
|
* @memberof ReqGetOrderBookOrders
|
|
26
26
|
*/
|
|
27
|
-
marketId
|
|
27
|
+
marketId?: number;
|
|
28
28
|
/**
|
|
29
29
|
*
|
|
30
30
|
* @type {number}
|
|
31
31
|
* @memberof ReqGetOrderBookOrders
|
|
32
32
|
*/
|
|
33
|
-
limit
|
|
33
|
+
limit?: number;
|
|
34
34
|
}
|
|
35
35
|
|
|
36
36
|
/**
|
|
37
37
|
* Check if a given object implements the ReqGetOrderBookOrders interface.
|
|
38
38
|
*/
|
|
39
39
|
export function instanceOfReqGetOrderBookOrders(value: object): value is ReqGetOrderBookOrders {
|
|
40
|
-
if (!('marketId' in value) || value['marketId'] === undefined) return false;
|
|
41
|
-
if (!('limit' in value) || value['limit'] === undefined) return false;
|
|
42
40
|
return true;
|
|
43
41
|
}
|
|
44
42
|
|
|
@@ -52,8 +50,8 @@ export function ReqGetOrderBookOrdersFromJSONTyped(json: any, ignoreDiscriminato
|
|
|
52
50
|
}
|
|
53
51
|
return {
|
|
54
52
|
|
|
55
|
-
'marketId': json['market_id'],
|
|
56
|
-
'limit': json['limit'],
|
|
53
|
+
'marketId': json['market_id'] == null ? undefined : json['market_id'],
|
|
54
|
+
'limit': json['limit'] == null ? undefined : json['limit'],
|
|
57
55
|
};
|
|
58
56
|
}
|
|
59
57
|
|
|
@@ -24,7 +24,7 @@ export interface ReqGetOrderBooks {
|
|
|
24
24
|
* @type {string}
|
|
25
25
|
* @memberof ReqGetOrderBooks
|
|
26
26
|
*/
|
|
27
|
-
filter
|
|
27
|
+
filter?: ReqGetOrderBooksFilterEnum;
|
|
28
28
|
/**
|
|
29
29
|
*
|
|
30
30
|
* @type {number}
|
|
@@ -48,7 +48,6 @@ export type ReqGetOrderBooksFilterEnum = typeof ReqGetOrderBooksFilterEnum[keyof
|
|
|
48
48
|
* Check if a given object implements the ReqGetOrderBooks interface.
|
|
49
49
|
*/
|
|
50
50
|
export function instanceOfReqGetOrderBooks(value: object): value is ReqGetOrderBooks {
|
|
51
|
-
if (!('filter' in value) || value['filter'] === undefined) return false;
|
|
52
51
|
return true;
|
|
53
52
|
}
|
|
54
53
|
|
|
@@ -62,7 +61,7 @@ export function ReqGetOrderBooksFromJSONTyped(json: any, ignoreDiscriminator: bo
|
|
|
62
61
|
}
|
|
63
62
|
return {
|
|
64
63
|
|
|
65
|
-
'filter': json['filter'],
|
|
64
|
+
'filter': json['filter'] == null ? undefined : json['filter'],
|
|
66
65
|
'marketId': json['market_id'] == null ? undefined : json['market_id'],
|
|
67
66
|
};
|
|
68
67
|
}
|
|
@@ -24,19 +24,19 @@ export interface ReqGetPermission {
|
|
|
24
24
|
* @type {string}
|
|
25
25
|
* @memberof ReqGetPermission
|
|
26
26
|
*/
|
|
27
|
-
by
|
|
27
|
+
by?: ReqGetPermissionByEnum;
|
|
28
28
|
/**
|
|
29
29
|
*
|
|
30
30
|
* @type {string}
|
|
31
31
|
* @memberof ReqGetPermission
|
|
32
32
|
*/
|
|
33
|
-
value
|
|
33
|
+
value?: string;
|
|
34
34
|
/**
|
|
35
35
|
*
|
|
36
36
|
* @type {number}
|
|
37
37
|
* @memberof ReqGetPermission
|
|
38
38
|
*/
|
|
39
|
-
txType
|
|
39
|
+
txType?: number;
|
|
40
40
|
}
|
|
41
41
|
|
|
42
42
|
|
|
@@ -54,9 +54,6 @@ export type ReqGetPermissionByEnum = typeof ReqGetPermissionByEnum[keyof typeof
|
|
|
54
54
|
* Check if a given object implements the ReqGetPermission interface.
|
|
55
55
|
*/
|
|
56
56
|
export function instanceOfReqGetPermission(value: object): value is ReqGetPermission {
|
|
57
|
-
if (!('by' in value) || value['by'] === undefined) return false;
|
|
58
|
-
if (!('value' in value) || value['value'] === undefined) return false;
|
|
59
|
-
if (!('txType' in value) || value['txType'] === undefined) return false;
|
|
60
57
|
return true;
|
|
61
58
|
}
|
|
62
59
|
|
|
@@ -70,9 +67,9 @@ export function ReqGetPermissionFromJSONTyped(json: any, ignoreDiscriminator: bo
|
|
|
70
67
|
}
|
|
71
68
|
return {
|
|
72
69
|
|
|
73
|
-
'by': json['by'],
|
|
74
|
-
'value': json['value'],
|
|
75
|
-
'txType': json['tx_type'],
|
|
70
|
+
'by': json['by'] == null ? undefined : json['by'],
|
|
71
|
+
'value': json['value'] == null ? undefined : json['value'],
|
|
72
|
+
'txType': json['tx_type'] == null ? undefined : json['tx_type'],
|
|
76
73
|
};
|
|
77
74
|
}
|
|
78
75
|
|