@nexusmutual/sdk 0.5.2 → 0.5.4
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/dist/data/abis/Pool.json +89 -26
- package/dist/data/abis/PriceFeedOracle.json +168 -1
- package/dist/data/addresses.json +2 -1
- package/dist/data/product-types.json +7 -0
- package/dist/data/products.json +359 -181
- package/dist/index.d.mts +759 -224
- package/dist/index.d.ts +759 -224
- package/dist/index.js +367 -181
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +367 -181
- package/dist/index.mjs.map +1 -1
- package/package.json +2 -2
package/dist/data/abis/Pool.json
CHANGED
|
@@ -30,6 +30,32 @@
|
|
|
30
30
|
"stateMutability": "nonpayable",
|
|
31
31
|
"type": "constructor"
|
|
32
32
|
},
|
|
33
|
+
{
|
|
34
|
+
"inputs": [],
|
|
35
|
+
"name": "AssetNotFound",
|
|
36
|
+
"type": "error"
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
"inputs": [],
|
|
40
|
+
"name": "OrderInProgress",
|
|
41
|
+
"type": "error"
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
"inputs": [
|
|
45
|
+
{
|
|
46
|
+
"internalType": "uint256",
|
|
47
|
+
"name": "index",
|
|
48
|
+
"type": "uint256"
|
|
49
|
+
}
|
|
50
|
+
],
|
|
51
|
+
"name": "RevertedWithoutReason",
|
|
52
|
+
"type": "error"
|
|
53
|
+
},
|
|
54
|
+
{
|
|
55
|
+
"inputs": [],
|
|
56
|
+
"name": "UnknownParameter",
|
|
57
|
+
"type": "error"
|
|
58
|
+
},
|
|
33
59
|
{
|
|
34
60
|
"anonymous": false,
|
|
35
61
|
"inputs": [
|
|
@@ -133,6 +159,19 @@
|
|
|
133
159
|
"stateMutability": "nonpayable",
|
|
134
160
|
"type": "function"
|
|
135
161
|
},
|
|
162
|
+
{
|
|
163
|
+
"inputs": [],
|
|
164
|
+
"name": "assetInSwapOperator",
|
|
165
|
+
"outputs": [
|
|
166
|
+
{
|
|
167
|
+
"internalType": "uint256",
|
|
168
|
+
"name": "",
|
|
169
|
+
"type": "uint256"
|
|
170
|
+
}
|
|
171
|
+
],
|
|
172
|
+
"stateMutability": "view",
|
|
173
|
+
"type": "function"
|
|
174
|
+
},
|
|
136
175
|
{
|
|
137
176
|
"inputs": [
|
|
138
177
|
{
|
|
@@ -162,6 +201,19 @@
|
|
|
162
201
|
"stateMutability": "view",
|
|
163
202
|
"type": "function"
|
|
164
203
|
},
|
|
204
|
+
{
|
|
205
|
+
"inputs": [],
|
|
206
|
+
"name": "assetsInSwapOperatorBitmap",
|
|
207
|
+
"outputs": [
|
|
208
|
+
{
|
|
209
|
+
"internalType": "uint32",
|
|
210
|
+
"name": "",
|
|
211
|
+
"type": "uint32"
|
|
212
|
+
}
|
|
213
|
+
],
|
|
214
|
+
"stateMutability": "view",
|
|
215
|
+
"type": "function"
|
|
216
|
+
},
|
|
165
217
|
{
|
|
166
218
|
"inputs": [
|
|
167
219
|
{
|
|
@@ -242,6 +294,25 @@
|
|
|
242
294
|
"stateMutability": "view",
|
|
243
295
|
"type": "function"
|
|
244
296
|
},
|
|
297
|
+
{
|
|
298
|
+
"inputs": [
|
|
299
|
+
{
|
|
300
|
+
"internalType": "address",
|
|
301
|
+
"name": "assetAddress",
|
|
302
|
+
"type": "address"
|
|
303
|
+
}
|
|
304
|
+
],
|
|
305
|
+
"name": "getAssetId",
|
|
306
|
+
"outputs": [
|
|
307
|
+
{
|
|
308
|
+
"internalType": "uint256",
|
|
309
|
+
"name": "",
|
|
310
|
+
"type": "uint256"
|
|
311
|
+
}
|
|
312
|
+
],
|
|
313
|
+
"stateMutability": "view",
|
|
314
|
+
"type": "function"
|
|
315
|
+
},
|
|
245
316
|
{
|
|
246
317
|
"inputs": [
|
|
247
318
|
{
|
|
@@ -517,6 +588,24 @@
|
|
|
517
588
|
"stateMutability": "nonpayable",
|
|
518
589
|
"type": "function"
|
|
519
590
|
},
|
|
591
|
+
{
|
|
592
|
+
"inputs": [
|
|
593
|
+
{
|
|
594
|
+
"internalType": "address",
|
|
595
|
+
"name": "assetAddress",
|
|
596
|
+
"type": "address"
|
|
597
|
+
},
|
|
598
|
+
{
|
|
599
|
+
"internalType": "uint256",
|
|
600
|
+
"name": "value",
|
|
601
|
+
"type": "uint256"
|
|
602
|
+
}
|
|
603
|
+
],
|
|
604
|
+
"name": "setSwapAssetAmount",
|
|
605
|
+
"outputs": [],
|
|
606
|
+
"stateMutability": "nonpayable",
|
|
607
|
+
"type": "function"
|
|
608
|
+
},
|
|
520
609
|
{
|
|
521
610
|
"inputs": [
|
|
522
611
|
{
|
|
@@ -563,19 +652,6 @@
|
|
|
563
652
|
"stateMutability": "nonpayable",
|
|
564
653
|
"type": "function"
|
|
565
654
|
},
|
|
566
|
-
{
|
|
567
|
-
"inputs": [
|
|
568
|
-
{
|
|
569
|
-
"internalType": "uint256",
|
|
570
|
-
"name": "newValue",
|
|
571
|
-
"type": "uint256"
|
|
572
|
-
}
|
|
573
|
-
],
|
|
574
|
-
"name": "setSwapValue",
|
|
575
|
-
"outputs": [],
|
|
576
|
-
"stateMutability": "nonpayable",
|
|
577
|
-
"type": "function"
|
|
578
|
-
},
|
|
579
655
|
{
|
|
580
656
|
"inputs": [
|
|
581
657
|
{
|
|
@@ -623,19 +699,6 @@
|
|
|
623
699
|
"stateMutability": "view",
|
|
624
700
|
"type": "function"
|
|
625
701
|
},
|
|
626
|
-
{
|
|
627
|
-
"inputs": [],
|
|
628
|
-
"name": "swapValue",
|
|
629
|
-
"outputs": [
|
|
630
|
-
{
|
|
631
|
-
"internalType": "uint96",
|
|
632
|
-
"name": "",
|
|
633
|
-
"type": "uint96"
|
|
634
|
-
}
|
|
635
|
-
],
|
|
636
|
-
"stateMutability": "view",
|
|
637
|
-
"type": "function"
|
|
638
|
-
},
|
|
639
702
|
{
|
|
640
703
|
"inputs": [
|
|
641
704
|
{
|
|
@@ -11,6 +11,11 @@
|
|
|
11
11
|
"name": "_assetAggregators",
|
|
12
12
|
"type": "address[]"
|
|
13
13
|
},
|
|
14
|
+
{
|
|
15
|
+
"internalType": "enum IPriceFeedOracle.AggregatorType[]",
|
|
16
|
+
"name": "_aggregatorTypes",
|
|
17
|
+
"type": "uint8[]"
|
|
18
|
+
},
|
|
14
19
|
{
|
|
15
20
|
"internalType": "uint8[]",
|
|
16
21
|
"name": "_assetDecimals",
|
|
@@ -25,6 +30,139 @@
|
|
|
25
30
|
"stateMutability": "nonpayable",
|
|
26
31
|
"type": "constructor"
|
|
27
32
|
},
|
|
33
|
+
{
|
|
34
|
+
"inputs": [
|
|
35
|
+
{
|
|
36
|
+
"internalType": "uint256",
|
|
37
|
+
"name": "assetAddressesLength",
|
|
38
|
+
"type": "uint256"
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
"internalType": "uint256",
|
|
42
|
+
"name": "aggregatorsLength",
|
|
43
|
+
"type": "uint256"
|
|
44
|
+
},
|
|
45
|
+
{
|
|
46
|
+
"internalType": "uint256",
|
|
47
|
+
"name": "typesLength",
|
|
48
|
+
"type": "uint256"
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
"internalType": "uint256",
|
|
52
|
+
"name": "decimalsLength",
|
|
53
|
+
"type": "uint256"
|
|
54
|
+
}
|
|
55
|
+
],
|
|
56
|
+
"name": "ArgumentLengthMismatch",
|
|
57
|
+
"type": "error"
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
"inputs": [],
|
|
61
|
+
"name": "EmptyAssetAddresses",
|
|
62
|
+
"type": "error"
|
|
63
|
+
},
|
|
64
|
+
{
|
|
65
|
+
"inputs": [],
|
|
66
|
+
"name": "EthUsdAggregatorNotSet",
|
|
67
|
+
"type": "error"
|
|
68
|
+
},
|
|
69
|
+
{
|
|
70
|
+
"inputs": [
|
|
71
|
+
{
|
|
72
|
+
"internalType": "address",
|
|
73
|
+
"name": "aggregator",
|
|
74
|
+
"type": "address"
|
|
75
|
+
},
|
|
76
|
+
{
|
|
77
|
+
"internalType": "uint8",
|
|
78
|
+
"name": "aggregatorDecimals",
|
|
79
|
+
"type": "uint8"
|
|
80
|
+
},
|
|
81
|
+
{
|
|
82
|
+
"internalType": "uint8",
|
|
83
|
+
"name": "expectedDecimals",
|
|
84
|
+
"type": "uint8"
|
|
85
|
+
}
|
|
86
|
+
],
|
|
87
|
+
"name": "IncompatibleAggregatorDecimals",
|
|
88
|
+
"type": "error"
|
|
89
|
+
},
|
|
90
|
+
{
|
|
91
|
+
"inputs": [
|
|
92
|
+
{
|
|
93
|
+
"internalType": "enum IPriceFeedOracle.AggregatorType",
|
|
94
|
+
"name": "actual",
|
|
95
|
+
"type": "uint8"
|
|
96
|
+
},
|
|
97
|
+
{
|
|
98
|
+
"internalType": "enum IPriceFeedOracle.AggregatorType",
|
|
99
|
+
"name": "expected",
|
|
100
|
+
"type": "uint8"
|
|
101
|
+
}
|
|
102
|
+
],
|
|
103
|
+
"name": "InvalidEthAggregatorType",
|
|
104
|
+
"type": "error"
|
|
105
|
+
},
|
|
106
|
+
{
|
|
107
|
+
"inputs": [
|
|
108
|
+
{
|
|
109
|
+
"internalType": "address",
|
|
110
|
+
"name": "aggregator",
|
|
111
|
+
"type": "address"
|
|
112
|
+
},
|
|
113
|
+
{
|
|
114
|
+
"internalType": "int256",
|
|
115
|
+
"name": "rate",
|
|
116
|
+
"type": "int256"
|
|
117
|
+
}
|
|
118
|
+
],
|
|
119
|
+
"name": "NonPositiveRate",
|
|
120
|
+
"type": "error"
|
|
121
|
+
},
|
|
122
|
+
{
|
|
123
|
+
"inputs": [
|
|
124
|
+
{
|
|
125
|
+
"internalType": "uint8",
|
|
126
|
+
"name": "aggregatorType",
|
|
127
|
+
"type": "uint8"
|
|
128
|
+
}
|
|
129
|
+
],
|
|
130
|
+
"name": "UnknownAggregatorType",
|
|
131
|
+
"type": "error"
|
|
132
|
+
},
|
|
133
|
+
{
|
|
134
|
+
"inputs": [
|
|
135
|
+
{
|
|
136
|
+
"internalType": "address",
|
|
137
|
+
"name": "asset",
|
|
138
|
+
"type": "address"
|
|
139
|
+
}
|
|
140
|
+
],
|
|
141
|
+
"name": "UnknownAsset",
|
|
142
|
+
"type": "error"
|
|
143
|
+
},
|
|
144
|
+
{
|
|
145
|
+
"inputs": [
|
|
146
|
+
{
|
|
147
|
+
"internalType": "string",
|
|
148
|
+
"name": "parameter",
|
|
149
|
+
"type": "string"
|
|
150
|
+
}
|
|
151
|
+
],
|
|
152
|
+
"name": "ZeroAddress",
|
|
153
|
+
"type": "error"
|
|
154
|
+
},
|
|
155
|
+
{
|
|
156
|
+
"inputs": [
|
|
157
|
+
{
|
|
158
|
+
"internalType": "address",
|
|
159
|
+
"name": "asset",
|
|
160
|
+
"type": "address"
|
|
161
|
+
}
|
|
162
|
+
],
|
|
163
|
+
"name": "ZeroDecimals",
|
|
164
|
+
"type": "error"
|
|
165
|
+
},
|
|
28
166
|
{
|
|
29
167
|
"inputs": [],
|
|
30
168
|
"name": "ETH",
|
|
@@ -42,17 +180,46 @@
|
|
|
42
180
|
"inputs": [
|
|
43
181
|
{
|
|
44
182
|
"internalType": "address",
|
|
45
|
-
"name": "",
|
|
183
|
+
"name": "assetAddress",
|
|
46
184
|
"type": "address"
|
|
47
185
|
}
|
|
48
186
|
],
|
|
49
187
|
"name": "assets",
|
|
188
|
+
"outputs": [
|
|
189
|
+
{
|
|
190
|
+
"internalType": "contract Aggregator",
|
|
191
|
+
"name": "",
|
|
192
|
+
"type": "address"
|
|
193
|
+
},
|
|
194
|
+
{
|
|
195
|
+
"internalType": "uint8",
|
|
196
|
+
"name": "",
|
|
197
|
+
"type": "uint8"
|
|
198
|
+
}
|
|
199
|
+
],
|
|
200
|
+
"stateMutability": "view",
|
|
201
|
+
"type": "function"
|
|
202
|
+
},
|
|
203
|
+
{
|
|
204
|
+
"inputs": [
|
|
205
|
+
{
|
|
206
|
+
"internalType": "address",
|
|
207
|
+
"name": "",
|
|
208
|
+
"type": "address"
|
|
209
|
+
}
|
|
210
|
+
],
|
|
211
|
+
"name": "assetsMap",
|
|
50
212
|
"outputs": [
|
|
51
213
|
{
|
|
52
214
|
"internalType": "contract Aggregator",
|
|
53
215
|
"name": "aggregator",
|
|
54
216
|
"type": "address"
|
|
55
217
|
},
|
|
218
|
+
{
|
|
219
|
+
"internalType": "enum IPriceFeedOracle.AggregatorType",
|
|
220
|
+
"name": "aggregatorType",
|
|
221
|
+
"type": "uint8"
|
|
222
|
+
},
|
|
56
223
|
{
|
|
57
224
|
"internalType": "uint8",
|
|
58
225
|
"name": "decimals",
|
package/dist/data/addresses.json
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"Assessment": "0xcafeaa5f9c401b7295890f309168Bbb8173690A3",
|
|
3
3
|
"AssessmentViewer": "0xcafeaC01F6BA70567f5EA7dD4e114f8E5FDa5bf6",
|
|
4
|
+
"cbBTC": "0xcbB7C0000aB88B473b1f5aFd9ef808440eed33Bf",
|
|
4
5
|
"Chainlink-DAI-ETH": "0x773616E4d11A78F511299002da57A0a94577F1f4",
|
|
5
6
|
"Chainlink-ENZYME-VAULT": "0xCc72039A141c6e34a779eF93AEF5eB4C82A893c7",
|
|
6
7
|
"Chainlink-ETH-USD": "0x5f4eC3Df9cbd43714FE2740f5E3616155c5b8419",
|
|
@@ -25,7 +26,7 @@
|
|
|
25
26
|
"NXMaster": "0x01BFd82675DBCc7762C84019cA518e701C0cD07e",
|
|
26
27
|
"NexusViewer": "0xcafea70070104A17f10a1E61d6BaBE30D64B7Ec2",
|
|
27
28
|
"Pool": "0xcafeaf6eA90CB931ae43a8Cf4B25a73a24cF6158",
|
|
28
|
-
"PriceFeedOracle": "
|
|
29
|
+
"PriceFeedOracle": "0xcafea905B417AC7778843aaE1A0b3848CA97a592",
|
|
29
30
|
"ProposalCategory": "0x888eA6Ab349c854936b98586CE6a17E98BF254b2",
|
|
30
31
|
"Ramm": "0xcafea54f03E1Cc036653444e581A10a43B2487CD",
|
|
31
32
|
"SafeTracker": "0xcafeaB8B01C74c2239eA9b2B0F6aB2dD409c6c13",
|
|
@@ -117,5 +117,12 @@
|
|
|
117
117
|
"name": "DeFi Pass",
|
|
118
118
|
"gracePeriod": 3024000,
|
|
119
119
|
"claimMethod": 0
|
|
120
|
+
},
|
|
121
|
+
{
|
|
122
|
+
"id": 17,
|
|
123
|
+
"coverWordingURL": "https://api.nexusmutual.io/ipfs/QmYgZNrGSAQZCGKEGdgvR132KWkLKtSDXmZVGfoGSKfYMG",
|
|
124
|
+
"name": "Follow On Cover",
|
|
125
|
+
"gracePeriod": 8640000,
|
|
126
|
+
"claimMethod": 0
|
|
120
127
|
}
|
|
121
128
|
]
|