zklighter-perps 1.0.164 → 1.0.166
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 +10 -0
- package/apis/BridgeApi.ts +92 -0
- package/apis/GeckoApi.ts +134 -0
- package/apis/index.ts +1 -0
- package/models/Bridge.ts +169 -0
- package/models/GeckoContract.ts +268 -0
- package/models/GeckoContracts.ts +68 -0
- package/models/GeckoOrderbook.ts +88 -0
- package/models/MarketConfig.ts +70 -0
- package/models/MarketInfo.ts +27 -0
- package/models/OrderBook.ts +9 -0
- package/models/OrderBookDetail.ts +25 -0
- package/models/ReqGetBridgesByL1Addr.ts +61 -0
- package/models/ReqGetGeckoOrderbook.ts +61 -0
- package/models/RespGetBridgesByL1Addr.ts +85 -0
- package/models/RespGetIsNextBridgeFast.ts +78 -0
- package/models/index.ts +9 -0
- package/openapi.json +507 -1
- package/package.json +1 -1
|
@@ -0,0 +1,268 @@
|
|
|
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 GeckoContract
|
|
20
|
+
*/
|
|
21
|
+
export interface GeckoContract {
|
|
22
|
+
/**
|
|
23
|
+
*
|
|
24
|
+
* @type {string}
|
|
25
|
+
* @memberof GeckoContract
|
|
26
|
+
*/
|
|
27
|
+
ticker_id: string;
|
|
28
|
+
/**
|
|
29
|
+
*
|
|
30
|
+
* @type {string}
|
|
31
|
+
* @memberof GeckoContract
|
|
32
|
+
*/
|
|
33
|
+
base_currency: string;
|
|
34
|
+
/**
|
|
35
|
+
*
|
|
36
|
+
* @type {string}
|
|
37
|
+
* @memberof GeckoContract
|
|
38
|
+
*/
|
|
39
|
+
target_currency: string;
|
|
40
|
+
/**
|
|
41
|
+
*
|
|
42
|
+
* @type {number}
|
|
43
|
+
* @memberof GeckoContract
|
|
44
|
+
*/
|
|
45
|
+
last_price: number;
|
|
46
|
+
/**
|
|
47
|
+
*
|
|
48
|
+
* @type {number}
|
|
49
|
+
* @memberof GeckoContract
|
|
50
|
+
*/
|
|
51
|
+
base_volume: number;
|
|
52
|
+
/**
|
|
53
|
+
*
|
|
54
|
+
* @type {number}
|
|
55
|
+
* @memberof GeckoContract
|
|
56
|
+
*/
|
|
57
|
+
target_volume: number;
|
|
58
|
+
/**
|
|
59
|
+
*
|
|
60
|
+
* @type {number}
|
|
61
|
+
* @memberof GeckoContract
|
|
62
|
+
*/
|
|
63
|
+
bid: number;
|
|
64
|
+
/**
|
|
65
|
+
*
|
|
66
|
+
* @type {number}
|
|
67
|
+
* @memberof GeckoContract
|
|
68
|
+
*/
|
|
69
|
+
ask: number;
|
|
70
|
+
/**
|
|
71
|
+
*
|
|
72
|
+
* @type {number}
|
|
73
|
+
* @memberof GeckoContract
|
|
74
|
+
*/
|
|
75
|
+
high: number;
|
|
76
|
+
/**
|
|
77
|
+
*
|
|
78
|
+
* @type {number}
|
|
79
|
+
* @memberof GeckoContract
|
|
80
|
+
*/
|
|
81
|
+
low: number;
|
|
82
|
+
/**
|
|
83
|
+
*
|
|
84
|
+
* @type {string}
|
|
85
|
+
* @memberof GeckoContract
|
|
86
|
+
*/
|
|
87
|
+
product_type: string;
|
|
88
|
+
/**
|
|
89
|
+
*
|
|
90
|
+
* @type {number}
|
|
91
|
+
* @memberof GeckoContract
|
|
92
|
+
*/
|
|
93
|
+
open_interest: number;
|
|
94
|
+
/**
|
|
95
|
+
*
|
|
96
|
+
* @type {number}
|
|
97
|
+
* @memberof GeckoContract
|
|
98
|
+
*/
|
|
99
|
+
open_interest_usd: number;
|
|
100
|
+
/**
|
|
101
|
+
*
|
|
102
|
+
* @type {number}
|
|
103
|
+
* @memberof GeckoContract
|
|
104
|
+
*/
|
|
105
|
+
index_price: number;
|
|
106
|
+
/**
|
|
107
|
+
*
|
|
108
|
+
* @type {string}
|
|
109
|
+
* @memberof GeckoContract
|
|
110
|
+
*/
|
|
111
|
+
index_name: string;
|
|
112
|
+
/**
|
|
113
|
+
*
|
|
114
|
+
* @type {string}
|
|
115
|
+
* @memberof GeckoContract
|
|
116
|
+
*/
|
|
117
|
+
index_currency: string;
|
|
118
|
+
/**
|
|
119
|
+
*
|
|
120
|
+
* @type {number}
|
|
121
|
+
* @memberof GeckoContract
|
|
122
|
+
*/
|
|
123
|
+
start_timestamp: number;
|
|
124
|
+
/**
|
|
125
|
+
*
|
|
126
|
+
* @type {number}
|
|
127
|
+
* @memberof GeckoContract
|
|
128
|
+
*/
|
|
129
|
+
end_timestamp: number;
|
|
130
|
+
/**
|
|
131
|
+
*
|
|
132
|
+
* @type {number}
|
|
133
|
+
* @memberof GeckoContract
|
|
134
|
+
*/
|
|
135
|
+
funding_rate: number;
|
|
136
|
+
/**
|
|
137
|
+
*
|
|
138
|
+
* @type {number}
|
|
139
|
+
* @memberof GeckoContract
|
|
140
|
+
*/
|
|
141
|
+
next_funding_rate: number;
|
|
142
|
+
/**
|
|
143
|
+
*
|
|
144
|
+
* @type {number}
|
|
145
|
+
* @memberof GeckoContract
|
|
146
|
+
*/
|
|
147
|
+
next_funding_rate_timestamp: number;
|
|
148
|
+
/**
|
|
149
|
+
*
|
|
150
|
+
* @type {string}
|
|
151
|
+
* @memberof GeckoContract
|
|
152
|
+
*/
|
|
153
|
+
contract_type: string;
|
|
154
|
+
/**
|
|
155
|
+
*
|
|
156
|
+
* @type {string}
|
|
157
|
+
* @memberof GeckoContract
|
|
158
|
+
*/
|
|
159
|
+
contract_price_currency: string;
|
|
160
|
+
/**
|
|
161
|
+
*
|
|
162
|
+
* @type {number}
|
|
163
|
+
* @memberof GeckoContract
|
|
164
|
+
*/
|
|
165
|
+
contract_price: number;
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
/**
|
|
169
|
+
* Check if a given object implements the GeckoContract interface.
|
|
170
|
+
*/
|
|
171
|
+
export function instanceOfGeckoContract(value: object): value is GeckoContract {
|
|
172
|
+
if (!('ticker_id' in value) || value['ticker_id'] === undefined) return false;
|
|
173
|
+
if (!('base_currency' in value) || value['base_currency'] === undefined) return false;
|
|
174
|
+
if (!('target_currency' in value) || value['target_currency'] === undefined) return false;
|
|
175
|
+
if (!('last_price' in value) || value['last_price'] === undefined) return false;
|
|
176
|
+
if (!('base_volume' in value) || value['base_volume'] === undefined) return false;
|
|
177
|
+
if (!('target_volume' in value) || value['target_volume'] === undefined) return false;
|
|
178
|
+
if (!('bid' in value) || value['bid'] === undefined) return false;
|
|
179
|
+
if (!('ask' in value) || value['ask'] === undefined) return false;
|
|
180
|
+
if (!('high' in value) || value['high'] === undefined) return false;
|
|
181
|
+
if (!('low' in value) || value['low'] === undefined) return false;
|
|
182
|
+
if (!('product_type' in value) || value['product_type'] === undefined) return false;
|
|
183
|
+
if (!('open_interest' in value) || value['open_interest'] === undefined) return false;
|
|
184
|
+
if (!('open_interest_usd' in value) || value['open_interest_usd'] === undefined) return false;
|
|
185
|
+
if (!('index_price' in value) || value['index_price'] === undefined) return false;
|
|
186
|
+
if (!('index_name' in value) || value['index_name'] === undefined) return false;
|
|
187
|
+
if (!('index_currency' in value) || value['index_currency'] === undefined) return false;
|
|
188
|
+
if (!('start_timestamp' in value) || value['start_timestamp'] === undefined) return false;
|
|
189
|
+
if (!('end_timestamp' in value) || value['end_timestamp'] === undefined) return false;
|
|
190
|
+
if (!('funding_rate' in value) || value['funding_rate'] === undefined) return false;
|
|
191
|
+
if (!('next_funding_rate' in value) || value['next_funding_rate'] === undefined) return false;
|
|
192
|
+
if (!('next_funding_rate_timestamp' in value) || value['next_funding_rate_timestamp'] === undefined) return false;
|
|
193
|
+
if (!('contract_type' in value) || value['contract_type'] === undefined) return false;
|
|
194
|
+
if (!('contract_price_currency' in value) || value['contract_price_currency'] === undefined) return false;
|
|
195
|
+
if (!('contract_price' in value) || value['contract_price'] === undefined) return false;
|
|
196
|
+
return true;
|
|
197
|
+
}
|
|
198
|
+
|
|
199
|
+
export function GeckoContractFromJSON(json: any): GeckoContract {
|
|
200
|
+
return GeckoContractFromJSONTyped(json, false);
|
|
201
|
+
}
|
|
202
|
+
|
|
203
|
+
export function GeckoContractFromJSONTyped(json: any, ignoreDiscriminator: boolean): GeckoContract {
|
|
204
|
+
if (json == null) {
|
|
205
|
+
return json;
|
|
206
|
+
}
|
|
207
|
+
return {
|
|
208
|
+
|
|
209
|
+
'ticker_id': json['ticker_id'],
|
|
210
|
+
'base_currency': json['base_currency'],
|
|
211
|
+
'target_currency': json['target_currency'],
|
|
212
|
+
'last_price': json['last_price'],
|
|
213
|
+
'base_volume': json['base_volume'],
|
|
214
|
+
'target_volume': json['target_volume'],
|
|
215
|
+
'bid': json['bid'],
|
|
216
|
+
'ask': json['ask'],
|
|
217
|
+
'high': json['high'],
|
|
218
|
+
'low': json['low'],
|
|
219
|
+
'product_type': json['product_type'],
|
|
220
|
+
'open_interest': json['open_interest'],
|
|
221
|
+
'open_interest_usd': json['open_interest_usd'],
|
|
222
|
+
'index_price': json['index_price'],
|
|
223
|
+
'index_name': json['index_name'],
|
|
224
|
+
'index_currency': json['index_currency'],
|
|
225
|
+
'start_timestamp': json['start_timestamp'],
|
|
226
|
+
'end_timestamp': json['end_timestamp'],
|
|
227
|
+
'funding_rate': json['funding_rate'],
|
|
228
|
+
'next_funding_rate': json['next_funding_rate'],
|
|
229
|
+
'next_funding_rate_timestamp': json['next_funding_rate_timestamp'],
|
|
230
|
+
'contract_type': json['contract_type'],
|
|
231
|
+
'contract_price_currency': json['contract_price_currency'],
|
|
232
|
+
'contract_price': json['contract_price'],
|
|
233
|
+
};
|
|
234
|
+
}
|
|
235
|
+
|
|
236
|
+
export function GeckoContractToJSON(value?: GeckoContract | null): any {
|
|
237
|
+
if (value == null) {
|
|
238
|
+
return value;
|
|
239
|
+
}
|
|
240
|
+
return {
|
|
241
|
+
|
|
242
|
+
'ticker_id': value['ticker_id'],
|
|
243
|
+
'base_currency': value['base_currency'],
|
|
244
|
+
'target_currency': value['target_currency'],
|
|
245
|
+
'last_price': value['last_price'],
|
|
246
|
+
'base_volume': value['base_volume'],
|
|
247
|
+
'target_volume': value['target_volume'],
|
|
248
|
+
'bid': value['bid'],
|
|
249
|
+
'ask': value['ask'],
|
|
250
|
+
'high': value['high'],
|
|
251
|
+
'low': value['low'],
|
|
252
|
+
'product_type': value['product_type'],
|
|
253
|
+
'open_interest': value['open_interest'],
|
|
254
|
+
'open_interest_usd': value['open_interest_usd'],
|
|
255
|
+
'index_price': value['index_price'],
|
|
256
|
+
'index_name': value['index_name'],
|
|
257
|
+
'index_currency': value['index_currency'],
|
|
258
|
+
'start_timestamp': value['start_timestamp'],
|
|
259
|
+
'end_timestamp': value['end_timestamp'],
|
|
260
|
+
'funding_rate': value['funding_rate'],
|
|
261
|
+
'next_funding_rate': value['next_funding_rate'],
|
|
262
|
+
'next_funding_rate_timestamp': value['next_funding_rate_timestamp'],
|
|
263
|
+
'contract_type': value['contract_type'],
|
|
264
|
+
'contract_price_currency': value['contract_price_currency'],
|
|
265
|
+
'contract_price': value['contract_price'],
|
|
266
|
+
};
|
|
267
|
+
}
|
|
268
|
+
|
|
@@ -0,0 +1,68 @@
|
|
|
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
|
+
import type { GeckoContract } from './GeckoContract';
|
|
17
|
+
import {
|
|
18
|
+
GeckoContractFromJSON,
|
|
19
|
+
GeckoContractFromJSONTyped,
|
|
20
|
+
GeckoContractToJSON,
|
|
21
|
+
} from './GeckoContract';
|
|
22
|
+
|
|
23
|
+
/**
|
|
24
|
+
*
|
|
25
|
+
* @export
|
|
26
|
+
* @interface GeckoContracts
|
|
27
|
+
*/
|
|
28
|
+
export interface GeckoContracts {
|
|
29
|
+
/**
|
|
30
|
+
*
|
|
31
|
+
* @type {Array<GeckoContract>}
|
|
32
|
+
* @memberof GeckoContracts
|
|
33
|
+
*/
|
|
34
|
+
contracts: Array<GeckoContract>;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
* Check if a given object implements the GeckoContracts interface.
|
|
39
|
+
*/
|
|
40
|
+
export function instanceOfGeckoContracts(value: object): value is GeckoContracts {
|
|
41
|
+
if (!('contracts' in value) || value['contracts'] === undefined) return false;
|
|
42
|
+
return true;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
export function GeckoContractsFromJSON(json: any): GeckoContracts {
|
|
46
|
+
return GeckoContractsFromJSONTyped(json, false);
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export function GeckoContractsFromJSONTyped(json: any, ignoreDiscriminator: boolean): GeckoContracts {
|
|
50
|
+
if (json == null) {
|
|
51
|
+
return json;
|
|
52
|
+
}
|
|
53
|
+
return {
|
|
54
|
+
|
|
55
|
+
'contracts': ((json['contracts'] as Array<any>).map(GeckoContractFromJSON)),
|
|
56
|
+
};
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
export function GeckoContractsToJSON(value?: GeckoContracts | null): any {
|
|
60
|
+
if (value == null) {
|
|
61
|
+
return value;
|
|
62
|
+
}
|
|
63
|
+
return {
|
|
64
|
+
|
|
65
|
+
'contracts': ((value['contracts'] as Array<any>).map(GeckoContractToJSON)),
|
|
66
|
+
};
|
|
67
|
+
}
|
|
68
|
+
|
|
@@ -0,0 +1,88 @@
|
|
|
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 GeckoOrderbook
|
|
20
|
+
*/
|
|
21
|
+
export interface GeckoOrderbook {
|
|
22
|
+
/**
|
|
23
|
+
*
|
|
24
|
+
* @type {string}
|
|
25
|
+
* @memberof GeckoOrderbook
|
|
26
|
+
*/
|
|
27
|
+
ticker_id: string;
|
|
28
|
+
/**
|
|
29
|
+
*
|
|
30
|
+
* @type {number}
|
|
31
|
+
* @memberof GeckoOrderbook
|
|
32
|
+
*/
|
|
33
|
+
timestamp: number;
|
|
34
|
+
/**
|
|
35
|
+
*
|
|
36
|
+
* @type {Array<Array<number>>}
|
|
37
|
+
* @memberof GeckoOrderbook
|
|
38
|
+
*/
|
|
39
|
+
bids: Array<Array<number>>;
|
|
40
|
+
/**
|
|
41
|
+
*
|
|
42
|
+
* @type {Array<Array<number>>}
|
|
43
|
+
* @memberof GeckoOrderbook
|
|
44
|
+
*/
|
|
45
|
+
asks: Array<Array<number>>;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
/**
|
|
49
|
+
* Check if a given object implements the GeckoOrderbook interface.
|
|
50
|
+
*/
|
|
51
|
+
export function instanceOfGeckoOrderbook(value: object): value is GeckoOrderbook {
|
|
52
|
+
if (!('ticker_id' in value) || value['ticker_id'] === undefined) return false;
|
|
53
|
+
if (!('timestamp' in value) || value['timestamp'] === undefined) return false;
|
|
54
|
+
if (!('bids' in value) || value['bids'] === undefined) return false;
|
|
55
|
+
if (!('asks' in value) || value['asks'] === undefined) return false;
|
|
56
|
+
return true;
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
export function GeckoOrderbookFromJSON(json: any): GeckoOrderbook {
|
|
60
|
+
return GeckoOrderbookFromJSONTyped(json, false);
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
export function GeckoOrderbookFromJSONTyped(json: any, ignoreDiscriminator: boolean): GeckoOrderbook {
|
|
64
|
+
if (json == null) {
|
|
65
|
+
return json;
|
|
66
|
+
}
|
|
67
|
+
return {
|
|
68
|
+
|
|
69
|
+
'ticker_id': json['ticker_id'],
|
|
70
|
+
'timestamp': json['timestamp'],
|
|
71
|
+
'bids': json['bids'],
|
|
72
|
+
'asks': json['asks'],
|
|
73
|
+
};
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
export function GeckoOrderbookToJSON(value?: GeckoOrderbook | null): any {
|
|
77
|
+
if (value == null) {
|
|
78
|
+
return value;
|
|
79
|
+
}
|
|
80
|
+
return {
|
|
81
|
+
|
|
82
|
+
'ticker_id': value['ticker_id'],
|
|
83
|
+
'timestamp': value['timestamp'],
|
|
84
|
+
'bids': value['bids'],
|
|
85
|
+
'asks': value['asks'],
|
|
86
|
+
};
|
|
87
|
+
}
|
|
88
|
+
|
|
@@ -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 MarketConfig
|
|
20
|
+
*/
|
|
21
|
+
export interface MarketConfig {
|
|
22
|
+
/**
|
|
23
|
+
*
|
|
24
|
+
* @type {number}
|
|
25
|
+
* @memberof MarketConfig
|
|
26
|
+
*/
|
|
27
|
+
market_margin_mode: number;
|
|
28
|
+
/**
|
|
29
|
+
*
|
|
30
|
+
* @type {number}
|
|
31
|
+
* @memberof MarketConfig
|
|
32
|
+
*/
|
|
33
|
+
insurance_fund_account_index: number;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
/**
|
|
37
|
+
* Check if a given object implements the MarketConfig interface.
|
|
38
|
+
*/
|
|
39
|
+
export function instanceOfMarketConfig(value: object): value is MarketConfig {
|
|
40
|
+
if (!('market_margin_mode' in value) || value['market_margin_mode'] === undefined) return false;
|
|
41
|
+
if (!('insurance_fund_account_index' in value) || value['insurance_fund_account_index'] === undefined) return false;
|
|
42
|
+
return true;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
export function MarketConfigFromJSON(json: any): MarketConfig {
|
|
46
|
+
return MarketConfigFromJSONTyped(json, false);
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export function MarketConfigFromJSONTyped(json: any, ignoreDiscriminator: boolean): MarketConfig {
|
|
50
|
+
if (json == null) {
|
|
51
|
+
return json;
|
|
52
|
+
}
|
|
53
|
+
return {
|
|
54
|
+
|
|
55
|
+
'market_margin_mode': json['market_margin_mode'],
|
|
56
|
+
'insurance_fund_account_index': json['insurance_fund_account_index'],
|
|
57
|
+
};
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
export function MarketConfigToJSON(value?: MarketConfig | null): any {
|
|
61
|
+
if (value == null) {
|
|
62
|
+
return value;
|
|
63
|
+
}
|
|
64
|
+
return {
|
|
65
|
+
|
|
66
|
+
'market_margin_mode': value['market_margin_mode'],
|
|
67
|
+
'insurance_fund_account_index': value['insurance_fund_account_index'],
|
|
68
|
+
};
|
|
69
|
+
}
|
|
70
|
+
|
package/models/MarketInfo.ts
CHANGED
|
@@ -43,6 +43,24 @@ export interface MarketInfo {
|
|
|
43
43
|
* @memberof MarketInfo
|
|
44
44
|
*/
|
|
45
45
|
open_interest: string;
|
|
46
|
+
/**
|
|
47
|
+
*
|
|
48
|
+
* @type {string}
|
|
49
|
+
* @memberof MarketInfo
|
|
50
|
+
*/
|
|
51
|
+
open_interest_limit: string;
|
|
52
|
+
/**
|
|
53
|
+
*
|
|
54
|
+
* @type {string}
|
|
55
|
+
* @memberof MarketInfo
|
|
56
|
+
*/
|
|
57
|
+
funding_clamp_small: string;
|
|
58
|
+
/**
|
|
59
|
+
*
|
|
60
|
+
* @type {string}
|
|
61
|
+
* @memberof MarketInfo
|
|
62
|
+
*/
|
|
63
|
+
funding_clamp_big: string;
|
|
46
64
|
/**
|
|
47
65
|
*
|
|
48
66
|
* @type {string}
|
|
@@ -107,6 +125,9 @@ export function instanceOfMarketInfo(value: object): value is MarketInfo {
|
|
|
107
125
|
if (!('index_price' in value) || value['index_price'] === undefined) return false;
|
|
108
126
|
if (!('mark_price' in value) || value['mark_price'] === undefined) return false;
|
|
109
127
|
if (!('open_interest' in value) || value['open_interest'] === undefined) return false;
|
|
128
|
+
if (!('open_interest_limit' in value) || value['open_interest_limit'] === undefined) return false;
|
|
129
|
+
if (!('funding_clamp_small' in value) || value['funding_clamp_small'] === undefined) return false;
|
|
130
|
+
if (!('funding_clamp_big' in value) || value['funding_clamp_big'] === undefined) return false;
|
|
110
131
|
if (!('last_trade_price' in value) || value['last_trade_price'] === undefined) return false;
|
|
111
132
|
if (!('current_funding_rate' in value) || value['current_funding_rate'] === undefined) return false;
|
|
112
133
|
if (!('funding_rate' in value) || value['funding_rate'] === undefined) return false;
|
|
@@ -133,6 +154,9 @@ export function MarketInfoFromJSONTyped(json: any, ignoreDiscriminator: boolean)
|
|
|
133
154
|
'index_price': json['index_price'],
|
|
134
155
|
'mark_price': json['mark_price'],
|
|
135
156
|
'open_interest': json['open_interest'],
|
|
157
|
+
'open_interest_limit': json['open_interest_limit'],
|
|
158
|
+
'funding_clamp_small': json['funding_clamp_small'],
|
|
159
|
+
'funding_clamp_big': json['funding_clamp_big'],
|
|
136
160
|
'last_trade_price': json['last_trade_price'],
|
|
137
161
|
'current_funding_rate': json['current_funding_rate'],
|
|
138
162
|
'funding_rate': json['funding_rate'],
|
|
@@ -155,6 +179,9 @@ export function MarketInfoToJSON(value?: MarketInfo | null): any {
|
|
|
155
179
|
'index_price': value['index_price'],
|
|
156
180
|
'mark_price': value['mark_price'],
|
|
157
181
|
'open_interest': value['open_interest'],
|
|
182
|
+
'open_interest_limit': value['open_interest_limit'],
|
|
183
|
+
'funding_clamp_small': value['funding_clamp_small'],
|
|
184
|
+
'funding_clamp_big': value['funding_clamp_big'],
|
|
158
185
|
'last_trade_price': value['last_trade_price'],
|
|
159
186
|
'current_funding_rate': value['current_funding_rate'],
|
|
160
187
|
'funding_rate': value['funding_rate'],
|
package/models/OrderBook.ts
CHANGED
|
@@ -67,6 +67,12 @@ export interface OrderBook {
|
|
|
67
67
|
* @memberof OrderBook
|
|
68
68
|
*/
|
|
69
69
|
min_quote_amount: string;
|
|
70
|
+
/**
|
|
71
|
+
*
|
|
72
|
+
* @type {string}
|
|
73
|
+
* @memberof OrderBook
|
|
74
|
+
*/
|
|
75
|
+
order_quote_limit: string;
|
|
70
76
|
/**
|
|
71
77
|
*
|
|
72
78
|
* @type {number}
|
|
@@ -110,6 +116,7 @@ export function instanceOfOrderBook(value: object): value is OrderBook {
|
|
|
110
116
|
if (!('liquidation_fee' in value) || value['liquidation_fee'] === undefined) return false;
|
|
111
117
|
if (!('min_base_amount' in value) || value['min_base_amount'] === undefined) return false;
|
|
112
118
|
if (!('min_quote_amount' in value) || value['min_quote_amount'] === undefined) return false;
|
|
119
|
+
if (!('order_quote_limit' in value) || value['order_quote_limit'] === undefined) return false;
|
|
113
120
|
if (!('supported_size_decimals' in value) || value['supported_size_decimals'] === undefined) return false;
|
|
114
121
|
if (!('supported_price_decimals' in value) || value['supported_price_decimals'] === undefined) return false;
|
|
115
122
|
if (!('supported_quote_decimals' in value) || value['supported_quote_decimals'] === undefined) return false;
|
|
@@ -134,6 +141,7 @@ export function OrderBookFromJSONTyped(json: any, ignoreDiscriminator: boolean):
|
|
|
134
141
|
'liquidation_fee': json['liquidation_fee'],
|
|
135
142
|
'min_base_amount': json['min_base_amount'],
|
|
136
143
|
'min_quote_amount': json['min_quote_amount'],
|
|
144
|
+
'order_quote_limit': json['order_quote_limit'],
|
|
137
145
|
'supported_size_decimals': json['supported_size_decimals'],
|
|
138
146
|
'supported_price_decimals': json['supported_price_decimals'],
|
|
139
147
|
'supported_quote_decimals': json['supported_quote_decimals'],
|
|
@@ -154,6 +162,7 @@ export function OrderBookToJSON(value?: OrderBook | null): any {
|
|
|
154
162
|
'liquidation_fee': value['liquidation_fee'],
|
|
155
163
|
'min_base_amount': value['min_base_amount'],
|
|
156
164
|
'min_quote_amount': value['min_quote_amount'],
|
|
165
|
+
'order_quote_limit': value['order_quote_limit'],
|
|
157
166
|
'supported_size_decimals': value['supported_size_decimals'],
|
|
158
167
|
'supported_price_decimals': value['supported_price_decimals'],
|
|
159
168
|
'supported_quote_decimals': value['supported_quote_decimals'],
|
|
@@ -13,6 +13,13 @@
|
|
|
13
13
|
*/
|
|
14
14
|
|
|
15
15
|
import { mapValues } from '../runtime';
|
|
16
|
+
import type { MarketConfig } from './MarketConfig';
|
|
17
|
+
import {
|
|
18
|
+
MarketConfigFromJSON,
|
|
19
|
+
MarketConfigFromJSONTyped,
|
|
20
|
+
MarketConfigToJSON,
|
|
21
|
+
} from './MarketConfig';
|
|
22
|
+
|
|
16
23
|
/**
|
|
17
24
|
*
|
|
18
25
|
* @export
|
|
@@ -67,6 +74,12 @@ export interface OrderBookDetail {
|
|
|
67
74
|
* @memberof OrderBookDetail
|
|
68
75
|
*/
|
|
69
76
|
min_quote_amount: string;
|
|
77
|
+
/**
|
|
78
|
+
*
|
|
79
|
+
* @type {string}
|
|
80
|
+
* @memberof OrderBookDetail
|
|
81
|
+
*/
|
|
82
|
+
order_quote_limit: string;
|
|
70
83
|
/**
|
|
71
84
|
*
|
|
72
85
|
* @type {number}
|
|
@@ -181,6 +194,12 @@ export interface OrderBookDetail {
|
|
|
181
194
|
* @memberof OrderBookDetail
|
|
182
195
|
*/
|
|
183
196
|
daily_chart: { [key: string]: number; };
|
|
197
|
+
/**
|
|
198
|
+
*
|
|
199
|
+
* @type {MarketConfig}
|
|
200
|
+
* @memberof OrderBookDetail
|
|
201
|
+
*/
|
|
202
|
+
market_config: MarketConfig;
|
|
184
203
|
}
|
|
185
204
|
|
|
186
205
|
|
|
@@ -206,6 +225,7 @@ export function instanceOfOrderBookDetail(value: object): value is OrderBookDeta
|
|
|
206
225
|
if (!('liquidation_fee' in value) || value['liquidation_fee'] === undefined) return false;
|
|
207
226
|
if (!('min_base_amount' in value) || value['min_base_amount'] === undefined) return false;
|
|
208
227
|
if (!('min_quote_amount' in value) || value['min_quote_amount'] === undefined) return false;
|
|
228
|
+
if (!('order_quote_limit' in value) || value['order_quote_limit'] === undefined) return false;
|
|
209
229
|
if (!('supported_size_decimals' in value) || value['supported_size_decimals'] === undefined) return false;
|
|
210
230
|
if (!('supported_price_decimals' in value) || value['supported_price_decimals'] === undefined) return false;
|
|
211
231
|
if (!('supported_quote_decimals' in value) || value['supported_quote_decimals'] === undefined) return false;
|
|
@@ -225,6 +245,7 @@ export function instanceOfOrderBookDetail(value: object): value is OrderBookDeta
|
|
|
225
245
|
if (!('daily_price_change' in value) || value['daily_price_change'] === undefined) return false;
|
|
226
246
|
if (!('open_interest' in value) || value['open_interest'] === undefined) return false;
|
|
227
247
|
if (!('daily_chart' in value) || value['daily_chart'] === undefined) return false;
|
|
248
|
+
if (!('market_config' in value) || value['market_config'] === undefined) return false;
|
|
228
249
|
return true;
|
|
229
250
|
}
|
|
230
251
|
|
|
@@ -246,6 +267,7 @@ export function OrderBookDetailFromJSONTyped(json: any, ignoreDiscriminator: boo
|
|
|
246
267
|
'liquidation_fee': json['liquidation_fee'],
|
|
247
268
|
'min_base_amount': json['min_base_amount'],
|
|
248
269
|
'min_quote_amount': json['min_quote_amount'],
|
|
270
|
+
'order_quote_limit': json['order_quote_limit'],
|
|
249
271
|
'supported_size_decimals': json['supported_size_decimals'],
|
|
250
272
|
'supported_price_decimals': json['supported_price_decimals'],
|
|
251
273
|
'supported_quote_decimals': json['supported_quote_decimals'],
|
|
@@ -265,6 +287,7 @@ export function OrderBookDetailFromJSONTyped(json: any, ignoreDiscriminator: boo
|
|
|
265
287
|
'daily_price_change': json['daily_price_change'],
|
|
266
288
|
'open_interest': json['open_interest'],
|
|
267
289
|
'daily_chart': json['daily_chart'],
|
|
290
|
+
'market_config': MarketConfigFromJSON(json['market_config']),
|
|
268
291
|
};
|
|
269
292
|
}
|
|
270
293
|
|
|
@@ -282,6 +305,7 @@ export function OrderBookDetailToJSON(value?: OrderBookDetail | null): any {
|
|
|
282
305
|
'liquidation_fee': value['liquidation_fee'],
|
|
283
306
|
'min_base_amount': value['min_base_amount'],
|
|
284
307
|
'min_quote_amount': value['min_quote_amount'],
|
|
308
|
+
'order_quote_limit': value['order_quote_limit'],
|
|
285
309
|
'supported_size_decimals': value['supported_size_decimals'],
|
|
286
310
|
'supported_price_decimals': value['supported_price_decimals'],
|
|
287
311
|
'supported_quote_decimals': value['supported_quote_decimals'],
|
|
@@ -301,6 +325,7 @@ export function OrderBookDetailToJSON(value?: OrderBookDetail | null): any {
|
|
|
301
325
|
'daily_price_change': value['daily_price_change'],
|
|
302
326
|
'open_interest': value['open_interest'],
|
|
303
327
|
'daily_chart': value['daily_chart'],
|
|
328
|
+
'market_config': MarketConfigToJSON(value['market_config']),
|
|
304
329
|
};
|
|
305
330
|
}
|
|
306
331
|
|