@bouncetech/contracts 1.0.3 → 1.1.0
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/README.md +12 -1
- package/dist/abis/erc20-abi.d.ts +171 -0
- package/dist/abis/erc20-abi.js +131 -0
- package/dist/abis/factory-abi.d.ts +149 -0
- package/dist/abis/factory-abi.js +197 -0
- package/dist/abis/global-storage-abi.d.ts +921 -0
- package/dist/abis/global-storage-abi.js +1188 -0
- package/dist/abis/global-storage-helper-abi.d.ts +100 -0
- package/dist/abis/global-storage-helper-abi.js +131 -0
- package/dist/abis/hyperliquid-handler-abi.d.ts +113 -0
- package/dist/abis/hyperliquid-handler-abi.js +154 -0
- package/dist/abis/leveraged-token-abi.d.ts +1036 -0
- package/dist/abis/leveraged-token-abi.js +1347 -0
- package/dist/abis/leveraged-token-helper-abi.d.ts +344 -0
- package/dist/abis/leveraged-token-helper-abi.js +446 -0
- package/dist/abis/referrals-abi.d.ts +323 -0
- package/dist/abis/referrals-abi.js +425 -0
- package/dist/index.d.ts +3165 -322
- package/dist/index.js +27 -32
- package/package.json +1 -1
- package/abis/factory-abi.json +0 -194
- package/abis/global-storage-abi.json +0 -1185
- package/abis/global-storage-helper-abi.json +0 -128
- package/abis/hyperliquid-handler-abi.json +0 -151
- package/abis/leveraged-token-abi.json +0 -1344
- package/abis/leveraged-token-helper-abi.json +0 -443
- package/abis/referrals-abi.json +0 -422
- package/addresses.json +0 -9
|
@@ -1,443 +0,0 @@
|
|
|
1
|
-
[
|
|
2
|
-
{
|
|
3
|
-
"type": "constructor",
|
|
4
|
-
"inputs": [
|
|
5
|
-
{
|
|
6
|
-
"name": "globalStorage_",
|
|
7
|
-
"type": "address",
|
|
8
|
-
"internalType": "address"
|
|
9
|
-
}
|
|
10
|
-
],
|
|
11
|
-
"stateMutability": "nonpayable"
|
|
12
|
-
},
|
|
13
|
-
{
|
|
14
|
-
"type": "function",
|
|
15
|
-
"name": "getLeveragedTokenPositionData",
|
|
16
|
-
"inputs": [
|
|
17
|
-
{
|
|
18
|
-
"name": "leveragedTokenAddress_",
|
|
19
|
-
"type": "address",
|
|
20
|
-
"internalType": "address"
|
|
21
|
-
}
|
|
22
|
-
],
|
|
23
|
-
"outputs": [
|
|
24
|
-
{
|
|
25
|
-
"name": "",
|
|
26
|
-
"type": "tuple",
|
|
27
|
-
"internalType": "struct ILeveragedTokenHelper.LeveragedTokenPositionData",
|
|
28
|
-
"components": [
|
|
29
|
-
{
|
|
30
|
-
"name": "leveragedToken",
|
|
31
|
-
"type": "address",
|
|
32
|
-
"internalType": "address"
|
|
33
|
-
},
|
|
34
|
-
{
|
|
35
|
-
"name": "baseAssetContractBalance",
|
|
36
|
-
"type": "uint256",
|
|
37
|
-
"internalType": "uint256"
|
|
38
|
-
},
|
|
39
|
-
{
|
|
40
|
-
"name": "baseAssetUserCredit",
|
|
41
|
-
"type": "uint256",
|
|
42
|
-
"internalType": "uint256"
|
|
43
|
-
},
|
|
44
|
-
{
|
|
45
|
-
"name": "usdcSpotBalance",
|
|
46
|
-
"type": "uint256",
|
|
47
|
-
"internalType": "uint256"
|
|
48
|
-
},
|
|
49
|
-
{
|
|
50
|
-
"name": "usdcPerpBalance",
|
|
51
|
-
"type": "uint256",
|
|
52
|
-
"internalType": "uint256"
|
|
53
|
-
},
|
|
54
|
-
{
|
|
55
|
-
"name": "usdcMargin",
|
|
56
|
-
"type": "uint256",
|
|
57
|
-
"internalType": "uint256"
|
|
58
|
-
},
|
|
59
|
-
{
|
|
60
|
-
"name": "notionalValue",
|
|
61
|
-
"type": "uint256",
|
|
62
|
-
"internalType": "uint256"
|
|
63
|
-
},
|
|
64
|
-
{
|
|
65
|
-
"name": "effectiveLeverage",
|
|
66
|
-
"type": "uint256",
|
|
67
|
-
"internalType": "uint256"
|
|
68
|
-
},
|
|
69
|
-
{
|
|
70
|
-
"name": "targetLeverage",
|
|
71
|
-
"type": "uint256",
|
|
72
|
-
"internalType": "uint256"
|
|
73
|
-
}
|
|
74
|
-
]
|
|
75
|
-
}
|
|
76
|
-
],
|
|
77
|
-
"stateMutability": "view"
|
|
78
|
-
},
|
|
79
|
-
{
|
|
80
|
-
"type": "function",
|
|
81
|
-
"name": "getLeveragedTokens",
|
|
82
|
-
"inputs": [],
|
|
83
|
-
"outputs": [
|
|
84
|
-
{
|
|
85
|
-
"name": "",
|
|
86
|
-
"type": "tuple[]",
|
|
87
|
-
"internalType": "struct ILeveragedTokenHelper.LeveragedTokenData[]",
|
|
88
|
-
"components": [
|
|
89
|
-
{
|
|
90
|
-
"name": "leveragedToken",
|
|
91
|
-
"type": "address",
|
|
92
|
-
"internalType": "address"
|
|
93
|
-
},
|
|
94
|
-
{
|
|
95
|
-
"name": "marketId",
|
|
96
|
-
"type": "uint32",
|
|
97
|
-
"internalType": "uint32"
|
|
98
|
-
},
|
|
99
|
-
{
|
|
100
|
-
"name": "targetAsset",
|
|
101
|
-
"type": "string",
|
|
102
|
-
"internalType": "string"
|
|
103
|
-
},
|
|
104
|
-
{
|
|
105
|
-
"name": "targetLeverage",
|
|
106
|
-
"type": "uint256",
|
|
107
|
-
"internalType": "uint256"
|
|
108
|
-
},
|
|
109
|
-
{
|
|
110
|
-
"name": "isLong",
|
|
111
|
-
"type": "bool",
|
|
112
|
-
"internalType": "bool"
|
|
113
|
-
},
|
|
114
|
-
{
|
|
115
|
-
"name": "exchangeRate",
|
|
116
|
-
"type": "uint256",
|
|
117
|
-
"internalType": "uint256"
|
|
118
|
-
},
|
|
119
|
-
{
|
|
120
|
-
"name": "baseAssetBalance",
|
|
121
|
-
"type": "uint256",
|
|
122
|
-
"internalType": "uint256"
|
|
123
|
-
},
|
|
124
|
-
{
|
|
125
|
-
"name": "totalAssets",
|
|
126
|
-
"type": "uint256",
|
|
127
|
-
"internalType": "uint256"
|
|
128
|
-
},
|
|
129
|
-
{
|
|
130
|
-
"name": "userCredit",
|
|
131
|
-
"type": "uint256",
|
|
132
|
-
"internalType": "uint256"
|
|
133
|
-
},
|
|
134
|
-
{
|
|
135
|
-
"name": "credit",
|
|
136
|
-
"type": "uint256",
|
|
137
|
-
"internalType": "uint256"
|
|
138
|
-
},
|
|
139
|
-
{
|
|
140
|
-
"name": "agentData",
|
|
141
|
-
"type": "tuple[3]",
|
|
142
|
-
"internalType": "struct ILeveragedTokenHelper.AgentData[3]",
|
|
143
|
-
"components": [
|
|
144
|
-
{
|
|
145
|
-
"name": "slot",
|
|
146
|
-
"type": "uint8",
|
|
147
|
-
"internalType": "uint8"
|
|
148
|
-
},
|
|
149
|
-
{
|
|
150
|
-
"name": "agent",
|
|
151
|
-
"type": "address",
|
|
152
|
-
"internalType": "address"
|
|
153
|
-
},
|
|
154
|
-
{
|
|
155
|
-
"name": "createdAt",
|
|
156
|
-
"type": "uint256",
|
|
157
|
-
"internalType": "uint256"
|
|
158
|
-
}
|
|
159
|
-
]
|
|
160
|
-
},
|
|
161
|
-
{
|
|
162
|
-
"name": "balanceOf",
|
|
163
|
-
"type": "uint256",
|
|
164
|
-
"internalType": "uint256"
|
|
165
|
-
},
|
|
166
|
-
{
|
|
167
|
-
"name": "mintPaused",
|
|
168
|
-
"type": "bool",
|
|
169
|
-
"internalType": "bool"
|
|
170
|
-
}
|
|
171
|
-
]
|
|
172
|
-
}
|
|
173
|
-
],
|
|
174
|
-
"stateMutability": "view"
|
|
175
|
-
},
|
|
176
|
-
{
|
|
177
|
-
"type": "function",
|
|
178
|
-
"name": "getLeveragedTokens",
|
|
179
|
-
"inputs": [
|
|
180
|
-
{
|
|
181
|
-
"name": "user_",
|
|
182
|
-
"type": "address",
|
|
183
|
-
"internalType": "address"
|
|
184
|
-
},
|
|
185
|
-
{
|
|
186
|
-
"name": "onlyHeld_",
|
|
187
|
-
"type": "bool",
|
|
188
|
-
"internalType": "bool"
|
|
189
|
-
}
|
|
190
|
-
],
|
|
191
|
-
"outputs": [
|
|
192
|
-
{
|
|
193
|
-
"name": "",
|
|
194
|
-
"type": "tuple[]",
|
|
195
|
-
"internalType": "struct ILeveragedTokenHelper.LeveragedTokenData[]",
|
|
196
|
-
"components": [
|
|
197
|
-
{
|
|
198
|
-
"name": "leveragedToken",
|
|
199
|
-
"type": "address",
|
|
200
|
-
"internalType": "address"
|
|
201
|
-
},
|
|
202
|
-
{
|
|
203
|
-
"name": "marketId",
|
|
204
|
-
"type": "uint32",
|
|
205
|
-
"internalType": "uint32"
|
|
206
|
-
},
|
|
207
|
-
{
|
|
208
|
-
"name": "targetAsset",
|
|
209
|
-
"type": "string",
|
|
210
|
-
"internalType": "string"
|
|
211
|
-
},
|
|
212
|
-
{
|
|
213
|
-
"name": "targetLeverage",
|
|
214
|
-
"type": "uint256",
|
|
215
|
-
"internalType": "uint256"
|
|
216
|
-
},
|
|
217
|
-
{
|
|
218
|
-
"name": "isLong",
|
|
219
|
-
"type": "bool",
|
|
220
|
-
"internalType": "bool"
|
|
221
|
-
},
|
|
222
|
-
{
|
|
223
|
-
"name": "exchangeRate",
|
|
224
|
-
"type": "uint256",
|
|
225
|
-
"internalType": "uint256"
|
|
226
|
-
},
|
|
227
|
-
{
|
|
228
|
-
"name": "baseAssetBalance",
|
|
229
|
-
"type": "uint256",
|
|
230
|
-
"internalType": "uint256"
|
|
231
|
-
},
|
|
232
|
-
{
|
|
233
|
-
"name": "totalAssets",
|
|
234
|
-
"type": "uint256",
|
|
235
|
-
"internalType": "uint256"
|
|
236
|
-
},
|
|
237
|
-
{
|
|
238
|
-
"name": "userCredit",
|
|
239
|
-
"type": "uint256",
|
|
240
|
-
"internalType": "uint256"
|
|
241
|
-
},
|
|
242
|
-
{
|
|
243
|
-
"name": "credit",
|
|
244
|
-
"type": "uint256",
|
|
245
|
-
"internalType": "uint256"
|
|
246
|
-
},
|
|
247
|
-
{
|
|
248
|
-
"name": "agentData",
|
|
249
|
-
"type": "tuple[3]",
|
|
250
|
-
"internalType": "struct ILeveragedTokenHelper.AgentData[3]",
|
|
251
|
-
"components": [
|
|
252
|
-
{
|
|
253
|
-
"name": "slot",
|
|
254
|
-
"type": "uint8",
|
|
255
|
-
"internalType": "uint8"
|
|
256
|
-
},
|
|
257
|
-
{
|
|
258
|
-
"name": "agent",
|
|
259
|
-
"type": "address",
|
|
260
|
-
"internalType": "address"
|
|
261
|
-
},
|
|
262
|
-
{
|
|
263
|
-
"name": "createdAt",
|
|
264
|
-
"type": "uint256",
|
|
265
|
-
"internalType": "uint256"
|
|
266
|
-
}
|
|
267
|
-
]
|
|
268
|
-
},
|
|
269
|
-
{
|
|
270
|
-
"name": "balanceOf",
|
|
271
|
-
"type": "uint256",
|
|
272
|
-
"internalType": "uint256"
|
|
273
|
-
},
|
|
274
|
-
{
|
|
275
|
-
"name": "mintPaused",
|
|
276
|
-
"type": "bool",
|
|
277
|
-
"internalType": "bool"
|
|
278
|
-
}
|
|
279
|
-
]
|
|
280
|
-
}
|
|
281
|
-
],
|
|
282
|
-
"stateMutability": "view"
|
|
283
|
-
},
|
|
284
|
-
{
|
|
285
|
-
"type": "function",
|
|
286
|
-
"name": "getLeveragedTokensCoreData",
|
|
287
|
-
"inputs": [],
|
|
288
|
-
"outputs": [
|
|
289
|
-
{
|
|
290
|
-
"name": "",
|
|
291
|
-
"type": "tuple[]",
|
|
292
|
-
"internalType": "struct ILeveragedTokenHelper.LeveragedTokenCoreData[]",
|
|
293
|
-
"components": [
|
|
294
|
-
{
|
|
295
|
-
"name": "leveragedToken",
|
|
296
|
-
"type": "address",
|
|
297
|
-
"internalType": "address"
|
|
298
|
-
},
|
|
299
|
-
{
|
|
300
|
-
"name": "marketId",
|
|
301
|
-
"type": "uint32",
|
|
302
|
-
"internalType": "uint32"
|
|
303
|
-
},
|
|
304
|
-
{
|
|
305
|
-
"name": "targetAsset",
|
|
306
|
-
"type": "string",
|
|
307
|
-
"internalType": "string"
|
|
308
|
-
},
|
|
309
|
-
{
|
|
310
|
-
"name": "targetLeverage",
|
|
311
|
-
"type": "uint256",
|
|
312
|
-
"internalType": "uint256"
|
|
313
|
-
},
|
|
314
|
-
{
|
|
315
|
-
"name": "isLong",
|
|
316
|
-
"type": "bool",
|
|
317
|
-
"internalType": "bool"
|
|
318
|
-
},
|
|
319
|
-
{
|
|
320
|
-
"name": "baseAssetBalance",
|
|
321
|
-
"type": "uint256",
|
|
322
|
-
"internalType": "uint256"
|
|
323
|
-
},
|
|
324
|
-
{
|
|
325
|
-
"name": "credit",
|
|
326
|
-
"type": "uint256",
|
|
327
|
-
"internalType": "uint256"
|
|
328
|
-
},
|
|
329
|
-
{
|
|
330
|
-
"name": "agentData",
|
|
331
|
-
"type": "tuple[3]",
|
|
332
|
-
"internalType": "struct ILeveragedTokenHelper.AgentData[3]",
|
|
333
|
-
"components": [
|
|
334
|
-
{
|
|
335
|
-
"name": "slot",
|
|
336
|
-
"type": "uint8",
|
|
337
|
-
"internalType": "uint8"
|
|
338
|
-
},
|
|
339
|
-
{
|
|
340
|
-
"name": "agent",
|
|
341
|
-
"type": "address",
|
|
342
|
-
"internalType": "address"
|
|
343
|
-
},
|
|
344
|
-
{
|
|
345
|
-
"name": "createdAt",
|
|
346
|
-
"type": "uint256",
|
|
347
|
-
"internalType": "uint256"
|
|
348
|
-
}
|
|
349
|
-
]
|
|
350
|
-
},
|
|
351
|
-
{
|
|
352
|
-
"name": "mintPaused",
|
|
353
|
-
"type": "bool",
|
|
354
|
-
"internalType": "bool"
|
|
355
|
-
}
|
|
356
|
-
]
|
|
357
|
-
}
|
|
358
|
-
],
|
|
359
|
-
"stateMutability": "view"
|
|
360
|
-
},
|
|
361
|
-
{
|
|
362
|
-
"type": "function",
|
|
363
|
-
"name": "getLeveragedTokensSnapshot",
|
|
364
|
-
"inputs": [],
|
|
365
|
-
"outputs": [
|
|
366
|
-
{
|
|
367
|
-
"name": "",
|
|
368
|
-
"type": "tuple",
|
|
369
|
-
"internalType": "struct ILeveragedTokenHelper.LeveragedTokensSnapshot",
|
|
370
|
-
"components": [
|
|
371
|
-
{
|
|
372
|
-
"name": "blockNumber",
|
|
373
|
-
"type": "uint256",
|
|
374
|
-
"internalType": "uint256"
|
|
375
|
-
},
|
|
376
|
-
{
|
|
377
|
-
"name": "blockTimestamp",
|
|
378
|
-
"type": "uint256",
|
|
379
|
-
"internalType": "uint256"
|
|
380
|
-
},
|
|
381
|
-
{
|
|
382
|
-
"name": "tokens",
|
|
383
|
-
"type": "tuple[]",
|
|
384
|
-
"internalType": "struct ILeveragedTokenHelper.LeveragedTokenSnapshotData[]",
|
|
385
|
-
"components": [
|
|
386
|
-
{
|
|
387
|
-
"name": "leveragedToken",
|
|
388
|
-
"type": "address",
|
|
389
|
-
"internalType": "address"
|
|
390
|
-
},
|
|
391
|
-
{
|
|
392
|
-
"name": "exchangeRate",
|
|
393
|
-
"type": "uint256",
|
|
394
|
-
"internalType": "uint256"
|
|
395
|
-
},
|
|
396
|
-
{
|
|
397
|
-
"name": "baseAssetContractBalance",
|
|
398
|
-
"type": "uint256",
|
|
399
|
-
"internalType": "uint256"
|
|
400
|
-
},
|
|
401
|
-
{
|
|
402
|
-
"name": "baseAssetUserCredit",
|
|
403
|
-
"type": "uint256",
|
|
404
|
-
"internalType": "uint256"
|
|
405
|
-
},
|
|
406
|
-
{
|
|
407
|
-
"name": "usdcSpotBalance",
|
|
408
|
-
"type": "uint256",
|
|
409
|
-
"internalType": "uint256"
|
|
410
|
-
},
|
|
411
|
-
{
|
|
412
|
-
"name": "usdcPerpBalance",
|
|
413
|
-
"type": "uint256",
|
|
414
|
-
"internalType": "uint256"
|
|
415
|
-
},
|
|
416
|
-
{
|
|
417
|
-
"name": "usdcMargin",
|
|
418
|
-
"type": "uint256",
|
|
419
|
-
"internalType": "uint256"
|
|
420
|
-
},
|
|
421
|
-
{
|
|
422
|
-
"name": "totalAssets",
|
|
423
|
-
"type": "uint256",
|
|
424
|
-
"internalType": "uint256"
|
|
425
|
-
},
|
|
426
|
-
{
|
|
427
|
-
"name": "notionalValue",
|
|
428
|
-
"type": "uint256",
|
|
429
|
-
"internalType": "uint256"
|
|
430
|
-
}
|
|
431
|
-
]
|
|
432
|
-
}
|
|
433
|
-
]
|
|
434
|
-
}
|
|
435
|
-
],
|
|
436
|
-
"stateMutability": "view"
|
|
437
|
-
},
|
|
438
|
-
{
|
|
439
|
-
"type": "error",
|
|
440
|
-
"name": "DivisionByZero",
|
|
441
|
-
"inputs": []
|
|
442
|
-
}
|
|
443
|
-
]
|