zklighter-perps 1.0.193 → 1.0.194
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 +3 -0
- package/apis/OrderApi.ts +106 -0
- package/models/ExchangeMetric.ts +70 -0
- package/models/ReqGetExchangeMetrics.ts +129 -0
- package/models/RespGetExchangeMetrics.ts +85 -0
- package/models/index.ts +3 -0
- package/openapi.json +171 -0
- package/package.json +1 -1
package/.openapi-generator/FILES
CHANGED
|
@@ -56,6 +56,7 @@ models/DetailedAccount.ts
|
|
|
56
56
|
models/DetailedAccounts.ts
|
|
57
57
|
models/DetailedCandlestick.ts
|
|
58
58
|
models/EnrichedTx.ts
|
|
59
|
+
models/ExchangeMetric.ts
|
|
59
60
|
models/ExchangeStats.ts
|
|
60
61
|
models/ExportData.ts
|
|
61
62
|
models/Funding.ts
|
|
@@ -121,6 +122,7 @@ models/ReqGetByAccount.ts
|
|
|
121
122
|
models/ReqGetCandles.ts
|
|
122
123
|
models/ReqGetCandlesticks.ts
|
|
123
124
|
models/ReqGetDepositHistory.ts
|
|
125
|
+
models/ReqGetExchangeMetrics.ts
|
|
124
126
|
models/ReqGetFastWithdrawInfo.ts
|
|
125
127
|
models/ReqGetFundings.ts
|
|
126
128
|
models/ReqGetGeckoOrderbook.ts
|
|
@@ -150,6 +152,7 @@ models/ReqIsWhitelisted.ts
|
|
|
150
152
|
models/RespChangeAccountTier.ts
|
|
151
153
|
models/RespGetApiTokens.ts
|
|
152
154
|
models/RespGetBridgesByL1Addr.ts
|
|
155
|
+
models/RespGetExchangeMetrics.ts
|
|
153
156
|
models/RespGetFastBridgeInfo.ts
|
|
154
157
|
models/RespGetFastwithdrawalInfo.ts
|
|
155
158
|
models/RespGetIsNextBridgeFast.ts
|
package/apis/OrderApi.ts
CHANGED
|
@@ -22,6 +22,7 @@ import type {
|
|
|
22
22
|
OrderBookOrders,
|
|
23
23
|
OrderBooks,
|
|
24
24
|
Orders,
|
|
25
|
+
RespGetExchangeMetrics,
|
|
25
26
|
ResultCode,
|
|
26
27
|
Trades,
|
|
27
28
|
} from '../models/index';
|
|
@@ -40,6 +41,8 @@ import {
|
|
|
40
41
|
OrderBooksToJSON,
|
|
41
42
|
OrdersFromJSON,
|
|
42
43
|
OrdersToJSON,
|
|
44
|
+
RespGetExchangeMetricsFromJSON,
|
|
45
|
+
RespGetExchangeMetricsToJSON,
|
|
43
46
|
ResultCodeFromJSON,
|
|
44
47
|
ResultCodeToJSON,
|
|
45
48
|
TradesFromJSON,
|
|
@@ -76,6 +79,13 @@ export interface AssetDetailsRequest {
|
|
|
76
79
|
asset_id?: number;
|
|
77
80
|
}
|
|
78
81
|
|
|
82
|
+
export interface ExchangeMetricsRequest {
|
|
83
|
+
period: ExchangeMetricsPeriodEnum;
|
|
84
|
+
kind: ExchangeMetricsKindEnum;
|
|
85
|
+
filter?: ExchangeMetricsFilterEnum;
|
|
86
|
+
value?: string;
|
|
87
|
+
}
|
|
88
|
+
|
|
79
89
|
export interface OrderBookDetailsRequest {
|
|
80
90
|
market_id?: number;
|
|
81
91
|
filter?: OrderBookDetailsFilterEnum;
|
|
@@ -337,6 +347,64 @@ export class OrderApi extends runtime.BaseAPI {
|
|
|
337
347
|
return await response.value();
|
|
338
348
|
}
|
|
339
349
|
|
|
350
|
+
/**
|
|
351
|
+
* Get exchange metrics
|
|
352
|
+
* exchangeMetrics
|
|
353
|
+
*/
|
|
354
|
+
async exchangeMetricsRaw(requestParameters: ExchangeMetricsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<RespGetExchangeMetrics>> {
|
|
355
|
+
if (requestParameters['period'] == null) {
|
|
356
|
+
throw new runtime.RequiredError(
|
|
357
|
+
'period',
|
|
358
|
+
'Required parameter "period" was null or undefined when calling exchangeMetrics().'
|
|
359
|
+
);
|
|
360
|
+
}
|
|
361
|
+
|
|
362
|
+
if (requestParameters['kind'] == null) {
|
|
363
|
+
throw new runtime.RequiredError(
|
|
364
|
+
'kind',
|
|
365
|
+
'Required parameter "kind" was null or undefined when calling exchangeMetrics().'
|
|
366
|
+
);
|
|
367
|
+
}
|
|
368
|
+
|
|
369
|
+
const queryParameters: any = {};
|
|
370
|
+
|
|
371
|
+
if (requestParameters['period'] != null) {
|
|
372
|
+
queryParameters['period'] = requestParameters['period'];
|
|
373
|
+
}
|
|
374
|
+
|
|
375
|
+
if (requestParameters['kind'] != null) {
|
|
376
|
+
queryParameters['kind'] = requestParameters['kind'];
|
|
377
|
+
}
|
|
378
|
+
|
|
379
|
+
if (requestParameters['filter'] != null) {
|
|
380
|
+
queryParameters['filter'] = requestParameters['filter'];
|
|
381
|
+
}
|
|
382
|
+
|
|
383
|
+
if (requestParameters['value'] != null) {
|
|
384
|
+
queryParameters['value'] = requestParameters['value'];
|
|
385
|
+
}
|
|
386
|
+
|
|
387
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
388
|
+
|
|
389
|
+
const response = await this.request({
|
|
390
|
+
path: `/api/v1/exchangeMetrics`,
|
|
391
|
+
method: 'GET',
|
|
392
|
+
headers: headerParameters,
|
|
393
|
+
query: queryParameters,
|
|
394
|
+
}, initOverrides);
|
|
395
|
+
|
|
396
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => RespGetExchangeMetricsFromJSON(jsonValue));
|
|
397
|
+
}
|
|
398
|
+
|
|
399
|
+
/**
|
|
400
|
+
* Get exchange metrics
|
|
401
|
+
* exchangeMetrics
|
|
402
|
+
*/
|
|
403
|
+
async exchangeMetrics(requestParameters: ExchangeMetricsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<RespGetExchangeMetrics> {
|
|
404
|
+
const response = await this.exchangeMetricsRaw(requestParameters, initOverrides);
|
|
405
|
+
return await response.value();
|
|
406
|
+
}
|
|
407
|
+
|
|
340
408
|
/**
|
|
341
409
|
* Get exchange stats
|
|
342
410
|
* exchangeStats
|
|
@@ -645,6 +713,44 @@ export const ExportTypeEnum = {
|
|
|
645
713
|
Trade: 'trade'
|
|
646
714
|
} as const;
|
|
647
715
|
export type ExportTypeEnum = typeof ExportTypeEnum[keyof typeof ExportTypeEnum];
|
|
716
|
+
/**
|
|
717
|
+
* @export
|
|
718
|
+
*/
|
|
719
|
+
export const ExchangeMetricsPeriodEnum = {
|
|
720
|
+
W: 'w',
|
|
721
|
+
M: 'm',
|
|
722
|
+
Q: 'q',
|
|
723
|
+
Y: 'y',
|
|
724
|
+
All: 'all'
|
|
725
|
+
} as const;
|
|
726
|
+
export type ExchangeMetricsPeriodEnum = typeof ExchangeMetricsPeriodEnum[keyof typeof ExchangeMetricsPeriodEnum];
|
|
727
|
+
/**
|
|
728
|
+
* @export
|
|
729
|
+
*/
|
|
730
|
+
export const ExchangeMetricsKindEnum = {
|
|
731
|
+
Volume: 'volume',
|
|
732
|
+
MakerFee: 'maker_fee',
|
|
733
|
+
TakerFee: 'taker_fee',
|
|
734
|
+
LiquidationFee: 'liquidation_fee',
|
|
735
|
+
TradeCount: 'trade_count',
|
|
736
|
+
LiquidationCount: 'liquidation_count',
|
|
737
|
+
LiquidationVolume: 'liquidation_volume',
|
|
738
|
+
Inflow: 'inflow',
|
|
739
|
+
Outflow: 'outflow',
|
|
740
|
+
TransferFee: 'transfer_fee',
|
|
741
|
+
WithdrawFee: 'withdraw_fee',
|
|
742
|
+
OpenInterest: 'open_interest',
|
|
743
|
+
AccountCount: 'account_count',
|
|
744
|
+
ActiveAccountCount: 'active_account_count'
|
|
745
|
+
} as const;
|
|
746
|
+
export type ExchangeMetricsKindEnum = typeof ExchangeMetricsKindEnum[keyof typeof ExchangeMetricsKindEnum];
|
|
747
|
+
/**
|
|
748
|
+
* @export
|
|
749
|
+
*/
|
|
750
|
+
export const ExchangeMetricsFilterEnum = {
|
|
751
|
+
ByMarket: 'byMarket'
|
|
752
|
+
} as const;
|
|
753
|
+
export type ExchangeMetricsFilterEnum = typeof ExchangeMetricsFilterEnum[keyof typeof ExchangeMetricsFilterEnum];
|
|
648
754
|
/**
|
|
649
755
|
* @export
|
|
650
756
|
*/
|
|
@@ -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 ExchangeMetric
|
|
20
|
+
*/
|
|
21
|
+
export interface ExchangeMetric {
|
|
22
|
+
/**
|
|
23
|
+
*
|
|
24
|
+
* @type {number}
|
|
25
|
+
* @memberof ExchangeMetric
|
|
26
|
+
*/
|
|
27
|
+
timestamp: number;
|
|
28
|
+
/**
|
|
29
|
+
*
|
|
30
|
+
* @type {number}
|
|
31
|
+
* @memberof ExchangeMetric
|
|
32
|
+
*/
|
|
33
|
+
data: number;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
/**
|
|
37
|
+
* Check if a given object implements the ExchangeMetric interface.
|
|
38
|
+
*/
|
|
39
|
+
export function instanceOfExchangeMetric(value: object): value is ExchangeMetric {
|
|
40
|
+
if (!('timestamp' in value) || value['timestamp'] === undefined) return false;
|
|
41
|
+
if (!('data' in value) || value['data'] === undefined) return false;
|
|
42
|
+
return true;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
export function ExchangeMetricFromJSON(json: any): ExchangeMetric {
|
|
46
|
+
return ExchangeMetricFromJSONTyped(json, false);
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export function ExchangeMetricFromJSONTyped(json: any, ignoreDiscriminator: boolean): ExchangeMetric {
|
|
50
|
+
if (json == null) {
|
|
51
|
+
return json;
|
|
52
|
+
}
|
|
53
|
+
return {
|
|
54
|
+
|
|
55
|
+
'timestamp': json['timestamp'],
|
|
56
|
+
'data': json['data'],
|
|
57
|
+
};
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
export function ExchangeMetricToJSON(value?: ExchangeMetric | null): any {
|
|
61
|
+
if (value == null) {
|
|
62
|
+
return value;
|
|
63
|
+
}
|
|
64
|
+
return {
|
|
65
|
+
|
|
66
|
+
'timestamp': value['timestamp'],
|
|
67
|
+
'data': value['data'],
|
|
68
|
+
};
|
|
69
|
+
}
|
|
70
|
+
|
|
@@ -0,0 +1,129 @@
|
|
|
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 ReqGetExchangeMetrics
|
|
20
|
+
*/
|
|
21
|
+
export interface ReqGetExchangeMetrics {
|
|
22
|
+
/**
|
|
23
|
+
*
|
|
24
|
+
* @type {string}
|
|
25
|
+
* @memberof ReqGetExchangeMetrics
|
|
26
|
+
*/
|
|
27
|
+
period: ReqGetExchangeMetricsPeriodEnum;
|
|
28
|
+
/**
|
|
29
|
+
*
|
|
30
|
+
* @type {string}
|
|
31
|
+
* @memberof ReqGetExchangeMetrics
|
|
32
|
+
*/
|
|
33
|
+
kind: ReqGetExchangeMetricsKindEnum;
|
|
34
|
+
/**
|
|
35
|
+
*
|
|
36
|
+
* @type {string}
|
|
37
|
+
* @memberof ReqGetExchangeMetrics
|
|
38
|
+
*/
|
|
39
|
+
filter?: ReqGetExchangeMetricsFilterEnum;
|
|
40
|
+
/**
|
|
41
|
+
*
|
|
42
|
+
* @type {string}
|
|
43
|
+
* @memberof ReqGetExchangeMetrics
|
|
44
|
+
*/
|
|
45
|
+
value?: string;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
|
|
49
|
+
/**
|
|
50
|
+
* @export
|
|
51
|
+
*/
|
|
52
|
+
export const ReqGetExchangeMetricsPeriodEnum = {
|
|
53
|
+
W: 'w',
|
|
54
|
+
M: 'm',
|
|
55
|
+
Q: 'q',
|
|
56
|
+
Y: 'y',
|
|
57
|
+
All: 'all'
|
|
58
|
+
} as const;
|
|
59
|
+
export type ReqGetExchangeMetricsPeriodEnum = typeof ReqGetExchangeMetricsPeriodEnum[keyof typeof ReqGetExchangeMetricsPeriodEnum];
|
|
60
|
+
|
|
61
|
+
/**
|
|
62
|
+
* @export
|
|
63
|
+
*/
|
|
64
|
+
export const ReqGetExchangeMetricsKindEnum = {
|
|
65
|
+
Volume: 'volume',
|
|
66
|
+
MakerFee: 'maker_fee',
|
|
67
|
+
TakerFee: 'taker_fee',
|
|
68
|
+
LiquidationFee: 'liquidation_fee',
|
|
69
|
+
TradeCount: 'trade_count',
|
|
70
|
+
LiquidationCount: 'liquidation_count',
|
|
71
|
+
LiquidationVolume: 'liquidation_volume',
|
|
72
|
+
Inflow: 'inflow',
|
|
73
|
+
Outflow: 'outflow',
|
|
74
|
+
TransferFee: 'transfer_fee',
|
|
75
|
+
WithdrawFee: 'withdraw_fee',
|
|
76
|
+
OpenInterest: 'open_interest',
|
|
77
|
+
AccountCount: 'account_count',
|
|
78
|
+
ActiveAccountCount: 'active_account_count'
|
|
79
|
+
} as const;
|
|
80
|
+
export type ReqGetExchangeMetricsKindEnum = typeof ReqGetExchangeMetricsKindEnum[keyof typeof ReqGetExchangeMetricsKindEnum];
|
|
81
|
+
|
|
82
|
+
/**
|
|
83
|
+
* @export
|
|
84
|
+
*/
|
|
85
|
+
export const ReqGetExchangeMetricsFilterEnum = {
|
|
86
|
+
ByMarket: 'byMarket'
|
|
87
|
+
} as const;
|
|
88
|
+
export type ReqGetExchangeMetricsFilterEnum = typeof ReqGetExchangeMetricsFilterEnum[keyof typeof ReqGetExchangeMetricsFilterEnum];
|
|
89
|
+
|
|
90
|
+
|
|
91
|
+
/**
|
|
92
|
+
* Check if a given object implements the ReqGetExchangeMetrics interface.
|
|
93
|
+
*/
|
|
94
|
+
export function instanceOfReqGetExchangeMetrics(value: object): value is ReqGetExchangeMetrics {
|
|
95
|
+
if (!('period' in value) || value['period'] === undefined) return false;
|
|
96
|
+
if (!('kind' in value) || value['kind'] === undefined) return false;
|
|
97
|
+
return true;
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
export function ReqGetExchangeMetricsFromJSON(json: any): ReqGetExchangeMetrics {
|
|
101
|
+
return ReqGetExchangeMetricsFromJSONTyped(json, false);
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
export function ReqGetExchangeMetricsFromJSONTyped(json: any, ignoreDiscriminator: boolean): ReqGetExchangeMetrics {
|
|
105
|
+
if (json == null) {
|
|
106
|
+
return json;
|
|
107
|
+
}
|
|
108
|
+
return {
|
|
109
|
+
|
|
110
|
+
'period': json['period'],
|
|
111
|
+
'kind': json['kind'],
|
|
112
|
+
'filter': json['filter'] == null ? undefined : json['filter'],
|
|
113
|
+
'value': json['value'] == null ? undefined : json['value'],
|
|
114
|
+
};
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
export function ReqGetExchangeMetricsToJSON(value?: ReqGetExchangeMetrics | null): any {
|
|
118
|
+
if (value == null) {
|
|
119
|
+
return value;
|
|
120
|
+
}
|
|
121
|
+
return {
|
|
122
|
+
|
|
123
|
+
'period': value['period'],
|
|
124
|
+
'kind': value['kind'],
|
|
125
|
+
'filter': value['filter'],
|
|
126
|
+
'value': value['value'],
|
|
127
|
+
};
|
|
128
|
+
}
|
|
129
|
+
|
|
@@ -0,0 +1,85 @@
|
|
|
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 { ExchangeMetric } from './ExchangeMetric';
|
|
17
|
+
import {
|
|
18
|
+
ExchangeMetricFromJSON,
|
|
19
|
+
ExchangeMetricFromJSONTyped,
|
|
20
|
+
ExchangeMetricToJSON,
|
|
21
|
+
} from './ExchangeMetric';
|
|
22
|
+
|
|
23
|
+
/**
|
|
24
|
+
*
|
|
25
|
+
* @export
|
|
26
|
+
* @interface RespGetExchangeMetrics
|
|
27
|
+
*/
|
|
28
|
+
export interface RespGetExchangeMetrics {
|
|
29
|
+
/**
|
|
30
|
+
*
|
|
31
|
+
* @type {number}
|
|
32
|
+
* @memberof RespGetExchangeMetrics
|
|
33
|
+
*/
|
|
34
|
+
code: number;
|
|
35
|
+
/**
|
|
36
|
+
*
|
|
37
|
+
* @type {string}
|
|
38
|
+
* @memberof RespGetExchangeMetrics
|
|
39
|
+
*/
|
|
40
|
+
message?: string;
|
|
41
|
+
/**
|
|
42
|
+
*
|
|
43
|
+
* @type {Array<ExchangeMetric>}
|
|
44
|
+
* @memberof RespGetExchangeMetrics
|
|
45
|
+
*/
|
|
46
|
+
metrics: Array<ExchangeMetric>;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
/**
|
|
50
|
+
* Check if a given object implements the RespGetExchangeMetrics interface.
|
|
51
|
+
*/
|
|
52
|
+
export function instanceOfRespGetExchangeMetrics(value: object): value is RespGetExchangeMetrics {
|
|
53
|
+
if (!('code' in value) || value['code'] === undefined) return false;
|
|
54
|
+
if (!('metrics' in value) || value['metrics'] === undefined) return false;
|
|
55
|
+
return true;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
export function RespGetExchangeMetricsFromJSON(json: any): RespGetExchangeMetrics {
|
|
59
|
+
return RespGetExchangeMetricsFromJSONTyped(json, false);
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
export function RespGetExchangeMetricsFromJSONTyped(json: any, ignoreDiscriminator: boolean): RespGetExchangeMetrics {
|
|
63
|
+
if (json == null) {
|
|
64
|
+
return json;
|
|
65
|
+
}
|
|
66
|
+
return {
|
|
67
|
+
|
|
68
|
+
'code': json['code'],
|
|
69
|
+
'message': json['message'] == null ? undefined : json['message'],
|
|
70
|
+
'metrics': ((json['metrics'] as Array<any>).map(ExchangeMetricFromJSON)),
|
|
71
|
+
};
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
export function RespGetExchangeMetricsToJSON(value?: RespGetExchangeMetrics | null): any {
|
|
75
|
+
if (value == null) {
|
|
76
|
+
return value;
|
|
77
|
+
}
|
|
78
|
+
return {
|
|
79
|
+
|
|
80
|
+
'code': value['code'],
|
|
81
|
+
'message': value['message'],
|
|
82
|
+
'metrics': ((value['metrics'] as Array<any>).map(ExchangeMetricToJSON)),
|
|
83
|
+
};
|
|
84
|
+
}
|
|
85
|
+
|
package/models/index.ts
CHANGED
|
@@ -42,6 +42,7 @@ export * from './DetailedAccount';
|
|
|
42
42
|
export * from './DetailedAccounts';
|
|
43
43
|
export * from './DetailedCandlestick';
|
|
44
44
|
export * from './EnrichedTx';
|
|
45
|
+
export * from './ExchangeMetric';
|
|
45
46
|
export * from './ExchangeStats';
|
|
46
47
|
export * from './ExportData';
|
|
47
48
|
export * from './Funding';
|
|
@@ -107,6 +108,7 @@ export * from './ReqGetByAccount';
|
|
|
107
108
|
export * from './ReqGetCandles';
|
|
108
109
|
export * from './ReqGetCandlesticks';
|
|
109
110
|
export * from './ReqGetDepositHistory';
|
|
111
|
+
export * from './ReqGetExchangeMetrics';
|
|
110
112
|
export * from './ReqGetFastWithdrawInfo';
|
|
111
113
|
export * from './ReqGetFundings';
|
|
112
114
|
export * from './ReqGetGeckoOrderbook';
|
|
@@ -136,6 +138,7 @@ export * from './ReqIsWhitelisted';
|
|
|
136
138
|
export * from './RespChangeAccountTier';
|
|
137
139
|
export * from './RespGetApiTokens';
|
|
138
140
|
export * from './RespGetBridgesByL1Addr';
|
|
141
|
+
export * from './RespGetExchangeMetrics';
|
|
139
142
|
export * from './RespGetFastBridgeInfo';
|
|
140
143
|
export * from './RespGetFastwithdrawalInfo';
|
|
141
144
|
export * from './RespGetIsNextBridgeFast';
|
package/openapi.json
CHANGED
|
@@ -1276,6 +1276,85 @@
|
|
|
1276
1276
|
"description": "Get deposit supporting networks"
|
|
1277
1277
|
}
|
|
1278
1278
|
},
|
|
1279
|
+
"/api/v1/exchangeMetrics": {
|
|
1280
|
+
"get": {
|
|
1281
|
+
"summary": "exchangeMetrics",
|
|
1282
|
+
"operationId": "exchangeMetrics",
|
|
1283
|
+
"responses": {
|
|
1284
|
+
"200": {
|
|
1285
|
+
"description": "A successful response.",
|
|
1286
|
+
"schema": {
|
|
1287
|
+
"$ref": "#/definitions/RespGetExchangeMetrics"
|
|
1288
|
+
}
|
|
1289
|
+
},
|
|
1290
|
+
"400": {
|
|
1291
|
+
"description": "Bad request",
|
|
1292
|
+
"schema": {
|
|
1293
|
+
"$ref": "#/definitions/ResultCode"
|
|
1294
|
+
}
|
|
1295
|
+
}
|
|
1296
|
+
},
|
|
1297
|
+
"parameters": [
|
|
1298
|
+
{
|
|
1299
|
+
"name": "period",
|
|
1300
|
+
"in": "query",
|
|
1301
|
+
"required": true,
|
|
1302
|
+
"type": "string",
|
|
1303
|
+
"enum": [
|
|
1304
|
+
"w",
|
|
1305
|
+
"m",
|
|
1306
|
+
"q",
|
|
1307
|
+
"y",
|
|
1308
|
+
"all"
|
|
1309
|
+
]
|
|
1310
|
+
},
|
|
1311
|
+
{
|
|
1312
|
+
"name": "kind",
|
|
1313
|
+
"in": "query",
|
|
1314
|
+
"required": true,
|
|
1315
|
+
"type": "string",
|
|
1316
|
+
"enum": [
|
|
1317
|
+
"volume",
|
|
1318
|
+
"maker_fee",
|
|
1319
|
+
"taker_fee",
|
|
1320
|
+
"liquidation_fee",
|
|
1321
|
+
"trade_count",
|
|
1322
|
+
"liquidation_count",
|
|
1323
|
+
"liquidation_volume",
|
|
1324
|
+
"inflow",
|
|
1325
|
+
"outflow",
|
|
1326
|
+
"transfer_fee",
|
|
1327
|
+
"withdraw_fee",
|
|
1328
|
+
"open_interest",
|
|
1329
|
+
"account_count",
|
|
1330
|
+
"active_account_count"
|
|
1331
|
+
]
|
|
1332
|
+
},
|
|
1333
|
+
{
|
|
1334
|
+
"name": "filter",
|
|
1335
|
+
"in": "query",
|
|
1336
|
+
"required": false,
|
|
1337
|
+
"type": "string",
|
|
1338
|
+
"enum": [
|
|
1339
|
+
"byMarket"
|
|
1340
|
+
]
|
|
1341
|
+
},
|
|
1342
|
+
{
|
|
1343
|
+
"name": "value",
|
|
1344
|
+
"in": "query",
|
|
1345
|
+
"required": false,
|
|
1346
|
+
"type": "string"
|
|
1347
|
+
}
|
|
1348
|
+
],
|
|
1349
|
+
"tags": [
|
|
1350
|
+
"order"
|
|
1351
|
+
],
|
|
1352
|
+
"consumes": [
|
|
1353
|
+
"multipart/form-data"
|
|
1354
|
+
],
|
|
1355
|
+
"description": "Get exchange metrics"
|
|
1356
|
+
}
|
|
1357
|
+
},
|
|
1279
1358
|
"/api/v1/exchangeStats": {
|
|
1280
1359
|
"get": {
|
|
1281
1360
|
"summary": "exchangeStats",
|
|
@@ -5511,6 +5590,26 @@
|
|
|
5511
5590
|
"verified_at"
|
|
5512
5591
|
]
|
|
5513
5592
|
},
|
|
5593
|
+
"ExchangeMetric": {
|
|
5594
|
+
"type": "object",
|
|
5595
|
+
"properties": {
|
|
5596
|
+
"timestamp": {
|
|
5597
|
+
"type": "integer",
|
|
5598
|
+
"format": "int64",
|
|
5599
|
+
"example": "1640995200"
|
|
5600
|
+
},
|
|
5601
|
+
"data": {
|
|
5602
|
+
"type": "number",
|
|
5603
|
+
"format": "double",
|
|
5604
|
+
"example": "93566.25"
|
|
5605
|
+
}
|
|
5606
|
+
},
|
|
5607
|
+
"title": "ExchangeMetric",
|
|
5608
|
+
"required": [
|
|
5609
|
+
"timestamp",
|
|
5610
|
+
"data"
|
|
5611
|
+
]
|
|
5612
|
+
},
|
|
5514
5613
|
"ExchangeStats": {
|
|
5515
5614
|
"type": "object",
|
|
5516
5615
|
"properties": {
|
|
@@ -8354,6 +8453,54 @@
|
|
|
8354
8453
|
"l1_address"
|
|
8355
8454
|
]
|
|
8356
8455
|
},
|
|
8456
|
+
"ReqGetExchangeMetrics": {
|
|
8457
|
+
"type": "object",
|
|
8458
|
+
"properties": {
|
|
8459
|
+
"period": {
|
|
8460
|
+
"type": "string",
|
|
8461
|
+
"enum": [
|
|
8462
|
+
"w",
|
|
8463
|
+
"m",
|
|
8464
|
+
"q",
|
|
8465
|
+
"y",
|
|
8466
|
+
"all"
|
|
8467
|
+
]
|
|
8468
|
+
},
|
|
8469
|
+
"kind": {
|
|
8470
|
+
"type": "string",
|
|
8471
|
+
"enum": [
|
|
8472
|
+
"volume",
|
|
8473
|
+
"maker_fee",
|
|
8474
|
+
"taker_fee",
|
|
8475
|
+
"liquidation_fee",
|
|
8476
|
+
"trade_count",
|
|
8477
|
+
"liquidation_count",
|
|
8478
|
+
"liquidation_volume",
|
|
8479
|
+
"inflow",
|
|
8480
|
+
"outflow",
|
|
8481
|
+
"transfer_fee",
|
|
8482
|
+
"withdraw_fee",
|
|
8483
|
+
"open_interest",
|
|
8484
|
+
"account_count",
|
|
8485
|
+
"active_account_count"
|
|
8486
|
+
]
|
|
8487
|
+
},
|
|
8488
|
+
"filter": {
|
|
8489
|
+
"type": "string",
|
|
8490
|
+
"enum": [
|
|
8491
|
+
"byMarket"
|
|
8492
|
+
]
|
|
8493
|
+
},
|
|
8494
|
+
"value": {
|
|
8495
|
+
"type": "string"
|
|
8496
|
+
}
|
|
8497
|
+
},
|
|
8498
|
+
"title": "ReqGetExchangeMetrics",
|
|
8499
|
+
"required": [
|
|
8500
|
+
"period",
|
|
8501
|
+
"kind"
|
|
8502
|
+
]
|
|
8503
|
+
},
|
|
8357
8504
|
"ReqGetExchangeStats": {
|
|
8358
8505
|
"type": "object",
|
|
8359
8506
|
"title": "ReqGetExchangeStats"
|
|
@@ -9252,6 +9399,30 @@
|
|
|
9252
9399
|
"bridges"
|
|
9253
9400
|
]
|
|
9254
9401
|
},
|
|
9402
|
+
"RespGetExchangeMetrics": {
|
|
9403
|
+
"type": "object",
|
|
9404
|
+
"properties": {
|
|
9405
|
+
"code": {
|
|
9406
|
+
"type": "integer",
|
|
9407
|
+
"format": "int32",
|
|
9408
|
+
"example": "200"
|
|
9409
|
+
},
|
|
9410
|
+
"message": {
|
|
9411
|
+
"type": "string"
|
|
9412
|
+
},
|
|
9413
|
+
"metrics": {
|
|
9414
|
+
"type": "array",
|
|
9415
|
+
"items": {
|
|
9416
|
+
"$ref": "#/definitions/ExchangeMetric"
|
|
9417
|
+
}
|
|
9418
|
+
}
|
|
9419
|
+
},
|
|
9420
|
+
"title": "RespGetExchangeMetrics",
|
|
9421
|
+
"required": [
|
|
9422
|
+
"code",
|
|
9423
|
+
"metrics"
|
|
9424
|
+
]
|
|
9425
|
+
},
|
|
9255
9426
|
"RespGetFastBridgeInfo": {
|
|
9256
9427
|
"type": "object",
|
|
9257
9428
|
"properties": {
|