@gearbox-protocol/sdk 3.0.0-vfour.112 → 3.0.0-vfour.113
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/cjs/sdk/index.cjs +1639 -40
- package/dist/cjs/sdk/index.d.ts +1459 -32
- package/dist/esm/sdk/index.d.mts +1459 -32
- package/dist/esm/sdk/index.mjs +1636 -41
- package/package.json +7 -7
package/dist/cjs/sdk/index.cjs
CHANGED
|
@@ -17147,6 +17147,1562 @@ var iMellowVaultAdapterAbi = [
|
|
|
17147
17147
|
]
|
|
17148
17148
|
}
|
|
17149
17149
|
];
|
|
17150
|
+
var iPendleRouterAdapterAbi = [
|
|
17151
|
+
{
|
|
17152
|
+
type: "function",
|
|
17153
|
+
name: "_gearboxAdapterType",
|
|
17154
|
+
inputs: [],
|
|
17155
|
+
outputs: [
|
|
17156
|
+
{
|
|
17157
|
+
name: "",
|
|
17158
|
+
type: "uint8",
|
|
17159
|
+
internalType: "enum AdapterType"
|
|
17160
|
+
}
|
|
17161
|
+
],
|
|
17162
|
+
stateMutability: "view"
|
|
17163
|
+
},
|
|
17164
|
+
{
|
|
17165
|
+
type: "function",
|
|
17166
|
+
name: "_gearboxAdapterVersion",
|
|
17167
|
+
inputs: [],
|
|
17168
|
+
outputs: [
|
|
17169
|
+
{
|
|
17170
|
+
name: "",
|
|
17171
|
+
type: "uint16",
|
|
17172
|
+
internalType: "uint16"
|
|
17173
|
+
}
|
|
17174
|
+
],
|
|
17175
|
+
stateMutability: "view"
|
|
17176
|
+
},
|
|
17177
|
+
{
|
|
17178
|
+
type: "function",
|
|
17179
|
+
name: "addressProvider",
|
|
17180
|
+
inputs: [],
|
|
17181
|
+
outputs: [
|
|
17182
|
+
{
|
|
17183
|
+
name: "",
|
|
17184
|
+
type: "address",
|
|
17185
|
+
internalType: "address"
|
|
17186
|
+
}
|
|
17187
|
+
],
|
|
17188
|
+
stateMutability: "view"
|
|
17189
|
+
},
|
|
17190
|
+
{
|
|
17191
|
+
type: "function",
|
|
17192
|
+
name: "creditManager",
|
|
17193
|
+
inputs: [],
|
|
17194
|
+
outputs: [
|
|
17195
|
+
{
|
|
17196
|
+
name: "",
|
|
17197
|
+
type: "address",
|
|
17198
|
+
internalType: "address"
|
|
17199
|
+
}
|
|
17200
|
+
],
|
|
17201
|
+
stateMutability: "view"
|
|
17202
|
+
},
|
|
17203
|
+
{
|
|
17204
|
+
type: "function",
|
|
17205
|
+
name: "getAllowedPairs",
|
|
17206
|
+
inputs: [],
|
|
17207
|
+
outputs: [
|
|
17208
|
+
{
|
|
17209
|
+
name: "pairs",
|
|
17210
|
+
type: "tuple[]",
|
|
17211
|
+
internalType: "struct PendlePairStatus[]",
|
|
17212
|
+
components: [
|
|
17213
|
+
{
|
|
17214
|
+
name: "market",
|
|
17215
|
+
type: "address",
|
|
17216
|
+
internalType: "address"
|
|
17217
|
+
},
|
|
17218
|
+
{
|
|
17219
|
+
name: "inputToken",
|
|
17220
|
+
type: "address",
|
|
17221
|
+
internalType: "address"
|
|
17222
|
+
},
|
|
17223
|
+
{
|
|
17224
|
+
name: "pendleToken",
|
|
17225
|
+
type: "address",
|
|
17226
|
+
internalType: "address"
|
|
17227
|
+
},
|
|
17228
|
+
{
|
|
17229
|
+
name: "status",
|
|
17230
|
+
type: "uint8",
|
|
17231
|
+
internalType: "enum PendleStatus"
|
|
17232
|
+
}
|
|
17233
|
+
]
|
|
17234
|
+
}
|
|
17235
|
+
],
|
|
17236
|
+
stateMutability: "view"
|
|
17237
|
+
},
|
|
17238
|
+
{
|
|
17239
|
+
type: "function",
|
|
17240
|
+
name: "isPairAllowed",
|
|
17241
|
+
inputs: [
|
|
17242
|
+
{
|
|
17243
|
+
name: "market",
|
|
17244
|
+
type: "address",
|
|
17245
|
+
internalType: "address"
|
|
17246
|
+
},
|
|
17247
|
+
{
|
|
17248
|
+
name: "inputToken",
|
|
17249
|
+
type: "address",
|
|
17250
|
+
internalType: "address"
|
|
17251
|
+
},
|
|
17252
|
+
{
|
|
17253
|
+
name: "pendleToken",
|
|
17254
|
+
type: "address",
|
|
17255
|
+
internalType: "address"
|
|
17256
|
+
}
|
|
17257
|
+
],
|
|
17258
|
+
outputs: [
|
|
17259
|
+
{
|
|
17260
|
+
name: "status",
|
|
17261
|
+
type: "uint8",
|
|
17262
|
+
internalType: "enum PendleStatus"
|
|
17263
|
+
}
|
|
17264
|
+
],
|
|
17265
|
+
stateMutability: "view"
|
|
17266
|
+
},
|
|
17267
|
+
{
|
|
17268
|
+
type: "function",
|
|
17269
|
+
name: "ptToMarket",
|
|
17270
|
+
inputs: [
|
|
17271
|
+
{
|
|
17272
|
+
name: "pt",
|
|
17273
|
+
type: "address",
|
|
17274
|
+
internalType: "address"
|
|
17275
|
+
}
|
|
17276
|
+
],
|
|
17277
|
+
outputs: [
|
|
17278
|
+
{
|
|
17279
|
+
name: "market",
|
|
17280
|
+
type: "address",
|
|
17281
|
+
internalType: "address"
|
|
17282
|
+
}
|
|
17283
|
+
],
|
|
17284
|
+
stateMutability: "view"
|
|
17285
|
+
},
|
|
17286
|
+
{
|
|
17287
|
+
type: "function",
|
|
17288
|
+
name: "redeemDiffPyToToken",
|
|
17289
|
+
inputs: [
|
|
17290
|
+
{
|
|
17291
|
+
name: "yt",
|
|
17292
|
+
type: "address",
|
|
17293
|
+
internalType: "address"
|
|
17294
|
+
},
|
|
17295
|
+
{
|
|
17296
|
+
name: "leftoverPt",
|
|
17297
|
+
type: "uint256",
|
|
17298
|
+
internalType: "uint256"
|
|
17299
|
+
},
|
|
17300
|
+
{
|
|
17301
|
+
name: "output",
|
|
17302
|
+
type: "tuple",
|
|
17303
|
+
internalType: "struct TokenDiffOutput",
|
|
17304
|
+
components: [
|
|
17305
|
+
{
|
|
17306
|
+
name: "tokenOut",
|
|
17307
|
+
type: "address",
|
|
17308
|
+
internalType: "address"
|
|
17309
|
+
},
|
|
17310
|
+
{
|
|
17311
|
+
name: "minRateRAY",
|
|
17312
|
+
type: "uint256",
|
|
17313
|
+
internalType: "uint256"
|
|
17314
|
+
}
|
|
17315
|
+
]
|
|
17316
|
+
}
|
|
17317
|
+
],
|
|
17318
|
+
outputs: [
|
|
17319
|
+
{
|
|
17320
|
+
name: "tokensToEnable",
|
|
17321
|
+
type: "uint256",
|
|
17322
|
+
internalType: "uint256"
|
|
17323
|
+
},
|
|
17324
|
+
{
|
|
17325
|
+
name: "tokensToDisable",
|
|
17326
|
+
type: "uint256",
|
|
17327
|
+
internalType: "uint256"
|
|
17328
|
+
}
|
|
17329
|
+
],
|
|
17330
|
+
stateMutability: "nonpayable"
|
|
17331
|
+
},
|
|
17332
|
+
{
|
|
17333
|
+
type: "function",
|
|
17334
|
+
name: "redeemPyToToken",
|
|
17335
|
+
inputs: [
|
|
17336
|
+
{
|
|
17337
|
+
name: "receiver",
|
|
17338
|
+
type: "address",
|
|
17339
|
+
internalType: "address"
|
|
17340
|
+
},
|
|
17341
|
+
{
|
|
17342
|
+
name: "yt",
|
|
17343
|
+
type: "address",
|
|
17344
|
+
internalType: "address"
|
|
17345
|
+
},
|
|
17346
|
+
{
|
|
17347
|
+
name: "netPyIn",
|
|
17348
|
+
type: "uint256",
|
|
17349
|
+
internalType: "uint256"
|
|
17350
|
+
},
|
|
17351
|
+
{
|
|
17352
|
+
name: "output",
|
|
17353
|
+
type: "tuple",
|
|
17354
|
+
internalType: "struct TokenOutput",
|
|
17355
|
+
components: [
|
|
17356
|
+
{
|
|
17357
|
+
name: "tokenOut",
|
|
17358
|
+
type: "address",
|
|
17359
|
+
internalType: "address"
|
|
17360
|
+
},
|
|
17361
|
+
{
|
|
17362
|
+
name: "minTokenOut",
|
|
17363
|
+
type: "uint256",
|
|
17364
|
+
internalType: "uint256"
|
|
17365
|
+
},
|
|
17366
|
+
{
|
|
17367
|
+
name: "tokenRedeemSy",
|
|
17368
|
+
type: "address",
|
|
17369
|
+
internalType: "address"
|
|
17370
|
+
},
|
|
17371
|
+
{
|
|
17372
|
+
name: "pendleSwap",
|
|
17373
|
+
type: "address",
|
|
17374
|
+
internalType: "address"
|
|
17375
|
+
},
|
|
17376
|
+
{
|
|
17377
|
+
name: "swapData",
|
|
17378
|
+
type: "tuple",
|
|
17379
|
+
internalType: "struct SwapData",
|
|
17380
|
+
components: [
|
|
17381
|
+
{
|
|
17382
|
+
name: "swapType",
|
|
17383
|
+
type: "uint8",
|
|
17384
|
+
internalType: "enum SwapType"
|
|
17385
|
+
},
|
|
17386
|
+
{
|
|
17387
|
+
name: "extRouter",
|
|
17388
|
+
type: "address",
|
|
17389
|
+
internalType: "address"
|
|
17390
|
+
},
|
|
17391
|
+
{
|
|
17392
|
+
name: "extCalldata",
|
|
17393
|
+
type: "bytes",
|
|
17394
|
+
internalType: "bytes"
|
|
17395
|
+
},
|
|
17396
|
+
{
|
|
17397
|
+
name: "needScale",
|
|
17398
|
+
type: "bool",
|
|
17399
|
+
internalType: "bool"
|
|
17400
|
+
}
|
|
17401
|
+
]
|
|
17402
|
+
}
|
|
17403
|
+
]
|
|
17404
|
+
}
|
|
17405
|
+
],
|
|
17406
|
+
outputs: [
|
|
17407
|
+
{
|
|
17408
|
+
name: "tokensToEnable",
|
|
17409
|
+
type: "uint256",
|
|
17410
|
+
internalType: "uint256"
|
|
17411
|
+
},
|
|
17412
|
+
{
|
|
17413
|
+
name: "tokensToDisable",
|
|
17414
|
+
type: "uint256",
|
|
17415
|
+
internalType: "uint256"
|
|
17416
|
+
}
|
|
17417
|
+
],
|
|
17418
|
+
stateMutability: "nonpayable"
|
|
17419
|
+
},
|
|
17420
|
+
{
|
|
17421
|
+
type: "function",
|
|
17422
|
+
name: "setPairStatusBatch",
|
|
17423
|
+
inputs: [
|
|
17424
|
+
{
|
|
17425
|
+
name: "pairs",
|
|
17426
|
+
type: "tuple[]",
|
|
17427
|
+
internalType: "struct PendlePairStatus[]",
|
|
17428
|
+
components: [
|
|
17429
|
+
{
|
|
17430
|
+
name: "market",
|
|
17431
|
+
type: "address",
|
|
17432
|
+
internalType: "address"
|
|
17433
|
+
},
|
|
17434
|
+
{
|
|
17435
|
+
name: "inputToken",
|
|
17436
|
+
type: "address",
|
|
17437
|
+
internalType: "address"
|
|
17438
|
+
},
|
|
17439
|
+
{
|
|
17440
|
+
name: "pendleToken",
|
|
17441
|
+
type: "address",
|
|
17442
|
+
internalType: "address"
|
|
17443
|
+
},
|
|
17444
|
+
{
|
|
17445
|
+
name: "status",
|
|
17446
|
+
type: "uint8",
|
|
17447
|
+
internalType: "enum PendleStatus"
|
|
17448
|
+
}
|
|
17449
|
+
]
|
|
17450
|
+
}
|
|
17451
|
+
],
|
|
17452
|
+
outputs: [],
|
|
17453
|
+
stateMutability: "nonpayable"
|
|
17454
|
+
},
|
|
17455
|
+
{
|
|
17456
|
+
type: "function",
|
|
17457
|
+
name: "swapDiffPtForToken",
|
|
17458
|
+
inputs: [
|
|
17459
|
+
{
|
|
17460
|
+
name: "market",
|
|
17461
|
+
type: "address",
|
|
17462
|
+
internalType: "address"
|
|
17463
|
+
},
|
|
17464
|
+
{
|
|
17465
|
+
name: "leftoverPt",
|
|
17466
|
+
type: "uint256",
|
|
17467
|
+
internalType: "uint256"
|
|
17468
|
+
},
|
|
17469
|
+
{
|
|
17470
|
+
name: "diffOutput",
|
|
17471
|
+
type: "tuple",
|
|
17472
|
+
internalType: "struct TokenDiffOutput",
|
|
17473
|
+
components: [
|
|
17474
|
+
{
|
|
17475
|
+
name: "tokenOut",
|
|
17476
|
+
type: "address",
|
|
17477
|
+
internalType: "address"
|
|
17478
|
+
},
|
|
17479
|
+
{
|
|
17480
|
+
name: "minRateRAY",
|
|
17481
|
+
type: "uint256",
|
|
17482
|
+
internalType: "uint256"
|
|
17483
|
+
}
|
|
17484
|
+
]
|
|
17485
|
+
}
|
|
17486
|
+
],
|
|
17487
|
+
outputs: [
|
|
17488
|
+
{
|
|
17489
|
+
name: "tokensToEnable",
|
|
17490
|
+
type: "uint256",
|
|
17491
|
+
internalType: "uint256"
|
|
17492
|
+
},
|
|
17493
|
+
{
|
|
17494
|
+
name: "tokensToDisable",
|
|
17495
|
+
type: "uint256",
|
|
17496
|
+
internalType: "uint256"
|
|
17497
|
+
}
|
|
17498
|
+
],
|
|
17499
|
+
stateMutability: "nonpayable"
|
|
17500
|
+
},
|
|
17501
|
+
{
|
|
17502
|
+
type: "function",
|
|
17503
|
+
name: "swapDiffTokenForPt",
|
|
17504
|
+
inputs: [
|
|
17505
|
+
{
|
|
17506
|
+
name: "market",
|
|
17507
|
+
type: "address",
|
|
17508
|
+
internalType: "address"
|
|
17509
|
+
},
|
|
17510
|
+
{
|
|
17511
|
+
name: "minRateRAY",
|
|
17512
|
+
type: "uint256",
|
|
17513
|
+
internalType: "uint256"
|
|
17514
|
+
},
|
|
17515
|
+
{
|
|
17516
|
+
name: "guessPtOut",
|
|
17517
|
+
type: "tuple",
|
|
17518
|
+
internalType: "struct ApproxParams",
|
|
17519
|
+
components: [
|
|
17520
|
+
{
|
|
17521
|
+
name: "guessMin",
|
|
17522
|
+
type: "uint256",
|
|
17523
|
+
internalType: "uint256"
|
|
17524
|
+
},
|
|
17525
|
+
{
|
|
17526
|
+
name: "guessMax",
|
|
17527
|
+
type: "uint256",
|
|
17528
|
+
internalType: "uint256"
|
|
17529
|
+
},
|
|
17530
|
+
{
|
|
17531
|
+
name: "guessOffchain",
|
|
17532
|
+
type: "uint256",
|
|
17533
|
+
internalType: "uint256"
|
|
17534
|
+
},
|
|
17535
|
+
{
|
|
17536
|
+
name: "maxIteration",
|
|
17537
|
+
type: "uint256",
|
|
17538
|
+
internalType: "uint256"
|
|
17539
|
+
},
|
|
17540
|
+
{
|
|
17541
|
+
name: "eps",
|
|
17542
|
+
type: "uint256",
|
|
17543
|
+
internalType: "uint256"
|
|
17544
|
+
}
|
|
17545
|
+
]
|
|
17546
|
+
},
|
|
17547
|
+
{
|
|
17548
|
+
name: "diffInput",
|
|
17549
|
+
type: "tuple",
|
|
17550
|
+
internalType: "struct TokenDiffInput",
|
|
17551
|
+
components: [
|
|
17552
|
+
{
|
|
17553
|
+
name: "tokenIn",
|
|
17554
|
+
type: "address",
|
|
17555
|
+
internalType: "address"
|
|
17556
|
+
},
|
|
17557
|
+
{
|
|
17558
|
+
name: "leftoverTokenIn",
|
|
17559
|
+
type: "uint256",
|
|
17560
|
+
internalType: "uint256"
|
|
17561
|
+
}
|
|
17562
|
+
]
|
|
17563
|
+
}
|
|
17564
|
+
],
|
|
17565
|
+
outputs: [
|
|
17566
|
+
{
|
|
17567
|
+
name: "tokensToEnable",
|
|
17568
|
+
type: "uint256",
|
|
17569
|
+
internalType: "uint256"
|
|
17570
|
+
},
|
|
17571
|
+
{
|
|
17572
|
+
name: "tokensToDisable",
|
|
17573
|
+
type: "uint256",
|
|
17574
|
+
internalType: "uint256"
|
|
17575
|
+
}
|
|
17576
|
+
],
|
|
17577
|
+
stateMutability: "nonpayable"
|
|
17578
|
+
},
|
|
17579
|
+
{
|
|
17580
|
+
type: "function",
|
|
17581
|
+
name: "swapExactPtForToken",
|
|
17582
|
+
inputs: [
|
|
17583
|
+
{
|
|
17584
|
+
name: "receiver",
|
|
17585
|
+
type: "address",
|
|
17586
|
+
internalType: "address"
|
|
17587
|
+
},
|
|
17588
|
+
{
|
|
17589
|
+
name: "market",
|
|
17590
|
+
type: "address",
|
|
17591
|
+
internalType: "address"
|
|
17592
|
+
},
|
|
17593
|
+
{
|
|
17594
|
+
name: "exactPtIn",
|
|
17595
|
+
type: "uint256",
|
|
17596
|
+
internalType: "uint256"
|
|
17597
|
+
},
|
|
17598
|
+
{
|
|
17599
|
+
name: "output",
|
|
17600
|
+
type: "tuple",
|
|
17601
|
+
internalType: "struct TokenOutput",
|
|
17602
|
+
components: [
|
|
17603
|
+
{
|
|
17604
|
+
name: "tokenOut",
|
|
17605
|
+
type: "address",
|
|
17606
|
+
internalType: "address"
|
|
17607
|
+
},
|
|
17608
|
+
{
|
|
17609
|
+
name: "minTokenOut",
|
|
17610
|
+
type: "uint256",
|
|
17611
|
+
internalType: "uint256"
|
|
17612
|
+
},
|
|
17613
|
+
{
|
|
17614
|
+
name: "tokenRedeemSy",
|
|
17615
|
+
type: "address",
|
|
17616
|
+
internalType: "address"
|
|
17617
|
+
},
|
|
17618
|
+
{
|
|
17619
|
+
name: "pendleSwap",
|
|
17620
|
+
type: "address",
|
|
17621
|
+
internalType: "address"
|
|
17622
|
+
},
|
|
17623
|
+
{
|
|
17624
|
+
name: "swapData",
|
|
17625
|
+
type: "tuple",
|
|
17626
|
+
internalType: "struct SwapData",
|
|
17627
|
+
components: [
|
|
17628
|
+
{
|
|
17629
|
+
name: "swapType",
|
|
17630
|
+
type: "uint8",
|
|
17631
|
+
internalType: "enum SwapType"
|
|
17632
|
+
},
|
|
17633
|
+
{
|
|
17634
|
+
name: "extRouter",
|
|
17635
|
+
type: "address",
|
|
17636
|
+
internalType: "address"
|
|
17637
|
+
},
|
|
17638
|
+
{
|
|
17639
|
+
name: "extCalldata",
|
|
17640
|
+
type: "bytes",
|
|
17641
|
+
internalType: "bytes"
|
|
17642
|
+
},
|
|
17643
|
+
{
|
|
17644
|
+
name: "needScale",
|
|
17645
|
+
type: "bool",
|
|
17646
|
+
internalType: "bool"
|
|
17647
|
+
}
|
|
17648
|
+
]
|
|
17649
|
+
}
|
|
17650
|
+
]
|
|
17651
|
+
},
|
|
17652
|
+
{
|
|
17653
|
+
name: "limit",
|
|
17654
|
+
type: "tuple",
|
|
17655
|
+
internalType: "struct LimitOrderData",
|
|
17656
|
+
components: [
|
|
17657
|
+
{
|
|
17658
|
+
name: "limitRouter",
|
|
17659
|
+
type: "address",
|
|
17660
|
+
internalType: "address"
|
|
17661
|
+
},
|
|
17662
|
+
{
|
|
17663
|
+
name: "epsSkipMarket",
|
|
17664
|
+
type: "uint256",
|
|
17665
|
+
internalType: "uint256"
|
|
17666
|
+
},
|
|
17667
|
+
{
|
|
17668
|
+
name: "normalFills",
|
|
17669
|
+
type: "tuple[]",
|
|
17670
|
+
internalType: "struct FillOrderParams[]",
|
|
17671
|
+
components: [
|
|
17672
|
+
{
|
|
17673
|
+
name: "order",
|
|
17674
|
+
type: "tuple",
|
|
17675
|
+
internalType: "struct Order",
|
|
17676
|
+
components: [
|
|
17677
|
+
{
|
|
17678
|
+
name: "salt",
|
|
17679
|
+
type: "uint256",
|
|
17680
|
+
internalType: "uint256"
|
|
17681
|
+
},
|
|
17682
|
+
{
|
|
17683
|
+
name: "expiry",
|
|
17684
|
+
type: "uint256",
|
|
17685
|
+
internalType: "uint256"
|
|
17686
|
+
},
|
|
17687
|
+
{
|
|
17688
|
+
name: "nonce",
|
|
17689
|
+
type: "uint256",
|
|
17690
|
+
internalType: "uint256"
|
|
17691
|
+
},
|
|
17692
|
+
{
|
|
17693
|
+
name: "orderType",
|
|
17694
|
+
type: "uint8",
|
|
17695
|
+
internalType: "enum OrderType"
|
|
17696
|
+
},
|
|
17697
|
+
{
|
|
17698
|
+
name: "token",
|
|
17699
|
+
type: "address",
|
|
17700
|
+
internalType: "address"
|
|
17701
|
+
},
|
|
17702
|
+
{
|
|
17703
|
+
name: "YT",
|
|
17704
|
+
type: "address",
|
|
17705
|
+
internalType: "address"
|
|
17706
|
+
},
|
|
17707
|
+
{
|
|
17708
|
+
name: "maker",
|
|
17709
|
+
type: "address",
|
|
17710
|
+
internalType: "address"
|
|
17711
|
+
},
|
|
17712
|
+
{
|
|
17713
|
+
name: "receiver",
|
|
17714
|
+
type: "address",
|
|
17715
|
+
internalType: "address"
|
|
17716
|
+
},
|
|
17717
|
+
{
|
|
17718
|
+
name: "makingAmount",
|
|
17719
|
+
type: "uint256",
|
|
17720
|
+
internalType: "uint256"
|
|
17721
|
+
},
|
|
17722
|
+
{
|
|
17723
|
+
name: "lnImpliedRate",
|
|
17724
|
+
type: "uint256",
|
|
17725
|
+
internalType: "uint256"
|
|
17726
|
+
},
|
|
17727
|
+
{
|
|
17728
|
+
name: "failSafeRate",
|
|
17729
|
+
type: "uint256",
|
|
17730
|
+
internalType: "uint256"
|
|
17731
|
+
},
|
|
17732
|
+
{
|
|
17733
|
+
name: "permit",
|
|
17734
|
+
type: "bytes",
|
|
17735
|
+
internalType: "bytes"
|
|
17736
|
+
}
|
|
17737
|
+
]
|
|
17738
|
+
},
|
|
17739
|
+
{
|
|
17740
|
+
name: "signature",
|
|
17741
|
+
type: "bytes",
|
|
17742
|
+
internalType: "bytes"
|
|
17743
|
+
},
|
|
17744
|
+
{
|
|
17745
|
+
name: "makingAmount",
|
|
17746
|
+
type: "uint256",
|
|
17747
|
+
internalType: "uint256"
|
|
17748
|
+
}
|
|
17749
|
+
]
|
|
17750
|
+
},
|
|
17751
|
+
{
|
|
17752
|
+
name: "flashFills",
|
|
17753
|
+
type: "tuple[]",
|
|
17754
|
+
internalType: "struct FillOrderParams[]",
|
|
17755
|
+
components: [
|
|
17756
|
+
{
|
|
17757
|
+
name: "order",
|
|
17758
|
+
type: "tuple",
|
|
17759
|
+
internalType: "struct Order",
|
|
17760
|
+
components: [
|
|
17761
|
+
{
|
|
17762
|
+
name: "salt",
|
|
17763
|
+
type: "uint256",
|
|
17764
|
+
internalType: "uint256"
|
|
17765
|
+
},
|
|
17766
|
+
{
|
|
17767
|
+
name: "expiry",
|
|
17768
|
+
type: "uint256",
|
|
17769
|
+
internalType: "uint256"
|
|
17770
|
+
},
|
|
17771
|
+
{
|
|
17772
|
+
name: "nonce",
|
|
17773
|
+
type: "uint256",
|
|
17774
|
+
internalType: "uint256"
|
|
17775
|
+
},
|
|
17776
|
+
{
|
|
17777
|
+
name: "orderType",
|
|
17778
|
+
type: "uint8",
|
|
17779
|
+
internalType: "enum OrderType"
|
|
17780
|
+
},
|
|
17781
|
+
{
|
|
17782
|
+
name: "token",
|
|
17783
|
+
type: "address",
|
|
17784
|
+
internalType: "address"
|
|
17785
|
+
},
|
|
17786
|
+
{
|
|
17787
|
+
name: "YT",
|
|
17788
|
+
type: "address",
|
|
17789
|
+
internalType: "address"
|
|
17790
|
+
},
|
|
17791
|
+
{
|
|
17792
|
+
name: "maker",
|
|
17793
|
+
type: "address",
|
|
17794
|
+
internalType: "address"
|
|
17795
|
+
},
|
|
17796
|
+
{
|
|
17797
|
+
name: "receiver",
|
|
17798
|
+
type: "address",
|
|
17799
|
+
internalType: "address"
|
|
17800
|
+
},
|
|
17801
|
+
{
|
|
17802
|
+
name: "makingAmount",
|
|
17803
|
+
type: "uint256",
|
|
17804
|
+
internalType: "uint256"
|
|
17805
|
+
},
|
|
17806
|
+
{
|
|
17807
|
+
name: "lnImpliedRate",
|
|
17808
|
+
type: "uint256",
|
|
17809
|
+
internalType: "uint256"
|
|
17810
|
+
},
|
|
17811
|
+
{
|
|
17812
|
+
name: "failSafeRate",
|
|
17813
|
+
type: "uint256",
|
|
17814
|
+
internalType: "uint256"
|
|
17815
|
+
},
|
|
17816
|
+
{
|
|
17817
|
+
name: "permit",
|
|
17818
|
+
type: "bytes",
|
|
17819
|
+
internalType: "bytes"
|
|
17820
|
+
}
|
|
17821
|
+
]
|
|
17822
|
+
},
|
|
17823
|
+
{
|
|
17824
|
+
name: "signature",
|
|
17825
|
+
type: "bytes",
|
|
17826
|
+
internalType: "bytes"
|
|
17827
|
+
},
|
|
17828
|
+
{
|
|
17829
|
+
name: "makingAmount",
|
|
17830
|
+
type: "uint256",
|
|
17831
|
+
internalType: "uint256"
|
|
17832
|
+
}
|
|
17833
|
+
]
|
|
17834
|
+
},
|
|
17835
|
+
{
|
|
17836
|
+
name: "optData",
|
|
17837
|
+
type: "bytes",
|
|
17838
|
+
internalType: "bytes"
|
|
17839
|
+
}
|
|
17840
|
+
]
|
|
17841
|
+
}
|
|
17842
|
+
],
|
|
17843
|
+
outputs: [
|
|
17844
|
+
{
|
|
17845
|
+
name: "tokensToEnable",
|
|
17846
|
+
type: "uint256",
|
|
17847
|
+
internalType: "uint256"
|
|
17848
|
+
},
|
|
17849
|
+
{
|
|
17850
|
+
name: "tokensToDisable",
|
|
17851
|
+
type: "uint256",
|
|
17852
|
+
internalType: "uint256"
|
|
17853
|
+
}
|
|
17854
|
+
],
|
|
17855
|
+
stateMutability: "nonpayable"
|
|
17856
|
+
},
|
|
17857
|
+
{
|
|
17858
|
+
type: "function",
|
|
17859
|
+
name: "swapExactTokenForPt",
|
|
17860
|
+
inputs: [
|
|
17861
|
+
{
|
|
17862
|
+
name: "receiver",
|
|
17863
|
+
type: "address",
|
|
17864
|
+
internalType: "address"
|
|
17865
|
+
},
|
|
17866
|
+
{
|
|
17867
|
+
name: "market",
|
|
17868
|
+
type: "address",
|
|
17869
|
+
internalType: "address"
|
|
17870
|
+
},
|
|
17871
|
+
{
|
|
17872
|
+
name: "minPtOut",
|
|
17873
|
+
type: "uint256",
|
|
17874
|
+
internalType: "uint256"
|
|
17875
|
+
},
|
|
17876
|
+
{
|
|
17877
|
+
name: "guessPtOut",
|
|
17878
|
+
type: "tuple",
|
|
17879
|
+
internalType: "struct ApproxParams",
|
|
17880
|
+
components: [
|
|
17881
|
+
{
|
|
17882
|
+
name: "guessMin",
|
|
17883
|
+
type: "uint256",
|
|
17884
|
+
internalType: "uint256"
|
|
17885
|
+
},
|
|
17886
|
+
{
|
|
17887
|
+
name: "guessMax",
|
|
17888
|
+
type: "uint256",
|
|
17889
|
+
internalType: "uint256"
|
|
17890
|
+
},
|
|
17891
|
+
{
|
|
17892
|
+
name: "guessOffchain",
|
|
17893
|
+
type: "uint256",
|
|
17894
|
+
internalType: "uint256"
|
|
17895
|
+
},
|
|
17896
|
+
{
|
|
17897
|
+
name: "maxIteration",
|
|
17898
|
+
type: "uint256",
|
|
17899
|
+
internalType: "uint256"
|
|
17900
|
+
},
|
|
17901
|
+
{
|
|
17902
|
+
name: "eps",
|
|
17903
|
+
type: "uint256",
|
|
17904
|
+
internalType: "uint256"
|
|
17905
|
+
}
|
|
17906
|
+
]
|
|
17907
|
+
},
|
|
17908
|
+
{
|
|
17909
|
+
name: "input",
|
|
17910
|
+
type: "tuple",
|
|
17911
|
+
internalType: "struct TokenInput",
|
|
17912
|
+
components: [
|
|
17913
|
+
{
|
|
17914
|
+
name: "tokenIn",
|
|
17915
|
+
type: "address",
|
|
17916
|
+
internalType: "address"
|
|
17917
|
+
},
|
|
17918
|
+
{
|
|
17919
|
+
name: "netTokenIn",
|
|
17920
|
+
type: "uint256",
|
|
17921
|
+
internalType: "uint256"
|
|
17922
|
+
},
|
|
17923
|
+
{
|
|
17924
|
+
name: "tokenMintSy",
|
|
17925
|
+
type: "address",
|
|
17926
|
+
internalType: "address"
|
|
17927
|
+
},
|
|
17928
|
+
{
|
|
17929
|
+
name: "pendleSwap",
|
|
17930
|
+
type: "address",
|
|
17931
|
+
internalType: "address"
|
|
17932
|
+
},
|
|
17933
|
+
{
|
|
17934
|
+
name: "swapData",
|
|
17935
|
+
type: "tuple",
|
|
17936
|
+
internalType: "struct SwapData",
|
|
17937
|
+
components: [
|
|
17938
|
+
{
|
|
17939
|
+
name: "swapType",
|
|
17940
|
+
type: "uint8",
|
|
17941
|
+
internalType: "enum SwapType"
|
|
17942
|
+
},
|
|
17943
|
+
{
|
|
17944
|
+
name: "extRouter",
|
|
17945
|
+
type: "address",
|
|
17946
|
+
internalType: "address"
|
|
17947
|
+
},
|
|
17948
|
+
{
|
|
17949
|
+
name: "extCalldata",
|
|
17950
|
+
type: "bytes",
|
|
17951
|
+
internalType: "bytes"
|
|
17952
|
+
},
|
|
17953
|
+
{
|
|
17954
|
+
name: "needScale",
|
|
17955
|
+
type: "bool",
|
|
17956
|
+
internalType: "bool"
|
|
17957
|
+
}
|
|
17958
|
+
]
|
|
17959
|
+
}
|
|
17960
|
+
]
|
|
17961
|
+
},
|
|
17962
|
+
{
|
|
17963
|
+
name: "limit",
|
|
17964
|
+
type: "tuple",
|
|
17965
|
+
internalType: "struct LimitOrderData",
|
|
17966
|
+
components: [
|
|
17967
|
+
{
|
|
17968
|
+
name: "limitRouter",
|
|
17969
|
+
type: "address",
|
|
17970
|
+
internalType: "address"
|
|
17971
|
+
},
|
|
17972
|
+
{
|
|
17973
|
+
name: "epsSkipMarket",
|
|
17974
|
+
type: "uint256",
|
|
17975
|
+
internalType: "uint256"
|
|
17976
|
+
},
|
|
17977
|
+
{
|
|
17978
|
+
name: "normalFills",
|
|
17979
|
+
type: "tuple[]",
|
|
17980
|
+
internalType: "struct FillOrderParams[]",
|
|
17981
|
+
components: [
|
|
17982
|
+
{
|
|
17983
|
+
name: "order",
|
|
17984
|
+
type: "tuple",
|
|
17985
|
+
internalType: "struct Order",
|
|
17986
|
+
components: [
|
|
17987
|
+
{
|
|
17988
|
+
name: "salt",
|
|
17989
|
+
type: "uint256",
|
|
17990
|
+
internalType: "uint256"
|
|
17991
|
+
},
|
|
17992
|
+
{
|
|
17993
|
+
name: "expiry",
|
|
17994
|
+
type: "uint256",
|
|
17995
|
+
internalType: "uint256"
|
|
17996
|
+
},
|
|
17997
|
+
{
|
|
17998
|
+
name: "nonce",
|
|
17999
|
+
type: "uint256",
|
|
18000
|
+
internalType: "uint256"
|
|
18001
|
+
},
|
|
18002
|
+
{
|
|
18003
|
+
name: "orderType",
|
|
18004
|
+
type: "uint8",
|
|
18005
|
+
internalType: "enum OrderType"
|
|
18006
|
+
},
|
|
18007
|
+
{
|
|
18008
|
+
name: "token",
|
|
18009
|
+
type: "address",
|
|
18010
|
+
internalType: "address"
|
|
18011
|
+
},
|
|
18012
|
+
{
|
|
18013
|
+
name: "YT",
|
|
18014
|
+
type: "address",
|
|
18015
|
+
internalType: "address"
|
|
18016
|
+
},
|
|
18017
|
+
{
|
|
18018
|
+
name: "maker",
|
|
18019
|
+
type: "address",
|
|
18020
|
+
internalType: "address"
|
|
18021
|
+
},
|
|
18022
|
+
{
|
|
18023
|
+
name: "receiver",
|
|
18024
|
+
type: "address",
|
|
18025
|
+
internalType: "address"
|
|
18026
|
+
},
|
|
18027
|
+
{
|
|
18028
|
+
name: "makingAmount",
|
|
18029
|
+
type: "uint256",
|
|
18030
|
+
internalType: "uint256"
|
|
18031
|
+
},
|
|
18032
|
+
{
|
|
18033
|
+
name: "lnImpliedRate",
|
|
18034
|
+
type: "uint256",
|
|
18035
|
+
internalType: "uint256"
|
|
18036
|
+
},
|
|
18037
|
+
{
|
|
18038
|
+
name: "failSafeRate",
|
|
18039
|
+
type: "uint256",
|
|
18040
|
+
internalType: "uint256"
|
|
18041
|
+
},
|
|
18042
|
+
{
|
|
18043
|
+
name: "permit",
|
|
18044
|
+
type: "bytes",
|
|
18045
|
+
internalType: "bytes"
|
|
18046
|
+
}
|
|
18047
|
+
]
|
|
18048
|
+
},
|
|
18049
|
+
{
|
|
18050
|
+
name: "signature",
|
|
18051
|
+
type: "bytes",
|
|
18052
|
+
internalType: "bytes"
|
|
18053
|
+
},
|
|
18054
|
+
{
|
|
18055
|
+
name: "makingAmount",
|
|
18056
|
+
type: "uint256",
|
|
18057
|
+
internalType: "uint256"
|
|
18058
|
+
}
|
|
18059
|
+
]
|
|
18060
|
+
},
|
|
18061
|
+
{
|
|
18062
|
+
name: "flashFills",
|
|
18063
|
+
type: "tuple[]",
|
|
18064
|
+
internalType: "struct FillOrderParams[]",
|
|
18065
|
+
components: [
|
|
18066
|
+
{
|
|
18067
|
+
name: "order",
|
|
18068
|
+
type: "tuple",
|
|
18069
|
+
internalType: "struct Order",
|
|
18070
|
+
components: [
|
|
18071
|
+
{
|
|
18072
|
+
name: "salt",
|
|
18073
|
+
type: "uint256",
|
|
18074
|
+
internalType: "uint256"
|
|
18075
|
+
},
|
|
18076
|
+
{
|
|
18077
|
+
name: "expiry",
|
|
18078
|
+
type: "uint256",
|
|
18079
|
+
internalType: "uint256"
|
|
18080
|
+
},
|
|
18081
|
+
{
|
|
18082
|
+
name: "nonce",
|
|
18083
|
+
type: "uint256",
|
|
18084
|
+
internalType: "uint256"
|
|
18085
|
+
},
|
|
18086
|
+
{
|
|
18087
|
+
name: "orderType",
|
|
18088
|
+
type: "uint8",
|
|
18089
|
+
internalType: "enum OrderType"
|
|
18090
|
+
},
|
|
18091
|
+
{
|
|
18092
|
+
name: "token",
|
|
18093
|
+
type: "address",
|
|
18094
|
+
internalType: "address"
|
|
18095
|
+
},
|
|
18096
|
+
{
|
|
18097
|
+
name: "YT",
|
|
18098
|
+
type: "address",
|
|
18099
|
+
internalType: "address"
|
|
18100
|
+
},
|
|
18101
|
+
{
|
|
18102
|
+
name: "maker",
|
|
18103
|
+
type: "address",
|
|
18104
|
+
internalType: "address"
|
|
18105
|
+
},
|
|
18106
|
+
{
|
|
18107
|
+
name: "receiver",
|
|
18108
|
+
type: "address",
|
|
18109
|
+
internalType: "address"
|
|
18110
|
+
},
|
|
18111
|
+
{
|
|
18112
|
+
name: "makingAmount",
|
|
18113
|
+
type: "uint256",
|
|
18114
|
+
internalType: "uint256"
|
|
18115
|
+
},
|
|
18116
|
+
{
|
|
18117
|
+
name: "lnImpliedRate",
|
|
18118
|
+
type: "uint256",
|
|
18119
|
+
internalType: "uint256"
|
|
18120
|
+
},
|
|
18121
|
+
{
|
|
18122
|
+
name: "failSafeRate",
|
|
18123
|
+
type: "uint256",
|
|
18124
|
+
internalType: "uint256"
|
|
18125
|
+
},
|
|
18126
|
+
{
|
|
18127
|
+
name: "permit",
|
|
18128
|
+
type: "bytes",
|
|
18129
|
+
internalType: "bytes"
|
|
18130
|
+
}
|
|
18131
|
+
]
|
|
18132
|
+
},
|
|
18133
|
+
{
|
|
18134
|
+
name: "signature",
|
|
18135
|
+
type: "bytes",
|
|
18136
|
+
internalType: "bytes"
|
|
18137
|
+
},
|
|
18138
|
+
{
|
|
18139
|
+
name: "makingAmount",
|
|
18140
|
+
type: "uint256",
|
|
18141
|
+
internalType: "uint256"
|
|
18142
|
+
}
|
|
18143
|
+
]
|
|
18144
|
+
},
|
|
18145
|
+
{
|
|
18146
|
+
name: "optData",
|
|
18147
|
+
type: "bytes",
|
|
18148
|
+
internalType: "bytes"
|
|
18149
|
+
}
|
|
18150
|
+
]
|
|
18151
|
+
}
|
|
18152
|
+
],
|
|
18153
|
+
outputs: [
|
|
18154
|
+
{
|
|
18155
|
+
name: "tokensToEnable",
|
|
18156
|
+
type: "uint256",
|
|
18157
|
+
internalType: "uint256"
|
|
18158
|
+
},
|
|
18159
|
+
{
|
|
18160
|
+
name: "tokensToDisable",
|
|
18161
|
+
type: "uint256",
|
|
18162
|
+
internalType: "uint256"
|
|
18163
|
+
}
|
|
18164
|
+
],
|
|
18165
|
+
stateMutability: "nonpayable"
|
|
18166
|
+
},
|
|
18167
|
+
{
|
|
18168
|
+
type: "function",
|
|
18169
|
+
name: "targetContract",
|
|
18170
|
+
inputs: [],
|
|
18171
|
+
outputs: [
|
|
18172
|
+
{
|
|
18173
|
+
name: "",
|
|
18174
|
+
type: "address",
|
|
18175
|
+
internalType: "address"
|
|
18176
|
+
}
|
|
18177
|
+
],
|
|
18178
|
+
stateMutability: "view"
|
|
18179
|
+
},
|
|
18180
|
+
{
|
|
18181
|
+
type: "event",
|
|
18182
|
+
name: "SetPairStatus",
|
|
18183
|
+
inputs: [
|
|
18184
|
+
{
|
|
18185
|
+
name: "market",
|
|
18186
|
+
type: "address",
|
|
18187
|
+
indexed: true,
|
|
18188
|
+
internalType: "address"
|
|
18189
|
+
},
|
|
18190
|
+
{
|
|
18191
|
+
name: "inputToken",
|
|
18192
|
+
type: "address",
|
|
18193
|
+
indexed: true,
|
|
18194
|
+
internalType: "address"
|
|
18195
|
+
},
|
|
18196
|
+
{
|
|
18197
|
+
name: "pendleToken",
|
|
18198
|
+
type: "address",
|
|
18199
|
+
indexed: true,
|
|
18200
|
+
internalType: "address"
|
|
18201
|
+
},
|
|
18202
|
+
{
|
|
18203
|
+
name: "allowed",
|
|
18204
|
+
type: "uint8",
|
|
18205
|
+
indexed: false,
|
|
18206
|
+
internalType: "enum PendleStatus"
|
|
18207
|
+
}
|
|
18208
|
+
],
|
|
18209
|
+
anonymous: false
|
|
18210
|
+
},
|
|
18211
|
+
{
|
|
18212
|
+
type: "error",
|
|
18213
|
+
name: "PairNotAllowedException",
|
|
18214
|
+
inputs: []
|
|
18215
|
+
},
|
|
18216
|
+
{
|
|
18217
|
+
type: "error",
|
|
18218
|
+
name: "RedemptionNotAllowedException",
|
|
18219
|
+
inputs: []
|
|
18220
|
+
}
|
|
18221
|
+
];
|
|
18222
|
+
var iDaiUsdsAdapterAbi = [
|
|
18223
|
+
{
|
|
18224
|
+
type: "function",
|
|
18225
|
+
name: "_gearboxAdapterType",
|
|
18226
|
+
inputs: [],
|
|
18227
|
+
outputs: [
|
|
18228
|
+
{
|
|
18229
|
+
name: "",
|
|
18230
|
+
type: "uint8",
|
|
18231
|
+
internalType: "enum AdapterType"
|
|
18232
|
+
}
|
|
18233
|
+
],
|
|
18234
|
+
stateMutability: "view"
|
|
18235
|
+
},
|
|
18236
|
+
{
|
|
18237
|
+
type: "function",
|
|
18238
|
+
name: "_gearboxAdapterVersion",
|
|
18239
|
+
inputs: [],
|
|
18240
|
+
outputs: [
|
|
18241
|
+
{
|
|
18242
|
+
name: "",
|
|
18243
|
+
type: "uint16",
|
|
18244
|
+
internalType: "uint16"
|
|
18245
|
+
}
|
|
18246
|
+
],
|
|
18247
|
+
stateMutability: "view"
|
|
18248
|
+
},
|
|
18249
|
+
{
|
|
18250
|
+
type: "function",
|
|
18251
|
+
name: "addressProvider",
|
|
18252
|
+
inputs: [],
|
|
18253
|
+
outputs: [
|
|
18254
|
+
{
|
|
18255
|
+
name: "",
|
|
18256
|
+
type: "address",
|
|
18257
|
+
internalType: "address"
|
|
18258
|
+
}
|
|
18259
|
+
],
|
|
18260
|
+
stateMutability: "view"
|
|
18261
|
+
},
|
|
18262
|
+
{
|
|
18263
|
+
type: "function",
|
|
18264
|
+
name: "creditManager",
|
|
18265
|
+
inputs: [],
|
|
18266
|
+
outputs: [
|
|
18267
|
+
{
|
|
18268
|
+
name: "",
|
|
18269
|
+
type: "address",
|
|
18270
|
+
internalType: "address"
|
|
18271
|
+
}
|
|
18272
|
+
],
|
|
18273
|
+
stateMutability: "view"
|
|
18274
|
+
},
|
|
18275
|
+
{
|
|
18276
|
+
type: "function",
|
|
18277
|
+
name: "dai",
|
|
18278
|
+
inputs: [],
|
|
18279
|
+
outputs: [
|
|
18280
|
+
{
|
|
18281
|
+
name: "",
|
|
18282
|
+
type: "address",
|
|
18283
|
+
internalType: "address"
|
|
18284
|
+
}
|
|
18285
|
+
],
|
|
18286
|
+
stateMutability: "view"
|
|
18287
|
+
},
|
|
18288
|
+
{
|
|
18289
|
+
type: "function",
|
|
18290
|
+
name: "daiMask",
|
|
18291
|
+
inputs: [],
|
|
18292
|
+
outputs: [
|
|
18293
|
+
{
|
|
18294
|
+
name: "",
|
|
18295
|
+
type: "uint256",
|
|
18296
|
+
internalType: "uint256"
|
|
18297
|
+
}
|
|
18298
|
+
],
|
|
18299
|
+
stateMutability: "view"
|
|
18300
|
+
},
|
|
18301
|
+
{
|
|
18302
|
+
type: "function",
|
|
18303
|
+
name: "daiToUsds",
|
|
18304
|
+
inputs: [
|
|
18305
|
+
{
|
|
18306
|
+
name: "usr",
|
|
18307
|
+
type: "address",
|
|
18308
|
+
internalType: "address"
|
|
18309
|
+
},
|
|
18310
|
+
{
|
|
18311
|
+
name: "wad",
|
|
18312
|
+
type: "uint256",
|
|
18313
|
+
internalType: "uint256"
|
|
18314
|
+
}
|
|
18315
|
+
],
|
|
18316
|
+
outputs: [
|
|
18317
|
+
{
|
|
18318
|
+
name: "tokensToEnable",
|
|
18319
|
+
type: "uint256",
|
|
18320
|
+
internalType: "uint256"
|
|
18321
|
+
},
|
|
18322
|
+
{
|
|
18323
|
+
name: "tokensToDisable",
|
|
18324
|
+
type: "uint256",
|
|
18325
|
+
internalType: "uint256"
|
|
18326
|
+
}
|
|
18327
|
+
],
|
|
18328
|
+
stateMutability: "nonpayable"
|
|
18329
|
+
},
|
|
18330
|
+
{
|
|
18331
|
+
type: "function",
|
|
18332
|
+
name: "daiToUsdsDiff",
|
|
18333
|
+
inputs: [
|
|
18334
|
+
{
|
|
18335
|
+
name: "leftoverAmount",
|
|
18336
|
+
type: "uint256",
|
|
18337
|
+
internalType: "uint256"
|
|
18338
|
+
}
|
|
18339
|
+
],
|
|
18340
|
+
outputs: [
|
|
18341
|
+
{
|
|
18342
|
+
name: "tokensToEnable",
|
|
18343
|
+
type: "uint256",
|
|
18344
|
+
internalType: "uint256"
|
|
18345
|
+
},
|
|
18346
|
+
{
|
|
18347
|
+
name: "tokensToDisable",
|
|
18348
|
+
type: "uint256",
|
|
18349
|
+
internalType: "uint256"
|
|
18350
|
+
}
|
|
18351
|
+
],
|
|
18352
|
+
stateMutability: "nonpayable"
|
|
18353
|
+
},
|
|
18354
|
+
{
|
|
18355
|
+
type: "function",
|
|
18356
|
+
name: "targetContract",
|
|
18357
|
+
inputs: [],
|
|
18358
|
+
outputs: [
|
|
18359
|
+
{
|
|
18360
|
+
name: "",
|
|
18361
|
+
type: "address",
|
|
18362
|
+
internalType: "address"
|
|
18363
|
+
}
|
|
18364
|
+
],
|
|
18365
|
+
stateMutability: "view"
|
|
18366
|
+
},
|
|
18367
|
+
{
|
|
18368
|
+
type: "function",
|
|
18369
|
+
name: "usds",
|
|
18370
|
+
inputs: [],
|
|
18371
|
+
outputs: [
|
|
18372
|
+
{
|
|
18373
|
+
name: "",
|
|
18374
|
+
type: "address",
|
|
18375
|
+
internalType: "address"
|
|
18376
|
+
}
|
|
18377
|
+
],
|
|
18378
|
+
stateMutability: "view"
|
|
18379
|
+
},
|
|
18380
|
+
{
|
|
18381
|
+
type: "function",
|
|
18382
|
+
name: "usdsMask",
|
|
18383
|
+
inputs: [],
|
|
18384
|
+
outputs: [
|
|
18385
|
+
{
|
|
18386
|
+
name: "",
|
|
18387
|
+
type: "uint256",
|
|
18388
|
+
internalType: "uint256"
|
|
18389
|
+
}
|
|
18390
|
+
],
|
|
18391
|
+
stateMutability: "view"
|
|
18392
|
+
},
|
|
18393
|
+
{
|
|
18394
|
+
type: "function",
|
|
18395
|
+
name: "usdsToDai",
|
|
18396
|
+
inputs: [
|
|
18397
|
+
{
|
|
18398
|
+
name: "usr",
|
|
18399
|
+
type: "address",
|
|
18400
|
+
internalType: "address"
|
|
18401
|
+
},
|
|
18402
|
+
{
|
|
18403
|
+
name: "wad",
|
|
18404
|
+
type: "uint256",
|
|
18405
|
+
internalType: "uint256"
|
|
18406
|
+
}
|
|
18407
|
+
],
|
|
18408
|
+
outputs: [
|
|
18409
|
+
{
|
|
18410
|
+
name: "tokensToEnable",
|
|
18411
|
+
type: "uint256",
|
|
18412
|
+
internalType: "uint256"
|
|
18413
|
+
},
|
|
18414
|
+
{
|
|
18415
|
+
name: "tokensToDisable",
|
|
18416
|
+
type: "uint256",
|
|
18417
|
+
internalType: "uint256"
|
|
18418
|
+
}
|
|
18419
|
+
],
|
|
18420
|
+
stateMutability: "nonpayable"
|
|
18421
|
+
},
|
|
18422
|
+
{
|
|
18423
|
+
type: "function",
|
|
18424
|
+
name: "usdsToDaiDiff",
|
|
18425
|
+
inputs: [
|
|
18426
|
+
{
|
|
18427
|
+
name: "leftoverAmount",
|
|
18428
|
+
type: "uint256",
|
|
18429
|
+
internalType: "uint256"
|
|
18430
|
+
}
|
|
18431
|
+
],
|
|
18432
|
+
outputs: [
|
|
18433
|
+
{
|
|
18434
|
+
name: "tokensToEnable",
|
|
18435
|
+
type: "uint256",
|
|
18436
|
+
internalType: "uint256"
|
|
18437
|
+
},
|
|
18438
|
+
{
|
|
18439
|
+
name: "tokensToDisable",
|
|
18440
|
+
type: "uint256",
|
|
18441
|
+
internalType: "uint256"
|
|
18442
|
+
}
|
|
18443
|
+
],
|
|
18444
|
+
stateMutability: "nonpayable"
|
|
18445
|
+
}
|
|
18446
|
+
];
|
|
18447
|
+
var iStakingRewardsAdapterAbi = [
|
|
18448
|
+
{
|
|
18449
|
+
type: "function",
|
|
18450
|
+
name: "_gearboxAdapterType",
|
|
18451
|
+
inputs: [],
|
|
18452
|
+
outputs: [
|
|
18453
|
+
{
|
|
18454
|
+
name: "",
|
|
18455
|
+
type: "uint8",
|
|
18456
|
+
internalType: "enum AdapterType"
|
|
18457
|
+
}
|
|
18458
|
+
],
|
|
18459
|
+
stateMutability: "view"
|
|
18460
|
+
},
|
|
18461
|
+
{
|
|
18462
|
+
type: "function",
|
|
18463
|
+
name: "_gearboxAdapterVersion",
|
|
18464
|
+
inputs: [],
|
|
18465
|
+
outputs: [
|
|
18466
|
+
{
|
|
18467
|
+
name: "",
|
|
18468
|
+
type: "uint16",
|
|
18469
|
+
internalType: "uint16"
|
|
18470
|
+
}
|
|
18471
|
+
],
|
|
18472
|
+
stateMutability: "view"
|
|
18473
|
+
},
|
|
18474
|
+
{
|
|
18475
|
+
type: "function",
|
|
18476
|
+
name: "addressProvider",
|
|
18477
|
+
inputs: [],
|
|
18478
|
+
outputs: [
|
|
18479
|
+
{
|
|
18480
|
+
name: "",
|
|
18481
|
+
type: "address",
|
|
18482
|
+
internalType: "address"
|
|
18483
|
+
}
|
|
18484
|
+
],
|
|
18485
|
+
stateMutability: "view"
|
|
18486
|
+
},
|
|
18487
|
+
{
|
|
18488
|
+
type: "function",
|
|
18489
|
+
name: "creditManager",
|
|
18490
|
+
inputs: [],
|
|
18491
|
+
outputs: [
|
|
18492
|
+
{
|
|
18493
|
+
name: "",
|
|
18494
|
+
type: "address",
|
|
18495
|
+
internalType: "address"
|
|
18496
|
+
}
|
|
18497
|
+
],
|
|
18498
|
+
stateMutability: "view"
|
|
18499
|
+
},
|
|
18500
|
+
{
|
|
18501
|
+
type: "function",
|
|
18502
|
+
name: "getReward",
|
|
18503
|
+
inputs: [],
|
|
18504
|
+
outputs: [
|
|
18505
|
+
{
|
|
18506
|
+
name: "tokensToEnable",
|
|
18507
|
+
type: "uint256",
|
|
18508
|
+
internalType: "uint256"
|
|
18509
|
+
},
|
|
18510
|
+
{
|
|
18511
|
+
name: "tokensToDisable",
|
|
18512
|
+
type: "uint256",
|
|
18513
|
+
internalType: "uint256"
|
|
18514
|
+
}
|
|
18515
|
+
],
|
|
18516
|
+
stateMutability: "nonpayable"
|
|
18517
|
+
},
|
|
18518
|
+
{
|
|
18519
|
+
type: "function",
|
|
18520
|
+
name: "rewardsToken",
|
|
18521
|
+
inputs: [],
|
|
18522
|
+
outputs: [
|
|
18523
|
+
{
|
|
18524
|
+
name: "",
|
|
18525
|
+
type: "address",
|
|
18526
|
+
internalType: "address"
|
|
18527
|
+
}
|
|
18528
|
+
],
|
|
18529
|
+
stateMutability: "view"
|
|
18530
|
+
},
|
|
18531
|
+
{
|
|
18532
|
+
type: "function",
|
|
18533
|
+
name: "rewardsTokenMask",
|
|
18534
|
+
inputs: [],
|
|
18535
|
+
outputs: [
|
|
18536
|
+
{
|
|
18537
|
+
name: "",
|
|
18538
|
+
type: "uint256",
|
|
18539
|
+
internalType: "uint256"
|
|
18540
|
+
}
|
|
18541
|
+
],
|
|
18542
|
+
stateMutability: "view"
|
|
18543
|
+
},
|
|
18544
|
+
{
|
|
18545
|
+
type: "function",
|
|
18546
|
+
name: "stake",
|
|
18547
|
+
inputs: [
|
|
18548
|
+
{
|
|
18549
|
+
name: "amount",
|
|
18550
|
+
type: "uint256",
|
|
18551
|
+
internalType: "uint256"
|
|
18552
|
+
}
|
|
18553
|
+
],
|
|
18554
|
+
outputs: [
|
|
18555
|
+
{
|
|
18556
|
+
name: "tokensToEnable",
|
|
18557
|
+
type: "uint256",
|
|
18558
|
+
internalType: "uint256"
|
|
18559
|
+
},
|
|
18560
|
+
{
|
|
18561
|
+
name: "tokensToDisable",
|
|
18562
|
+
type: "uint256",
|
|
18563
|
+
internalType: "uint256"
|
|
18564
|
+
}
|
|
18565
|
+
],
|
|
18566
|
+
stateMutability: "nonpayable"
|
|
18567
|
+
},
|
|
18568
|
+
{
|
|
18569
|
+
type: "function",
|
|
18570
|
+
name: "stakeDiff",
|
|
18571
|
+
inputs: [
|
|
18572
|
+
{
|
|
18573
|
+
name: "leftoverAmount",
|
|
18574
|
+
type: "uint256",
|
|
18575
|
+
internalType: "uint256"
|
|
18576
|
+
}
|
|
18577
|
+
],
|
|
18578
|
+
outputs: [
|
|
18579
|
+
{
|
|
18580
|
+
name: "tokensToEnable",
|
|
18581
|
+
type: "uint256",
|
|
18582
|
+
internalType: "uint256"
|
|
18583
|
+
},
|
|
18584
|
+
{
|
|
18585
|
+
name: "tokensToDisable",
|
|
18586
|
+
type: "uint256",
|
|
18587
|
+
internalType: "uint256"
|
|
18588
|
+
}
|
|
18589
|
+
],
|
|
18590
|
+
stateMutability: "nonpayable"
|
|
18591
|
+
},
|
|
18592
|
+
{
|
|
18593
|
+
type: "function",
|
|
18594
|
+
name: "stakedPhantomToken",
|
|
18595
|
+
inputs: [],
|
|
18596
|
+
outputs: [
|
|
18597
|
+
{
|
|
18598
|
+
name: "",
|
|
18599
|
+
type: "address",
|
|
18600
|
+
internalType: "address"
|
|
18601
|
+
}
|
|
18602
|
+
],
|
|
18603
|
+
stateMutability: "view"
|
|
18604
|
+
},
|
|
18605
|
+
{
|
|
18606
|
+
type: "function",
|
|
18607
|
+
name: "stakedPhantomTokenMask",
|
|
18608
|
+
inputs: [],
|
|
18609
|
+
outputs: [
|
|
18610
|
+
{
|
|
18611
|
+
name: "",
|
|
18612
|
+
type: "uint256",
|
|
18613
|
+
internalType: "uint256"
|
|
18614
|
+
}
|
|
18615
|
+
],
|
|
18616
|
+
stateMutability: "view"
|
|
18617
|
+
},
|
|
18618
|
+
{
|
|
18619
|
+
type: "function",
|
|
18620
|
+
name: "stakingToken",
|
|
18621
|
+
inputs: [],
|
|
18622
|
+
outputs: [
|
|
18623
|
+
{
|
|
18624
|
+
name: "",
|
|
18625
|
+
type: "address",
|
|
18626
|
+
internalType: "address"
|
|
18627
|
+
}
|
|
18628
|
+
],
|
|
18629
|
+
stateMutability: "view"
|
|
18630
|
+
},
|
|
18631
|
+
{
|
|
18632
|
+
type: "function",
|
|
18633
|
+
name: "stakingTokenMask",
|
|
18634
|
+
inputs: [],
|
|
18635
|
+
outputs: [
|
|
18636
|
+
{
|
|
18637
|
+
name: "",
|
|
18638
|
+
type: "uint256",
|
|
18639
|
+
internalType: "uint256"
|
|
18640
|
+
}
|
|
18641
|
+
],
|
|
18642
|
+
stateMutability: "view"
|
|
18643
|
+
},
|
|
18644
|
+
{
|
|
18645
|
+
type: "function",
|
|
18646
|
+
name: "targetContract",
|
|
18647
|
+
inputs: [],
|
|
18648
|
+
outputs: [
|
|
18649
|
+
{
|
|
18650
|
+
name: "",
|
|
18651
|
+
type: "address",
|
|
18652
|
+
internalType: "address"
|
|
18653
|
+
}
|
|
18654
|
+
],
|
|
18655
|
+
stateMutability: "view"
|
|
18656
|
+
},
|
|
18657
|
+
{
|
|
18658
|
+
type: "function",
|
|
18659
|
+
name: "withdraw",
|
|
18660
|
+
inputs: [
|
|
18661
|
+
{
|
|
18662
|
+
name: "amount",
|
|
18663
|
+
type: "uint256",
|
|
18664
|
+
internalType: "uint256"
|
|
18665
|
+
}
|
|
18666
|
+
],
|
|
18667
|
+
outputs: [
|
|
18668
|
+
{
|
|
18669
|
+
name: "tokensToEnable",
|
|
18670
|
+
type: "uint256",
|
|
18671
|
+
internalType: "uint256"
|
|
18672
|
+
},
|
|
18673
|
+
{
|
|
18674
|
+
name: "tokensToDisable",
|
|
18675
|
+
type: "uint256",
|
|
18676
|
+
internalType: "uint256"
|
|
18677
|
+
}
|
|
18678
|
+
],
|
|
18679
|
+
stateMutability: "nonpayable"
|
|
18680
|
+
},
|
|
18681
|
+
{
|
|
18682
|
+
type: "function",
|
|
18683
|
+
name: "withdrawDiff",
|
|
18684
|
+
inputs: [
|
|
18685
|
+
{
|
|
18686
|
+
name: "leftoverAmount",
|
|
18687
|
+
type: "uint256",
|
|
18688
|
+
internalType: "uint256"
|
|
18689
|
+
}
|
|
18690
|
+
],
|
|
18691
|
+
outputs: [
|
|
18692
|
+
{
|
|
18693
|
+
name: "tokensToEnable",
|
|
18694
|
+
type: "uint256",
|
|
18695
|
+
internalType: "uint256"
|
|
18696
|
+
},
|
|
18697
|
+
{
|
|
18698
|
+
name: "tokensToDisable",
|
|
18699
|
+
type: "uint256",
|
|
18700
|
+
internalType: "uint256"
|
|
18701
|
+
}
|
|
18702
|
+
],
|
|
18703
|
+
stateMutability: "nonpayable"
|
|
18704
|
+
}
|
|
18705
|
+
];
|
|
17150
18706
|
|
|
17151
18707
|
// src/sdk/abi/misc.ts
|
|
17152
18708
|
var ierc20MetadataAbi = [
|
|
@@ -23038,12 +24594,12 @@ var json_parse = (s) => {
|
|
|
23038
24594
|
function createRawTx(to, parameters, description) {
|
|
23039
24595
|
const { args } = parameters;
|
|
23040
24596
|
const fname = parameters.functionName;
|
|
23041
|
-
const { abi:
|
|
24597
|
+
const { abi: abi29, functionName } = (() => {
|
|
23042
24598
|
if (parameters.abi.length === 1 && parameters.functionName?.startsWith("0x"))
|
|
23043
24599
|
return parameters;
|
|
23044
24600
|
return viem.prepareEncodeFunctionData(parameters);
|
|
23045
24601
|
})();
|
|
23046
|
-
const abiItem =
|
|
24602
|
+
const abiItem = abi29[0];
|
|
23047
24603
|
const signature = functionName;
|
|
23048
24604
|
const data = "inputs" in abiItem && abiItem.inputs ? viem.encodeAbiParameters(abiItem.inputs, args ?? []) : void 0;
|
|
23049
24605
|
const functionEncodedData = viem.concatHex([signature, data ?? "0x"]);
|
|
@@ -23532,57 +25088,90 @@ var CurveV1AdapterStETHContract = class extends AbstractAdapterContract {
|
|
|
23532
25088
|
}
|
|
23533
25089
|
};
|
|
23534
25090
|
|
|
25091
|
+
// src/sdk/market/adapters/DaiUsdsAdapterContract.ts
|
|
25092
|
+
var abi10 = iDaiUsdsAdapterAbi;
|
|
25093
|
+
var DaiUsdsAdapterContract = class extends AbstractAdapterContract {
|
|
25094
|
+
constructor(sdk, args) {
|
|
25095
|
+
super(sdk, {
|
|
25096
|
+
...args,
|
|
25097
|
+
abi: abi10
|
|
25098
|
+
});
|
|
25099
|
+
}
|
|
25100
|
+
};
|
|
25101
|
+
|
|
23535
25102
|
// src/sdk/market/adapters/ERC4626AdapterContract.ts
|
|
23536
|
-
var
|
|
25103
|
+
var abi11 = erc4626AdapterAbi;
|
|
23537
25104
|
var ERC4626AdapterContract = class extends AbstractAdapterContract {
|
|
23538
25105
|
constructor(sdk, args) {
|
|
23539
25106
|
super(sdk, {
|
|
23540
25107
|
...args,
|
|
23541
|
-
abi:
|
|
25108
|
+
abi: abi11
|
|
23542
25109
|
});
|
|
23543
25110
|
}
|
|
23544
25111
|
};
|
|
23545
25112
|
|
|
23546
25113
|
// src/sdk/market/adapters/CurveV1StableNGAdapterContract.ts
|
|
23547
|
-
var
|
|
25114
|
+
var abi12 = curveV1AdapterStableNgAbi;
|
|
23548
25115
|
var CurveV1StableNGAdapterContract = class extends AbstractAdapterContract {
|
|
23549
25116
|
constructor(sdk, args) {
|
|
23550
25117
|
super(sdk, {
|
|
23551
25118
|
...args,
|
|
23552
|
-
abi:
|
|
25119
|
+
abi: abi12
|
|
23553
25120
|
});
|
|
23554
25121
|
}
|
|
23555
25122
|
};
|
|
23556
25123
|
|
|
23557
25124
|
// src/sdk/market/adapters/MellowVaultAdapterContract.ts
|
|
23558
|
-
var
|
|
25125
|
+
var abi13 = iMellowVaultAdapterAbi;
|
|
23559
25126
|
var MellowVaultAdapterContract = class extends AbstractAdapterContract {
|
|
23560
25127
|
constructor(sdk, args) {
|
|
23561
25128
|
super(sdk, {
|
|
23562
25129
|
...args,
|
|
23563
|
-
abi:
|
|
25130
|
+
abi: abi13
|
|
25131
|
+
});
|
|
25132
|
+
}
|
|
25133
|
+
};
|
|
25134
|
+
|
|
25135
|
+
// src/sdk/market/adapters/PendleRouterAdapterContract.ts
|
|
25136
|
+
var abi14 = iPendleRouterAdapterAbi;
|
|
25137
|
+
var PendleRouterAdapterContract = class extends AbstractAdapterContract {
|
|
25138
|
+
constructor(sdk, args) {
|
|
25139
|
+
super(sdk, {
|
|
25140
|
+
...args,
|
|
25141
|
+
abi: abi14
|
|
25142
|
+
});
|
|
25143
|
+
}
|
|
25144
|
+
};
|
|
25145
|
+
|
|
25146
|
+
// src/sdk/market/adapters/StakingRewardsAdapterContract.ts
|
|
25147
|
+
var abi15 = iStakingRewardsAdapterAbi;
|
|
25148
|
+
var StakingRewardsAdapterContract = class extends AbstractAdapterContract {
|
|
25149
|
+
constructor(sdk, args) {
|
|
25150
|
+
super(sdk, {
|
|
25151
|
+
...args,
|
|
25152
|
+
abi: abi15
|
|
23564
25153
|
});
|
|
23565
25154
|
}
|
|
23566
25155
|
};
|
|
23567
25156
|
|
|
23568
25157
|
// src/sdk/market/adapters/UniswapV2AdapterContract.ts
|
|
23569
|
-
var
|
|
25158
|
+
var abi16 = uniswapV2AdapterAbi;
|
|
23570
25159
|
var UniswapV2AdapterContract = class extends AbstractAdapterContract {
|
|
23571
25160
|
constructor(sdk, args) {
|
|
23572
25161
|
super(sdk, {
|
|
23573
25162
|
...args,
|
|
23574
|
-
abi:
|
|
25163
|
+
abi: abi16
|
|
23575
25164
|
});
|
|
23576
25165
|
}
|
|
23577
25166
|
};
|
|
23578
25167
|
|
|
23579
25168
|
// src/sdk/market/adapters/UniswapV3AdapterContract.ts
|
|
23580
|
-
var
|
|
25169
|
+
var abi17 = uniswapV3AdapterAbi;
|
|
23581
25170
|
var UniswapV3AdapterContract = class extends AbstractAdapterContract {
|
|
23582
25171
|
constructor(sdk, args) {
|
|
23583
25172
|
super(sdk, {
|
|
23584
25173
|
...args,
|
|
23585
|
-
abi:
|
|
25174
|
+
abi: abi17
|
|
23586
25175
|
});
|
|
23587
25176
|
}
|
|
23588
25177
|
parseFunctionParams(params) {
|
|
@@ -23703,34 +25292,34 @@ var UniswapV3AdapterContract = class extends AbstractAdapterContract {
|
|
|
23703
25292
|
};
|
|
23704
25293
|
|
|
23705
25294
|
// src/sdk/market/adapters/VelodromeV2AdapterContract.ts
|
|
23706
|
-
var
|
|
25295
|
+
var abi18 = velodromeV2RouterAdapterAbi;
|
|
23707
25296
|
var VelodromeV2RouterAdapterContract = class extends AbstractAdapterContract {
|
|
23708
25297
|
constructor(sdk, args) {
|
|
23709
25298
|
super(sdk, {
|
|
23710
25299
|
...args,
|
|
23711
|
-
abi:
|
|
25300
|
+
abi: abi18
|
|
23712
25301
|
});
|
|
23713
25302
|
}
|
|
23714
25303
|
};
|
|
23715
25304
|
|
|
23716
25305
|
// src/sdk/market/adapters/WstETHV1AdapterContract.ts
|
|
23717
|
-
var
|
|
25306
|
+
var abi19 = wstEthv1AdapterAbi;
|
|
23718
25307
|
var WstETHV1AdapterContract = class extends AbstractAdapterContract {
|
|
23719
25308
|
constructor(sdk, args) {
|
|
23720
25309
|
super(sdk, {
|
|
23721
25310
|
...args,
|
|
23722
|
-
abi:
|
|
25311
|
+
abi: abi19
|
|
23723
25312
|
});
|
|
23724
25313
|
}
|
|
23725
25314
|
};
|
|
23726
25315
|
|
|
23727
25316
|
// src/sdk/market/adapters/YearnV2AdapterContract.ts
|
|
23728
|
-
var
|
|
25317
|
+
var abi20 = yearnV2AdapterAbi;
|
|
23729
25318
|
var YearnV2RouterAdapterContract = class extends AbstractAdapterContract {
|
|
23730
25319
|
constructor(sdk, args) {
|
|
23731
25320
|
super(sdk, {
|
|
23732
25321
|
...args,
|
|
23733
|
-
abi:
|
|
25322
|
+
abi: abi20
|
|
23734
25323
|
});
|
|
23735
25324
|
}
|
|
23736
25325
|
};
|
|
@@ -23775,13 +25364,19 @@ function createAdapter(sdk, args) {
|
|
|
23775
25364
|
return new YearnV2RouterAdapterContract(sdk, args);
|
|
23776
25365
|
case "AD_MELLOW_LRT_VAULT":
|
|
23777
25366
|
return new MellowVaultAdapterContract(sdk, args);
|
|
25367
|
+
case "AD_PENDLE_ROUTER":
|
|
25368
|
+
return new PendleRouterAdapterContract(sdk, args);
|
|
25369
|
+
case "AD_DAI_USDS_EXCHANGE":
|
|
25370
|
+
return new DaiUsdsAdapterContract(sdk, args);
|
|
25371
|
+
case "AD_STAKING_REWARDS":
|
|
25372
|
+
return new StakingRewardsAdapterContract(sdk, args);
|
|
23778
25373
|
default:
|
|
23779
25374
|
throw new Error(`adapter for ${adapterType} is not implemented`);
|
|
23780
25375
|
}
|
|
23781
25376
|
}
|
|
23782
25377
|
|
|
23783
25378
|
// src/sdk/market/CreditConfiguratorV300Contract.ts
|
|
23784
|
-
var
|
|
25379
|
+
var abi21 = creditConfiguratorV3Abi;
|
|
23785
25380
|
var CreditConfiguratorV300Contract = class extends BaseContract {
|
|
23786
25381
|
adapters = [];
|
|
23787
25382
|
isPaused = false;
|
|
@@ -23789,7 +25384,7 @@ var CreditConfiguratorV300Contract = class extends BaseContract {
|
|
|
23789
25384
|
super(sdk, {
|
|
23790
25385
|
...creditConfigurator.baseParams,
|
|
23791
25386
|
name: `CreditConfigurator(${creditManager.name})`,
|
|
23792
|
-
abi:
|
|
25387
|
+
abi: abi21
|
|
23793
25388
|
});
|
|
23794
25389
|
}
|
|
23795
25390
|
processLog(log) {
|
|
@@ -23890,7 +25485,7 @@ var CreditConfiguratorV300Contract = class extends BaseContract {
|
|
|
23890
25485
|
};
|
|
23891
25486
|
|
|
23892
25487
|
// src/sdk/market/CreditConfiguratorV310Contract.ts
|
|
23893
|
-
var
|
|
25488
|
+
var abi22 = iCreditConfiguratorV310Abi;
|
|
23894
25489
|
var CreditConfiguratorV310Contract = class extends BaseContract {
|
|
23895
25490
|
adapters = [];
|
|
23896
25491
|
isPaused = false;
|
|
@@ -23898,7 +25493,7 @@ var CreditConfiguratorV310Contract = class extends BaseContract {
|
|
|
23898
25493
|
super(sdk, {
|
|
23899
25494
|
...creditConfigurator.baseParams,
|
|
23900
25495
|
name: `CreditConfigurator(${creditManager.name})`,
|
|
23901
|
-
abi:
|
|
25496
|
+
abi: abi22
|
|
23902
25497
|
});
|
|
23903
25498
|
}
|
|
23904
25499
|
processLog(log) {
|
|
@@ -23984,7 +25579,7 @@ var CreditConfiguratorV310Contract = class extends BaseContract {
|
|
|
23984
25579
|
}
|
|
23985
25580
|
}
|
|
23986
25581
|
};
|
|
23987
|
-
var
|
|
25582
|
+
var abi23 = [...creditFacadeV3Abi, ...iCreditFacadeV3MulticallAbi];
|
|
23988
25583
|
var CreditFacadeV300Contract = class extends BaseContract {
|
|
23989
25584
|
underlying;
|
|
23990
25585
|
constructor(sdk, { creditFacade, creditManager }) {
|
|
@@ -23992,7 +25587,7 @@ var CreditFacadeV300Contract = class extends BaseContract {
|
|
|
23992
25587
|
super(sdk, {
|
|
23993
25588
|
...baseParams,
|
|
23994
25589
|
name: `CreditFacadeV3(${creditManager.name})`,
|
|
23995
|
-
abi:
|
|
25590
|
+
abi: abi23
|
|
23996
25591
|
});
|
|
23997
25592
|
Object.assign(this, rest);
|
|
23998
25593
|
this.underlying = creditManager.underlying;
|
|
@@ -24121,7 +25716,7 @@ var CreditFacadeV300Contract = class extends BaseContract {
|
|
|
24121
25716
|
}
|
|
24122
25717
|
}
|
|
24123
25718
|
};
|
|
24124
|
-
var
|
|
25719
|
+
var abi24 = [...iCreditFacadeV310Abi, ...iCreditFacadeV310MulticallAbi];
|
|
24125
25720
|
var CreditFacadeV310Contract = class extends BaseContract {
|
|
24126
25721
|
underlying;
|
|
24127
25722
|
constructor(sdk, { creditFacade, creditManager }) {
|
|
@@ -24129,7 +25724,7 @@ var CreditFacadeV310Contract = class extends BaseContract {
|
|
|
24129
25724
|
super(sdk, {
|
|
24130
25725
|
...baseParams,
|
|
24131
25726
|
name: `CreditFacadeV310(${creditManager.name})`,
|
|
24132
|
-
abi:
|
|
25727
|
+
abi: abi24
|
|
24133
25728
|
});
|
|
24134
25729
|
Object.assign(this, rest);
|
|
24135
25730
|
this.underlying = creditManager.underlying;
|
|
@@ -24250,7 +25845,7 @@ var CreditFacadeV310Contract = class extends BaseContract {
|
|
|
24250
25845
|
};
|
|
24251
25846
|
|
|
24252
25847
|
// src/sdk/market/CreditManagerV300Contract.ts
|
|
24253
|
-
var
|
|
25848
|
+
var abi25 = creditManagerV3Abi;
|
|
24254
25849
|
var CreditManagerV300Contract = class extends BaseContract {
|
|
24255
25850
|
/**
|
|
24256
25851
|
* Mapping targetContract => adapter
|
|
@@ -24265,7 +25860,7 @@ var CreditManagerV300Contract = class extends BaseContract {
|
|
|
24265
25860
|
super(sdk, {
|
|
24266
25861
|
...baseParams,
|
|
24267
25862
|
name: `CreditManagerV300(${creditManager.name})`,
|
|
24268
|
-
abi:
|
|
25863
|
+
abi: abi25
|
|
24269
25864
|
});
|
|
24270
25865
|
Object.assign(this, rest);
|
|
24271
25866
|
this.liquidationThresholds = new AddressMap(
|
|
@@ -24332,7 +25927,7 @@ var CreditManagerV300Contract = class extends BaseContract {
|
|
|
24332
25927
|
};
|
|
24333
25928
|
|
|
24334
25929
|
// src/sdk/market/CreditManagerV310Contract.ts
|
|
24335
|
-
var
|
|
25930
|
+
var abi26 = iCreditManagerV310Abi;
|
|
24336
25931
|
var CreditManagerV310Contract = class extends BaseContract {
|
|
24337
25932
|
/**
|
|
24338
25933
|
* Mapping targetContract => adapter
|
|
@@ -24347,7 +25942,7 @@ var CreditManagerV310Contract = class extends BaseContract {
|
|
|
24347
25942
|
super(sdk, {
|
|
24348
25943
|
...baseParams,
|
|
24349
25944
|
name: `CreditManagerV310(${creditManager.name})`,
|
|
24350
|
-
abi:
|
|
25945
|
+
abi: abi26
|
|
24351
25946
|
});
|
|
24352
25947
|
Object.assign(this, rest);
|
|
24353
25948
|
this.liquidationThresholds = new AddressMap(
|
|
@@ -24611,7 +26206,7 @@ var LinearModelContract = class extends BaseContract {
|
|
|
24611
26206
|
};
|
|
24612
26207
|
|
|
24613
26208
|
// src/sdk/market/PoolContract.ts
|
|
24614
|
-
var
|
|
26209
|
+
var abi27 = poolV3Abi;
|
|
24615
26210
|
var PoolContract = class extends BaseContract {
|
|
24616
26211
|
creditManagerDebtParams;
|
|
24617
26212
|
constructor(sdk, data) {
|
|
@@ -24619,7 +26214,7 @@ var PoolContract = class extends BaseContract {
|
|
|
24619
26214
|
super(sdk, {
|
|
24620
26215
|
...data.baseParams,
|
|
24621
26216
|
name: `PoolV3(${data.name})`,
|
|
24622
|
-
abi:
|
|
26217
|
+
abi: abi27
|
|
24623
26218
|
});
|
|
24624
26219
|
Object.assign(this, rest);
|
|
24625
26220
|
this.creditManagerDebtParams = new AddressMap(
|
|
@@ -26120,9 +27715,9 @@ async function simulateMulticall(client, parameters) {
|
|
|
26120
27715
|
let currentChunk = 0;
|
|
26121
27716
|
let currentChunkSize = 0;
|
|
26122
27717
|
for (const contract of contracts) {
|
|
26123
|
-
const { abi:
|
|
27718
|
+
const { abi: abi29, address, args, functionName } = contract;
|
|
26124
27719
|
try {
|
|
26125
|
-
const callData = viem.encodeFunctionData({ abi:
|
|
27720
|
+
const callData = viem.encodeFunctionData({ abi: abi29, args, functionName });
|
|
26126
27721
|
currentChunkSize += (callData.length - 2) / 2;
|
|
26127
27722
|
if (
|
|
26128
27723
|
// Check if batching is enabled.
|
|
@@ -26144,7 +27739,7 @@ async function simulateMulticall(client, parameters) {
|
|
|
26144
27739
|
];
|
|
26145
27740
|
} catch (err) {
|
|
26146
27741
|
const error = viem.getContractError(err, {
|
|
26147
|
-
abi:
|
|
27742
|
+
abi: abi29,
|
|
26148
27743
|
address,
|
|
26149
27744
|
args,
|
|
26150
27745
|
docsPath: "/docs/contract/multicall",
|
|
@@ -26201,12 +27796,12 @@ async function simulateMulticall(client, parameters) {
|
|
|
26201
27796
|
for (let j = 0; j < aggregate3Result.length; j++) {
|
|
26202
27797
|
const { returnData, success } = aggregate3Result[j];
|
|
26203
27798
|
const { callData } = chunkedCalls[i][j];
|
|
26204
|
-
const { abi:
|
|
27799
|
+
const { abi: abi29, address, functionName, args } = contracts[results.length];
|
|
26205
27800
|
try {
|
|
26206
27801
|
if (callData === "0x") throw new viem.AbiDecodingZeroDataError();
|
|
26207
27802
|
if (!success) throw new viem.RawContractError({ data: returnData });
|
|
26208
27803
|
const result2 = viem.decodeFunctionResult({
|
|
26209
|
-
abi:
|
|
27804
|
+
abi: abi29,
|
|
26210
27805
|
args,
|
|
26211
27806
|
data: returnData,
|
|
26212
27807
|
functionName
|
|
@@ -26214,7 +27809,7 @@ async function simulateMulticall(client, parameters) {
|
|
|
26214
27809
|
results.push(allowFailure ? { result: result2, status: "success" } : result2);
|
|
26215
27810
|
} catch (err) {
|
|
26216
27811
|
const error = viem.getContractError(err, {
|
|
26217
|
-
abi:
|
|
27812
|
+
abi: abi29,
|
|
26218
27813
|
address,
|
|
26219
27814
|
args,
|
|
26220
27815
|
docsPath: "/docs/contract/multicall",
|
|
@@ -26231,11 +27826,11 @@ async function simulateMulticall(client, parameters) {
|
|
|
26231
27826
|
}
|
|
26232
27827
|
|
|
26233
27828
|
// src/sdk/market/MarketConfiguratorContract.ts
|
|
26234
|
-
var
|
|
27829
|
+
var abi28 = iMarketConfiguratorV310Abi;
|
|
26235
27830
|
var MarketConfiguratorContract = class extends BaseContract {
|
|
26236
27831
|
constructor(sdk, address) {
|
|
26237
27832
|
super(sdk, {
|
|
26238
|
-
abi:
|
|
27833
|
+
abi: abi28,
|
|
26239
27834
|
addr: address,
|
|
26240
27835
|
contractType: AP_MARKET_CONFIGURATOR,
|
|
26241
27836
|
version: 0
|
|
@@ -28230,6 +29825,7 @@ exports.CurveStablePriceFeedContract = CurveStablePriceFeedContract;
|
|
|
28230
29825
|
exports.CurveUSDPriceFeedContract = CurveUSDPriceFeedContract;
|
|
28231
29826
|
exports.CurveV1AdapterStETHContract = CurveV1AdapterStETHContract;
|
|
28232
29827
|
exports.CurveV1AdapterStableNGContract = CurveV1AdapterStableNGContract;
|
|
29828
|
+
exports.DaiUsdsAdapterContract = DaiUsdsAdapterContract;
|
|
28233
29829
|
exports.ERC4626AdapterContract = ERC4626AdapterContract;
|
|
28234
29830
|
exports.Erc4626PriceFeedContract = Erc4626PriceFeedContract;
|
|
28235
29831
|
exports.GaugeContract = GaugeContract;
|
|
@@ -28243,12 +29839,14 @@ exports.MIN_INT96 = MIN_INT96;
|
|
|
28243
29839
|
exports.MarketFactory = MarketFactory;
|
|
28244
29840
|
exports.MarketRegister = MarketRegister;
|
|
28245
29841
|
exports.MellowLRTPriceFeedContract = MellowLRTPriceFeedContract;
|
|
29842
|
+
exports.MellowVaultAdapterContract = MellowVaultAdapterContract;
|
|
28246
29843
|
exports.NOT_DEPLOYED = NOT_DEPLOYED;
|
|
28247
29844
|
exports.NO_VERSION = NO_VERSION;
|
|
28248
29845
|
exports.PERCENTAGE_DECIMALS = PERCENTAGE_DECIMALS;
|
|
28249
29846
|
exports.PERCENTAGE_FACTOR = PERCENTAGE_FACTOR;
|
|
28250
29847
|
exports.PRICE_DECIMALS = PRICE_DECIMALS;
|
|
28251
29848
|
exports.PRICE_DECIMALS_POW = PRICE_DECIMALS_POW;
|
|
29849
|
+
exports.PendleRouterAdapterContract = PendleRouterAdapterContract;
|
|
28252
29850
|
exports.PoolContract = PoolContract;
|
|
28253
29851
|
exports.PoolFactory = PoolFactory;
|
|
28254
29852
|
exports.PoolQuotaKeeperContract = PoolQuotaKeeperContract;
|
|
@@ -28264,6 +29862,7 @@ exports.RedstonePriceFeedContract = RedstonePriceFeedContract;
|
|
|
28264
29862
|
exports.RouterV3Contract = RouterV3Contract;
|
|
28265
29863
|
exports.SDKConstruct = SDKConstruct;
|
|
28266
29864
|
exports.SUPPORTED_CHAINS = SUPPORTED_CHAINS;
|
|
29865
|
+
exports.StakingRewardsAdapterContract = StakingRewardsAdapterContract;
|
|
28267
29866
|
exports.TIMELOCK = TIMELOCK;
|
|
28268
29867
|
exports.TokensMeta = TokensMeta;
|
|
28269
29868
|
exports.USDC = USDC;
|