@underscore-finance/sdk 0.0.8 → 0.2.2

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.
Files changed (83) hide show
  1. package/dist/contracts/AddyRegistry.d.ts +659 -82
  2. package/dist/contracts/AddyRegistry.d.ts.map +1 -1
  3. package/dist/contracts/AddyRegistry.js +903 -184
  4. package/dist/contracts/Agent.d.ts +223 -145
  5. package/dist/contracts/Agent.d.ts.map +1 -1
  6. package/dist/contracts/Agent.js +248 -162
  7. package/dist/contracts/AgentFactory.d.ts +335 -42
  8. package/dist/contracts/AgentFactory.d.ts.map +1 -1
  9. package/dist/contracts/AgentFactory.js +403 -42
  10. package/dist/contracts/Agent_v1.d.ts +2629 -0
  11. package/dist/contracts/Agent_v1.d.ts.map +1 -0
  12. package/dist/contracts/Agent_v1.js +3370 -0
  13. package/dist/contracts/ChainlinkFeeds.d.ts +160 -23
  14. package/dist/contracts/ChainlinkFeeds.d.ts.map +1 -1
  15. package/dist/contracts/ChainlinkFeeds.js +186 -23
  16. package/dist/contracts/LegoAaveV3.d.ts +160 -23
  17. package/dist/contracts/LegoAaveV3.d.ts.map +1 -1
  18. package/dist/contracts/LegoAaveV3.js +186 -23
  19. package/dist/contracts/LegoAeroClassic.d.ts +160 -23
  20. package/dist/contracts/LegoAeroClassic.d.ts.map +1 -1
  21. package/dist/contracts/LegoAeroClassic.js +186 -23
  22. package/dist/contracts/LegoAeroSlipstream.d.ts +160 -23
  23. package/dist/contracts/LegoAeroSlipstream.d.ts.map +1 -1
  24. package/dist/contracts/LegoAeroSlipstream.js +186 -23
  25. package/dist/contracts/LegoCompoundV3.d.ts +160 -23
  26. package/dist/contracts/LegoCompoundV3.d.ts.map +1 -1
  27. package/dist/contracts/LegoCompoundV3.js +186 -23
  28. package/dist/contracts/LegoCurve.d.ts +160 -23
  29. package/dist/contracts/LegoCurve.d.ts.map +1 -1
  30. package/dist/contracts/LegoCurve.js +186 -23
  31. package/dist/contracts/LegoEuler.d.ts +160 -23
  32. package/dist/contracts/LegoEuler.d.ts.map +1 -1
  33. package/dist/contracts/LegoEuler.js +186 -23
  34. package/dist/contracts/LegoFluid.d.ts +171 -23
  35. package/dist/contracts/LegoFluid.d.ts.map +1 -1
  36. package/dist/contracts/LegoFluid.js +200 -23
  37. package/dist/contracts/LegoHelper.js +1 -1
  38. package/dist/contracts/LegoMoonwell.d.ts +160 -23
  39. package/dist/contracts/LegoMoonwell.d.ts.map +1 -1
  40. package/dist/contracts/LegoMoonwell.js +186 -23
  41. package/dist/contracts/LegoMorpho.d.ts +160 -23
  42. package/dist/contracts/LegoMorpho.d.ts.map +1 -1
  43. package/dist/contracts/LegoMorpho.js +186 -23
  44. package/dist/contracts/LegoRegistry.d.ts +501 -96
  45. package/dist/contracts/LegoRegistry.d.ts.map +1 -1
  46. package/dist/contracts/LegoRegistry.js +686 -174
  47. package/dist/contracts/LegoSky.d.ts +160 -23
  48. package/dist/contracts/LegoSky.d.ts.map +1 -1
  49. package/dist/contracts/LegoSky.js +186 -23
  50. package/dist/contracts/LegoUniswapV2.d.ts +160 -23
  51. package/dist/contracts/LegoUniswapV2.d.ts.map +1 -1
  52. package/dist/contracts/LegoUniswapV2.js +186 -23
  53. package/dist/contracts/LegoUniswapV3.d.ts +160 -23
  54. package/dist/contracts/LegoUniswapV3.d.ts.map +1 -1
  55. package/dist/contracts/LegoUniswapV3.js +186 -23
  56. package/dist/contracts/OracleRegistry.d.ts +506 -109
  57. package/dist/contracts/OracleRegistry.d.ts.map +1 -1
  58. package/dist/contracts/OracleRegistry.js +628 -131
  59. package/dist/contracts/PriceSheets.d.ts +160 -23
  60. package/dist/contracts/PriceSheets.d.ts.map +1 -1
  61. package/dist/contracts/PriceSheets.js +186 -23
  62. package/dist/contracts/PythFeeds.d.ts +160 -23
  63. package/dist/contracts/PythFeeds.d.ts.map +1 -1
  64. package/dist/contracts/PythFeeds.js +186 -23
  65. package/dist/contracts/StorkFeeds.d.ts +160 -23
  66. package/dist/contracts/StorkFeeds.d.ts.map +1 -1
  67. package/dist/contracts/StorkFeeds.js +186 -23
  68. package/dist/contracts/UserWallet.d.ts +1956 -0
  69. package/dist/contracts/UserWallet.d.ts.map +1 -0
  70. package/dist/contracts/UserWallet.js +2551 -0
  71. package/dist/contracts/UserWalletConfig.d.ts +1466 -0
  72. package/dist/contracts/UserWalletConfig.d.ts.map +1 -0
  73. package/dist/contracts/UserWalletConfig.js +1762 -0
  74. package/dist/contracts/index.d.ts +3 -2
  75. package/dist/contracts/index.d.ts.map +1 -1
  76. package/dist/contracts/index.js +3 -2
  77. package/dist/contracts/sdk.d.ts +6 -4
  78. package/dist/contracts/sdk.d.ts.map +1 -1
  79. package/dist/contracts/sdk.js +6 -4
  80. package/dist/index.d.ts +8 -2
  81. package/dist/index.d.ts.map +1 -1
  82. package/dist/index.js +8 -2
  83. package/package.json +1 -1
