@obolnetwork/obol-sdk 2.0.1 → 2.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (49) hide show
  1. package/README.md +6 -0
  2. package/dist/cjs/package.json +1 -1
  3. package/dist/cjs/src/abi/Multicall.js +148 -0
  4. package/dist/cjs/src/abi/OWR.js +133 -0
  5. package/dist/cjs/src/abi/SplitMain.js +929 -0
  6. package/dist/cjs/src/ajv.js +17 -2
  7. package/dist/cjs/src/bytecodes.js +9 -0
  8. package/dist/cjs/src/constants.js +48 -1
  9. package/dist/cjs/src/index.js +146 -0
  10. package/dist/cjs/src/schema.js +52 -5
  11. package/dist/cjs/src/splitHelpers.js +177 -0
  12. package/dist/cjs/src/utils.js +22 -1
  13. package/dist/cjs/test/fixtures.js +1 -1
  14. package/dist/cjs/test/methods.test.js +215 -11
  15. package/dist/esm/package.json +1 -1
  16. package/dist/esm/src/abi/Multicall.js +145 -0
  17. package/dist/esm/src/abi/OWR.js +130 -0
  18. package/dist/esm/src/abi/SplitMain.js +926 -0
  19. package/dist/esm/src/ajv.js +17 -2
  20. package/dist/esm/src/bytecodes.js +6 -0
  21. package/dist/esm/src/constants.js +47 -0
  22. package/dist/esm/src/index.js +148 -2
  23. package/dist/esm/src/schema.js +51 -4
  24. package/dist/esm/src/splitHelpers.js +168 -0
  25. package/dist/esm/src/utils.js +19 -0
  26. package/dist/esm/test/fixtures.js +1 -1
  27. package/dist/esm/test/methods.test.js +193 -12
  28. package/dist/types/src/abi/Multicall.d.ts +35 -0
  29. package/dist/types/src/abi/OWR.d.ts +52 -0
  30. package/dist/types/src/abi/SplitMain.d.ts +1159 -0
  31. package/dist/types/src/bytecodes.d.ts +6 -0
  32. package/dist/types/src/constants.d.ts +25 -0
  33. package/dist/types/src/index.d.ts +29 -1
  34. package/dist/types/src/schema.d.ts +85 -4
  35. package/dist/types/src/splitHelpers.d.ts +62 -0
  36. package/dist/types/src/types.d.ts +39 -2
  37. package/dist/types/src/utils.d.ts +3 -0
  38. package/package.json +1 -1
  39. package/src/abi/Multicall.ts +145 -0
  40. package/src/abi/OWR.ts +130 -0
  41. package/src/abi/SplitMain.ts +927 -0
  42. package/src/ajv.ts +33 -2
  43. package/src/bytecodes.ts +12 -0
  44. package/src/constants.ts +59 -0
  45. package/src/index.ts +244 -2
  46. package/src/schema.ts +67 -4
  47. package/src/splitHelpers.ts +341 -0
  48. package/src/types.ts +49 -2
  49. package/src/utils.ts +21 -0
