zklighter-perps 1.0.6 → 1.0.8
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 -1
- package/apis/BlockApi.ts +3 -0
- package/apis/CandlestickApi.ts +3 -0
- package/apis/InfoApi.ts +3 -0
- package/apis/OrderApi.ts +3 -0
- package/apis/RelayerApi.ts +3 -0
- package/apis/RootApi.ts +3 -0
- package/apis/TransactionApi.ts +110 -6
- package/apis/index.ts +0 -1
- package/models/AccountMarketStats.ts +18 -12
- package/models/AccountPnL.ts +7 -5
- package/models/AccountPosition.ts +33 -22
- package/models/AccountStats.ts +15 -10
- package/models/Block.ts +40 -27
- package/models/Blocks.ts +7 -5
- package/models/Candlestick.ts +21 -14
- package/models/Candlesticks.ts +7 -5
- package/models/ContractAddress.ts +6 -4
- package/models/CurrentHeight.ts +3 -2
- package/models/DetailedAccount.ts +11 -8
- package/models/DetailedAccounts.ts +7 -5
- package/models/EnrichedTx.ts +9 -6
- package/models/ExchangeStats.ts +13 -9
- package/models/Funding.ts +12 -8
- package/models/Fundings.ts +7 -5
- package/models/L1ProviderInfo.ts +12 -8
- package/models/Layer1BasicInfo.ts +24 -17
- package/models/Layer2BasicInfo.ts +9 -6
- package/models/MainAccount.ts +9 -6
- package/models/MainAccounts.ts +7 -5
- package/models/MarketInfo.ts +33 -22
- package/models/MarketSig.ts +12 -8
- package/models/NextNonce.ts +3 -2
- package/models/Order.ts +48 -32
- package/models/OrderBook.ts +30 -20
- package/models/OrderBookDepth.ts +11 -8
- package/models/OrderBookDetail.ts +54 -36
- package/models/OrderBookDetails.ts +4 -3
- package/models/OrderBookOrders.ts +14 -10
- package/models/OrderBookStats.ts +18 -12
- package/models/OrderBooks.ts +4 -3
- package/models/Orders.ts +4 -3
- package/models/Permission.ts +3 -2
- package/models/PnLEntry.ts +6 -4
- package/models/PriceLevel.ts +6 -4
- package/models/ReqDoFaucet.ts +3 -2
- package/models/ReqGetAccount.ts +6 -4
- package/models/ReqGetAccountActiveOrders.ts +9 -6
- package/models/ReqGetAccountByL1Address.ts +3 -2
- package/models/ReqGetAccountInactiveOrders.ts +12 -8
- package/models/ReqGetAccountOrders.ts +9 -6
- package/models/ReqGetAccountPnL.ts +18 -12
- package/models/ReqGetBlock.ts +6 -4
- package/models/ReqGetBlockTxs.ts +6 -4
- package/models/ReqGetByAccount.ts +6 -4
- package/models/ReqGetCandlesticks.ts +15 -10
- package/models/ReqGetFundings.ts +15 -10
- package/models/ReqGetL1Tx.ts +3 -2
- package/models/ReqGetMarketSig.ts +9 -6
- package/models/ReqGetNextNonce.ts +6 -4
- package/models/ReqGetOrderBookDetails.ts +3 -2
- package/models/ReqGetOrderBookOrders.ts +6 -4
- package/models/ReqGetOrderBooks.ts +3 -2
- package/models/ReqGetPermission.ts +9 -6
- package/models/ReqGetRangeWithCursor.ts +3 -2
- package/models/ReqGetRangeWithIndex.ts +3 -2
- package/models/ReqGetRecentTrades.ts +6 -4
- package/models/ReqGetRollbacks.ts +9 -6
- package/models/ReqGetSubAccount.ts +9 -6
- package/models/ReqGetTrades.ts +12 -8
- package/models/ReqGetTx.ts +6 -4
- package/models/ReqSearch.ts +3 -2
- package/models/ResultCode.ts +3 -2
- package/models/Rollback.ts +12 -8
- package/models/Rollbacks.ts +7 -5
- package/models/Search.ts +3 -2
- package/models/SignBody.ts +3 -2
- package/models/SimpleOrder.ts +18 -12
- package/models/Status.ts +6 -4
- package/models/SubAccount.ts +24 -16
- package/models/SubAccounts.ts +13 -9
- package/models/Trade.ts +36 -24
- package/models/Trades.ts +4 -3
- package/models/Tx.ts +42 -28
- package/models/TxHash.ts +3 -2
- package/models/TxHashes.ts +77 -0
- package/models/Txs.ts +4 -3
- package/models/ValidatorInfo.ts +6 -4
- package/models/index.ts +1 -0
- package/openapi.json +828 -116
- package/package.json +1 -1
package/models/Tx.ts
CHANGED
|
@@ -24,91 +24,105 @@ export interface Tx {
|
|
|
24
24
|
* @type {string}
|
|
25
25
|
* @memberof Tx
|
|
26
26
|
*/
|
|
27
|
-
hash
|
|
27
|
+
hash: string;
|
|
28
28
|
/**
|
|
29
29
|
*
|
|
30
30
|
* @type {number}
|
|
31
31
|
* @memberof Tx
|
|
32
32
|
*/
|
|
33
|
-
type
|
|
33
|
+
type: number;
|
|
34
34
|
/**
|
|
35
35
|
*
|
|
36
36
|
* @type {string}
|
|
37
37
|
* @memberof Tx
|
|
38
38
|
*/
|
|
39
|
-
info
|
|
39
|
+
info: string;
|
|
40
40
|
/**
|
|
41
41
|
*
|
|
42
42
|
* @type {string}
|
|
43
43
|
* @memberof Tx
|
|
44
44
|
*/
|
|
45
|
-
eventInfo
|
|
45
|
+
eventInfo: string;
|
|
46
46
|
/**
|
|
47
47
|
*
|
|
48
48
|
* @type {number}
|
|
49
49
|
* @memberof Tx
|
|
50
50
|
*/
|
|
51
|
-
status
|
|
51
|
+
status: number;
|
|
52
52
|
/**
|
|
53
53
|
*
|
|
54
54
|
* @type {number}
|
|
55
55
|
* @memberof Tx
|
|
56
56
|
*/
|
|
57
|
-
transactionIndex
|
|
57
|
+
transactionIndex: number;
|
|
58
58
|
/**
|
|
59
59
|
*
|
|
60
60
|
* @type {string}
|
|
61
61
|
* @memberof Tx
|
|
62
62
|
*/
|
|
63
|
-
l1Address
|
|
63
|
+
l1Address: string;
|
|
64
64
|
/**
|
|
65
65
|
*
|
|
66
66
|
* @type {number}
|
|
67
67
|
* @memberof Tx
|
|
68
68
|
*/
|
|
69
|
-
accountIndex
|
|
69
|
+
accountIndex: number;
|
|
70
70
|
/**
|
|
71
71
|
*
|
|
72
72
|
* @type {number}
|
|
73
73
|
* @memberof Tx
|
|
74
74
|
*/
|
|
75
|
-
nonce
|
|
75
|
+
nonce: number;
|
|
76
76
|
/**
|
|
77
77
|
*
|
|
78
78
|
* @type {number}
|
|
79
79
|
* @memberof Tx
|
|
80
80
|
*/
|
|
81
|
-
expireAt
|
|
81
|
+
expireAt: number;
|
|
82
82
|
/**
|
|
83
83
|
*
|
|
84
84
|
* @type {number}
|
|
85
85
|
* @memberof Tx
|
|
86
86
|
*/
|
|
87
|
-
blockHeight
|
|
87
|
+
blockHeight: number;
|
|
88
88
|
/**
|
|
89
89
|
*
|
|
90
90
|
* @type {number}
|
|
91
91
|
* @memberof Tx
|
|
92
92
|
*/
|
|
93
|
-
createdAt
|
|
93
|
+
createdAt: number;
|
|
94
94
|
/**
|
|
95
95
|
*
|
|
96
96
|
* @type {number}
|
|
97
97
|
* @memberof Tx
|
|
98
98
|
*/
|
|
99
|
-
verifyAt
|
|
99
|
+
verifyAt: number;
|
|
100
100
|
/**
|
|
101
101
|
*
|
|
102
102
|
* @type {number}
|
|
103
103
|
* @memberof Tx
|
|
104
104
|
*/
|
|
105
|
-
sequenceIndex
|
|
105
|
+
sequenceIndex: number;
|
|
106
106
|
}
|
|
107
107
|
|
|
108
108
|
/**
|
|
109
109
|
* Check if a given object implements the Tx interface.
|
|
110
110
|
*/
|
|
111
111
|
export function instanceOfTx(value: object): value is Tx {
|
|
112
|
+
if (!('hash' in value) || value['hash'] === undefined) return false;
|
|
113
|
+
if (!('type' in value) || value['type'] === undefined) return false;
|
|
114
|
+
if (!('info' in value) || value['info'] === undefined) return false;
|
|
115
|
+
if (!('eventInfo' in value) || value['eventInfo'] === undefined) return false;
|
|
116
|
+
if (!('status' in value) || value['status'] === undefined) return false;
|
|
117
|
+
if (!('transactionIndex' in value) || value['transactionIndex'] === undefined) return false;
|
|
118
|
+
if (!('l1Address' in value) || value['l1Address'] === undefined) return false;
|
|
119
|
+
if (!('accountIndex' in value) || value['accountIndex'] === undefined) return false;
|
|
120
|
+
if (!('nonce' in value) || value['nonce'] === undefined) return false;
|
|
121
|
+
if (!('expireAt' in value) || value['expireAt'] === undefined) return false;
|
|
122
|
+
if (!('blockHeight' in value) || value['blockHeight'] === undefined) return false;
|
|
123
|
+
if (!('createdAt' in value) || value['createdAt'] === undefined) return false;
|
|
124
|
+
if (!('verifyAt' in value) || value['verifyAt'] === undefined) return false;
|
|
125
|
+
if (!('sequenceIndex' in value) || value['sequenceIndex'] === undefined) return false;
|
|
112
126
|
return true;
|
|
113
127
|
}
|
|
114
128
|
|
|
@@ -122,20 +136,20 @@ export function TxFromJSONTyped(json: any, ignoreDiscriminator: boolean): Tx {
|
|
|
122
136
|
}
|
|
123
137
|
return {
|
|
124
138
|
|
|
125
|
-
'hash': json['hash']
|
|
126
|
-
'type': json['type']
|
|
127
|
-
'info': json['info']
|
|
128
|
-
'eventInfo': json['event_info']
|
|
129
|
-
'status': json['status']
|
|
130
|
-
'transactionIndex': json['transaction_index']
|
|
131
|
-
'l1Address': json['l1_address']
|
|
132
|
-
'accountIndex': json['account_index']
|
|
133
|
-
'nonce': json['nonce']
|
|
134
|
-
'expireAt': json['expire_at']
|
|
135
|
-
'blockHeight': json['block_height']
|
|
136
|
-
'createdAt': json['created_at']
|
|
137
|
-
'verifyAt': json['verify_at']
|
|
138
|
-
'sequenceIndex': json['sequence_index']
|
|
139
|
+
'hash': json['hash'],
|
|
140
|
+
'type': json['type'],
|
|
141
|
+
'info': json['info'],
|
|
142
|
+
'eventInfo': json['event_info'],
|
|
143
|
+
'status': json['status'],
|
|
144
|
+
'transactionIndex': json['transaction_index'],
|
|
145
|
+
'l1Address': json['l1_address'],
|
|
146
|
+
'accountIndex': json['account_index'],
|
|
147
|
+
'nonce': json['nonce'],
|
|
148
|
+
'expireAt': json['expire_at'],
|
|
149
|
+
'blockHeight': json['block_height'],
|
|
150
|
+
'createdAt': json['created_at'],
|
|
151
|
+
'verifyAt': json['verify_at'],
|
|
152
|
+
'sequenceIndex': json['sequence_index'],
|
|
139
153
|
};
|
|
140
154
|
}
|
|
141
155
|
|
package/models/TxHash.ts
CHANGED
|
@@ -36,13 +36,14 @@ export interface TxHash {
|
|
|
36
36
|
* @type {string}
|
|
37
37
|
* @memberof TxHash
|
|
38
38
|
*/
|
|
39
|
-
txHash
|
|
39
|
+
txHash: string;
|
|
40
40
|
}
|
|
41
41
|
|
|
42
42
|
/**
|
|
43
43
|
* Check if a given object implements the TxHash interface.
|
|
44
44
|
*/
|
|
45
45
|
export function instanceOfTxHash(value: object): value is TxHash {
|
|
46
|
+
if (!('txHash' in value) || value['txHash'] === undefined) return false;
|
|
46
47
|
return true;
|
|
47
48
|
}
|
|
48
49
|
|
|
@@ -58,7 +59,7 @@ export function TxHashFromJSONTyped(json: any, ignoreDiscriminator: boolean): Tx
|
|
|
58
59
|
|
|
59
60
|
'code': json['code'] == null ? undefined : json['code'],
|
|
60
61
|
'message': json['message'] == null ? undefined : json['message'],
|
|
61
|
-
'txHash': json['tx_hash']
|
|
62
|
+
'txHash': json['tx_hash'],
|
|
62
63
|
};
|
|
63
64
|
}
|
|
64
65
|
|
|
@@ -0,0 +1,77 @@
|
|
|
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 TxHashes
|
|
20
|
+
*/
|
|
21
|
+
export interface TxHashes {
|
|
22
|
+
/**
|
|
23
|
+
*
|
|
24
|
+
* @type {number}
|
|
25
|
+
* @memberof TxHashes
|
|
26
|
+
*/
|
|
27
|
+
code?: number;
|
|
28
|
+
/**
|
|
29
|
+
*
|
|
30
|
+
* @type {string}
|
|
31
|
+
* @memberof TxHashes
|
|
32
|
+
*/
|
|
33
|
+
message?: string;
|
|
34
|
+
/**
|
|
35
|
+
*
|
|
36
|
+
* @type {Array<string>}
|
|
37
|
+
* @memberof TxHashes
|
|
38
|
+
*/
|
|
39
|
+
txHash: Array<string>;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
/**
|
|
43
|
+
* Check if a given object implements the TxHashes interface.
|
|
44
|
+
*/
|
|
45
|
+
export function instanceOfTxHashes(value: object): value is TxHashes {
|
|
46
|
+
if (!('txHash' in value) || value['txHash'] === undefined) return false;
|
|
47
|
+
return true;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
export function TxHashesFromJSON(json: any): TxHashes {
|
|
51
|
+
return TxHashesFromJSONTyped(json, false);
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
export function TxHashesFromJSONTyped(json: any, ignoreDiscriminator: boolean): TxHashes {
|
|
55
|
+
if (json == null) {
|
|
56
|
+
return json;
|
|
57
|
+
}
|
|
58
|
+
return {
|
|
59
|
+
|
|
60
|
+
'code': json['code'] == null ? undefined : json['code'],
|
|
61
|
+
'message': json['message'] == null ? undefined : json['message'],
|
|
62
|
+
'txHash': json['tx_hash'],
|
|
63
|
+
};
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
export function TxHashesToJSON(value?: TxHashes | null): any {
|
|
67
|
+
if (value == null) {
|
|
68
|
+
return value;
|
|
69
|
+
}
|
|
70
|
+
return {
|
|
71
|
+
|
|
72
|
+
'code': value['code'],
|
|
73
|
+
'message': value['message'],
|
|
74
|
+
'tx_hash': value['txHash'],
|
|
75
|
+
};
|
|
76
|
+
}
|
|
77
|
+
|
package/models/Txs.ts
CHANGED
|
@@ -43,13 +43,14 @@ export interface Txs {
|
|
|
43
43
|
* @type {Array<Tx>}
|
|
44
44
|
* @memberof Txs
|
|
45
45
|
*/
|
|
46
|
-
txs
|
|
46
|
+
txs: Array<Tx>;
|
|
47
47
|
}
|
|
48
48
|
|
|
49
49
|
/**
|
|
50
50
|
* Check if a given object implements the Txs interface.
|
|
51
51
|
*/
|
|
52
52
|
export function instanceOfTxs(value: object): value is Txs {
|
|
53
|
+
if (!('txs' in value) || value['txs'] === undefined) return false;
|
|
53
54
|
return true;
|
|
54
55
|
}
|
|
55
56
|
|
|
@@ -65,7 +66,7 @@ export function TxsFromJSONTyped(json: any, ignoreDiscriminator: boolean): Txs {
|
|
|
65
66
|
|
|
66
67
|
'code': json['code'] == null ? undefined : json['code'],
|
|
67
68
|
'message': json['message'] == null ? undefined : json['message'],
|
|
68
|
-
'txs':
|
|
69
|
+
'txs': ((json['txs'] as Array<any>).map(TxFromJSON)),
|
|
69
70
|
};
|
|
70
71
|
}
|
|
71
72
|
|
|
@@ -77,7 +78,7 @@ export function TxsToJSON(value?: Txs | null): any {
|
|
|
77
78
|
|
|
78
79
|
'code': value['code'],
|
|
79
80
|
'message': value['message'],
|
|
80
|
-
'txs':
|
|
81
|
+
'txs': ((value['txs'] as Array<any>).map(TxToJSON)),
|
|
81
82
|
};
|
|
82
83
|
}
|
|
83
84
|
|
package/models/ValidatorInfo.ts
CHANGED
|
@@ -24,19 +24,21 @@ export interface ValidatorInfo {
|
|
|
24
24
|
* @type {string}
|
|
25
25
|
* @memberof ValidatorInfo
|
|
26
26
|
*/
|
|
27
|
-
address
|
|
27
|
+
address: string;
|
|
28
28
|
/**
|
|
29
29
|
*
|
|
30
30
|
* @type {boolean}
|
|
31
31
|
* @memberof ValidatorInfo
|
|
32
32
|
*/
|
|
33
|
-
isActive
|
|
33
|
+
isActive: boolean;
|
|
34
34
|
}
|
|
35
35
|
|
|
36
36
|
/**
|
|
37
37
|
* Check if a given object implements the ValidatorInfo interface.
|
|
38
38
|
*/
|
|
39
39
|
export function instanceOfValidatorInfo(value: object): value is ValidatorInfo {
|
|
40
|
+
if (!('address' in value) || value['address'] === undefined) return false;
|
|
41
|
+
if (!('isActive' in value) || value['isActive'] === undefined) return false;
|
|
40
42
|
return true;
|
|
41
43
|
}
|
|
42
44
|
|
|
@@ -50,8 +52,8 @@ export function ValidatorInfoFromJSONTyped(json: any, ignoreDiscriminator: boole
|
|
|
50
52
|
}
|
|
51
53
|
return {
|
|
52
54
|
|
|
53
|
-
'address': json['address']
|
|
54
|
-
'isActive': json['is_active']
|
|
55
|
+
'address': json['address'],
|
|
56
|
+
'isActive': json['is_active'],
|
|
55
57
|
};
|
|
56
58
|
}
|
|
57
59
|
|