@@ -0,0 +1,1762 @@
1
+ /* Autogenerated file. Do not edit manually. */
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /* @ts-nocheck */
5
+ import { singleQuery, mutate } from '@dappql/async';
6
+ export const abi = [
7
+ {
8
+ anonymous: false,
9
+ inputs: [
10
+ {
11
+ indexed: true,
12
+ name: 'agent',
13
+ type: 'address',
14
+ },
15
+ {
16
+ indexed: false,
17
+ name: 'allowedAssets',
18
+ type: 'uint256',
19
+ },
20
+ {
21
+ indexed: false,
22
+ name: 'allowedLegoIds',
23
+ type: 'uint256',
24
+ },
25
+ ],
26
+ name: 'AgentAdded',
27
+ type: 'event',
28
+ },
29
+ {
30
+ anonymous: false,
31
+ inputs: [
32
+ {
33
+ indexed: true,
34
+ name: 'agent',
35
+ type: 'address',
36
+ },
37
+ {
38
+ indexed: false,
39
+ name: 'allowedAssets',
40
+ type: 'uint256',
41
+ },
42
+ {
43
+ indexed: false,
44
+ name: 'allowedLegoIds',
45
+ type: 'uint256',
46
+ },
47
+ ],
48
+ name: 'AgentModified',
49
+ type: 'event',
50
+ },
51
+ {
52
+ anonymous: false,
53
+ inputs: [
54
+ {
55
+ indexed: true,
56
+ name: 'agent',
57
+ type: 'address',
58
+ },
59
+ {
60
+ indexed: false,
61
+ name: 'prevAllowedAssets',
62
+ type: 'uint256',
63
+ },
64
+ {
65
+ indexed: false,
66
+ name: 'prevAllowedLegoIds',
67
+ type: 'uint256',
68
+ },
69
+ ],
70
+ name: 'AgentDisabled',
71
+ type: 'event',
72
+ },
73
+ {
74
+ anonymous: false,
75
+ inputs: [
76
+ {
77
+ indexed: true,
78
+ name: 'agent',
79
+ type: 'address',
80
+ },
81
+ {
82
+ indexed: true,
83
+ name: 'legoId',
84
+ type: 'uint256',
85
+ },
86
+ ],
87
+ name: 'LegoIdAddedToAgent',
88
+ type: 'event',
89
+ },
90
+ {
91
+ anonymous: false,
92
+ inputs: [
93
+ {
94
+ indexed: true,
95
+ name: 'agent',
96
+ type: 'address',
97
+ },
98
+ {
99
+ indexed: true,
100
+ name: 'asset',
101
+ type: 'address',
102
+ },
103
+ ],
104
+ name: 'AssetAddedToAgent',
105
+ type: 'event',
106
+ },
107
+ {
108
+ anonymous: false,
109
+ inputs: [
110
+ {
111
+ indexed: true,
112
+ name: 'agent',
113
+ type: 'address',
114
+ },
115
+ {
116
+ indexed: false,
117
+ name: 'canDeposit',
118
+ type: 'bool',
119
+ },
120
+ {
121
+ indexed: false,
122
+ name: 'canWithdraw',
123
+ type: 'bool',
124
+ },
125
+ {
126
+ indexed: false,
127
+ name: 'canRebalance',
128
+ type: 'bool',
129
+ },
130
+ {
131
+ indexed: false,
132
+ name: 'canTransfer',
133
+ type: 'bool',
134
+ },
135
+ {
136
+ indexed: false,
137
+ name: 'canSwap',
138
+ type: 'bool',
139
+ },
140
+ {
141
+ indexed: false,
142
+ name: 'canConvert',
143
+ type: 'bool',
144
+ },
145
+ {
146
+ indexed: false,
147
+ name: 'canAddLiq',
148
+ type: 'bool',
149
+ },
150
+ {
151
+ indexed: false,
152
+ name: 'canRemoveLiq',
153
+ type: 'bool',
154
+ },
155
+ {
156
+ indexed: false,
157
+ name: 'canClaimRewards',
158
+ type: 'bool',
159
+ },
160
+ {
161
+ indexed: false,
162
+ name: 'canBorrow',
163
+ type: 'bool',
164
+ },
165
+ {
166
+ indexed: false,
167
+ name: 'canRepay',
168
+ type: 'bool',
169
+ },
170
+ ],
171
+ name: 'AllowedActionsModified',
172
+ type: 'event',
173
+ },
174
+ {
175
+ anonymous: false,
176
+ inputs: [
177
+ {
178
+ indexed: false,
179
+ name: 'canTransfer',
180
+ type: 'bool',
181
+ },
182
+ ],
183
+ name: 'CanTransferToAltOwnerWalletsSet',
184
+ type: 'event',
185
+ },
186
+ {
187
+ anonymous: false,
188
+ inputs: [
189
+ {
190
+ indexed: true,
191
+ name: 'addr',
192
+ type: 'address',
193
+ },
194
+ {
195
+ indexed: false,
196
+ name: 'confirmBlock',
197
+ type: 'uint256',
198
+ },
199
+ ],
200
+ name: 'WhitelistAddrPending',
201
+ type: 'event',
202
+ },
203
+ {
204
+ anonymous: false,
205
+ inputs: [
206
+ {
207
+ indexed: true,
208
+ name: 'addr',
209
+ type: 'address',
210
+ },
211
+ {
212
+ indexed: false,
213
+ name: 'initiatedBlock',
214
+ type: 'uint256',
215
+ },
216
+ {
217
+ indexed: false,
218
+ name: 'confirmBlock',
219
+ type: 'uint256',
220
+ },
221
+ ],
222
+ name: 'WhitelistAddrConfirmed',
223
+ type: 'event',
224
+ },
225
+ {
226
+ anonymous: false,
227
+ inputs: [
228
+ {
229
+ indexed: true,
230
+ name: 'addr',
231
+ type: 'address',
232
+ },
233
+ {
234
+ indexed: false,
235
+ name: 'initiatedBlock',
236
+ type: 'uint256',
237
+ },
238
+ {
239
+ indexed: false,
240
+ name: 'confirmBlock',
241
+ type: 'uint256',
242
+ },
243
+ {
244
+ indexed: true,
245
+ name: 'cancelledBy',
246
+ type: 'address',
247
+ },
248
+ ],
249
+ name: 'WhitelistAddrCancelled',
250
+ type: 'event',
251
+ },
252
+ {
253
+ anonymous: false,
254
+ inputs: [
255
+ {
256
+ indexed: true,
257
+ name: 'addr',
258
+ type: 'address',
259
+ },
260
+ ],
261
+ name: 'WhitelistAddrRemoved',
262
+ type: 'event',
263
+ },
264
+ {
265
+ anonymous: false,
266
+ inputs: [
267
+ {
268
+ indexed: true,
269
+ name: 'asset',
270
+ type: 'address',
271
+ },
272
+ {
273
+ indexed: false,
274
+ name: 'amount',
275
+ type: 'uint256',
276
+ },
277
+ ],
278
+ name: 'ReserveAssetSet',
279
+ type: 'event',
280
+ },
281
+ {
282
+ anonymous: false,
283
+ inputs: [
284
+ {
285
+ indexed: true,
286
+ name: 'asset',
287
+ type: 'address',
288
+ },
289
+ {
290
+ indexed: true,
291
+ name: 'recipient',
292
+ type: 'address',
293
+ },
294
+ {
295
+ indexed: false,
296
+ name: 'balance',
297
+ type: 'uint256',
298
+ },
299
+ ],
300
+ name: 'FundsRecovered',
301
+ type: 'event',
302
+ },
303
+ {
304
+ anonymous: false,
305
+ inputs: [
306
+ {
307
+ indexed: true,
308
+ name: 'prevOwner',
309
+ type: 'address',
310
+ },
311
+ {
312
+ indexed: true,
313
+ name: 'newOwner',
314
+ type: 'address',
315
+ },
316
+ {
317
+ indexed: false,
318
+ name: 'confirmBlock',
319
+ type: 'uint256',
320
+ },
321
+ ],
322
+ name: 'OwnershipChangeInitiated',
323
+ type: 'event',
324
+ },
325
+ {
326
+ anonymous: false,
327
+ inputs: [
328
+ {
329
+ indexed: true,
330
+ name: 'prevOwner',
331
+ type: 'address',
332
+ },
333
+ {
334
+ indexed: true,
335
+ name: 'newOwner',
336
+ type: 'address',
337
+ },
338
+ {
339
+ indexed: false,
340
+ name: 'initiatedBlock',
341
+ type: 'uint256',
342
+ },
343
+ {
344
+ indexed: false,
345
+ name: 'confirmBlock',
346
+ type: 'uint256',
347
+ },
348
+ ],
349
+ name: 'OwnershipChangeConfirmed',
350
+ type: 'event',
351
+ },
352
+ {
353
+ anonymous: false,
354
+ inputs: [
355
+ {
356
+ indexed: true,
357
+ name: 'cancelledOwner',
358
+ type: 'address',
359
+ },
360
+ {
361
+ indexed: true,
362
+ name: 'cancelledBy',
363
+ type: 'address',
364
+ },
365
+ {
366
+ indexed: false,
367
+ name: 'initiatedBlock',
368
+ type: 'uint256',
369
+ },
370
+ {
371
+ indexed: false,
372
+ name: 'confirmBlock',
373
+ type: 'uint256',
374
+ },
375
+ ],
376
+ name: 'OwnershipChangeCancelled',
377
+ type: 'event',
378
+ },
379
+ {
380
+ anonymous: false,
381
+ inputs: [
382
+ {
383
+ indexed: false,
384
+ name: 'delayBlocks',
385
+ type: 'uint256',
386
+ },
387
+ ],
388
+ name: 'OwnershipChangeDelaySet',
389
+ type: 'event',
390
+ },
391
+ {
392
+ inputs: [],
393
+ name: 'hasPendingOwnerChange',
394
+ outputs: [
395
+ {
396
+ name: '',
397
+ type: 'bool',
398
+ },
399
+ ],
400
+ stateMutability: 'view',
401
+ type: 'function',
402
+ },
403
+ {
404
+ inputs: [
405
+ {
406
+ name: '_newOwner',
407
+ type: 'address',
408
+ },
409
+ ],
410
+ name: 'changeOwnership',
411
+ outputs: [],
412
+ stateMutability: 'nonpayable',
413
+ type: 'function',
414
+ },
415
+ {
416
+ inputs: [],
417
+ name: 'confirmOwnershipChange',
418
+ outputs: [],
419
+ stateMutability: 'nonpayable',
420
+ type: 'function',
421
+ },
422
+ {
423
+ inputs: [],
424
+ name: 'cancelOwnershipChange',
425
+ outputs: [],
426
+ stateMutability: 'nonpayable',
427
+ type: 'function',
428
+ },
429
+ {
430
+ inputs: [
431
+ {
432
+ name: '_numBlocks',
433
+ type: 'uint256',
434
+ },
435
+ ],
436
+ name: 'setOwnershipChangeDelay',
437
+ outputs: [],
438
+ stateMutability: 'nonpayable',
439
+ type: 'function',
440
+ },
441
+ {
442
+ inputs: [],
443
+ name: 'owner',
444
+ outputs: [
445
+ {
446
+ name: '',
447
+ type: 'address',
448
+ },
449
+ ],
450
+ stateMutability: 'view',
451
+ type: 'function',
452
+ },
453
+ {
454
+ inputs: [],
455
+ name: 'pendingOwner',
456
+ outputs: [
457
+ {
458
+ components: [
459
+ {
460
+ name: 'newOwner',
461
+ type: 'address',
462
+ },
463
+ {
464
+ name: 'initiatedBlock',
465
+ type: 'uint256',
466
+ },
467
+ {
468
+ name: 'confirmBlock',
469
+ type: 'uint256',
470
+ },
471
+ ],
472
+ name: '',
473
+ type: 'tuple',
474
+ },
475
+ ],
476
+ stateMutability: 'view',
477
+ type: 'function',
478
+ },
479
+ {
480
+ inputs: [],
481
+ name: 'ownershipChangeDelay',
482
+ outputs: [
483
+ {
484
+ name: '',
485
+ type: 'uint256',
486
+ },
487
+ ],
488
+ stateMutability: 'view',
489
+ type: 'function',
490
+ },
491
+ {
492
+ inputs: [],
493
+ name: 'MIN_OWNER_CHANGE_DELAY',
494
+ outputs: [
495
+ {
496
+ name: '',
497
+ type: 'uint256',
498
+ },
499
+ ],
500
+ stateMutability: 'view',
501
+ type: 'function',
502
+ },
503
+ {
504
+ inputs: [],
505
+ name: 'MAX_OWNER_CHANGE_DELAY',
506
+ outputs: [
507
+ {
508
+ name: '',
509
+ type: 'uint256',
510
+ },
511
+ ],
512
+ stateMutability: 'view',
513
+ type: 'function',
514
+ },
515
+ {
516
+ inputs: [],
517
+ name: '_ADDY_REGISTRY',
518
+ outputs: [
519
+ {
520
+ name: '',
521
+ type: 'address',
522
+ },
523
+ ],
524
+ stateMutability: 'view',
525
+ type: 'function',
526
+ },
527
+ {
528
+ inputs: [
529
+ {
530
+ name: '_wallet',
531
+ type: 'address',
532
+ },
533
+ ],
534
+ name: 'setWallet',
535
+ outputs: [
536
+ {
537
+ name: '',
538
+ type: 'bool',
539
+ },
540
+ ],
541
+ stateMutability: 'nonpayable',
542
+ type: 'function',
543
+ },
544
+ {
545
+ inputs: [],
546
+ name: 'apiVersion',
547
+ outputs: [
548
+ {
549
+ name: '',
550
+ type: 'string',
551
+ },
552
+ ],
553
+ stateMutability: 'pure',
554
+ type: 'function',
555
+ },
556
+ {
557
+ inputs: [
558
+ {
559
+ name: '_agent',
560
+ type: 'address',
561
+ },
562
+ ],
563
+ name: 'isAgentActive',
564
+ outputs: [
565
+ {
566
+ name: '',
567
+ type: 'bool',
568
+ },
569
+ ],
570
+ stateMutability: 'view',
571
+ type: 'function',
572
+ },
573
+ {
574
+ inputs: [
575
+ {
576
+ name: '_agent',
577
+ type: 'address',
578
+ },
579
+ {
580
+ name: '_action',
581
+ type: 'uint256',
582
+ },
583
+ {
584
+ name: '_assets',
585
+ type: 'address[]',
586
+ },
587
+ {
588
+ name: '_legoIds',
589
+ type: 'uint256[]',
590
+ },
591
+ ],
592
+ name: 'canAgentAccess',
593
+ outputs: [
594
+ {
595
+ name: '',
596
+ type: 'bool',
597
+ },
598
+ ],
599
+ stateMutability: 'view',
600
+ type: 'function',
601
+ },
602
+ {
603
+ inputs: [
604
+ {
605
+ name: '_agent',
606
+ type: 'address',
607
+ },
608
+ ],
609
+ name: 'getAgentSubscriptionStatus',
610
+ outputs: [
611
+ {
612
+ components: [
613
+ {
614
+ name: 'recipient',
615
+ type: 'address',
616
+ },
617
+ {
618
+ name: 'asset',
619
+ type: 'address',
620
+ },
621
+ {
622
+ name: 'amount',
623
+ type: 'uint256',
624
+ },
625
+ {
626
+ name: 'usdValue',
627
+ type: 'uint256',
628
+ },
629
+ {
630
+ name: 'paidThroughBlock',
631
+ type: 'uint256',
632
+ },
633
+ {
634
+ name: 'didChange',
635
+ type: 'bool',
636
+ },
637
+ ],
638
+ name: '',
639
+ type: 'tuple',
640
+ },
641
+ ],
642
+ stateMutability: 'view',
643
+ type: 'function',
644
+ },
645
+ {
646
+ inputs: [],
647
+ name: 'getProtocolSubscriptionStatus',
648
+ outputs: [
649
+ {
650
+ components: [
651
+ {
652
+ name: 'recipient',
653
+ type: 'address',
654
+ },
655
+ {
656
+ name: 'asset',
657
+ type: 'address',
658
+ },
659
+ {
660
+ name: 'amount',
661
+ type: 'uint256',
662
+ },
663
+ {
664
+ name: 'usdValue',
665
+ type: 'uint256',
666
+ },
667
+ {
668
+ name: 'paidThroughBlock',
669
+ type: 'uint256',
670
+ },
671
+ {
672
+ name: 'didChange',
673
+ type: 'bool',
674
+ },
675
+ ],
676
+ name: '',
677
+ type: 'tuple',
678
+ },
679
+ ],
680
+ stateMutability: 'view',
681
+ type: 'function',
682
+ },
683
+ {
684
+ inputs: [
685
+ {
686
+ name: '_agent',
687
+ type: 'address',
688
+ },
689
+ ],
690
+ name: 'canMakeSubscriptionPayments',
691
+ outputs: [
692
+ {
693
+ name: '',
694
+ type: 'bool',
695
+ },
696
+ {
697
+ name: '',
698
+ type: 'bool',
699
+ },
700
+ ],
701
+ stateMutability: 'view',
702
+ type: 'function',
703
+ },
704
+ {
705
+ inputs: [
706
+ {
707
+ name: '_agent',
708
+ type: 'address',
709
+ },
710
+ {
711
+ name: '_action',
712
+ type: 'uint256',
713
+ },
714
+ {
715
+ name: '_assets',
716
+ type: 'address[]',
717
+ },
718
+ {
719
+ name: '_legoIds',
720
+ type: 'uint256[]',
721
+ },
722
+ {
723
+ components: [
724
+ {
725
+ name: 'owner',
726
+ type: 'address',
727
+ },
728
+ {
729
+ name: 'wallet',
730
+ type: 'address',
731
+ },
732
+ {
733
+ name: 'walletConfig',
734
+ type: 'address',
735
+ },
736
+ {
737
+ name: 'addyRegistry',
738
+ type: 'address',
739
+ },
740
+ {
741
+ name: 'legoRegistry',
742
+ type: 'address',
743
+ },
744
+ {
745
+ name: 'priceSheets',
746
+ type: 'address',
747
+ },
748
+ {
749
+ name: 'oracleRegistry',
750
+ type: 'address',
751
+ },
752
+ {
753
+ name: 'trialFundsAsset',
754
+ type: 'address',
755
+ },
756
+ {
757
+ name: 'trialFundsInitialAmount',
758
+ type: 'uint256',
759
+ },
760
+ ],
761
+ name: '_cd',
762
+ type: 'tuple',
763
+ },
764
+ ],
765
+ name: 'handleSubscriptionsAndPermissions',
766
+ outputs: [
767
+ {
768
+ components: [
769
+ {
770
+ name: 'recipient',
771
+ type: 'address',
772
+ },
773
+ {
774
+ name: 'asset',
775
+ type: 'address',
776
+ },
777
+ {
778
+ name: 'amount',
779
+ type: 'uint256',
780
+ },
781
+ {
782
+ name: 'usdValue',
783
+ type: 'uint256',
784
+ },
785
+ {
786
+ name: 'paidThroughBlock',
787
+ type: 'uint256',
788
+ },
789
+ {
790
+ name: 'didChange',
791
+ type: 'bool',
792
+ },
793
+ ],
794
+ name: '',
795
+ type: 'tuple',
796
+ },
797
+ {
798
+ components: [
799
+ {
800
+ name: 'recipient',
801
+ type: 'address',
802
+ },
803
+ {
804
+ name: 'asset',
805
+ type: 'address',
806
+ },
807
+ {
808
+ name: 'amount',
809
+ type: 'uint256',
810
+ },
811
+ {
812
+ name: 'usdValue',
813
+ type: 'uint256',
814
+ },
815
+ {
816
+ name: 'paidThroughBlock',
817
+ type: 'uint256',
818
+ },
819
+ {
820
+ name: 'didChange',
821
+ type: 'bool',
822
+ },
823
+ ],
824
+ name: '',
825
+ type: 'tuple',
826
+ },
827
+ ],
828
+ stateMutability: 'nonpayable',
829
+ type: 'function',
830
+ },
831
+ {
832
+ inputs: [
833
+ {
834
+ name: '_asset',
835
+ type: 'address',
836
+ },
837
+ {
838
+ name: '_wantedAmount',
839
+ type: 'uint256',
840
+ },
841
+ {
842
+ name: '_shouldCheckTrialFunds',
843
+ type: 'bool',
844
+ },
845
+ ],
846
+ name: 'getAvailableTxAmount',
847
+ outputs: [
848
+ {
849
+ name: '',
850
+ type: 'uint256',
851
+ },
852
+ ],
853
+ stateMutability: 'view',
854
+ type: 'function',
855
+ },
856
+ {
857
+ inputs: [
858
+ {
859
+ name: '_asset',
860
+ type: 'address',
861
+ },
862
+ {
863
+ name: '_wantedAmount',
864
+ type: 'uint256',
865
+ },
866
+ {
867
+ name: '_shouldCheckTrialFunds',
868
+ type: 'bool',
869
+ },
870
+ {
871
+ components: [
872
+ {
873
+ name: 'owner',
874
+ type: 'address',
875
+ },
876
+ {
877
+ name: 'wallet',
878
+ type: 'address',
879
+ },
880
+ {
881
+ name: 'walletConfig',
882
+ type: 'address',
883
+ },
884
+ {
885
+ name: 'addyRegistry',
886
+ type: 'address',
887
+ },
888
+ {
889
+ name: 'legoRegistry',
890
+ type: 'address',
891
+ },
892
+ {
893
+ name: 'priceSheets',
894
+ type: 'address',
895
+ },
896
+ {
897
+ name: 'oracleRegistry',
898
+ type: 'address',
899
+ },
900
+ {
901
+ name: 'trialFundsAsset',
902
+ type: 'address',
903
+ },
904
+ {
905
+ name: 'trialFundsInitialAmount',
906
+ type: 'uint256',
907
+ },
908
+ ],
909
+ name: '_cd',
910
+ type: 'tuple',
911
+ },
912
+ ],
913
+ name: 'getAvailableTxAmount',
914
+ outputs: [
915
+ {
916
+ name: '',
917
+ type: 'uint256',
918
+ },
919
+ ],
920
+ stateMutability: 'view',
921
+ type: 'function',
922
+ },
923
+ {
924
+ inputs: [
925
+ {
926
+ name: '_agent',
927
+ type: 'address',
928
+ },
929
+ ],
930
+ name: 'addOrModifyAgent',
931
+ outputs: [
932
+ {
933
+ name: '',
934
+ type: 'bool',
935
+ },
936
+ ],
937
+ stateMutability: 'nonpayable',
938
+ type: 'function',
939
+ },
940
+ {
941
+ inputs: [
942
+ {
943
+ name: '_agent',
944
+ type: 'address',
945
+ },
946
+ {
947
+ name: '_allowedAssets',
948
+ type: 'address[]',
949
+ },
950
+ ],
951
+ name: 'addOrModifyAgent',
952
+ outputs: [
953
+ {
954
+ name: '',
955
+ type: 'bool',
956
+ },
957
+ ],
958
+ stateMutability: 'nonpayable',
959
+ type: 'function',
960
+ },
961
+ {
962
+ inputs: [
963
+ {
964
+ name: '_agent',
965
+ type: 'address',
966
+ },
967
+ {
968
+ name: '_allowedAssets',
969
+ type: 'address[]',
970
+ },
971
+ {
972
+ name: '_allowedLegoIds',
973
+ type: 'uint256[]',
974
+ },
975
+ ],
976
+ name: 'addOrModifyAgent',
977
+ outputs: [
978
+ {
979
+ name: '',
980
+ type: 'bool',
981
+ },
982
+ ],
983
+ stateMutability: 'nonpayable',
984
+ type: 'function',
985
+ },
986
+ {
987
+ inputs: [
988
+ {
989
+ name: '_agent',
990
+ type: 'address',
991
+ },
992
+ {
993
+ name: '_allowedAssets',
994
+ type: 'address[]',
995
+ },
996
+ {
997
+ name: '_allowedLegoIds',
998
+ type: 'uint256[]',
999
+ },
1000
+ {
1001
+ components: [
1002
+ {
1003
+ name: 'isSet',
1004
+ type: 'bool',
1005
+ },
1006
+ {
1007
+ name: 'canDeposit',
1008
+ type: 'bool',
1009
+ },
1010
+ {
1011
+ name: 'canWithdraw',
1012
+ type: 'bool',
1013
+ },
1014
+ {
1015
+ name: 'canRebalance',
1016
+ type: 'bool',
1017
+ },
1018
+ {
1019
+ name: 'canTransfer',
1020
+ type: 'bool',
1021
+ },
1022
+ {
1023
+ name: 'canSwap',
1024
+ type: 'bool',
1025
+ },
1026
+ {
1027
+ name: 'canConvert',
1028
+ type: 'bool',
1029
+ },
1030
+ {
1031
+ name: 'canAddLiq',
1032
+ type: 'bool',
1033
+ },
1034
+ {
1035
+ name: 'canRemoveLiq',
1036
+ type: 'bool',
1037
+ },
1038
+ {
1039
+ name: 'canClaimRewards',
1040
+ type: 'bool',
1041
+ },
1042
+ {
1043
+ name: 'canBorrow',
1044
+ type: 'bool',
1045
+ },
1046
+ {
1047
+ name: 'canRepay',
1048
+ type: 'bool',
1049
+ },
1050
+ ],
1051
+ name: '_allowedActions',
1052
+ type: 'tuple',
1053
+ },
1054
+ ],
1055
+ name: 'addOrModifyAgent',
1056
+ outputs: [
1057
+ {
1058
+ name: '',
1059
+ type: 'bool',
1060
+ },
1061
+ ],
1062
+ stateMutability: 'nonpayable',
1063
+ type: 'function',
1064
+ },
1065
+ {
1066
+ inputs: [
1067
+ {
1068
+ name: '_agent',
1069
+ type: 'address',
1070
+ },
1071
+ ],
1072
+ name: 'disableAgent',
1073
+ outputs: [
1074
+ {
1075
+ name: '',
1076
+ type: 'bool',
1077
+ },
1078
+ ],
1079
+ stateMutability: 'nonpayable',
1080
+ type: 'function',
1081
+ },
1082
+ {
1083
+ inputs: [
1084
+ {
1085
+ name: '_agent',
1086
+ type: 'address',
1087
+ },
1088
+ {
1089
+ name: '_legoId',
1090
+ type: 'uint256',
1091
+ },
1092
+ ],
1093
+ name: 'addLegoIdForAgent',
1094
+ outputs: [
1095
+ {
1096
+ name: '',
1097
+ type: 'bool',
1098
+ },
1099
+ ],
1100
+ stateMutability: 'nonpayable',
1101
+ type: 'function',
1102
+ },
1103
+ {
1104
+ inputs: [
1105
+ {
1106
+ name: '_agent',
1107
+ type: 'address',
1108
+ },
1109
+ {
1110
+ name: '_asset',
1111
+ type: 'address',
1112
+ },
1113
+ ],
1114
+ name: 'addAssetForAgent',
1115
+ outputs: [
1116
+ {
1117
+ name: '',
1118
+ type: 'bool',
1119
+ },
1120
+ ],
1121
+ stateMutability: 'nonpayable',
1122
+ type: 'function',
1123
+ },
1124
+ {
1125
+ inputs: [
1126
+ {
1127
+ name: '_agent',
1128
+ type: 'address',
1129
+ },
1130
+ ],
1131
+ name: 'modifyAllowedActions',
1132
+ outputs: [
1133
+ {
1134
+ name: '',
1135
+ type: 'bool',
1136
+ },
1137
+ ],
1138
+ stateMutability: 'nonpayable',
1139
+ type: 'function',
1140
+ },
1141
+ {
1142
+ inputs: [
1143
+ {
1144
+ name: '_agent',
1145
+ type: 'address',
1146
+ },
1147
+ {
1148
+ components: [
1149
+ {
1150
+ name: 'isSet',
1151
+ type: 'bool',
1152
+ },
1153
+ {
1154
+ name: 'canDeposit',
1155
+ type: 'bool',
1156
+ },
1157
+ {
1158
+ name: 'canWithdraw',
1159
+ type: 'bool',
1160
+ },
1161
+ {
1162
+ name: 'canRebalance',
1163
+ type: 'bool',
1164
+ },
1165
+ {
1166
+ name: 'canTransfer',
1167
+ type: 'bool',
1168
+ },
1169
+ {
1170
+ name: 'canSwap',
1171
+ type: 'bool',
1172
+ },
1173
+ {
1174
+ name: 'canConvert',
1175
+ type: 'bool',
1176
+ },
1177
+ {
1178
+ name: 'canAddLiq',
1179
+ type: 'bool',
1180
+ },
1181
+ {
1182
+ name: 'canRemoveLiq',
1183
+ type: 'bool',
1184
+ },
1185
+ {
1186
+ name: 'canClaimRewards',
1187
+ type: 'bool',
1188
+ },
1189
+ {
1190
+ name: 'canBorrow',
1191
+ type: 'bool',
1192
+ },
1193
+ {
1194
+ name: 'canRepay',
1195
+ type: 'bool',
1196
+ },
1197
+ ],
1198
+ name: '_allowedActions',
1199
+ type: 'tuple',
1200
+ },
1201
+ ],
1202
+ name: 'modifyAllowedActions',
1203
+ outputs: [
1204
+ {
1205
+ name: '',
1206
+ type: 'bool',
1207
+ },
1208
+ ],
1209
+ stateMutability: 'nonpayable',
1210
+ type: 'function',
1211
+ },
1212
+ {
1213
+ inputs: [
1214
+ {
1215
+ name: '_recipient',
1216
+ type: 'address',
1217
+ },
1218
+ ],
1219
+ name: 'canTransferToRecipient',
1220
+ outputs: [
1221
+ {
1222
+ name: '',
1223
+ type: 'bool',
1224
+ },
1225
+ ],
1226
+ stateMutability: 'view',
1227
+ type: 'function',
1228
+ },
1229
+ {
1230
+ inputs: [
1231
+ {
1232
+ name: '_wallet',
1233
+ type: 'address',
1234
+ },
1235
+ ],
1236
+ name: 'doesWalletHaveSameOwner',
1237
+ outputs: [
1238
+ {
1239
+ name: '',
1240
+ type: 'bool',
1241
+ },
1242
+ ],
1243
+ stateMutability: 'view',
1244
+ type: 'function',
1245
+ },
1246
+ {
1247
+ inputs: [
1248
+ {
1249
+ name: '_canTransfer',
1250
+ type: 'bool',
1251
+ },
1252
+ ],
1253
+ name: 'setCanTransferToAltOwnerWallets',
1254
+ outputs: [
1255
+ {
1256
+ name: '',
1257
+ type: 'bool',
1258
+ },
1259
+ ],
1260
+ stateMutability: 'nonpayable',
1261
+ type: 'function',
1262
+ },
1263
+ {
1264
+ inputs: [
1265
+ {
1266
+ name: '_addr',
1267
+ type: 'address',
1268
+ },
1269
+ ],
1270
+ name: 'addWhitelistAddr',
1271
+ outputs: [],
1272
+ stateMutability: 'nonpayable',
1273
+ type: 'function',
1274
+ },
1275
+ {
1276
+ inputs: [
1277
+ {
1278
+ name: '_addr',
1279
+ type: 'address',
1280
+ },
1281
+ ],
1282
+ name: 'confirmWhitelistAddr',
1283
+ outputs: [],
1284
+ stateMutability: 'nonpayable',
1285
+ type: 'function',
1286
+ },
1287
+ {
1288
+ inputs: [
1289
+ {
1290
+ name: '_addr',
1291
+ type: 'address',
1292
+ },
1293
+ ],
1294
+ name: 'cancelPendingWhitelistAddr',
1295
+ outputs: [],
1296
+ stateMutability: 'nonpayable',
1297
+ type: 'function',
1298
+ },
1299
+ {
1300
+ inputs: [
1301
+ {
1302
+ name: '_addr',
1303
+ type: 'address',
1304
+ },
1305
+ ],
1306
+ name: 'removeWhitelistAddr',
1307
+ outputs: [],
1308
+ stateMutability: 'nonpayable',
1309
+ type: 'function',
1310
+ },
1311
+ {
1312
+ inputs: [
1313
+ {
1314
+ name: '_asset',
1315
+ type: 'address',
1316
+ },
1317
+ {
1318
+ name: '_amount',
1319
+ type: 'uint256',
1320
+ },
1321
+ ],
1322
+ name: 'setReserveAsset',
1323
+ outputs: [
1324
+ {
1325
+ name: '',
1326
+ type: 'bool',
1327
+ },
1328
+ ],
1329
+ stateMutability: 'nonpayable',
1330
+ type: 'function',
1331
+ },
1332
+ {
1333
+ inputs: [
1334
+ {
1335
+ components: [
1336
+ {
1337
+ name: 'asset',
1338
+ type: 'address',
1339
+ },
1340
+ {
1341
+ name: 'amount',
1342
+ type: 'uint256',
1343
+ },
1344
+ ],
1345
+ name: '_assets',
1346
+ type: 'tuple[]',
1347
+ },
1348
+ ],
1349
+ name: 'setManyReserveAssets',
1350
+ outputs: [
1351
+ {
1352
+ name: '',
1353
+ type: 'bool',
1354
+ },
1355
+ ],
1356
+ stateMutability: 'nonpayable',
1357
+ type: 'function',
1358
+ },
1359
+ {
1360
+ inputs: [
1361
+ {
1362
+ name: '_asset',
1363
+ type: 'address',
1364
+ },
1365
+ ],
1366
+ name: 'recoverFunds',
1367
+ outputs: [
1368
+ {
1369
+ name: '',
1370
+ type: 'bool',
1371
+ },
1372
+ ],
1373
+ stateMutability: 'nonpayable',
1374
+ type: 'function',
1375
+ },
1376
+ {
1377
+ inputs: [],
1378
+ name: 'wallet',
1379
+ outputs: [
1380
+ {
1381
+ name: '',
1382
+ type: 'address',
1383
+ },
1384
+ ],
1385
+ stateMutability: 'view',
1386
+ type: 'function',
1387
+ },
1388
+ {
1389
+ inputs: [],
1390
+ name: 'didSetWallet',
1391
+ outputs: [
1392
+ {
1393
+ name: '',
1394
+ type: 'bool',
1395
+ },
1396
+ ],
1397
+ stateMutability: 'view',
1398
+ type: 'function',
1399
+ },
1400
+ {
1401
+ inputs: [],
1402
+ name: 'protocolSub',
1403
+ outputs: [
1404
+ {
1405
+ components: [
1406
+ {
1407
+ name: 'installBlock',
1408
+ type: 'uint256',
1409
+ },
1410
+ {
1411
+ name: 'paidThroughBlock',
1412
+ type: 'uint256',
1413
+ },
1414
+ ],
1415
+ name: '',
1416
+ type: 'tuple',
1417
+ },
1418
+ ],
1419
+ stateMutability: 'view',
1420
+ type: 'function',
1421
+ },
1422
+ {
1423
+ inputs: [
1424
+ {
1425
+ name: 'arg0',
1426
+ type: 'address',
1427
+ },
1428
+ ],
1429
+ name: 'reserveAssets',
1430
+ outputs: [
1431
+ {
1432
+ name: '',
1433
+ type: 'uint256',
1434
+ },
1435
+ ],
1436
+ stateMutability: 'view',
1437
+ type: 'function',
1438
+ },
1439
+ {
1440
+ inputs: [
1441
+ {
1442
+ name: 'arg0',
1443
+ type: 'address',
1444
+ },
1445
+ ],
1446
+ name: 'agentSettings',
1447
+ outputs: [
1448
+ {
1449
+ components: [
1450
+ {
1451
+ name: 'isActive',
1452
+ type: 'bool',
1453
+ },
1454
+ {
1455
+ name: 'installBlock',
1456
+ type: 'uint256',
1457
+ },
1458
+ {
1459
+ name: 'paidThroughBlock',
1460
+ type: 'uint256',
1461
+ },
1462
+ {
1463
+ name: 'allowedAssets',
1464
+ type: 'address[]',
1465
+ },
1466
+ {
1467
+ name: 'allowedLegoIds',
1468
+ type: 'uint256[]',
1469
+ },
1470
+ {
1471
+ components: [
1472
+ {
1473
+ name: 'isSet',
1474
+ type: 'bool',
1475
+ },
1476
+ {
1477
+ name: 'canDeposit',
1478
+ type: 'bool',
1479
+ },
1480
+ {
1481
+ name: 'canWithdraw',
1482
+ type: 'bool',
1483
+ },
1484
+ {
1485
+ name: 'canRebalance',
1486
+ type: 'bool',
1487
+ },
1488
+ {
1489
+ name: 'canTransfer',
1490
+ type: 'bool',
1491
+ },
1492
+ {
1493
+ name: 'canSwap',
1494
+ type: 'bool',
1495
+ },
1496
+ {
1497
+ name: 'canConvert',
1498
+ type: 'bool',
1499
+ },
1500
+ {
1501
+ name: 'canAddLiq',
1502
+ type: 'bool',
1503
+ },
1504
+ {
1505
+ name: 'canRemoveLiq',
1506
+ type: 'bool',
1507
+ },
1508
+ {
1509
+ name: 'canClaimRewards',
1510
+ type: 'bool',
1511
+ },
1512
+ {
1513
+ name: 'canBorrow',
1514
+ type: 'bool',
1515
+ },
1516
+ {
1517
+ name: 'canRepay',
1518
+ type: 'bool',
1519
+ },
1520
+ ],
1521
+ name: 'allowedActions',
1522
+ type: 'tuple',
1523
+ },
1524
+ ],
1525
+ name: '',
1526
+ type: 'tuple',
1527
+ },
1528
+ ],
1529
+ stateMutability: 'view',
1530
+ type: 'function',
1531
+ },
1532
+ {
1533
+ inputs: [
1534
+ {
1535
+ name: 'arg0',
1536
+ type: 'address',
1537
+ },
1538
+ ],
1539
+ name: 'isRecipientAllowed',
1540
+ outputs: [
1541
+ {
1542
+ name: '',
1543
+ type: 'bool',
1544
+ },
1545
+ ],
1546
+ stateMutability: 'view',
1547
+ type: 'function',
1548
+ },
1549
+ {
1550
+ inputs: [
1551
+ {
1552
+ name: 'arg0',
1553
+ type: 'address',
1554
+ },
1555
+ ],
1556
+ name: 'pendingWhitelist',
1557
+ outputs: [
1558
+ {
1559
+ components: [
1560
+ {
1561
+ name: 'initiatedBlock',
1562
+ type: 'uint256',
1563
+ },
1564
+ {
1565
+ name: 'confirmBlock',
1566
+ type: 'uint256',
1567
+ },
1568
+ ],
1569
+ name: '',
1570
+ type: 'tuple',
1571
+ },
1572
+ ],
1573
+ stateMutability: 'view',
1574
+ type: 'function',
1575
+ },
1576
+ {
1577
+ inputs: [],
1578
+ name: 'canTransferToAltOwnerWallets',
1579
+ outputs: [
1580
+ {
1581
+ name: '',
1582
+ type: 'bool',
1583
+ },
1584
+ ],
1585
+ stateMutability: 'view',
1586
+ type: 'function',
1587
+ },
1588
+ {
1589
+ inputs: [],
1590
+ name: 'ADDY_REGISTRY',
1591
+ outputs: [
1592
+ {
1593
+ name: '',
1594
+ type: 'address',
1595
+ },
1596
+ ],
1597
+ stateMutability: 'view',
1598
+ type: 'function',
1599
+ },
1600
+ {
1601
+ inputs: [
1602
+ {
1603
+ name: '_owner',
1604
+ type: 'address',
1605
+ },
1606
+ {
1607
+ name: '_initialAgent',
1608
+ type: 'address',
1609
+ },
1610
+ {
1611
+ name: '_addyRegistry',
1612
+ type: 'address',
1613
+ },
1614
+ {
1615
+ name: '_minOwnerChangeDelay',
1616
+ type: 'uint256',
1617
+ },
1618
+ {
1619
+ name: '_maxOwnerChangeDelay',
1620
+ type: 'uint256',
1621
+ },
1622
+ ],
1623
+ outputs: [],
1624
+ stateMutability: 'nonpayable',
1625
+ type: 'constructor',
1626
+ },
1627
+ ];
1628
+ export const deployAddress = '0xAeE931cC57CfBE31328bCfF092Af7eC7dFD7EBC8';
1629
+ function getRequest(method, args, contractAddressOrOptions) {
1630
+ const address = typeof contractAddressOrOptions === 'string' ? contractAddressOrOptions : contractAddressOrOptions?.contractAddress;
1631
+ const defaultValue = typeof contractAddressOrOptions === 'string' ? undefined : contractAddressOrOptions?.defaultValue;
1632
+ const call = {
1633
+ contractName: 'UserWalletConfig',
1634
+ method,
1635
+ args,
1636
+ address,
1637
+ deployAddress,
1638
+ defaultValue,
1639
+ getAbi: () => abi,
1640
+ with: (options) => {
1641
+ call.address = options.contractAddress;
1642
+ call.defaultValue = options.defaultValue;
1643
+ return call;
1644
+ },
1645
+ defaultTo: (defaultValue) => {
1646
+ call.defaultValue = defaultValue;
1647
+ return call;
1648
+ },
1649
+ at: (address) => {
1650
+ call.address = address;
1651
+ return call;
1652
+ },
1653
+ };
1654
+ return call;
1655
+ }
1656
+ export const call = {
1657
+ hasPendingOwnerChange: (...args) => getRequest('hasPendingOwnerChange', args),
1658
+ owner: (...args) => getRequest('owner', args),
1659
+ pendingOwner: (...args) => getRequest('pendingOwner', args),
1660
+ ownershipChangeDelay: (...args) => getRequest('ownershipChangeDelay', args),
1661
+ MIN_OWNER_CHANGE_DELAY: (...args) => getRequest('MIN_OWNER_CHANGE_DELAY', args),
1662
+ MAX_OWNER_CHANGE_DELAY: (...args) => getRequest('MAX_OWNER_CHANGE_DELAY', args),
1663
+ _ADDY_REGISTRY: (...args) => getRequest('_ADDY_REGISTRY', args),
1664
+ apiVersion: (...args) => getRequest('apiVersion', args),
1665
+ isAgentActive: (...args) => getRequest('isAgentActive', args),
1666
+ canAgentAccess: (...args) => getRequest('canAgentAccess', args),
1667
+ getAgentSubscriptionStatus: (...args) => getRequest('getAgentSubscriptionStatus', args),
1668
+ getProtocolSubscriptionStatus: (...args) => getRequest('getProtocolSubscriptionStatus', args),
1669
+ canMakeSubscriptionPayments: (...args) => getRequest('canMakeSubscriptionPayments', args),
1670
+ getAvailableTxAmount: (...args) => getRequest('getAvailableTxAmount', args),
1671
+ canTransferToRecipient: (...args) => getRequest('canTransferToRecipient', args),
1672
+ doesWalletHaveSameOwner: (...args) => getRequest('doesWalletHaveSameOwner', args),
1673
+ wallet: (...args) => getRequest('wallet', args),
1674
+ didSetWallet: (...args) => getRequest('didSetWallet', args),
1675
+ protocolSub: (...args) => getRequest('protocolSub', args),
1676
+ reserveAssets: (...args) => getRequest('reserveAssets', args),
1677
+ agentSettings: (...args) => getRequest('agentSettings', args),
1678
+ isRecipientAllowed: (...args) => getRequest('isRecipientAllowed', args),
1679
+ pendingWhitelist: (...args) => getRequest('pendingWhitelist', args),
1680
+ canTransferToAltOwnerWallets: (...args) => getRequest('canTransferToAltOwnerWallets', args),
1681
+ ADDY_REGISTRY: (...args) => getRequest('ADDY_REGISTRY', args),
1682
+ };
1683
+ function getMutation(functionName) {
1684
+ return {
1685
+ contractName: 'UserWalletConfig',
1686
+ functionName,
1687
+ deployAddress,
1688
+ argsType: undefined,
1689
+ getAbi: () => abi,
1690
+ };
1691
+ }
1692
+ export const mutation = {
1693
+ changeOwnership: getMutation('changeOwnership'),
1694
+ confirmOwnershipChange: getMutation('confirmOwnershipChange'),
1695
+ cancelOwnershipChange: getMutation('cancelOwnershipChange'),
1696
+ setOwnershipChangeDelay: getMutation('setOwnershipChangeDelay'),
1697
+ setWallet: getMutation('setWallet'),
1698
+ handleSubscriptionsAndPermissions: getMutation('handleSubscriptionsAndPermissions'),
1699
+ addOrModifyAgent: getMutation('addOrModifyAgent'),
1700
+ disableAgent: getMutation('disableAgent'),
1701
+ addLegoIdForAgent: getMutation('addLegoIdForAgent'),
1702
+ addAssetForAgent: getMutation('addAssetForAgent'),
1703
+ modifyAllowedActions: getMutation('modifyAllowedActions'),
1704
+ setCanTransferToAltOwnerWallets: getMutation('setCanTransferToAltOwnerWallets'),
1705
+ addWhitelistAddr: getMutation('addWhitelistAddr'),
1706
+ confirmWhitelistAddr: getMutation('confirmWhitelistAddr'),
1707
+ cancelPendingWhitelistAddr: getMutation('cancelPendingWhitelistAddr'),
1708
+ removeWhitelistAddr: getMutation('removeWhitelistAddr'),
1709
+ setReserveAsset: getMutation('setReserveAsset'),
1710
+ setManyReserveAssets: getMutation('setManyReserveAssets'),
1711
+ recoverFunds: getMutation('recoverFunds'),
1712
+ };
1713
+ export function toSdk(address, publicClient, walletClient) {
1714
+ return {
1715
+ // Queries
1716
+ hasPendingOwnerChange: (...args) => singleQuery(publicClient, call.hasPendingOwnerChange(...args).at(address)),
1717
+ owner: (...args) => singleQuery(publicClient, call.owner(...args).at(address)),
1718
+ pendingOwner: (...args) => singleQuery(publicClient, call.pendingOwner(...args).at(address)),
1719
+ ownershipChangeDelay: (...args) => singleQuery(publicClient, call.ownershipChangeDelay(...args).at(address)),
1720
+ MIN_OWNER_CHANGE_DELAY: (...args) => singleQuery(publicClient, call.MIN_OWNER_CHANGE_DELAY(...args).at(address)),
1721
+ MAX_OWNER_CHANGE_DELAY: (...args) => singleQuery(publicClient, call.MAX_OWNER_CHANGE_DELAY(...args).at(address)),
1722
+ _ADDY_REGISTRY: (...args) => singleQuery(publicClient, call._ADDY_REGISTRY(...args).at(address)),
1723
+ apiVersion: (...args) => singleQuery(publicClient, call.apiVersion(...args).at(address)),
1724
+ isAgentActive: (...args) => singleQuery(publicClient, call.isAgentActive(...args).at(address)),
1725
+ canAgentAccess: (...args) => singleQuery(publicClient, call.canAgentAccess(...args).at(address)),
1726
+ getAgentSubscriptionStatus: (...args) => singleQuery(publicClient, call.getAgentSubscriptionStatus(...args).at(address)),
1727
+ getProtocolSubscriptionStatus: (...args) => singleQuery(publicClient, call.getProtocolSubscriptionStatus(...args).at(address)),
1728
+ canMakeSubscriptionPayments: (...args) => singleQuery(publicClient, call.canMakeSubscriptionPayments(...args).at(address)),
1729
+ getAvailableTxAmount: (...args) => singleQuery(publicClient, call.getAvailableTxAmount(...args).at(address)),
1730
+ canTransferToRecipient: (...args) => singleQuery(publicClient, call.canTransferToRecipient(...args).at(address)),
1731
+ doesWalletHaveSameOwner: (...args) => singleQuery(publicClient, call.doesWalletHaveSameOwner(...args).at(address)),
1732
+ wallet: (...args) => singleQuery(publicClient, call.wallet(...args).at(address)),
1733
+ didSetWallet: (...args) => singleQuery(publicClient, call.didSetWallet(...args).at(address)),
1734
+ protocolSub: (...args) => singleQuery(publicClient, call.protocolSub(...args).at(address)),
1735
+ reserveAssets: (...args) => singleQuery(publicClient, call.reserveAssets(...args).at(address)),
1736
+ agentSettings: (...args) => singleQuery(publicClient, call.agentSettings(...args).at(address)),
1737
+ isRecipientAllowed: (...args) => singleQuery(publicClient, call.isRecipientAllowed(...args).at(address)),
1738
+ pendingWhitelist: (...args) => singleQuery(publicClient, call.pendingWhitelist(...args).at(address)),
1739
+ canTransferToAltOwnerWallets: (...args) => singleQuery(publicClient, call.canTransferToAltOwnerWallets(...args).at(address)),
1740
+ ADDY_REGISTRY: (...args) => singleQuery(publicClient, call.ADDY_REGISTRY(...args).at(address)),
1741
+ // Mutations
1742
+ changeOwnership: (...args) => mutate(walletClient, mutation.changeOwnership, { address })(...args),
1743
+ confirmOwnershipChange: (...args) => mutate(walletClient, mutation.confirmOwnershipChange, { address })(...args),
1744
+ cancelOwnershipChange: (...args) => mutate(walletClient, mutation.cancelOwnershipChange, { address })(...args),
1745
+ setOwnershipChangeDelay: (...args) => mutate(walletClient, mutation.setOwnershipChangeDelay, { address })(...args),
1746
+ setWallet: (...args) => mutate(walletClient, mutation.setWallet, { address })(...args),
1747
+ handleSubscriptionsAndPermissions: (...args) => mutate(walletClient, mutation.handleSubscriptionsAndPermissions, { address })(...args),
1748
+ addOrModifyAgent: (...args) => mutate(walletClient, mutation.addOrModifyAgent, { address })(...args),
1749
+ disableAgent: (...args) => mutate(walletClient, mutation.disableAgent, { address })(...args),
1750
+ addLegoIdForAgent: (...args) => mutate(walletClient, mutation.addLegoIdForAgent, { address })(...args),
1751
+ addAssetForAgent: (...args) => mutate(walletClient, mutation.addAssetForAgent, { address })(...args),
1752
+ modifyAllowedActions: (...args) => mutate(walletClient, mutation.modifyAllowedActions, { address })(...args),
1753
+ setCanTransferToAltOwnerWallets: (...args) => mutate(walletClient, mutation.setCanTransferToAltOwnerWallets, { address })(...args),
1754
+ addWhitelistAddr: (...args) => mutate(walletClient, mutation.addWhitelistAddr, { address })(...args),
1755
+ confirmWhitelistAddr: (...args) => mutate(walletClient, mutation.confirmWhitelistAddr, { address })(...args),
1756
+ cancelPendingWhitelistAddr: (...args) => mutate(walletClient, mutation.cancelPendingWhitelistAddr, { address })(...args),
1757
+ removeWhitelistAddr: (...args) => mutate(walletClient, mutation.removeWhitelistAddr, { address })(...args),
1758
+ setReserveAsset: (...args) => mutate(walletClient, mutation.setReserveAsset, { address })(...args),
1759
+ setManyReserveAssets: (...args) => mutate(walletClient, mutation.setManyReserveAssets, { address })(...args),
1760
+ recoverFunds: (...args) => mutate(walletClient, mutation.recoverFunds, { address })(...args),
1761
+ };
1762
+ }