nado-protocol 0.1.1__py3-none-any.whl → 0.1.2__py3-none-any.whl
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.
- nado_protocol/client/__init__.py +11 -2
- nado_protocol/client/apis/market/execute.py +10 -26
- nado_protocol/client/apis/market/query.py +2 -2
- nado_protocol/client/apis/rewards/execute.py +27 -27
- nado_protocol/client/apis/rewards/query.py +5 -4
- nado_protocol/client/apis/subaccount/query.py +1 -1
- nado_protocol/client/context.py +0 -2
- nado_protocol/contracts/__init__.py +41 -33
- nado_protocol/contracts/abis/Endpoint.json +151 -228
- nado_protocol/contracts/abis/FQuerier.json +91 -508
- nado_protocol/contracts/abis/IAirdrop.json +76 -0
- nado_protocol/contracts/abis/IClearinghouse.json +277 -390
- nado_protocol/contracts/abis/IEndpoint.json +42 -80
- nado_protocol/contracts/abis/IPerpEngine.json +69 -422
- nado_protocol/contracts/abis/IProductEngine.json +87 -205
- nado_protocol/contracts/abis/ISpotEngine.json +173 -362
- nado_protocol/contracts/abis/MockERC20.json +1 -1
- nado_protocol/contracts/deployments/{deployment.test.json → deployment.testing.json} +2 -5
- nado_protocol/contracts/deployments/deployment.testnet.json +15 -0
- nado_protocol/contracts/eip712/types.py +15 -20
- nado_protocol/contracts/types.py +15 -13
- nado_protocol/engine_client/execute.py +18 -39
- nado_protocol/engine_client/query.py +1 -1
- nado_protocol/engine_client/types/__init__.py +4 -8
- nado_protocol/engine_client/types/execute.py +37 -103
- nado_protocol/engine_client/types/models.py +3 -59
- nado_protocol/engine_client/types/query.py +3 -6
- nado_protocol/indexer_client/query.py +4 -9
- nado_protocol/indexer_client/types/__init__.py +4 -5
- nado_protocol/indexer_client/types/models.py +16 -23
- nado_protocol/indexer_client/types/query.py +12 -11
- nado_protocol/trigger_client/execute.py +1 -1
- nado_protocol/trigger_client/types/execute.py +3 -1
- nado_protocol/utils/__init__.py +18 -1
- nado_protocol/utils/backend.py +5 -2
- nado_protocol/utils/exceptions.py +3 -3
- nado_protocol/utils/execute.py +26 -67
- nado_protocol/utils/expiration.py +7 -28
- nado_protocol/utils/nonce.py +0 -4
- nado_protocol/utils/order.py +356 -0
- {nado_protocol-0.1.1.dist-info → nado_protocol-0.1.2.dist-info}/METADATA +4 -2
- nado_protocol-0.1.2.dist-info/RECORD +78 -0
- {nado_protocol-0.1.1.dist-info → nado_protocol-0.1.2.dist-info}/entry_points.txt +0 -1
- nado_protocol/contracts/abis/IERC20.json +0 -185
- nado_protocol/contracts/abis/IOffchainBook.json +0 -536
- nado_protocol/contracts/abis/IVrtxAirdrop.json +0 -138
- nado_protocol-0.1.1.dist-info/RECORD +0 -78
- {nado_protocol-0.1.1.dist-info → nado_protocol-0.1.2.dist-info}/WHEEL +0 -0
|
@@ -13,12 +13,6 @@
|
|
|
13
13
|
"internalType": "address",
|
|
14
14
|
"name": "quote",
|
|
15
15
|
"type": "address"
|
|
16
|
-
},
|
|
17
|
-
{
|
|
18
|
-
"indexed": false,
|
|
19
|
-
"internalType": "address",
|
|
20
|
-
"name": "fees",
|
|
21
|
-
"type": "address"
|
|
22
16
|
}
|
|
23
17
|
],
|
|
24
18
|
"name": "ClearinghouseInitialized",
|
|
@@ -39,34 +33,28 @@
|
|
|
39
33
|
"name": "liquidateeSubaccount",
|
|
40
34
|
"type": "bytes32"
|
|
41
35
|
},
|
|
42
|
-
{
|
|
43
|
-
"indexed": true,
|
|
44
|
-
"internalType": "uint8",
|
|
45
|
-
"name": "mode",
|
|
46
|
-
"type": "uint8"
|
|
47
|
-
},
|
|
48
36
|
{
|
|
49
37
|
"indexed": false,
|
|
50
38
|
"internalType": "uint32",
|
|
51
|
-
"name": "
|
|
39
|
+
"name": "productId",
|
|
52
40
|
"type": "uint32"
|
|
53
41
|
},
|
|
54
42
|
{
|
|
55
43
|
"indexed": false,
|
|
56
|
-
"internalType": "
|
|
57
|
-
"name": "
|
|
58
|
-
"type": "
|
|
44
|
+
"internalType": "bool",
|
|
45
|
+
"name": "isEncodedSpread",
|
|
46
|
+
"type": "bool"
|
|
59
47
|
},
|
|
60
48
|
{
|
|
61
49
|
"indexed": false,
|
|
62
50
|
"internalType": "int128",
|
|
63
|
-
"name": "
|
|
51
|
+
"name": "amount",
|
|
64
52
|
"type": "int128"
|
|
65
53
|
},
|
|
66
54
|
{
|
|
67
55
|
"indexed": false,
|
|
68
56
|
"internalType": "int128",
|
|
69
|
-
"name": "
|
|
57
|
+
"name": "amountQuote",
|
|
70
58
|
"type": "int128"
|
|
71
59
|
}
|
|
72
60
|
],
|
|
@@ -105,6 +93,11 @@
|
|
|
105
93
|
"name": "engine",
|
|
106
94
|
"type": "address"
|
|
107
95
|
},
|
|
96
|
+
{
|
|
97
|
+
"internalType": "address",
|
|
98
|
+
"name": "offchainExchange",
|
|
99
|
+
"type": "address"
|
|
100
|
+
},
|
|
108
101
|
{
|
|
109
102
|
"internalType": "enum IProductEngine.EngineType",
|
|
110
103
|
"name": "engineType",
|
|
@@ -116,6 +109,19 @@
|
|
|
116
109
|
"stateMutability": "nonpayable",
|
|
117
110
|
"type": "function"
|
|
118
111
|
},
|
|
112
|
+
{
|
|
113
|
+
"inputs": [
|
|
114
|
+
{
|
|
115
|
+
"internalType": "bytes",
|
|
116
|
+
"name": "tx",
|
|
117
|
+
"type": "bytes"
|
|
118
|
+
}
|
|
119
|
+
],
|
|
120
|
+
"name": "assertCode",
|
|
121
|
+
"outputs": [],
|
|
122
|
+
"stateMutability": "nonpayable",
|
|
123
|
+
"type": "function"
|
|
124
|
+
},
|
|
119
125
|
{
|
|
120
126
|
"inputs": [
|
|
121
127
|
{
|
|
@@ -125,14 +131,9 @@
|
|
|
125
131
|
"name": "sender",
|
|
126
132
|
"type": "bytes32"
|
|
127
133
|
},
|
|
128
|
-
{
|
|
129
|
-
"internalType": "uint32",
|
|
130
|
-
"name": "productId",
|
|
131
|
-
"type": "uint32"
|
|
132
|
-
},
|
|
133
134
|
{
|
|
134
135
|
"internalType": "uint128",
|
|
135
|
-
"name": "
|
|
136
|
+
"name": "nlpAmount",
|
|
136
137
|
"type": "uint128"
|
|
137
138
|
},
|
|
138
139
|
{
|
|
@@ -141,65 +142,55 @@
|
|
|
141
142
|
"type": "uint64"
|
|
142
143
|
}
|
|
143
144
|
],
|
|
144
|
-
"internalType": "struct IEndpoint.
|
|
145
|
-
"name": "
|
|
145
|
+
"internalType": "struct IEndpoint.BurnNlp",
|
|
146
|
+
"name": "txn",
|
|
146
147
|
"type": "tuple"
|
|
147
|
-
}
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
},
|
|
154
|
-
{
|
|
155
|
-
"inputs": [
|
|
148
|
+
},
|
|
149
|
+
{
|
|
150
|
+
"internalType": "int128",
|
|
151
|
+
"name": "oraclePriceX18",
|
|
152
|
+
"type": "int128"
|
|
153
|
+
},
|
|
156
154
|
{
|
|
157
155
|
"components": [
|
|
156
|
+
{
|
|
157
|
+
"internalType": "uint64",
|
|
158
|
+
"name": "poolId",
|
|
159
|
+
"type": "uint64"
|
|
160
|
+
},
|
|
158
161
|
{
|
|
159
162
|
"internalType": "bytes32",
|
|
160
|
-
"name": "
|
|
163
|
+
"name": "subaccount",
|
|
161
164
|
"type": "bytes32"
|
|
162
165
|
},
|
|
163
166
|
{
|
|
164
|
-
"internalType": "
|
|
165
|
-
"name": "
|
|
166
|
-
"type": "
|
|
167
|
+
"internalType": "address",
|
|
168
|
+
"name": "owner",
|
|
169
|
+
"type": "address"
|
|
167
170
|
},
|
|
168
171
|
{
|
|
169
172
|
"internalType": "uint128",
|
|
170
|
-
"name": "
|
|
173
|
+
"name": "balanceWeightX18",
|
|
171
174
|
"type": "uint128"
|
|
172
|
-
},
|
|
173
|
-
{
|
|
174
|
-
"internalType": "bytes32",
|
|
175
|
-
"name": "recipient",
|
|
176
|
-
"type": "bytes32"
|
|
177
175
|
}
|
|
178
176
|
],
|
|
179
|
-
"internalType": "struct IEndpoint.
|
|
180
|
-
"name": "
|
|
181
|
-
"type": "tuple"
|
|
177
|
+
"internalType": "struct IEndpoint.NlpPool[]",
|
|
178
|
+
"name": "nlpPools",
|
|
179
|
+
"type": "tuple[]"
|
|
180
|
+
},
|
|
181
|
+
{
|
|
182
|
+
"internalType": "int128[]",
|
|
183
|
+
"name": "nlpPoolRebalanceX18",
|
|
184
|
+
"type": "int128[]"
|
|
182
185
|
}
|
|
183
186
|
],
|
|
184
|
-
"name": "
|
|
187
|
+
"name": "burnNlp",
|
|
185
188
|
"outputs": [],
|
|
186
189
|
"stateMutability": "nonpayable",
|
|
187
190
|
"type": "function"
|
|
188
191
|
},
|
|
189
192
|
{
|
|
190
193
|
"inputs": [
|
|
191
|
-
{
|
|
192
|
-
"components": [
|
|
193
|
-
{
|
|
194
|
-
"internalType": "bytes32",
|
|
195
|
-
"name": "subaccount",
|
|
196
|
-
"type": "bytes32"
|
|
197
|
-
}
|
|
198
|
-
],
|
|
199
|
-
"internalType": "struct IEndpoint.ClaimSequencerFees",
|
|
200
|
-
"name": "tx",
|
|
201
|
-
"type": "tuple"
|
|
202
|
-
},
|
|
203
194
|
{
|
|
204
195
|
"internalType": "int128[]",
|
|
205
196
|
"name": "fees",
|
|
@@ -211,6 +202,32 @@
|
|
|
211
202
|
"stateMutability": "nonpayable",
|
|
212
203
|
"type": "function"
|
|
213
204
|
},
|
|
205
|
+
{
|
|
206
|
+
"inputs": [
|
|
207
|
+
{
|
|
208
|
+
"internalType": "bytes32",
|
|
209
|
+
"name": "subaccount",
|
|
210
|
+
"type": "bytes32"
|
|
211
|
+
}
|
|
212
|
+
],
|
|
213
|
+
"name": "clearNlpPoolPosition",
|
|
214
|
+
"outputs": [],
|
|
215
|
+
"stateMutability": "nonpayable",
|
|
216
|
+
"type": "function"
|
|
217
|
+
},
|
|
218
|
+
{
|
|
219
|
+
"inputs": [
|
|
220
|
+
{
|
|
221
|
+
"internalType": "bytes",
|
|
222
|
+
"name": "transaction",
|
|
223
|
+
"type": "bytes"
|
|
224
|
+
}
|
|
225
|
+
],
|
|
226
|
+
"name": "delistProduct",
|
|
227
|
+
"outputs": [],
|
|
228
|
+
"stateMutability": "nonpayable",
|
|
229
|
+
"type": "function"
|
|
230
|
+
},
|
|
214
231
|
{
|
|
215
232
|
"inputs": [
|
|
216
233
|
{
|
|
@@ -244,16 +261,9 @@
|
|
|
244
261
|
{
|
|
245
262
|
"inputs": [
|
|
246
263
|
{
|
|
247
|
-
"
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
"name": "amount",
|
|
251
|
-
"type": "uint128"
|
|
252
|
-
}
|
|
253
|
-
],
|
|
254
|
-
"internalType": "struct IEndpoint.DepositInsurance",
|
|
255
|
-
"name": "tx",
|
|
256
|
-
"type": "tuple"
|
|
264
|
+
"internalType": "bytes",
|
|
265
|
+
"name": "transaction",
|
|
266
|
+
"type": "bytes"
|
|
257
267
|
}
|
|
258
268
|
],
|
|
259
269
|
"name": "depositInsurance",
|
|
@@ -263,12 +273,12 @@
|
|
|
263
273
|
},
|
|
264
274
|
{
|
|
265
275
|
"inputs": [],
|
|
266
|
-
"name": "
|
|
276
|
+
"name": "getClearinghouseLiq",
|
|
267
277
|
"outputs": [
|
|
268
278
|
{
|
|
269
|
-
"internalType": "address
|
|
279
|
+
"internalType": "address",
|
|
270
280
|
"name": "",
|
|
271
|
-
"type": "address
|
|
281
|
+
"type": "address"
|
|
272
282
|
}
|
|
273
283
|
],
|
|
274
284
|
"stateMutability": "view",
|
|
@@ -362,101 +372,6 @@
|
|
|
362
372
|
"stateMutability": "view",
|
|
363
373
|
"type": "function"
|
|
364
374
|
},
|
|
365
|
-
{
|
|
366
|
-
"inputs": [],
|
|
367
|
-
"name": "getMaxHealthGroup",
|
|
368
|
-
"outputs": [
|
|
369
|
-
{
|
|
370
|
-
"internalType": "uint32",
|
|
371
|
-
"name": "",
|
|
372
|
-
"type": "uint32"
|
|
373
|
-
}
|
|
374
|
-
],
|
|
375
|
-
"stateMutability": "view",
|
|
376
|
-
"type": "function"
|
|
377
|
-
},
|
|
378
|
-
{
|
|
379
|
-
"inputs": [],
|
|
380
|
-
"name": "getNumProducts",
|
|
381
|
-
"outputs": [
|
|
382
|
-
{
|
|
383
|
-
"internalType": "uint32",
|
|
384
|
-
"name": "",
|
|
385
|
-
"type": "uint32"
|
|
386
|
-
}
|
|
387
|
-
],
|
|
388
|
-
"stateMutability": "view",
|
|
389
|
-
"type": "function"
|
|
390
|
-
},
|
|
391
|
-
{
|
|
392
|
-
"inputs": [
|
|
393
|
-
{
|
|
394
|
-
"internalType": "uint32",
|
|
395
|
-
"name": "productId",
|
|
396
|
-
"type": "uint32"
|
|
397
|
-
}
|
|
398
|
-
],
|
|
399
|
-
"name": "getOraclePriceX18",
|
|
400
|
-
"outputs": [
|
|
401
|
-
{
|
|
402
|
-
"internalType": "int128",
|
|
403
|
-
"name": "",
|
|
404
|
-
"type": "int128"
|
|
405
|
-
}
|
|
406
|
-
],
|
|
407
|
-
"stateMutability": "view",
|
|
408
|
-
"type": "function"
|
|
409
|
-
},
|
|
410
|
-
{
|
|
411
|
-
"inputs": [
|
|
412
|
-
{
|
|
413
|
-
"internalType": "uint32",
|
|
414
|
-
"name": "healthGroup",
|
|
415
|
-
"type": "uint32"
|
|
416
|
-
}
|
|
417
|
-
],
|
|
418
|
-
"name": "getOraclePricesX18",
|
|
419
|
-
"outputs": [
|
|
420
|
-
{
|
|
421
|
-
"components": [
|
|
422
|
-
{
|
|
423
|
-
"internalType": "int128",
|
|
424
|
-
"name": "spotPriceX18",
|
|
425
|
-
"type": "int128"
|
|
426
|
-
},
|
|
427
|
-
{
|
|
428
|
-
"internalType": "int128",
|
|
429
|
-
"name": "perpPriceX18",
|
|
430
|
-
"type": "int128"
|
|
431
|
-
}
|
|
432
|
-
],
|
|
433
|
-
"internalType": "struct IEndpoint.Prices",
|
|
434
|
-
"name": "",
|
|
435
|
-
"type": "tuple"
|
|
436
|
-
}
|
|
437
|
-
],
|
|
438
|
-
"stateMutability": "view",
|
|
439
|
-
"type": "function"
|
|
440
|
-
},
|
|
441
|
-
{
|
|
442
|
-
"inputs": [
|
|
443
|
-
{
|
|
444
|
-
"internalType": "uint32",
|
|
445
|
-
"name": "productId",
|
|
446
|
-
"type": "uint32"
|
|
447
|
-
}
|
|
448
|
-
],
|
|
449
|
-
"name": "getOrderbook",
|
|
450
|
-
"outputs": [
|
|
451
|
-
{
|
|
452
|
-
"internalType": "address",
|
|
453
|
-
"name": "",
|
|
454
|
-
"type": "address"
|
|
455
|
-
}
|
|
456
|
-
],
|
|
457
|
-
"stateMutability": "view",
|
|
458
|
-
"type": "function"
|
|
459
|
-
},
|
|
460
375
|
{
|
|
461
376
|
"inputs": [],
|
|
462
377
|
"name": "getQuote",
|
|
@@ -471,46 +386,13 @@
|
|
|
471
386
|
"type": "function"
|
|
472
387
|
},
|
|
473
388
|
{
|
|
474
|
-
"inputs": [
|
|
475
|
-
|
|
476
|
-
"internalType": "uint32",
|
|
477
|
-
"name": "productId",
|
|
478
|
-
"type": "uint32"
|
|
479
|
-
}
|
|
480
|
-
],
|
|
481
|
-
"name": "getRisk",
|
|
389
|
+
"inputs": [],
|
|
390
|
+
"name": "getSlowModeFee",
|
|
482
391
|
"outputs": [
|
|
483
392
|
{
|
|
484
|
-
"
|
|
485
|
-
{
|
|
486
|
-
"internalType": "int128",
|
|
487
|
-
"name": "longWeightInitialX18",
|
|
488
|
-
"type": "int128"
|
|
489
|
-
},
|
|
490
|
-
{
|
|
491
|
-
"internalType": "int128",
|
|
492
|
-
"name": "shortWeightInitialX18",
|
|
493
|
-
"type": "int128"
|
|
494
|
-
},
|
|
495
|
-
{
|
|
496
|
-
"internalType": "int128",
|
|
497
|
-
"name": "longWeightMaintenanceX18",
|
|
498
|
-
"type": "int128"
|
|
499
|
-
},
|
|
500
|
-
{
|
|
501
|
-
"internalType": "int128",
|
|
502
|
-
"name": "shortWeightMaintenanceX18",
|
|
503
|
-
"type": "int128"
|
|
504
|
-
},
|
|
505
|
-
{
|
|
506
|
-
"internalType": "int128",
|
|
507
|
-
"name": "largePositionPenaltyX18",
|
|
508
|
-
"type": "int128"
|
|
509
|
-
}
|
|
510
|
-
],
|
|
511
|
-
"internalType": "struct RiskHelper.Risk",
|
|
393
|
+
"internalType": "uint256",
|
|
512
394
|
"name": "",
|
|
513
|
-
"type": "
|
|
395
|
+
"type": "uint256"
|
|
514
396
|
}
|
|
515
397
|
],
|
|
516
398
|
"stateMutability": "view",
|
|
@@ -518,12 +400,12 @@
|
|
|
518
400
|
},
|
|
519
401
|
{
|
|
520
402
|
"inputs": [],
|
|
521
|
-
"name": "
|
|
403
|
+
"name": "getSpreads",
|
|
522
404
|
"outputs": [
|
|
523
405
|
{
|
|
524
|
-
"internalType": "
|
|
406
|
+
"internalType": "uint256",
|
|
525
407
|
"name": "",
|
|
526
|
-
"type": "
|
|
408
|
+
"type": "uint256"
|
|
527
409
|
}
|
|
528
410
|
],
|
|
529
411
|
"stateMutability": "view",
|
|
@@ -531,15 +413,15 @@
|
|
|
531
413
|
},
|
|
532
414
|
{
|
|
533
415
|
"inputs": [],
|
|
534
|
-
"name": "
|
|
416
|
+
"name": "getWithdrawPool",
|
|
535
417
|
"outputs": [
|
|
536
418
|
{
|
|
537
|
-
"internalType": "
|
|
419
|
+
"internalType": "address",
|
|
538
420
|
"name": "",
|
|
539
|
-
"type": "
|
|
421
|
+
"type": "address"
|
|
540
422
|
}
|
|
541
423
|
],
|
|
542
|
-
"stateMutability": "
|
|
424
|
+
"stateMutability": "view",
|
|
543
425
|
"type": "function"
|
|
544
426
|
},
|
|
545
427
|
{
|
|
@@ -556,16 +438,16 @@
|
|
|
556
438
|
"name": "liquidatee",
|
|
557
439
|
"type": "bytes32"
|
|
558
440
|
},
|
|
559
|
-
{
|
|
560
|
-
"internalType": "uint8",
|
|
561
|
-
"name": "mode",
|
|
562
|
-
"type": "uint8"
|
|
563
|
-
},
|
|
564
441
|
{
|
|
565
442
|
"internalType": "uint32",
|
|
566
|
-
"name": "
|
|
443
|
+
"name": "productId",
|
|
567
444
|
"type": "uint32"
|
|
568
445
|
},
|
|
446
|
+
{
|
|
447
|
+
"internalType": "bool",
|
|
448
|
+
"name": "isEncodedSpread",
|
|
449
|
+
"type": "bool"
|
|
450
|
+
},
|
|
569
451
|
{
|
|
570
452
|
"internalType": "int128",
|
|
571
453
|
"name": "amount",
|
|
@@ -590,44 +472,12 @@
|
|
|
590
472
|
{
|
|
591
473
|
"inputs": [
|
|
592
474
|
{
|
|
593
|
-
"
|
|
594
|
-
{
|
|
595
|
-
"internalType": "bytes32",
|
|
596
|
-
"name": "sender",
|
|
597
|
-
"type": "bytes32"
|
|
598
|
-
},
|
|
599
|
-
{
|
|
600
|
-
"internalType": "uint32",
|
|
601
|
-
"name": "productId",
|
|
602
|
-
"type": "uint32"
|
|
603
|
-
},
|
|
604
|
-
{
|
|
605
|
-
"internalType": "uint128",
|
|
606
|
-
"name": "amountBase",
|
|
607
|
-
"type": "uint128"
|
|
608
|
-
},
|
|
609
|
-
{
|
|
610
|
-
"internalType": "uint128",
|
|
611
|
-
"name": "quoteAmountLow",
|
|
612
|
-
"type": "uint128"
|
|
613
|
-
},
|
|
614
|
-
{
|
|
615
|
-
"internalType": "uint128",
|
|
616
|
-
"name": "quoteAmountHigh",
|
|
617
|
-
"type": "uint128"
|
|
618
|
-
},
|
|
619
|
-
{
|
|
620
|
-
"internalType": "uint64",
|
|
621
|
-
"name": "nonce",
|
|
622
|
-
"type": "uint64"
|
|
623
|
-
}
|
|
624
|
-
],
|
|
625
|
-
"internalType": "struct IEndpoint.MintLp",
|
|
475
|
+
"internalType": "bytes",
|
|
626
476
|
"name": "tx",
|
|
627
|
-
"type": "
|
|
477
|
+
"type": "bytes"
|
|
628
478
|
}
|
|
629
479
|
],
|
|
630
|
-
"name": "
|
|
480
|
+
"name": "manualAssert",
|
|
631
481
|
"outputs": [],
|
|
632
482
|
"stateMutability": "nonpayable",
|
|
633
483
|
"type": "function"
|
|
@@ -641,24 +491,9 @@
|
|
|
641
491
|
"name": "sender",
|
|
642
492
|
"type": "bytes32"
|
|
643
493
|
},
|
|
644
|
-
{
|
|
645
|
-
"internalType": "uint32",
|
|
646
|
-
"name": "productId",
|
|
647
|
-
"type": "uint32"
|
|
648
|
-
},
|
|
649
|
-
{
|
|
650
|
-
"internalType": "uint128",
|
|
651
|
-
"name": "amountBase",
|
|
652
|
-
"type": "uint128"
|
|
653
|
-
},
|
|
654
|
-
{
|
|
655
|
-
"internalType": "uint128",
|
|
656
|
-
"name": "quoteAmountLow",
|
|
657
|
-
"type": "uint128"
|
|
658
|
-
},
|
|
659
494
|
{
|
|
660
495
|
"internalType": "uint128",
|
|
661
|
-
"name": "
|
|
496
|
+
"name": "quoteAmount",
|
|
662
497
|
"type": "uint128"
|
|
663
498
|
},
|
|
664
499
|
{
|
|
@@ -667,57 +502,49 @@
|
|
|
667
502
|
"type": "uint64"
|
|
668
503
|
}
|
|
669
504
|
],
|
|
670
|
-
"internalType": "struct IEndpoint.
|
|
671
|
-
"name": "
|
|
505
|
+
"internalType": "struct IEndpoint.MintNlp",
|
|
506
|
+
"name": "txn",
|
|
672
507
|
"type": "tuple"
|
|
673
|
-
}
|
|
674
|
-
],
|
|
675
|
-
"name": "mintLpSlowMode",
|
|
676
|
-
"outputs": [],
|
|
677
|
-
"stateMutability": "nonpayable",
|
|
678
|
-
"type": "function"
|
|
679
|
-
},
|
|
680
|
-
{
|
|
681
|
-
"inputs": [
|
|
508
|
+
},
|
|
682
509
|
{
|
|
683
|
-
"internalType": "
|
|
684
|
-
"name": "
|
|
685
|
-
"type": "
|
|
510
|
+
"internalType": "int128",
|
|
511
|
+
"name": "oraclePriceX18",
|
|
512
|
+
"type": "int128"
|
|
686
513
|
},
|
|
687
514
|
{
|
|
688
515
|
"components": [
|
|
689
516
|
{
|
|
690
|
-
"internalType": "
|
|
691
|
-
"name": "
|
|
692
|
-
"type": "
|
|
693
|
-
},
|
|
694
|
-
{
|
|
695
|
-
"internalType": "int32",
|
|
696
|
-
"name": "shortWeightInitial",
|
|
697
|
-
"type": "int32"
|
|
517
|
+
"internalType": "uint64",
|
|
518
|
+
"name": "poolId",
|
|
519
|
+
"type": "uint64"
|
|
698
520
|
},
|
|
699
521
|
{
|
|
700
|
-
"internalType": "
|
|
701
|
-
"name": "
|
|
702
|
-
"type": "
|
|
522
|
+
"internalType": "bytes32",
|
|
523
|
+
"name": "subaccount",
|
|
524
|
+
"type": "bytes32"
|
|
703
525
|
},
|
|
704
526
|
{
|
|
705
|
-
"internalType": "
|
|
706
|
-
"name": "
|
|
707
|
-
"type": "
|
|
527
|
+
"internalType": "address",
|
|
528
|
+
"name": "owner",
|
|
529
|
+
"type": "address"
|
|
708
530
|
},
|
|
709
531
|
{
|
|
710
|
-
"internalType": "
|
|
711
|
-
"name": "
|
|
712
|
-
"type": "
|
|
532
|
+
"internalType": "uint128",
|
|
533
|
+
"name": "balanceWeightX18",
|
|
534
|
+
"type": "uint128"
|
|
713
535
|
}
|
|
714
536
|
],
|
|
715
|
-
"internalType": "struct
|
|
716
|
-
"name": "
|
|
717
|
-
"type": "tuple"
|
|
537
|
+
"internalType": "struct IEndpoint.NlpPool[]",
|
|
538
|
+
"name": "nlpPools",
|
|
539
|
+
"type": "tuple[]"
|
|
540
|
+
},
|
|
541
|
+
{
|
|
542
|
+
"internalType": "int128[]",
|
|
543
|
+
"name": "nlpPoolRebalanceX18",
|
|
544
|
+
"type": "int128[]"
|
|
718
545
|
}
|
|
719
546
|
],
|
|
720
|
-
"name": "
|
|
547
|
+
"name": "mintNlp",
|
|
721
548
|
"outputs": [],
|
|
722
549
|
"stateMutability": "nonpayable",
|
|
723
550
|
"type": "function"
|
|
@@ -725,80 +552,61 @@
|
|
|
725
552
|
{
|
|
726
553
|
"inputs": [
|
|
727
554
|
{
|
|
728
|
-
"internalType": "
|
|
729
|
-
"name": "
|
|
730
|
-
"type": "
|
|
555
|
+
"internalType": "bytes",
|
|
556
|
+
"name": "transaction",
|
|
557
|
+
"type": "bytes"
|
|
731
558
|
},
|
|
732
559
|
{
|
|
733
|
-
"
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
|
|
739
|
-
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
743
|
-
|
|
744
|
-
|
|
745
|
-
"internalType": "int32",
|
|
746
|
-
"name": "longWeightMaintenance",
|
|
747
|
-
"type": "int32"
|
|
748
|
-
},
|
|
749
|
-
{
|
|
750
|
-
"internalType": "int32",
|
|
751
|
-
"name": "shortWeightMaintenance",
|
|
752
|
-
"type": "int32"
|
|
753
|
-
},
|
|
754
|
-
{
|
|
755
|
-
"internalType": "int32",
|
|
756
|
-
"name": "largePositionPenalty",
|
|
757
|
-
"type": "int32"
|
|
758
|
-
}
|
|
759
|
-
],
|
|
760
|
-
"internalType": "struct IClearinghouseState.RiskStore",
|
|
761
|
-
"name": "riskStore",
|
|
762
|
-
"type": "tuple"
|
|
763
|
-
},
|
|
560
|
+
"internalType": "uint64",
|
|
561
|
+
"name": "nSubmissions",
|
|
562
|
+
"type": "uint64"
|
|
563
|
+
}
|
|
564
|
+
],
|
|
565
|
+
"name": "rebalanceXWithdraw",
|
|
566
|
+
"outputs": [],
|
|
567
|
+
"stateMutability": "nonpayable",
|
|
568
|
+
"type": "function"
|
|
569
|
+
},
|
|
570
|
+
{
|
|
571
|
+
"inputs": [
|
|
764
572
|
{
|
|
765
573
|
"internalType": "uint32",
|
|
766
|
-
"name": "
|
|
574
|
+
"name": "productId",
|
|
767
575
|
"type": "uint32"
|
|
768
576
|
}
|
|
769
577
|
],
|
|
770
|
-
"name": "
|
|
771
|
-
"outputs": [
|
|
578
|
+
"name": "registerProduct",
|
|
579
|
+
"outputs": [],
|
|
580
|
+
"stateMutability": "nonpayable",
|
|
581
|
+
"type": "function"
|
|
582
|
+
},
|
|
583
|
+
{
|
|
584
|
+
"inputs": [
|
|
772
585
|
{
|
|
773
586
|
"internalType": "uint32",
|
|
774
|
-
"name": "",
|
|
587
|
+
"name": "productId",
|
|
775
588
|
"type": "uint32"
|
|
589
|
+
},
|
|
590
|
+
{
|
|
591
|
+
"internalType": "uint128",
|
|
592
|
+
"name": "amount",
|
|
593
|
+
"type": "uint128"
|
|
776
594
|
}
|
|
777
595
|
],
|
|
596
|
+
"name": "requireMinDeposit",
|
|
597
|
+
"outputs": [],
|
|
778
598
|
"stateMutability": "nonpayable",
|
|
779
599
|
"type": "function"
|
|
780
600
|
},
|
|
781
601
|
{
|
|
782
602
|
"inputs": [
|
|
783
603
|
{
|
|
784
|
-
"
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
"name": "subaccounts",
|
|
788
|
-
"type": "bytes32[]"
|
|
789
|
-
},
|
|
790
|
-
{
|
|
791
|
-
"internalType": "uint256[]",
|
|
792
|
-
"name": "productIds",
|
|
793
|
-
"type": "uint256[]"
|
|
794
|
-
}
|
|
795
|
-
],
|
|
796
|
-
"internalType": "struct IEndpoint.SettlePnl",
|
|
797
|
-
"name": "tx",
|
|
798
|
-
"type": "tuple"
|
|
604
|
+
"internalType": "address",
|
|
605
|
+
"name": "_withdrawPool",
|
|
606
|
+
"type": "address"
|
|
799
607
|
}
|
|
800
608
|
],
|
|
801
|
-
"name": "
|
|
609
|
+
"name": "setWithdrawPool",
|
|
802
610
|
"outputs": [],
|
|
803
611
|
"stateMutability": "nonpayable",
|
|
804
612
|
"type": "function"
|
|
@@ -806,34 +614,12 @@
|
|
|
806
614
|
{
|
|
807
615
|
"inputs": [
|
|
808
616
|
{
|
|
809
|
-
"
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
"name": "user",
|
|
813
|
-
"type": "address"
|
|
814
|
-
},
|
|
815
|
-
{
|
|
816
|
-
"internalType": "uint32",
|
|
817
|
-
"name": "productId",
|
|
818
|
-
"type": "uint32"
|
|
819
|
-
},
|
|
820
|
-
{
|
|
821
|
-
"internalType": "int64",
|
|
822
|
-
"name": "makerRateX18",
|
|
823
|
-
"type": "int64"
|
|
824
|
-
},
|
|
825
|
-
{
|
|
826
|
-
"internalType": "int64",
|
|
827
|
-
"name": "takerRateX18",
|
|
828
|
-
"type": "int64"
|
|
829
|
-
}
|
|
830
|
-
],
|
|
831
|
-
"internalType": "struct IEndpoint.UpdateFeeRates",
|
|
832
|
-
"name": "tx",
|
|
833
|
-
"type": "tuple"
|
|
617
|
+
"internalType": "bytes",
|
|
618
|
+
"name": "transaction",
|
|
619
|
+
"type": "bytes"
|
|
834
620
|
}
|
|
835
621
|
],
|
|
836
|
-
"name": "
|
|
622
|
+
"name": "settlePnl",
|
|
837
623
|
"outputs": [],
|
|
838
624
|
"stateMutability": "nonpayable",
|
|
839
625
|
"type": "function"
|
|
@@ -848,9 +634,9 @@
|
|
|
848
634
|
"type": "bytes32"
|
|
849
635
|
},
|
|
850
636
|
{
|
|
851
|
-
"internalType": "
|
|
852
|
-
"name": "
|
|
853
|
-
"type": "
|
|
637
|
+
"internalType": "bytes32",
|
|
638
|
+
"name": "recipient",
|
|
639
|
+
"type": "bytes32"
|
|
854
640
|
},
|
|
855
641
|
{
|
|
856
642
|
"internalType": "uint128",
|
|
@@ -863,14 +649,115 @@
|
|
|
863
649
|
"type": "uint64"
|
|
864
650
|
}
|
|
865
651
|
],
|
|
866
|
-
"internalType": "struct IEndpoint.
|
|
652
|
+
"internalType": "struct IEndpoint.TransferQuote",
|
|
867
653
|
"name": "tx",
|
|
868
654
|
"type": "tuple"
|
|
869
655
|
}
|
|
870
656
|
],
|
|
657
|
+
"name": "transferQuote",
|
|
658
|
+
"outputs": [],
|
|
659
|
+
"stateMutability": "nonpayable",
|
|
660
|
+
"type": "function"
|
|
661
|
+
},
|
|
662
|
+
{
|
|
663
|
+
"inputs": [
|
|
664
|
+
{
|
|
665
|
+
"internalType": "bytes",
|
|
666
|
+
"name": "transaction",
|
|
667
|
+
"type": "bytes"
|
|
668
|
+
}
|
|
669
|
+
],
|
|
670
|
+
"name": "updateFeeTier",
|
|
671
|
+
"outputs": [],
|
|
672
|
+
"stateMutability": "nonpayable",
|
|
673
|
+
"type": "function"
|
|
674
|
+
},
|
|
675
|
+
{
|
|
676
|
+
"inputs": [
|
|
677
|
+
{
|
|
678
|
+
"internalType": "bytes",
|
|
679
|
+
"name": "transaction",
|
|
680
|
+
"type": "bytes"
|
|
681
|
+
}
|
|
682
|
+
],
|
|
683
|
+
"name": "updatePrice",
|
|
684
|
+
"outputs": [
|
|
685
|
+
{
|
|
686
|
+
"internalType": "uint32",
|
|
687
|
+
"name": "",
|
|
688
|
+
"type": "uint32"
|
|
689
|
+
},
|
|
690
|
+
{
|
|
691
|
+
"internalType": "int128",
|
|
692
|
+
"name": "",
|
|
693
|
+
"type": "int128"
|
|
694
|
+
}
|
|
695
|
+
],
|
|
696
|
+
"stateMutability": "nonpayable",
|
|
697
|
+
"type": "function"
|
|
698
|
+
},
|
|
699
|
+
{
|
|
700
|
+
"inputs": [
|
|
701
|
+
{
|
|
702
|
+
"internalType": "address",
|
|
703
|
+
"name": "_clearinghouseLiq",
|
|
704
|
+
"type": "address"
|
|
705
|
+
}
|
|
706
|
+
],
|
|
707
|
+
"name": "upgradeClearinghouseLiq",
|
|
708
|
+
"outputs": [],
|
|
709
|
+
"stateMutability": "nonpayable",
|
|
710
|
+
"type": "function"
|
|
711
|
+
},
|
|
712
|
+
{
|
|
713
|
+
"inputs": [
|
|
714
|
+
{
|
|
715
|
+
"internalType": "bytes32",
|
|
716
|
+
"name": "sender",
|
|
717
|
+
"type": "bytes32"
|
|
718
|
+
},
|
|
719
|
+
{
|
|
720
|
+
"internalType": "uint32",
|
|
721
|
+
"name": "productId",
|
|
722
|
+
"type": "uint32"
|
|
723
|
+
},
|
|
724
|
+
{
|
|
725
|
+
"internalType": "uint128",
|
|
726
|
+
"name": "amount",
|
|
727
|
+
"type": "uint128"
|
|
728
|
+
},
|
|
729
|
+
{
|
|
730
|
+
"internalType": "address",
|
|
731
|
+
"name": "sendTo",
|
|
732
|
+
"type": "address"
|
|
733
|
+
},
|
|
734
|
+
{
|
|
735
|
+
"internalType": "uint64",
|
|
736
|
+
"name": "idx",
|
|
737
|
+
"type": "uint64"
|
|
738
|
+
}
|
|
739
|
+
],
|
|
871
740
|
"name": "withdrawCollateral",
|
|
872
741
|
"outputs": [],
|
|
873
742
|
"stateMutability": "nonpayable",
|
|
874
743
|
"type": "function"
|
|
744
|
+
},
|
|
745
|
+
{
|
|
746
|
+
"inputs": [
|
|
747
|
+
{
|
|
748
|
+
"internalType": "bytes",
|
|
749
|
+
"name": "transaction",
|
|
750
|
+
"type": "bytes"
|
|
751
|
+
},
|
|
752
|
+
{
|
|
753
|
+
"internalType": "uint64",
|
|
754
|
+
"name": "idx",
|
|
755
|
+
"type": "uint64"
|
|
756
|
+
}
|
|
757
|
+
],
|
|
758
|
+
"name": "withdrawInsurance",
|
|
759
|
+
"outputs": [],
|
|
760
|
+
"stateMutability": "nonpayable",
|
|
761
|
+
"type": "function"
|
|
875
762
|
}
|
|
876
|
-
]
|
|
763
|
+
]
|