@@ -0,0 +1,929 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.splitMainPolygonAbi = exports.splitMainEthereumAbi = void 0;
4
+ exports.splitMainEthereumAbi = [
5
+ { inputs: [], stateMutability: 'nonpayable', type: 'constructor' },
6
+ { inputs: [], name: 'Create2Error', type: 'error' },
7
+ { inputs: [], name: 'CreateError', type: 'error' },
8
+ {
9
+ inputs: [
10
+ { internalType: 'address', name: 'newController', type: 'address' },
11
+ ],
12
+ name: 'InvalidNewController',
13
+ type: 'error',
14
+ },
15
+ {
16
+ inputs: [
17
+ { internalType: 'uint256', name: 'accountsLength', type: 'uint256' },
18
+ { internalType: 'uint256', name: 'allocationsLength', type: 'uint256' },
19
+ ],
20
+ name: 'InvalidSplit__AccountsAndAllocationsMismatch',
21
+ type: 'error',
22
+ },
23
+ {
24
+ inputs: [{ internalType: 'uint256', name: 'index', type: 'uint256' }],
25
+ name: 'InvalidSplit__AccountsOutOfOrder',
26
+ type: 'error',
27
+ },
28
+ {
29
+ inputs: [{ internalType: 'uint256', name: 'index', type: 'uint256' }],
30
+ name: 'InvalidSplit__AllocationMustBePositive',
31
+ type: 'error',
32
+ },
33
+ {
34
+ inputs: [
35
+ { internalType: 'uint32', name: 'allocationsSum', type: 'uint32' },
36
+ ],
37
+ name: 'InvalidSplit__InvalidAllocationsSum',
38
+ type: 'error',
39
+ },
40
+ {
41
+ inputs: [
42
+ { internalType: 'uint32', name: 'distributorFee', type: 'uint32' },
43
+ ],
44
+ name: 'InvalidSplit__InvalidDistributorFee',
45
+ type: 'error',
46
+ },
47
+ {
48
+ inputs: [{ internalType: 'bytes32', name: 'hash', type: 'bytes32' }],
49
+ name: 'InvalidSplit__InvalidHash',
50
+ type: 'error',
51
+ },
52
+ {
53
+ inputs: [
54
+ { internalType: 'uint256', name: 'accountsLength', type: 'uint256' },
55
+ ],
56
+ name: 'InvalidSplit__TooFewAccounts',
57
+ type: 'error',
58
+ },
59
+ {
60
+ inputs: [{ internalType: 'address', name: 'sender', type: 'address' }],
61
+ name: 'Unauthorized',
62
+ type: 'error',
63
+ },
64
+ {
65
+ anonymous: false,
66
+ inputs: [
67
+ {
68
+ indexed: true,
69
+ internalType: 'address',
70
+ name: 'split',
71
+ type: 'address',
72
+ },
73
+ ],
74
+ name: 'CancelControlTransfer',
75
+ type: 'event',
76
+ },
77
+ {
78
+ anonymous: false,
79
+ inputs: [
80
+ {
81
+ indexed: true,
82
+ internalType: 'address',
83
+ name: 'split',
84
+ type: 'address',
85
+ },
86
+ {
87
+ indexed: true,
88
+ internalType: 'address',
89
+ name: 'previousController',
90
+ type: 'address',
91
+ },
92
+ {
93
+ indexed: true,
94
+ internalType: 'address',
95
+ name: 'newController',
96
+ type: 'address',
97
+ },
98
+ ],
99
+ name: 'ControlTransfer',
100
+ type: 'event',
101
+ },
102
+ {
103
+ anonymous: false,
104
+ inputs: [
105
+ {
106
+ indexed: true,
107
+ internalType: 'address',
108
+ name: 'split',
109
+ type: 'address',
110
+ },
111
+ ],
112
+ name: 'CreateSplit',
113
+ type: 'event',
114
+ },
115
+ {
116
+ anonymous: false,
117
+ inputs: [
118
+ {
119
+ indexed: true,
120
+ internalType: 'address',
121
+ name: 'split',
122
+ type: 'address',
123
+ },
124
+ {
125
+ indexed: true,
126
+ internalType: 'contract ERC20',
127
+ name: 'token',
128
+ type: 'address',
129
+ },
130
+ {
131
+ indexed: false,
132
+ internalType: 'uint256',
133
+ name: 'amount',
134
+ type: 'uint256',
135
+ },
136
+ {
137
+ indexed: true,
138
+ internalType: 'address',
139
+ name: 'distributorAddress',
140
+ type: 'address',
141
+ },
142
+ ],
143
+ name: 'DistributeERC20',
144
+ type: 'event',
145
+ },
146
+ {
147
+ anonymous: false,
148
+ inputs: [
149
+ {
150
+ indexed: true,
151
+ internalType: 'address',
152
+ name: 'split',
153
+ type: 'address',
154
+ },
155
+ {
156
+ indexed: false,
157
+ internalType: 'uint256',
158
+ name: 'amount',
159
+ type: 'uint256',
160
+ },
161
+ {
162
+ indexed: true,
163
+ internalType: 'address',
164
+ name: 'distributorAddress',
165
+ type: 'address',
166
+ },
167
+ ],
168
+ name: 'DistributeETH',
169
+ type: 'event',
170
+ },
171
+ {
172
+ anonymous: false,
173
+ inputs: [
174
+ {
175
+ indexed: true,
176
+ internalType: 'address',
177
+ name: 'split',
178
+ type: 'address',
179
+ },
180
+ {
181
+ indexed: true,
182
+ internalType: 'address',
183
+ name: 'newPotentialController',
184
+ type: 'address',
185
+ },
186
+ ],
187
+ name: 'InitiateControlTransfer',
188
+ type: 'event',
189
+ },
190
+ {
191
+ anonymous: false,
192
+ inputs: [
193
+ {
194
+ indexed: true,
195
+ internalType: 'address',
196
+ name: 'split',
197
+ type: 'address',
198
+ },
199
+ ],
200
+ name: 'UpdateSplit',
201
+ type: 'event',
202
+ },
203
+ {
204
+ anonymous: false,
205
+ inputs: [
206
+ {
207
+ indexed: true,
208
+ internalType: 'address',
209
+ name: 'account',
210
+ type: 'address',
211
+ },
212
+ {
213
+ indexed: false,
214
+ internalType: 'uint256',
215
+ name: 'ethAmount',
216
+ type: 'uint256',
217
+ },
218
+ {
219
+ indexed: false,
220
+ internalType: 'contract ERC20[]',
221
+ name: 'tokens',
222
+ type: 'address[]',
223
+ },
224
+ {
225
+ indexed: false,
226
+ internalType: 'uint256[]',
227
+ name: 'tokenAmounts',
228
+ type: 'uint256[]',
229
+ },
230
+ ],
231
+ name: 'Withdrawal',
232
+ type: 'event',
233
+ },
234
+ {
235
+ inputs: [],
236
+ name: 'PERCENTAGE_SCALE',
237
+ outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }],
238
+ stateMutability: 'view',
239
+ type: 'function',
240
+ },
241
+ {
242
+ inputs: [{ internalType: 'address', name: 'split', type: 'address' }],
243
+ name: 'acceptControl',
244
+ outputs: [],
245
+ stateMutability: 'nonpayable',
246
+ type: 'function',
247
+ },
248
+ {
249
+ inputs: [{ internalType: 'address', name: 'split', type: 'address' }],
250
+ name: 'cancelControlTransfer',
251
+ outputs: [],
252
+ stateMutability: 'nonpayable',
253
+ type: 'function',
254
+ },
255
+ {
256
+ inputs: [
257
+ { internalType: 'address[]', name: 'accounts', type: 'address[]' },
258
+ {
259
+ internalType: 'uint32[]',
260
+ name: 'percentAllocations',
261
+ type: 'uint32[]',
262
+ },
263
+ { internalType: 'uint32', name: 'distributorFee', type: 'uint32' },
264
+ { internalType: 'address', name: 'controller', type: 'address' },
265
+ ],
266
+ name: 'createSplit',
267
+ outputs: [{ internalType: 'address', name: 'split', type: 'address' }],
268
+ stateMutability: 'nonpayable',
269
+ type: 'function',
270
+ },
271
+ {
272
+ inputs: [
273
+ { internalType: 'address', name: 'split', type: 'address' },
274
+ { internalType: 'contract ERC20', name: 'token', type: 'address' },
275
+ { internalType: 'address[]', name: 'accounts', type: 'address[]' },
276
+ {
277
+ internalType: 'uint32[]',
278
+ name: 'percentAllocations',
279
+ type: 'uint32[]',
280
+ },
281
+ { internalType: 'uint32', name: 'distributorFee', type: 'uint32' },
282
+ { internalType: 'address', name: 'distributorAddress', type: 'address' },
283
+ ],
284
+ name: 'distributeERC20',
285
+ outputs: [],
286
+ stateMutability: 'nonpayable',
287
+ type: 'function',
288
+ },
289
+ {
290
+ inputs: [
291
+ { internalType: 'address', name: 'split', type: 'address' },
292
+ { internalType: 'address[]', name: 'accounts', type: 'address[]' },
293
+ {
294
+ internalType: 'uint32[]',
295
+ name: 'percentAllocations',
296
+ type: 'uint32[]',
297
+ },
298
+ { internalType: 'uint32', name: 'distributorFee', type: 'uint32' },
299
+ { internalType: 'address', name: 'distributorAddress', type: 'address' },
300
+ ],
301
+ name: 'distributeETH',
302
+ outputs: [],
303
+ stateMutability: 'nonpayable',
304
+ type: 'function',
305
+ },
306
+ {
307
+ inputs: [{ internalType: 'address', name: 'split', type: 'address' }],
308
+ name: 'getController',
309
+ outputs: [{ internalType: 'address', name: '', type: 'address' }],
310
+ stateMutability: 'view',
311
+ type: 'function',
312
+ },
313
+ {
314
+ inputs: [
315
+ { internalType: 'address', name: 'account', type: 'address' },
316
+ { internalType: 'contract ERC20', name: 'token', type: 'address' },
317
+ ],
318
+ name: 'getERC20Balance',
319
+ outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }],
320
+ stateMutability: 'view',
321
+ type: 'function',
322
+ },
323
+ {
324
+ inputs: [{ internalType: 'address', name: 'account', type: 'address' }],
325
+ name: 'getETHBalance',
326
+ outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }],
327
+ stateMutability: 'view',
328
+ type: 'function',
329
+ },
330
+ {
331
+ inputs: [{ internalType: 'address', name: 'split', type: 'address' }],
332
+ name: 'getHash',
333
+ outputs: [{ internalType: 'bytes32', name: '', type: 'bytes32' }],
334
+ stateMutability: 'view',
335
+ type: 'function',
336
+ },
337
+ {
338
+ inputs: [{ internalType: 'address', name: 'split', type: 'address' }],
339
+ name: 'getNewPotentialController',
340
+ outputs: [{ internalType: 'address', name: '', type: 'address' }],
341
+ stateMutability: 'view',
342
+ type: 'function',
343
+ },
344
+ {
345
+ inputs: [{ internalType: 'address', name: 'split', type: 'address' }],
346
+ name: 'makeSplitImmutable',
347
+ outputs: [],
348
+ stateMutability: 'nonpayable',
349
+ type: 'function',
350
+ },
351
+ {
352
+ inputs: [
353
+ { internalType: 'address[]', name: 'accounts', type: 'address[]' },
354
+ {
355
+ internalType: 'uint32[]',
356
+ name: 'percentAllocations',
357
+ type: 'uint32[]',
358
+ },
359
+ { internalType: 'uint32', name: 'distributorFee', type: 'uint32' },
360
+ ],
361
+ name: 'predictImmutableSplitAddress',
362
+ outputs: [{ internalType: 'address', name: 'split', type: 'address' }],
363
+ stateMutability: 'view',
364
+ type: 'function',
365
+ },
366
+ {
367
+ inputs: [
368
+ { internalType: 'address', name: 'split', type: 'address' },
369
+ { internalType: 'address', name: 'newController', type: 'address' },
370
+ ],
371
+ name: 'transferControl',
372
+ outputs: [],
373
+ stateMutability: 'nonpayable',
374
+ type: 'function',
375
+ },
376
+ {
377
+ inputs: [
378
+ { internalType: 'address', name: 'split', type: 'address' },
379
+ { internalType: 'contract ERC20', name: 'token', type: 'address' },
380
+ { internalType: 'address[]', name: 'accounts', type: 'address[]' },
381
+ {
382
+ internalType: 'uint32[]',
383
+ name: 'percentAllocations',
384
+ type: 'uint32[]',
385
+ },
386
+ { internalType: 'uint32', name: 'distributorFee', type: 'uint32' },
387
+ { internalType: 'address', name: 'distributorAddress', type: 'address' },
388
+ ],
389
+ name: 'updateAndDistributeERC20',
390
+ outputs: [],
391
+ stateMutability: 'nonpayable',
392
+ type: 'function',
393
+ },
394
+ {
395
+ inputs: [
396
+ { internalType: 'address', name: 'split', type: 'address' },
397
+ { internalType: 'address[]', name: 'accounts', type: 'address[]' },
398
+ {
399
+ internalType: 'uint32[]',
400
+ name: 'percentAllocations',
401
+ type: 'uint32[]',
402
+ },
403
+ { internalType: 'uint32', name: 'distributorFee', type: 'uint32' },
404
+ { internalType: 'address', name: 'distributorAddress', type: 'address' },
405
+ ],
406
+ name: 'updateAndDistributeETH',
407
+ outputs: [],
408
+ stateMutability: 'nonpayable',
409
+ type: 'function',
410
+ },
411
+ {
412
+ inputs: [
413
+ { internalType: 'address', name: 'split', type: 'address' },
414
+ { internalType: 'address[]', name: 'accounts', type: 'address[]' },
415
+ {
416
+ internalType: 'uint32[]',
417
+ name: 'percentAllocations',
418
+ type: 'uint32[]',
419
+ },
420
+ { internalType: 'uint32', name: 'distributorFee', type: 'uint32' },
421
+ ],
422
+ name: 'updateSplit',
423
+ outputs: [],
424
+ stateMutability: 'nonpayable',
425
+ type: 'function',
426
+ },
427
+ {
428
+ inputs: [],
429
+ name: 'walletImplementation',
430
+ outputs: [{ internalType: 'address', name: '', type: 'address' }],
431
+ stateMutability: 'view',
432
+ type: 'function',
433
+ },
434
+ {
435
+ inputs: [
436
+ { internalType: 'address', name: 'account', type: 'address' },
437
+ { internalType: 'uint256', name: 'withdrawETH', type: 'uint256' },
438
+ { internalType: 'contract ERC20[]', name: 'tokens', type: 'address[]' },
439
+ ],
440
+ name: 'withdraw',
441
+ outputs: [],
442
+ stateMutability: 'nonpayable',
443
+ type: 'function',
444
+ },
445
+ ];
446
+ exports.splitMainPolygonAbi = [
447
+ { inputs: [], stateMutability: 'nonpayable', type: 'constructor' },
448
+ { inputs: [], name: 'Create2Error', type: 'error' },
449
+ { inputs: [], name: 'CreateError', type: 'error' },
450
+ {
451
+ inputs: [
452
+ { internalType: 'address', name: 'newController', type: 'address' },
453
+ ],
454
+ name: 'InvalidNewController',
455
+ type: 'error',
456
+ },
457
+ {
458
+ inputs: [
459
+ { internalType: 'uint256', name: 'accountsLength', type: 'uint256' },
460
+ { internalType: 'uint256', name: 'allocationsLength', type: 'uint256' },
461
+ ],
462
+ name: 'InvalidSplit__AccountsAndAllocationsMismatch',
463
+ type: 'error',
464
+ },
465
+ {
466
+ inputs: [{ internalType: 'uint256', name: 'index', type: 'uint256' }],
467
+ name: 'InvalidSplit__AccountsOutOfOrder',
468
+ type: 'error',
469
+ },
470
+ {
471
+ inputs: [{ internalType: 'uint256', name: 'index', type: 'uint256' }],
472
+ name: 'InvalidSplit__AllocationMustBePositive',
473
+ type: 'error',
474
+ },
475
+ {
476
+ inputs: [
477
+ { internalType: 'uint32', name: 'allocationsSum', type: 'uint32' },
478
+ ],
479
+ name: 'InvalidSplit__InvalidAllocationsSum',
480
+ type: 'error',
481
+ },
482
+ {
483
+ inputs: [
484
+ { internalType: 'uint32', name: 'distributorFee', type: 'uint32' },
485
+ ],
486
+ name: 'InvalidSplit__InvalidDistributorFee',
487
+ type: 'error',
488
+ },
489
+ {
490
+ inputs: [{ internalType: 'bytes32', name: 'hash', type: 'bytes32' }],
491
+ name: 'InvalidSplit__InvalidHash',
492
+ type: 'error',
493
+ },
494
+ {
495
+ inputs: [
496
+ { internalType: 'uint256', name: 'accountsLength', type: 'uint256' },
497
+ ],
498
+ name: 'InvalidSplit__TooFewAccounts',
499
+ type: 'error',
500
+ },
501
+ {
502
+ inputs: [{ internalType: 'address', name: 'sender', type: 'address' }],
503
+ name: 'Unauthorized',
504
+ type: 'error',
505
+ },
506
+ {
507
+ anonymous: false,
508
+ inputs: [
509
+ {
510
+ indexed: true,
511
+ internalType: 'address',
512
+ name: 'split',
513
+ type: 'address',
514
+ },
515
+ ],
516
+ name: 'CancelControlTransfer',
517
+ type: 'event',
518
+ },
519
+ {
520
+ anonymous: false,
521
+ inputs: [
522
+ {
523
+ indexed: true,
524
+ internalType: 'address',
525
+ name: 'split',
526
+ type: 'address',
527
+ },
528
+ {
529
+ indexed: true,
530
+ internalType: 'address',
531
+ name: 'previousController',
532
+ type: 'address',
533
+ },
534
+ {
535
+ indexed: true,
536
+ internalType: 'address',
537
+ name: 'newController',
538
+ type: 'address',
539
+ },
540
+ ],
541
+ name: 'ControlTransfer',
542
+ type: 'event',
543
+ },
544
+ {
545
+ anonymous: false,
546
+ inputs: [
547
+ {
548
+ indexed: true,
549
+ internalType: 'address',
550
+ name: 'split',
551
+ type: 'address',
552
+ },
553
+ {
554
+ indexed: false,
555
+ internalType: 'address[]',
556
+ name: 'accounts',
557
+ type: 'address[]',
558
+ },
559
+ {
560
+ indexed: false,
561
+ internalType: 'uint32[]',
562
+ name: 'percentAllocations',
563
+ type: 'uint32[]',
564
+ },
565
+ {
566
+ indexed: false,
567
+ internalType: 'uint32',
568
+ name: 'distributorFee',
569
+ type: 'uint32',
570
+ },
571
+ {
572
+ indexed: false,
573
+ internalType: 'address',
574
+ name: 'controller',
575
+ type: 'address',
576
+ },
577
+ ],
578
+ name: 'CreateSplit',
579
+ type: 'event',
580
+ },
581
+ {
582
+ anonymous: false,
583
+ inputs: [
584
+ {
585
+ indexed: true,
586
+ internalType: 'address',
587
+ name: 'split',
588
+ type: 'address',
589
+ },
590
+ {
591
+ indexed: true,
592
+ internalType: 'contract ERC20',
593
+ name: 'token',
594
+ type: 'address',
595
+ },
596
+ {
597
+ indexed: false,
598
+ internalType: 'uint256',
599
+ name: 'amount',
600
+ type: 'uint256',
601
+ },
602
+ {
603
+ indexed: true,
604
+ internalType: 'address',
605
+ name: 'distributorAddress',
606
+ type: 'address',
607
+ },
608
+ ],
609
+ name: 'DistributeERC20',
610
+ type: 'event',
611
+ },
612
+ {
613
+ anonymous: false,
614
+ inputs: [
615
+ {
616
+ indexed: true,
617
+ internalType: 'address',
618
+ name: 'split',
619
+ type: 'address',
620
+ },
621
+ {
622
+ indexed: false,
623
+ internalType: 'uint256',
624
+ name: 'amount',
625
+ type: 'uint256',
626
+ },
627
+ {
628
+ indexed: true,
629
+ internalType: 'address',
630
+ name: 'distributorAddress',
631
+ type: 'address',
632
+ },
633
+ ],
634
+ name: 'DistributeETH',
635
+ type: 'event',
636
+ },
637
+ {
638
+ anonymous: false,
639
+ inputs: [
640
+ {
641
+ indexed: true,
642
+ internalType: 'address',
643
+ name: 'split',
644
+ type: 'address',
645
+ },
646
+ {
647
+ indexed: true,
648
+ internalType: 'address',
649
+ name: 'newPotentialController',
650
+ type: 'address',
651
+ },
652
+ ],
653
+ name: 'InitiateControlTransfer',
654
+ type: 'event',
655
+ },
656
+ {
657
+ anonymous: false,
658
+ inputs: [
659
+ {
660
+ indexed: true,
661
+ internalType: 'address',
662
+ name: 'split',
663
+ type: 'address',
664
+ },
665
+ {
666
+ indexed: false,
667
+ internalType: 'address[]',
668
+ name: 'accounts',
669
+ type: 'address[]',
670
+ },
671
+ {
672
+ indexed: false,
673
+ internalType: 'uint32[]',
674
+ name: 'percentAllocations',
675
+ type: 'uint32[]',
676
+ },
677
+ {
678
+ indexed: false,
679
+ internalType: 'uint32',
680
+ name: 'distributorFee',
681
+ type: 'uint32',
682
+ },
683
+ ],
684
+ name: 'UpdateSplit',
685
+ type: 'event',
686
+ },
687
+ {
688
+ anonymous: false,
689
+ inputs: [
690
+ {
691
+ indexed: true,
692
+ internalType: 'address',
693
+ name: 'account',
694
+ type: 'address',
695
+ },
696
+ {
697
+ indexed: false,
698
+ internalType: 'uint256',
699
+ name: 'ethAmount',
700
+ type: 'uint256',
701
+ },
702
+ {
703
+ indexed: false,
704
+ internalType: 'contract ERC20[]',
705
+ name: 'tokens',
706
+ type: 'address[]',
707
+ },
708
+ {
709
+ indexed: false,
710
+ internalType: 'uint256[]',
711
+ name: 'tokenAmounts',
712
+ type: 'uint256[]',
713
+ },
714
+ ],
715
+ name: 'Withdrawal',
716
+ type: 'event',
717
+ },
718
+ {
719
+ inputs: [],
720
+ name: 'PERCENTAGE_SCALE',
721
+ outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }],
722
+ stateMutability: 'view',
723
+ type: 'function',
724
+ },
725
+ {
726
+ inputs: [{ internalType: 'address', name: 'split', type: 'address' }],
727
+ name: 'acceptControl',
728
+ outputs: [],
729
+ stateMutability: 'nonpayable',
730
+ type: 'function',
731
+ },
732
+ {
733
+ inputs: [{ internalType: 'address', name: 'split', type: 'address' }],
734
+ name: 'cancelControlTransfer',
735
+ outputs: [],
736
+ stateMutability: 'nonpayable',
737
+ type: 'function',
738
+ },
739
+ {
740
+ inputs: [
741
+ { internalType: 'address[]', name: 'accounts', type: 'address[]' },
742
+ {
743
+ internalType: 'uint32[]',
744
+ name: 'percentAllocations',
745
+ type: 'uint32[]',
746
+ },
747
+ { internalType: 'uint32', name: 'distributorFee', type: 'uint32' },
748
+ { internalType: 'address', name: 'controller', type: 'address' },
749
+ ],
750
+ name: 'createSplit',
751
+ outputs: [{ internalType: 'address', name: 'split', type: 'address' }],
752
+ stateMutability: 'nonpayable',
753
+ type: 'function',
754
+ },
755
+ {
756
+ inputs: [
757
+ { internalType: 'address', name: 'split', type: 'address' },
758
+ { internalType: 'contract ERC20', name: 'token', type: 'address' },
759
+ { internalType: 'address[]', name: 'accounts', type: 'address[]' },
760
+ {
761
+ internalType: 'uint32[]',
762
+ name: 'percentAllocations',
763
+ type: 'uint32[]',
764
+ },
765
+ { internalType: 'uint32', name: 'distributorFee', type: 'uint32' },
766
+ { internalType: 'address', name: 'distributorAddress', type: 'address' },
767
+ ],
768
+ name: 'distributeERC20',
769
+ outputs: [],
770
+ stateMutability: 'nonpayable',
771
+ type: 'function',
772
+ },
773
+ {
774
+ inputs: [
775
+ { internalType: 'address', name: 'split', type: 'address' },
776
+ { internalType: 'address[]', name: 'accounts', type: 'address[]' },
777
+ {
778
+ internalType: 'uint32[]',
779
+ name: 'percentAllocations',
780
+ type: 'uint32[]',
781
+ },
782
+ { internalType: 'uint32', name: 'distributorFee', type: 'uint32' },
783
+ { internalType: 'address', name: 'distributorAddress', type: 'address' },
784
+ ],
785
+ name: 'distributeETH',
786
+ outputs: [],
787
+ stateMutability: 'nonpayable',
788
+ type: 'function',
789
+ },
790
+ {
791
+ inputs: [{ internalType: 'address', name: 'split', type: 'address' }],
792
+ name: 'getController',
793
+ outputs: [{ internalType: 'address', name: '', type: 'address' }],
794
+ stateMutability: 'view',
795
+ type: 'function',
796
+ },
797
+ {
798
+ inputs: [
799
+ { internalType: 'address', name: 'account', type: 'address' },
800
+ { internalType: 'contract ERC20', name: 'token', type: 'address' },
801
+ ],
802
+ name: 'getERC20Balance',
803
+ outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }],
804
+ stateMutability: 'view',
805
+ type: 'function',
806
+ },
807
+ {
808
+ inputs: [{ internalType: 'address', name: 'account', type: 'address' }],
809
+ name: 'getETHBalance',
810
+ outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }],
811
+ stateMutability: 'view',
812
+ type: 'function',
813
+ },
814
+ {
815
+ inputs: [{ internalType: 'address', name: 'split', type: 'address' }],
816
+ name: 'getHash',
817
+ outputs: [{ internalType: 'bytes32', name: '', type: 'bytes32' }],
818
+ stateMutability: 'view',
819
+ type: 'function',
820
+ },
821
+ {
822
+ inputs: [{ internalType: 'address', name: 'split', type: 'address' }],
823
+ name: 'getNewPotentialController',
824
+ outputs: [{ internalType: 'address', name: '', type: 'address' }],
825
+ stateMutability: 'view',
826
+ type: 'function',
827
+ },
828
+ {
829
+ inputs: [{ internalType: 'address', name: 'split', type: 'address' }],
830
+ name: 'makeSplitImmutable',
831
+ outputs: [],
832
+ stateMutability: 'nonpayable',
833
+ type: 'function',
834
+ },
835
+ {
836
+ inputs: [
837
+ { internalType: 'address[]', name: 'accounts', type: 'address[]' },
838
+ {
839
+ internalType: 'uint32[]',
840
+ name: 'percentAllocations',
841
+ type: 'uint32[]',
842
+ },
843
+ { internalType: 'uint32', name: 'distributorFee', type: 'uint32' },
844
+ ],
845
+ name: 'predictImmutableSplitAddress',
846
+ outputs: [{ internalType: 'address', name: 'split', type: 'address' }],
847
+ stateMutability: 'view',
848
+ type: 'function',
849
+ },
850
+ {
851
+ inputs: [
852
+ { internalType: 'address', name: 'split', type: 'address' },
853
+ { internalType: 'address', name: 'newController', type: 'address' },
854
+ ],
855
+ name: 'transferControl',
856
+ outputs: [],
857
+ stateMutability: 'nonpayable',
858
+ type: 'function',
859
+ },
860
+ {
861
+ inputs: [
862
+ { internalType: 'address', name: 'split', type: 'address' },
863
+ { internalType: 'contract ERC20', name: 'token', type: 'address' },
864
+ { internalType: 'address[]', name: 'accounts', type: 'address[]' },
865
+ {
866
+ internalType: 'uint32[]',
867
+ name: 'percentAllocations',
868
+ type: 'uint32[]',
869
+ },
870
+ { internalType: 'uint32', name: 'distributorFee', type: 'uint32' },
871
+ { internalType: 'address', name: 'distributorAddress', type: 'address' },
872
+ ],
873
+ name: 'updateAndDistributeERC20',
874
+ outputs: [],
875
+ stateMutability: 'nonpayable',
876
+ type: 'function',
877
+ },
878
+ {
879
+ inputs: [
880
+ { internalType: 'address', name: 'split', type: 'address' },
881
+ { internalType: 'address[]', name: 'accounts', type: 'address[]' },
882
+ {
883
+ internalType: 'uint32[]',
884
+ name: 'percentAllocations',
885
+ type: 'uint32[]',
886
+ },
887
+ { internalType: 'uint32', name: 'distributorFee', type: 'uint32' },
888
+ { internalType: 'address', name: 'distributorAddress', type: 'address' },
889
+ ],
890
+ name: 'updateAndDistributeETH',
891
+ outputs: [],
892
+ stateMutability: 'nonpayable',
893
+ type: 'function',
894
+ },
895
+ {
896
+ inputs: [
897
+ { internalType: 'address', name: 'split', type: 'address' },
898
+ { internalType: 'address[]', name: 'accounts', type: 'address[]' },
899
+ {
900
+ internalType: 'uint32[]',
901
+ name: 'percentAllocations',
902
+ type: 'uint32[]',
903
+ },
904
+ { internalType: 'uint32', name: 'distributorFee', type: 'uint32' },
905
+ ],
906
+ name: 'updateSplit',
907
+ outputs: [],
908
+ stateMutability: 'nonpayable',
909
+ type: 'function',
910
+ },
911
+ {
912
+ inputs: [],
913
+ name: 'walletImplementation',
914
+ outputs: [{ internalType: 'address', name: '', type: 'address' }],
915
+ stateMutability: 'view',
916
+ type: 'function',
917
+ },
918
+ {
919
+ inputs: [
920
+ { internalType: 'address', name: 'account', type: 'address' },
921
+ { internalType: 'uint256', name: 'withdrawETH', type: 'uint256' },
922
+ { internalType: 'contract ERC20[]', name: 'tokens', type: 'address[]' },
923
+ ],
924
+ name: 'withdraw',
925
+ outputs: [],
926
+ stateMutability: 'nonpayable',
927
+ type: 'function',
928
+ },
929
+ ];