zklighter-perps 1.0.83 → 1.0.85
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/.openapi-generator/FILES +1 -0
- package/apis/OrderApi.ts +5 -0
- package/models/AccountMarketStats.ts +27 -0
- package/models/AccountTradeStats.ts +70 -0
- package/models/MarketInfo.ts +9 -0
- package/models/ReqGetAccountInactiveOrders.ts +8 -0
- package/models/index.ts +1 -0
- package/openapi.json +53 -1
- package/package.json +1 -1
package/.openapi-generator/FILES
CHANGED
package/apis/OrderApi.ts
CHANGED
|
@@ -51,6 +51,7 @@ export interface AccountInactiveOrdersRequest {
|
|
|
51
51
|
limit: number;
|
|
52
52
|
market_id?: number;
|
|
53
53
|
ask_filter?: number;
|
|
54
|
+
between_timestamps?: string;
|
|
54
55
|
cursor?: string;
|
|
55
56
|
}
|
|
56
57
|
|
|
@@ -190,6 +191,10 @@ export class OrderApi extends runtime.BaseAPI {
|
|
|
190
191
|
queryParameters['ask_filter'] = requestParameters['ask_filter'];
|
|
191
192
|
}
|
|
192
193
|
|
|
194
|
+
if (requestParameters['between_timestamps'] != null) {
|
|
195
|
+
queryParameters['between_timestamps'] = requestParameters['between_timestamps'];
|
|
196
|
+
}
|
|
197
|
+
|
|
193
198
|
if (requestParameters['cursor'] != null) {
|
|
194
199
|
queryParameters['cursor'] = requestParameters['cursor'];
|
|
195
200
|
}
|
|
@@ -43,6 +43,24 @@ export interface AccountMarketStats {
|
|
|
43
43
|
* @memberof AccountMarketStats
|
|
44
44
|
*/
|
|
45
45
|
daily_quote_token_volume: number;
|
|
46
|
+
/**
|
|
47
|
+
*
|
|
48
|
+
* @type {number}
|
|
49
|
+
* @memberof AccountMarketStats
|
|
50
|
+
*/
|
|
51
|
+
total_trades_count: number;
|
|
52
|
+
/**
|
|
53
|
+
*
|
|
54
|
+
* @type {number}
|
|
55
|
+
* @memberof AccountMarketStats
|
|
56
|
+
*/
|
|
57
|
+
total_base_token_volume: number;
|
|
58
|
+
/**
|
|
59
|
+
*
|
|
60
|
+
* @type {number}
|
|
61
|
+
* @memberof AccountMarketStats
|
|
62
|
+
*/
|
|
63
|
+
total_quote_token_volume: number;
|
|
46
64
|
}
|
|
47
65
|
|
|
48
66
|
/**
|
|
@@ -53,6 +71,9 @@ export function instanceOfAccountMarketStats(value: object): value is AccountMar
|
|
|
53
71
|
if (!('daily_trades_count' in value) || value['daily_trades_count'] === undefined) return false;
|
|
54
72
|
if (!('daily_base_token_volume' in value) || value['daily_base_token_volume'] === undefined) return false;
|
|
55
73
|
if (!('daily_quote_token_volume' in value) || value['daily_quote_token_volume'] === undefined) return false;
|
|
74
|
+
if (!('total_trades_count' in value) || value['total_trades_count'] === undefined) return false;
|
|
75
|
+
if (!('total_base_token_volume' in value) || value['total_base_token_volume'] === undefined) return false;
|
|
76
|
+
if (!('total_quote_token_volume' in value) || value['total_quote_token_volume'] === undefined) return false;
|
|
56
77
|
return true;
|
|
57
78
|
}
|
|
58
79
|
|
|
@@ -70,6 +91,9 @@ export function AccountMarketStatsFromJSONTyped(json: any, ignoreDiscriminator:
|
|
|
70
91
|
'daily_trades_count': json['daily_trades_count'],
|
|
71
92
|
'daily_base_token_volume': json['daily_base_token_volume'],
|
|
72
93
|
'daily_quote_token_volume': json['daily_quote_token_volume'],
|
|
94
|
+
'total_trades_count': json['total_trades_count'],
|
|
95
|
+
'total_base_token_volume': json['total_base_token_volume'],
|
|
96
|
+
'total_quote_token_volume': json['total_quote_token_volume'],
|
|
73
97
|
};
|
|
74
98
|
}
|
|
75
99
|
|
|
@@ -83,6 +107,9 @@ export function AccountMarketStatsToJSON(value?: AccountMarketStats | null): any
|
|
|
83
107
|
'daily_trades_count': value['daily_trades_count'],
|
|
84
108
|
'daily_base_token_volume': value['daily_base_token_volume'],
|
|
85
109
|
'daily_quote_token_volume': value['daily_quote_token_volume'],
|
|
110
|
+
'total_trades_count': value['total_trades_count'],
|
|
111
|
+
'total_base_token_volume': value['total_base_token_volume'],
|
|
112
|
+
'total_quote_token_volume': value['total_quote_token_volume'],
|
|
86
113
|
};
|
|
87
114
|
}
|
|
88
115
|
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
*
|
|
5
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document:
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
/**
|
|
17
|
+
*
|
|
18
|
+
* @export
|
|
19
|
+
* @interface AccountTradeStats
|
|
20
|
+
*/
|
|
21
|
+
export interface AccountTradeStats {
|
|
22
|
+
/**
|
|
23
|
+
*
|
|
24
|
+
* @type {number}
|
|
25
|
+
* @memberof AccountTradeStats
|
|
26
|
+
*/
|
|
27
|
+
total_trades_count: number;
|
|
28
|
+
/**
|
|
29
|
+
*
|
|
30
|
+
* @type {number}
|
|
31
|
+
* @memberof AccountTradeStats
|
|
32
|
+
*/
|
|
33
|
+
total_volume: number;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
/**
|
|
37
|
+
* Check if a given object implements the AccountTradeStats interface.
|
|
38
|
+
*/
|
|
39
|
+
export function instanceOfAccountTradeStats(value: object): value is AccountTradeStats {
|
|
40
|
+
if (!('total_trades_count' in value) || value['total_trades_count'] === undefined) return false;
|
|
41
|
+
if (!('total_volume' in value) || value['total_volume'] === undefined) return false;
|
|
42
|
+
return true;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
export function AccountTradeStatsFromJSON(json: any): AccountTradeStats {
|
|
46
|
+
return AccountTradeStatsFromJSONTyped(json, false);
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export function AccountTradeStatsFromJSONTyped(json: any, ignoreDiscriminator: boolean): AccountTradeStats {
|
|
50
|
+
if (json == null) {
|
|
51
|
+
return json;
|
|
52
|
+
}
|
|
53
|
+
return {
|
|
54
|
+
|
|
55
|
+
'total_trades_count': json['total_trades_count'],
|
|
56
|
+
'total_volume': json['total_volume'],
|
|
57
|
+
};
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
export function AccountTradeStatsToJSON(value?: AccountTradeStats | null): any {
|
|
61
|
+
if (value == null) {
|
|
62
|
+
return value;
|
|
63
|
+
}
|
|
64
|
+
return {
|
|
65
|
+
|
|
66
|
+
'total_trades_count': value['total_trades_count'],
|
|
67
|
+
'total_volume': value['total_volume'],
|
|
68
|
+
};
|
|
69
|
+
}
|
|
70
|
+
|
package/models/MarketInfo.ts
CHANGED
|
@@ -49,6 +49,12 @@ export interface MarketInfo {
|
|
|
49
49
|
* @memberof MarketInfo
|
|
50
50
|
*/
|
|
51
51
|
last_trade_price: string;
|
|
52
|
+
/**
|
|
53
|
+
*
|
|
54
|
+
* @type {string}
|
|
55
|
+
* @memberof MarketInfo
|
|
56
|
+
*/
|
|
57
|
+
current_funding_rate: string;
|
|
52
58
|
/**
|
|
53
59
|
*
|
|
54
60
|
* @type {string}
|
|
@@ -102,6 +108,7 @@ export function instanceOfMarketInfo(value: object): value is MarketInfo {
|
|
|
102
108
|
if (!('mark_price' in value) || value['mark_price'] === undefined) return false;
|
|
103
109
|
if (!('open_interest' in value) || value['open_interest'] === undefined) return false;
|
|
104
110
|
if (!('last_trade_price' in value) || value['last_trade_price'] === undefined) return false;
|
|
111
|
+
if (!('current_funding_rate' in value) || value['current_funding_rate'] === undefined) return false;
|
|
105
112
|
if (!('funding_rate' in value) || value['funding_rate'] === undefined) return false;
|
|
106
113
|
if (!('funding_timestamp' in value) || value['funding_timestamp'] === undefined) return false;
|
|
107
114
|
if (!('daily_base_token_volume' in value) || value['daily_base_token_volume'] === undefined) return false;
|
|
@@ -127,6 +134,7 @@ export function MarketInfoFromJSONTyped(json: any, ignoreDiscriminator: boolean)
|
|
|
127
134
|
'mark_price': json['mark_price'],
|
|
128
135
|
'open_interest': json['open_interest'],
|
|
129
136
|
'last_trade_price': json['last_trade_price'],
|
|
137
|
+
'current_funding_rate': json['current_funding_rate'],
|
|
130
138
|
'funding_rate': json['funding_rate'],
|
|
131
139
|
'funding_timestamp': json['funding_timestamp'],
|
|
132
140
|
'daily_base_token_volume': json['daily_base_token_volume'],
|
|
@@ -148,6 +156,7 @@ export function MarketInfoToJSON(value?: MarketInfo | null): any {
|
|
|
148
156
|
'mark_price': value['mark_price'],
|
|
149
157
|
'open_interest': value['open_interest'],
|
|
150
158
|
'last_trade_price': value['last_trade_price'],
|
|
159
|
+
'current_funding_rate': value['current_funding_rate'],
|
|
151
160
|
'funding_rate': value['funding_rate'],
|
|
152
161
|
'funding_timestamp': value['funding_timestamp'],
|
|
153
162
|
'daily_base_token_volume': value['daily_base_token_volume'],
|
|
@@ -37,6 +37,12 @@ export interface ReqGetAccountInactiveOrders {
|
|
|
37
37
|
* @memberof ReqGetAccountInactiveOrders
|
|
38
38
|
*/
|
|
39
39
|
ask_filter?: number;
|
|
40
|
+
/**
|
|
41
|
+
*
|
|
42
|
+
* @type {string}
|
|
43
|
+
* @memberof ReqGetAccountInactiveOrders
|
|
44
|
+
*/
|
|
45
|
+
between_timestamps?: string;
|
|
40
46
|
/**
|
|
41
47
|
*
|
|
42
48
|
* @type {string}
|
|
@@ -73,6 +79,7 @@ export function ReqGetAccountInactiveOrdersFromJSONTyped(json: any, ignoreDiscri
|
|
|
73
79
|
'account_index': json['account_index'],
|
|
74
80
|
'market_id': json['market_id'] == null ? undefined : json['market_id'],
|
|
75
81
|
'ask_filter': json['ask_filter'] == null ? undefined : json['ask_filter'],
|
|
82
|
+
'between_timestamps': json['between_timestamps'] == null ? undefined : json['between_timestamps'],
|
|
76
83
|
'cursor': json['cursor'] == null ? undefined : json['cursor'],
|
|
77
84
|
'limit': json['limit'],
|
|
78
85
|
};
|
|
@@ -87,6 +94,7 @@ export function ReqGetAccountInactiveOrdersToJSON(value?: ReqGetAccountInactiveO
|
|
|
87
94
|
'account_index': value['account_index'],
|
|
88
95
|
'market_id': value['market_id'],
|
|
89
96
|
'ask_filter': value['ask_filter'],
|
|
97
|
+
'between_timestamps': value['between_timestamps'],
|
|
90
98
|
'cursor': value['cursor'],
|
|
91
99
|
'limit': value['limit'],
|
|
92
100
|
};
|
package/models/index.ts
CHANGED
package/openapi.json
CHANGED
|
@@ -175,6 +175,12 @@
|
|
|
175
175
|
"format": "int8",
|
|
176
176
|
"default": "-1"
|
|
177
177
|
},
|
|
178
|
+
{
|
|
179
|
+
"name": "between_timestamps",
|
|
180
|
+
"in": "query",
|
|
181
|
+
"required": false,
|
|
182
|
+
"type": "string"
|
|
183
|
+
},
|
|
178
184
|
{
|
|
179
185
|
"name": "cursor",
|
|
180
186
|
"in": "query",
|
|
@@ -2270,6 +2276,21 @@
|
|
|
2270
2276
|
"type": "number",
|
|
2271
2277
|
"format": "double",
|
|
2272
2278
|
"example": "93566.25"
|
|
2279
|
+
},
|
|
2280
|
+
"total_trades_count": {
|
|
2281
|
+
"type": "integer",
|
|
2282
|
+
"format": "int64",
|
|
2283
|
+
"example": "68"
|
|
2284
|
+
},
|
|
2285
|
+
"total_base_token_volume": {
|
|
2286
|
+
"type": "number",
|
|
2287
|
+
"format": "double",
|
|
2288
|
+
"example": "235.25"
|
|
2289
|
+
},
|
|
2290
|
+
"total_quote_token_volume": {
|
|
2291
|
+
"type": "number",
|
|
2292
|
+
"format": "double",
|
|
2293
|
+
"example": "93566.25"
|
|
2273
2294
|
}
|
|
2274
2295
|
},
|
|
2275
2296
|
"title": "AccountMarketStats",
|
|
@@ -2277,7 +2298,10 @@
|
|
|
2277
2298
|
"market_id",
|
|
2278
2299
|
"daily_trades_count",
|
|
2279
2300
|
"daily_base_token_volume",
|
|
2280
|
-
"daily_quote_token_volume"
|
|
2301
|
+
"daily_quote_token_volume",
|
|
2302
|
+
"total_trades_count",
|
|
2303
|
+
"total_base_token_volume",
|
|
2304
|
+
"total_quote_token_volume"
|
|
2281
2305
|
]
|
|
2282
2306
|
},
|
|
2283
2307
|
"AccountMetadata": {
|
|
@@ -2430,6 +2454,26 @@
|
|
|
2430
2454
|
"buying_power"
|
|
2431
2455
|
]
|
|
2432
2456
|
},
|
|
2457
|
+
"AccountTradeStats": {
|
|
2458
|
+
"type": "object",
|
|
2459
|
+
"properties": {
|
|
2460
|
+
"total_trades_count": {
|
|
2461
|
+
"type": "integer",
|
|
2462
|
+
"format": "int64",
|
|
2463
|
+
"example": "68"
|
|
2464
|
+
},
|
|
2465
|
+
"total_volume": {
|
|
2466
|
+
"type": "number",
|
|
2467
|
+
"format": "double",
|
|
2468
|
+
"example": "235.25"
|
|
2469
|
+
}
|
|
2470
|
+
},
|
|
2471
|
+
"title": "AccountTradeStats",
|
|
2472
|
+
"required": [
|
|
2473
|
+
"total_trades_count",
|
|
2474
|
+
"total_volume"
|
|
2475
|
+
]
|
|
2476
|
+
},
|
|
2433
2477
|
"Accounts": {
|
|
2434
2478
|
"type": "object",
|
|
2435
2479
|
"properties": {
|
|
@@ -3624,6 +3668,10 @@
|
|
|
3624
3668
|
"type": "string",
|
|
3625
3669
|
"example": "3024.66"
|
|
3626
3670
|
},
|
|
3671
|
+
"current_funding_rate": {
|
|
3672
|
+
"type": "string",
|
|
3673
|
+
"example": "0.0001"
|
|
3674
|
+
},
|
|
3627
3675
|
"funding_rate": {
|
|
3628
3676
|
"type": "string",
|
|
3629
3677
|
"example": "0.0001"
|
|
@@ -3666,6 +3714,7 @@
|
|
|
3666
3714
|
"mark_price",
|
|
3667
3715
|
"open_interest",
|
|
3668
3716
|
"last_trade_price",
|
|
3717
|
+
"current_funding_rate",
|
|
3669
3718
|
"funding_rate",
|
|
3670
3719
|
"funding_timestamp",
|
|
3671
3720
|
"daily_base_token_volume",
|
|
@@ -4737,6 +4786,9 @@
|
|
|
4737
4786
|
"format": "int8",
|
|
4738
4787
|
"default": "-1"
|
|
4739
4788
|
},
|
|
4789
|
+
"between_timestamps": {
|
|
4790
|
+
"type": "string"
|
|
4791
|
+
},
|
|
4740
4792
|
"cursor": {
|
|
4741
4793
|
"type": "string"
|
|
4742
4794
|
},
|