@pushchain/core 2.1.11 → 3.0.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 (35) hide show
  1. package/CHANGELOG.md +6 -0
  2. package/package.json +4 -3
  3. package/src/lib/constants/abi/erc20.evm.d.ts +33 -0
  4. package/src/lib/constants/abi/erc20.evm.js +19 -0
  5. package/src/lib/constants/abi/erc20.evm.js.map +1 -1
  6. package/src/lib/constants/abi/universalGatewayV0.evm.d.ts +56 -9
  7. package/src/lib/constants/abi/universalGatewayV0.evm.js +1023 -64
  8. package/src/lib/constants/abi/universalGatewayV0.evm.js.map +1 -1
  9. package/src/lib/constants/abi/universalGatewayV0.json +1223 -206
  10. package/src/lib/constants/chain.d.ts +4 -0
  11. package/src/lib/constants/chain.js +24 -2
  12. package/src/lib/constants/chain.js.map +1 -1
  13. package/src/lib/constants/tokens.d.ts +1 -0
  14. package/src/lib/constants/tokens.js +3 -0
  15. package/src/lib/constants/tokens.js.map +1 -1
  16. package/src/lib/generated/v1/tx.d.ts +1 -2
  17. package/src/lib/generated/v1/tx.js +2 -1
  18. package/src/lib/generated/v1/tx.js.map +1 -1
  19. package/src/lib/orchestrator/orchestrator.d.ts +6 -2
  20. package/src/lib/orchestrator/orchestrator.js +645 -336
  21. package/src/lib/orchestrator/orchestrator.js.map +1 -1
  22. package/src/lib/orchestrator/payload-builders.d.ts +5 -0
  23. package/src/lib/orchestrator/payload-builders.js +58 -0
  24. package/src/lib/orchestrator/payload-builders.js.map +1 -0
  25. package/src/lib/push-chain/helpers/abis.d.ts +31 -0
  26. package/src/lib/push-chain/helpers/abis.js +75 -0
  27. package/src/lib/push-chain/helpers/abis.js.map +1 -0
  28. package/src/lib/push-chain/helpers/addresses.d.ts +1 -0
  29. package/src/lib/push-chain/helpers/addresses.js +5 -0
  30. package/src/lib/push-chain/helpers/addresses.js.map +1 -0
  31. package/src/lib/utils.d.ts +9 -0
  32. package/src/lib/utils.js +73 -0
  33. package/src/lib/utils.js.map +1 -1
  34. package/src/lib/vm-client/svm-client.js +26 -3
  35. package/src/lib/vm-client/svm-client.js.map +1 -1
@@ -2,140 +2,1099 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.UNIVERSAL_GATEWAY_V0 = void 0;
4
4
  exports.UNIVERSAL_GATEWAY_V0 = [
5
+ { inputs: [], name: 'AccessControlBadConfirmation', type: 'error' },
5
6
  {
7
+ inputs: [
8
+ { internalType: 'address', name: 'account', type: 'address' },
9
+ { internalType: 'bytes32', name: 'neededRole', type: 'bytes32' },
10
+ ],
11
+ name: 'AccessControlUnauthorizedAccount',
12
+ type: 'error',
13
+ },
14
+ { inputs: [], name: 'BlockCapLimitExceeded', type: 'error' },
15
+ { inputs: [], name: 'DepositFailed', type: 'error' },
16
+ { inputs: [], name: 'EnforcedPause', type: 'error' },
17
+ { inputs: [], name: 'ExpectedPause', type: 'error' },
18
+ { inputs: [], name: 'InvalidAmount', type: 'error' },
19
+ { inputs: [], name: 'InvalidCapRange', type: 'error' },
20
+ { inputs: [], name: 'InvalidData', type: 'error' },
21
+ { inputs: [], name: 'InvalidInitialization', type: 'error' },
22
+ { inputs: [], name: 'InvalidInput', type: 'error' },
23
+ { inputs: [], name: 'InvalidRecipient', type: 'error' },
24
+ { inputs: [], name: 'InvalidTxType', type: 'error' },
25
+ { inputs: [], name: 'NotInitializing', type: 'error' },
26
+ { inputs: [], name: 'NotSupported', type: 'error' },
27
+ { inputs: [], name: 'ReentrancyGuardReentrantCall', type: 'error' },
28
+ {
29
+ inputs: [{ internalType: 'address', name: 'token', type: 'address' }],
30
+ name: 'SafeERC20FailedOperation',
31
+ type: 'error',
32
+ },
33
+ { inputs: [], name: 'SlippageExceededOrExpired', type: 'error' },
34
+ { inputs: [], name: 'WithdrawFailed', type: 'error' },
35
+ { inputs: [], name: 'ZeroAddress', type: 'error' },
36
+ {
37
+ anonymous: false,
38
+ inputs: [
39
+ {
40
+ indexed: false,
41
+ internalType: 'uint256',
42
+ name: 'minCapUsd',
43
+ type: 'uint256',
44
+ },
45
+ {
46
+ indexed: false,
47
+ internalType: 'uint256',
48
+ name: 'maxCapUsd',
49
+ type: 'uint256',
50
+ },
51
+ ],
52
+ name: 'CapsUpdated',
53
+ type: 'event',
54
+ },
55
+ {
56
+ anonymous: false,
57
+ inputs: [
58
+ {
59
+ indexed: false,
60
+ internalType: 'uint256',
61
+ name: 'oldDuration',
62
+ type: 'uint256',
63
+ },
64
+ {
65
+ indexed: false,
66
+ internalType: 'uint256',
67
+ name: 'newDuration',
68
+ type: 'uint256',
69
+ },
70
+ ],
71
+ name: 'EpochDurationUpdated',
72
+ type: 'event',
73
+ },
74
+ {
75
+ anonymous: false,
76
+ inputs: [
77
+ { indexed: true, internalType: 'address', name: 'user', type: 'address' },
78
+ {
79
+ indexed: true,
80
+ internalType: 'bytes32',
81
+ name: 'transactionHash',
82
+ type: 'bytes32',
83
+ },
84
+ {
85
+ components: [
86
+ { internalType: 'uint256', name: 'amountInUSD', type: 'uint256' },
87
+ { internalType: 'uint8', name: 'decimals', type: 'uint8' },
88
+ ],
89
+ indexed: false,
90
+ internalType: 'struct UniversalGatewayV0.AmountInUSD',
91
+ name: 'AmountInUSD',
92
+ type: 'tuple',
93
+ },
94
+ ],
95
+ name: 'FundsAdded',
96
+ type: 'event',
97
+ },
98
+ {
99
+ anonymous: false,
100
+ inputs: [
101
+ {
102
+ indexed: false,
103
+ internalType: 'uint64',
104
+ name: 'version',
105
+ type: 'uint64',
106
+ },
107
+ ],
108
+ name: 'Initialized',
109
+ type: 'event',
110
+ },
111
+ {
112
+ anonymous: false,
113
+ inputs: [
114
+ {
115
+ indexed: false,
116
+ internalType: 'address',
117
+ name: 'account',
118
+ type: 'address',
119
+ },
120
+ ],
121
+ name: 'Paused',
122
+ type: 'event',
123
+ },
124
+ {
125
+ anonymous: false,
126
+ inputs: [
127
+ { indexed: true, internalType: 'bytes32', name: 'role', type: 'bytes32' },
128
+ {
129
+ indexed: true,
130
+ internalType: 'bytes32',
131
+ name: 'previousAdminRole',
132
+ type: 'bytes32',
133
+ },
134
+ {
135
+ indexed: true,
136
+ internalType: 'bytes32',
137
+ name: 'newAdminRole',
138
+ type: 'bytes32',
139
+ },
140
+ ],
141
+ name: 'RoleAdminChanged',
142
+ type: 'event',
143
+ },
144
+ {
145
+ anonymous: false,
146
+ inputs: [
147
+ { indexed: true, internalType: 'bytes32', name: 'role', type: 'bytes32' },
148
+ {
149
+ indexed: true,
150
+ internalType: 'address',
151
+ name: 'account',
152
+ type: 'address',
153
+ },
154
+ {
155
+ indexed: true,
156
+ internalType: 'address',
157
+ name: 'sender',
158
+ type: 'address',
159
+ },
160
+ ],
161
+ name: 'RoleGranted',
162
+ type: 'event',
163
+ },
164
+ {
165
+ anonymous: false,
166
+ inputs: [
167
+ { indexed: true, internalType: 'bytes32', name: 'role', type: 'bytes32' },
168
+ {
169
+ indexed: true,
170
+ internalType: 'address',
171
+ name: 'account',
172
+ type: 'address',
173
+ },
174
+ {
175
+ indexed: true,
176
+ internalType: 'address',
177
+ name: 'sender',
178
+ type: 'address',
179
+ },
180
+ ],
181
+ name: 'RoleRevoked',
182
+ type: 'event',
183
+ },
184
+ {
185
+ anonymous: false,
186
+ inputs: [
187
+ {
188
+ indexed: true,
189
+ internalType: 'address',
190
+ name: 'token',
191
+ type: 'address',
192
+ },
193
+ {
194
+ indexed: false,
195
+ internalType: 'uint256',
196
+ name: 'newThreshold',
197
+ type: 'uint256',
198
+ },
199
+ ],
200
+ name: 'TokenLimitThresholdUpdated',
201
+ type: 'event',
202
+ },
203
+ {
204
+ anonymous: false,
205
+ inputs: [
206
+ {
207
+ indexed: true,
208
+ internalType: 'address',
209
+ name: 'sender',
210
+ type: 'address',
211
+ },
212
+ {
213
+ indexed: true,
214
+ internalType: 'address',
215
+ name: 'recipient',
216
+ type: 'address',
217
+ },
218
+ {
219
+ indexed: false,
220
+ internalType: 'address',
221
+ name: 'token',
222
+ type: 'address',
223
+ },
224
+ {
225
+ indexed: false,
226
+ internalType: 'uint256',
227
+ name: 'amount',
228
+ type: 'uint256',
229
+ },
230
+ { indexed: false, internalType: 'bytes', name: 'payload', type: 'bytes' },
231
+ {
232
+ components: [
233
+ { internalType: 'address', name: 'fundRecipient', type: 'address' },
234
+ { internalType: 'bytes', name: 'revertMsg', type: 'bytes' },
235
+ ],
236
+ indexed: false,
237
+ internalType: 'struct RevertInstructions',
238
+ name: 'revertInstruction',
239
+ type: 'tuple',
240
+ },
241
+ {
242
+ indexed: false,
243
+ internalType: 'enum TX_TYPE',
244
+ name: 'txType',
245
+ type: 'uint8',
246
+ },
247
+ {
248
+ indexed: false,
249
+ internalType: 'bytes',
250
+ name: 'signatureData',
251
+ type: 'bytes',
252
+ },
253
+ ],
254
+ name: 'UniversalTx',
255
+ type: 'event',
256
+ },
257
+ {
258
+ anonymous: false,
259
+ inputs: [
260
+ {
261
+ indexed: false,
262
+ internalType: 'address',
263
+ name: 'account',
264
+ type: 'address',
265
+ },
266
+ ],
267
+ name: 'Unpaused',
268
+ type: 'event',
269
+ },
270
+ {
271
+ anonymous: false,
272
+ inputs: [
273
+ {
274
+ indexed: true,
275
+ internalType: 'address',
276
+ name: 'recipient',
277
+ type: 'address',
278
+ },
279
+ {
280
+ indexed: false,
281
+ internalType: 'uint256',
282
+ name: 'amount',
283
+ type: 'uint256',
284
+ },
285
+ {
286
+ indexed: false,
287
+ internalType: 'address',
288
+ name: 'tokenAddress',
289
+ type: 'address',
290
+ },
291
+ ],
292
+ name: 'WithdrawFunds',
293
+ type: 'event',
294
+ },
295
+ {
296
+ inputs: [],
297
+ name: 'BLOCK_USD_CAP',
298
+ outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }],
299
+ stateMutability: 'view',
300
+ type: 'function',
301
+ },
302
+ {
303
+ inputs: [],
304
+ name: 'DEFAULT_ADMIN_ROLE',
305
+ outputs: [{ internalType: 'bytes32', name: '', type: 'bytes32' }],
306
+ stateMutability: 'view',
307
+ type: 'function',
308
+ },
309
+ {
310
+ inputs: [],
311
+ name: 'MAX_CAP_UNIVERSAL_TX_USD',
312
+ outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }],
313
+ stateMutability: 'view',
314
+ type: 'function',
315
+ },
316
+ {
317
+ inputs: [],
318
+ name: 'MIN_CAP_UNIVERSAL_TX_USD',
319
+ outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }],
320
+ stateMutability: 'view',
321
+ type: 'function',
322
+ },
323
+ {
324
+ inputs: [],
325
+ name: 'PAUSER_ROLE',
326
+ outputs: [{ internalType: 'bytes32', name: '', type: 'bytes32' }],
327
+ stateMutability: 'view',
328
+ type: 'function',
329
+ },
330
+ {
331
+ inputs: [],
332
+ name: 'POOL_FEE',
333
+ outputs: [{ internalType: 'uint24', name: '', type: 'uint24' }],
334
+ stateMutability: 'view',
335
+ type: 'function',
336
+ },
337
+ {
338
+ inputs: [],
339
+ name: 'TSS_ADDRESS',
340
+ outputs: [{ internalType: 'address', name: '', type: 'address' }],
341
+ stateMutability: 'view',
342
+ type: 'function',
343
+ },
344
+ {
345
+ inputs: [],
346
+ name: 'TSS_ROLE',
347
+ outputs: [{ internalType: 'bytes32', name: '', type: 'bytes32' }],
348
+ stateMutability: 'view',
349
+ type: 'function',
350
+ },
351
+ {
352
+ inputs: [],
353
+ name: 'USDT',
354
+ outputs: [{ internalType: 'address', name: '', type: 'address' }],
355
+ stateMutability: 'view',
356
+ type: 'function',
357
+ },
358
+ {
359
+ inputs: [],
360
+ name: 'WETH',
361
+ outputs: [{ internalType: 'address', name: '', type: 'address' }],
362
+ stateMutability: 'view',
363
+ type: 'function',
364
+ },
365
+ {
366
+ inputs: [{ internalType: 'uint256', name: 'amountWei', type: 'uint256' }],
367
+ name: '_checkBlockUSDCap',
368
+ outputs: [],
369
+ stateMutability: 'nonpayable',
370
+ type: 'function',
371
+ },
372
+ {
373
+ inputs: [{ internalType: 'uint256', name: 'amount', type: 'uint256' }],
374
+ name: '_checkUSDCaps',
375
+ outputs: [],
376
+ stateMutability: 'view',
6
377
  type: 'function',
378
+ },
379
+ {
380
+ inputs: [
381
+ { internalType: 'bytes32', name: '_transactionHash', type: 'bytes32' },
382
+ ],
383
+ name: 'addFunds',
384
+ outputs: [],
385
+ stateMutability: 'payable',
386
+ type: 'function',
387
+ },
388
+ {
389
+ inputs: [],
390
+ name: 'chainlinkEthUsdDecimals',
391
+ outputs: [{ internalType: 'uint8', name: '', type: 'uint8' }],
392
+ stateMutability: 'view',
393
+ type: 'function',
394
+ },
395
+ {
396
+ inputs: [],
397
+ name: 'chainlinkStalePeriod',
398
+ outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }],
399
+ stateMutability: 'view',
400
+ type: 'function',
401
+ },
402
+ {
403
+ inputs: [{ internalType: 'address', name: 'token', type: 'address' }],
404
+ name: 'currentTokenUsage',
405
+ outputs: [
406
+ { internalType: 'uint256', name: 'used', type: 'uint256' },
407
+ { internalType: 'uint256', name: 'remaining', type: 'uint256' },
408
+ ],
409
+ stateMutability: 'view',
410
+ type: 'function',
411
+ },
412
+ {
413
+ inputs: [],
414
+ name: 'defaultSwapDeadlineSec',
415
+ outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }],
416
+ stateMutability: 'view',
417
+ type: 'function',
418
+ },
419
+ {
420
+ inputs: [],
421
+ name: 'epochDurationSec',
422
+ outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }],
423
+ stateMutability: 'view',
424
+ type: 'function',
425
+ },
426
+ {
427
+ inputs: [],
428
+ name: 'ethUsdFeed',
429
+ outputs: [
430
+ {
431
+ internalType: 'contract AggregatorV3Interface',
432
+ name: '',
433
+ type: 'address',
434
+ },
435
+ ],
436
+ stateMutability: 'view',
437
+ type: 'function',
438
+ },
439
+ {
440
+ inputs: [],
441
+ name: 'getEthUsdPrice',
442
+ outputs: [
443
+ { internalType: 'uint256', name: '', type: 'uint256' },
444
+ { internalType: 'uint8', name: '', type: 'uint8' },
445
+ ],
446
+ stateMutability: 'view',
447
+ type: 'function',
448
+ },
449
+ {
450
+ inputs: [],
451
+ name: 'getEthUsdPrice_old',
452
+ outputs: [
453
+ { internalType: 'uint256', name: '', type: 'uint256' },
454
+ { internalType: 'uint8', name: '', type: 'uint8' },
455
+ ],
456
+ stateMutability: 'view',
457
+ type: 'function',
458
+ },
459
+ {
460
+ inputs: [],
7
461
  name: 'getMinMaxValueForNative',
462
+ outputs: [
463
+ { internalType: 'uint256', name: 'minValue', type: 'uint256' },
464
+ { internalType: 'uint256', name: 'maxValue', type: 'uint256' },
465
+ ],
466
+ stateMutability: 'view',
467
+ type: 'function',
468
+ },
469
+ {
470
+ inputs: [{ internalType: 'bytes32', name: 'role', type: 'bytes32' }],
471
+ name: 'getRoleAdmin',
472
+ outputs: [{ internalType: 'bytes32', name: '', type: 'bytes32' }],
473
+ stateMutability: 'view',
474
+ type: 'function',
475
+ },
476
+ {
477
+ inputs: [
478
+ { internalType: 'bytes32', name: 'role', type: 'bytes32' },
479
+ { internalType: 'address', name: 'account', type: 'address' },
480
+ ],
481
+ name: 'grantRole',
482
+ outputs: [],
483
+ stateMutability: 'nonpayable',
484
+ type: 'function',
485
+ },
486
+ {
487
+ inputs: [
488
+ { internalType: 'bytes32', name: 'role', type: 'bytes32' },
489
+ { internalType: 'address', name: 'account', type: 'address' },
490
+ ],
491
+ name: 'hasRole',
492
+ outputs: [{ internalType: 'bool', name: '', type: 'bool' }],
493
+ stateMutability: 'view',
494
+ type: 'function',
495
+ },
496
+ {
497
+ inputs: [
498
+ { internalType: 'address', name: 'admin', type: 'address' },
499
+ { internalType: 'address', name: 'pauser', type: 'address' },
500
+ { internalType: 'address', name: 'tss', type: 'address' },
501
+ { internalType: 'uint256', name: 'minCapUsd', type: 'uint256' },
502
+ { internalType: 'uint256', name: 'maxCapUsd', type: 'uint256' },
503
+ { internalType: 'address', name: 'factory', type: 'address' },
504
+ { internalType: 'address', name: 'router', type: 'address' },
505
+ { internalType: 'address', name: '_wethAddress', type: 'address' },
506
+ { internalType: 'address', name: '_usdtAddress', type: 'address' },
507
+ { internalType: 'address', name: '_usdtUsdPriceFeed', type: 'address' },
508
+ { internalType: 'address', name: '_ethUsdPriceFeed', type: 'address' },
509
+ ],
510
+ name: 'initialize',
511
+ outputs: [],
512
+ stateMutability: 'nonpayable',
513
+ type: 'function',
514
+ },
515
+ {
516
+ inputs: [{ internalType: 'address', name: '', type: 'address' }],
517
+ name: 'isSupportedToken',
518
+ outputs: [{ internalType: 'bool', name: '', type: 'bool' }],
519
+ stateMutability: 'view',
520
+ type: 'function',
521
+ },
522
+ {
8
523
  inputs: [],
524
+ name: 'l2SequencerFeed',
9
525
  outputs: [
10
- { name: 'minValue', type: 'uint256', internalType: 'uint256' },
11
- { name: 'maxValue', type: 'uint256', internalType: 'uint256' },
526
+ {
527
+ internalType: 'contract AggregatorV3Interface',
528
+ name: '',
529
+ type: 'address',
530
+ },
531
+ ],
532
+ stateMutability: 'view',
533
+ type: 'function',
534
+ },
535
+ {
536
+ inputs: [],
537
+ name: 'l2SequencerGracePeriodSec',
538
+ outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }],
539
+ stateMutability: 'view',
540
+ type: 'function',
541
+ },
542
+ {
543
+ inputs: [
544
+ { internalType: 'address[]', name: 'tokens', type: 'address[]' },
545
+ { internalType: 'bool[]', name: 'isSupported', type: 'bool[]' },
546
+ ],
547
+ name: 'modifySupportForToken',
548
+ outputs: [],
549
+ stateMutability: 'nonpayable',
550
+ type: 'function',
551
+ },
552
+ {
553
+ inputs: [],
554
+ name: 'pause',
555
+ outputs: [],
556
+ stateMutability: 'nonpayable',
557
+ type: 'function',
558
+ },
559
+ {
560
+ inputs: [],
561
+ name: 'paused',
562
+ outputs: [{ internalType: 'bool', name: '', type: 'bool' }],
563
+ stateMutability: 'view',
564
+ type: 'function',
565
+ },
566
+ {
567
+ inputs: [{ internalType: 'uint256', name: 'amountWei', type: 'uint256' }],
568
+ name: 'quoteEthAmountInUsd1e18',
569
+ outputs: [{ internalType: 'uint256', name: 'usd1e18', type: 'uint256' }],
570
+ stateMutability: 'view',
571
+ type: 'function',
572
+ },
573
+ {
574
+ inputs: [
575
+ { internalType: 'bytes32', name: 'role', type: 'bytes32' },
576
+ { internalType: 'address', name: 'callerConfirmation', type: 'address' },
577
+ ],
578
+ name: 'renounceRole',
579
+ outputs: [],
580
+ stateMutability: 'nonpayable',
581
+ type: 'function',
582
+ },
583
+ {
584
+ inputs: [
585
+ { internalType: 'address', name: 'token', type: 'address' },
586
+ { internalType: 'uint256', name: 'amount', type: 'uint256' },
587
+ {
588
+ components: [
589
+ { internalType: 'address', name: 'fundRecipient', type: 'address' },
590
+ { internalType: 'bytes', name: 'revertMsg', type: 'bytes' },
591
+ ],
592
+ internalType: 'struct RevertInstructions',
593
+ name: 'revertInstruction',
594
+ type: 'tuple',
595
+ },
596
+ ],
597
+ name: 'revertWithdrawFunds',
598
+ outputs: [],
599
+ stateMutability: 'nonpayable',
600
+ type: 'function',
601
+ },
602
+ {
603
+ inputs: [
604
+ { internalType: 'bytes32', name: 'role', type: 'bytes32' },
605
+ { internalType: 'address', name: 'account', type: 'address' },
606
+ ],
607
+ name: 'revokeRole',
608
+ outputs: [],
609
+ stateMutability: 'nonpayable',
610
+ type: 'function',
611
+ },
612
+ {
613
+ inputs: [
614
+ { internalType: 'address', name: 'recipient', type: 'address' },
615
+ { internalType: 'address', name: 'bridgeToken', type: 'address' },
616
+ { internalType: 'uint256', name: 'bridgeAmount', type: 'uint256' },
617
+ {
618
+ components: [
619
+ { internalType: 'address', name: 'fundRecipient', type: 'address' },
620
+ { internalType: 'bytes', name: 'revertMsg', type: 'bytes' },
621
+ ],
622
+ internalType: 'struct RevertInstructions',
623
+ name: 'revertInstruction',
624
+ type: 'tuple',
625
+ },
626
+ ],
627
+ name: 'sendFunds',
628
+ outputs: [],
629
+ stateMutability: 'payable',
630
+ type: 'function',
631
+ },
632
+ {
633
+ inputs: [
634
+ { internalType: 'address', name: 'bridgeToken', type: 'address' },
635
+ { internalType: 'uint256', name: 'bridgeAmount', type: 'uint256' },
636
+ { internalType: 'address', name: 'gasToken', type: 'address' },
637
+ { internalType: 'uint256', name: 'gasAmount', type: 'uint256' },
638
+ { internalType: 'uint256', name: 'amountOutMinETH', type: 'uint256' },
639
+ { internalType: 'uint256', name: 'deadline', type: 'uint256' },
640
+ {
641
+ components: [
642
+ { internalType: 'address', name: 'to', type: 'address' },
643
+ { internalType: 'uint256', name: 'value', type: 'uint256' },
644
+ { internalType: 'bytes', name: 'data', type: 'bytes' },
645
+ { internalType: 'uint256', name: 'gasLimit', type: 'uint256' },
646
+ { internalType: 'uint256', name: 'maxFeePerGas', type: 'uint256' },
647
+ {
648
+ internalType: 'uint256',
649
+ name: 'maxPriorityFeePerGas',
650
+ type: 'uint256',
651
+ },
652
+ { internalType: 'uint256', name: 'nonce', type: 'uint256' },
653
+ { internalType: 'uint256', name: 'deadline', type: 'uint256' },
654
+ {
655
+ internalType: 'enum VerificationType',
656
+ name: 'vType',
657
+ type: 'uint8',
658
+ },
659
+ ],
660
+ internalType: 'struct UniversalPayload',
661
+ name: 'payload',
662
+ type: 'tuple',
663
+ },
664
+ {
665
+ components: [
666
+ { internalType: 'address', name: 'fundRecipient', type: 'address' },
667
+ { internalType: 'bytes', name: 'revertMsg', type: 'bytes' },
668
+ ],
669
+ internalType: 'struct RevertInstructions',
670
+ name: 'revertInstruction',
671
+ type: 'tuple',
672
+ },
673
+ { internalType: 'bytes', name: 'signatureData', type: 'bytes' },
12
674
  ],
13
- stateMutability: 'view',
675
+ name: 'sendTxWithFunds',
676
+ outputs: [],
677
+ stateMutability: 'nonpayable',
678
+ type: 'function',
14
679
  },
15
680
  {
16
- type: 'function',
17
- name: 'addFunds',
18
681
  inputs: [
682
+ { internalType: 'address', name: 'bridgeToken', type: 'address' },
683
+ { internalType: 'uint256', name: 'bridgeAmount', type: 'uint256' },
19
684
  {
20
- name: '_transactionHash',
21
- type: 'bytes32',
22
- internalType: 'bytes32',
685
+ components: [
686
+ { internalType: 'address', name: 'to', type: 'address' },
687
+ { internalType: 'uint256', name: 'value', type: 'uint256' },
688
+ { internalType: 'bytes', name: 'data', type: 'bytes' },
689
+ { internalType: 'uint256', name: 'gasLimit', type: 'uint256' },
690
+ { internalType: 'uint256', name: 'maxFeePerGas', type: 'uint256' },
691
+ {
692
+ internalType: 'uint256',
693
+ name: 'maxPriorityFeePerGas',
694
+ type: 'uint256',
695
+ },
696
+ { internalType: 'uint256', name: 'nonce', type: 'uint256' },
697
+ { internalType: 'uint256', name: 'deadline', type: 'uint256' },
698
+ {
699
+ internalType: 'enum VerificationType',
700
+ name: 'vType',
701
+ type: 'uint8',
702
+ },
703
+ ],
704
+ internalType: 'struct UniversalPayload',
705
+ name: 'payload',
706
+ type: 'tuple',
707
+ },
708
+ {
709
+ components: [
710
+ { internalType: 'address', name: 'fundRecipient', type: 'address' },
711
+ { internalType: 'bytes', name: 'revertMsg', type: 'bytes' },
712
+ ],
713
+ internalType: 'struct RevertInstructions',
714
+ name: 'revertInstruction',
715
+ type: 'tuple',
23
716
  },
717
+ { internalType: 'bytes', name: 'signatureData', type: 'bytes' },
24
718
  ],
719
+ name: 'sendTxWithFunds',
25
720
  outputs: [],
26
721
  stateMutability: 'payable',
722
+ type: 'function',
27
723
  },
28
724
  {
29
- type: 'function',
30
- name: 'sendFunds',
31
725
  inputs: [
32
- { name: 'recipient', type: 'address', internalType: 'address' },
33
- { name: 'bridgeToken', type: 'address', internalType: 'address' },
34
- { name: 'bridgeAmount', type: 'uint256', internalType: 'uint256' },
726
+ { internalType: 'address', name: 'bridgeToken', type: 'address' },
727
+ { internalType: 'uint256', name: 'bridgeAmount', type: 'uint256' },
728
+ { internalType: 'address', name: 'gasToken', type: 'address' },
729
+ { internalType: 'uint256', name: 'gasAmount', type: 'uint256' },
730
+ { internalType: 'uint256', name: 'amountOutMinETH', type: 'uint256' },
731
+ { internalType: 'uint256', name: 'deadline', type: 'uint256' },
35
732
  {
36
- name: 'revertCFG',
733
+ components: [
734
+ { internalType: 'address', name: 'to', type: 'address' },
735
+ { internalType: 'uint256', name: 'value', type: 'uint256' },
736
+ { internalType: 'bytes', name: 'data', type: 'bytes' },
737
+ { internalType: 'uint256', name: 'gasLimit', type: 'uint256' },
738
+ { internalType: 'uint256', name: 'maxFeePerGas', type: 'uint256' },
739
+ {
740
+ internalType: 'uint256',
741
+ name: 'maxPriorityFeePerGas',
742
+ type: 'uint256',
743
+ },
744
+ { internalType: 'uint256', name: 'nonce', type: 'uint256' },
745
+ { internalType: 'uint256', name: 'deadline', type: 'uint256' },
746
+ {
747
+ internalType: 'enum VerificationType',
748
+ name: 'vType',
749
+ type: 'uint8',
750
+ },
751
+ ],
752
+ internalType: 'struct UniversalPayload',
753
+ name: 'payload',
37
754
  type: 'tuple',
38
- internalType: 'struct RevertSettings',
755
+ },
756
+ {
39
757
  components: [
40
- { name: 'fundRecipient', type: 'address', internalType: 'address' },
41
- { name: 'revertMsg', type: 'bytes', internalType: 'bytes' },
758
+ { internalType: 'address', name: 'fundRecipient', type: 'address' },
759
+ { internalType: 'bytes', name: 'revertMsg', type: 'bytes' },
42
760
  ],
761
+ internalType: 'struct RevertInstructions',
762
+ name: 'revertInstruction',
763
+ type: 'tuple',
43
764
  },
765
+ { internalType: 'bytes', name: 'signatureData', type: 'bytes' },
44
766
  ],
767
+ name: 'sendTxWithFunds_new',
45
768
  outputs: [],
46
- stateMutability: 'payable',
769
+ stateMutability: 'nonpayable',
770
+ type: 'function',
47
771
  },
48
772
  {
49
- type: 'function',
50
- name: 'sendTxWithFunds',
51
773
  inputs: [
52
- { name: 'bridgeToken', type: 'address', internalType: 'address' },
53
- { name: 'bridgeAmount', type: 'uint256', internalType: 'uint256' },
774
+ { internalType: 'address', name: 'bridgeToken', type: 'address' },
775
+ { internalType: 'uint256', name: 'bridgeAmount', type: 'uint256' },
54
776
  {
55
- name: 'payload',
56
- type: 'tuple',
57
- internalType: 'struct UniversalPayload',
58
777
  components: [
59
- { name: 'to', type: 'address', internalType: 'address' },
60
- { name: 'value', type: 'uint256', internalType: 'uint256' },
61
- { name: 'data', type: 'bytes', internalType: 'bytes' },
62
- { name: 'gasLimit', type: 'uint256', internalType: 'uint256' },
63
- { name: 'maxFeePerGas', type: 'uint256', internalType: 'uint256' },
778
+ { internalType: 'address', name: 'to', type: 'address' },
779
+ { internalType: 'uint256', name: 'value', type: 'uint256' },
780
+ { internalType: 'bytes', name: 'data', type: 'bytes' },
781
+ { internalType: 'uint256', name: 'gasLimit', type: 'uint256' },
782
+ { internalType: 'uint256', name: 'maxFeePerGas', type: 'uint256' },
64
783
  {
784
+ internalType: 'uint256',
65
785
  name: 'maxPriorityFeePerGas',
66
786
  type: 'uint256',
67
- internalType: 'uint256',
68
787
  },
69
- { name: 'nonce', type: 'uint256', internalType: 'uint256' },
70
- { name: 'deadline', type: 'uint256', internalType: 'uint256' },
788
+ { internalType: 'uint256', name: 'nonce', type: 'uint256' },
789
+ { internalType: 'uint256', name: 'deadline', type: 'uint256' },
71
790
  {
791
+ internalType: 'enum VerificationType',
72
792
  name: 'vType',
73
793
  type: 'uint8',
74
- internalType: 'enum VerificationType',
75
794
  },
76
795
  ],
796
+ internalType: 'struct UniversalPayload',
797
+ name: 'payload',
798
+ type: 'tuple',
77
799
  },
78
800
  {
79
- name: 'revertCFG',
80
- type: 'tuple',
81
- internalType: 'struct RevertSettings',
82
801
  components: [
83
- { name: 'fundRecipient', type: 'address', internalType: 'address' },
84
- { name: 'revertMsg', type: 'bytes', internalType: 'bytes' },
802
+ { internalType: 'address', name: 'fundRecipient', type: 'address' },
803
+ { internalType: 'bytes', name: 'revertMsg', type: 'bytes' },
85
804
  ],
805
+ internalType: 'struct RevertInstructions',
806
+ name: 'revertInstruction',
807
+ type: 'tuple',
86
808
  },
87
- { name: 'signatureData', type: 'bytes', internalType: 'bytes' },
809
+ { internalType: 'bytes', name: 'signatureData', type: 'bytes' },
88
810
  ],
811
+ name: 'sendTxWithFunds_new',
89
812
  outputs: [],
90
813
  stateMutability: 'payable',
814
+ type: 'function',
91
815
  },
92
816
  {
93
- type: 'function',
94
- name: 'sendTxWithFunds',
95
817
  inputs: [
96
- { name: 'bridgeToken', type: 'address', internalType: 'address' },
97
- { name: 'bridgeAmount', type: 'uint256', internalType: 'uint256' },
98
- { name: 'gasToken', type: 'address', internalType: 'address' },
99
- { name: 'gasAmount', type: 'uint256', internalType: 'uint256' },
100
- { name: 'amountOutMinETH', type: 'uint256', internalType: 'uint256' },
101
- { name: 'deadline', type: 'uint256', internalType: 'uint256' },
102
818
  {
819
+ components: [
820
+ { internalType: 'address', name: 'to', type: 'address' },
821
+ { internalType: 'uint256', name: 'value', type: 'uint256' },
822
+ { internalType: 'bytes', name: 'data', type: 'bytes' },
823
+ { internalType: 'uint256', name: 'gasLimit', type: 'uint256' },
824
+ { internalType: 'uint256', name: 'maxFeePerGas', type: 'uint256' },
825
+ {
826
+ internalType: 'uint256',
827
+ name: 'maxPriorityFeePerGas',
828
+ type: 'uint256',
829
+ },
830
+ { internalType: 'uint256', name: 'nonce', type: 'uint256' },
831
+ { internalType: 'uint256', name: 'deadline', type: 'uint256' },
832
+ {
833
+ internalType: 'enum VerificationType',
834
+ name: 'vType',
835
+ type: 'uint8',
836
+ },
837
+ ],
838
+ internalType: 'struct UniversalPayload',
103
839
  name: 'payload',
104
840
  type: 'tuple',
105
- internalType: 'struct UniversalPayload',
841
+ },
842
+ {
843
+ components: [
844
+ { internalType: 'address', name: 'fundRecipient', type: 'address' },
845
+ { internalType: 'bytes', name: 'revertMsg', type: 'bytes' },
846
+ ],
847
+ internalType: 'struct RevertInstructions',
848
+ name: 'revertInstruction',
849
+ type: 'tuple',
850
+ },
851
+ { internalType: 'bytes', name: 'signatureData', type: 'bytes' },
852
+ ],
853
+ name: 'sendTxWithGas',
854
+ outputs: [],
855
+ stateMutability: 'payable',
856
+ type: 'function',
857
+ },
858
+ {
859
+ inputs: [
860
+ { internalType: 'address', name: 'tokenIn', type: 'address' },
861
+ { internalType: 'uint256', name: 'amountIn', type: 'uint256' },
862
+ {
106
863
  components: [
107
- { name: 'to', type: 'address', internalType: 'address' },
108
- { name: 'value', type: 'uint256', internalType: 'uint256' },
109
- { name: 'data', type: 'bytes', internalType: 'bytes' },
110
- { name: 'gasLimit', type: 'uint256', internalType: 'uint256' },
111
- { name: 'maxFeePerGas', type: 'uint256', internalType: 'uint256' },
864
+ { internalType: 'address', name: 'to', type: 'address' },
865
+ { internalType: 'uint256', name: 'value', type: 'uint256' },
866
+ { internalType: 'bytes', name: 'data', type: 'bytes' },
867
+ { internalType: 'uint256', name: 'gasLimit', type: 'uint256' },
868
+ { internalType: 'uint256', name: 'maxFeePerGas', type: 'uint256' },
112
869
  {
870
+ internalType: 'uint256',
113
871
  name: 'maxPriorityFeePerGas',
114
872
  type: 'uint256',
115
- internalType: 'uint256',
116
873
  },
117
- { name: 'nonce', type: 'uint256', internalType: 'uint256' },
118
- { name: 'deadline', type: 'uint256', internalType: 'uint256' },
874
+ { internalType: 'uint256', name: 'nonce', type: 'uint256' },
875
+ { internalType: 'uint256', name: 'deadline', type: 'uint256' },
119
876
  {
877
+ internalType: 'enum VerificationType',
120
878
  name: 'vType',
121
879
  type: 'uint8',
122
- internalType: 'enum VerificationType',
123
880
  },
124
881
  ],
882
+ internalType: 'struct UniversalPayload',
883
+ name: 'payload',
884
+ type: 'tuple',
125
885
  },
126
886
  {
127
- name: 'revertCFG',
128
- type: 'tuple',
129
- internalType: 'struct RevertSettings',
130
887
  components: [
131
- { name: 'fundRecipient', type: 'address', internalType: 'address' },
132
- { name: 'revertMsg', type: 'bytes', internalType: 'bytes' },
888
+ { internalType: 'address', name: 'fundRecipient', type: 'address' },
889
+ { internalType: 'bytes', name: 'revertMsg', type: 'bytes' },
133
890
  ],
891
+ internalType: 'struct RevertInstructions',
892
+ name: 'revertInstruction',
893
+ type: 'tuple',
894
+ },
895
+ { internalType: 'uint256', name: 'amountOutMinETH', type: 'uint256' },
896
+ { internalType: 'uint256', name: 'deadline', type: 'uint256' },
897
+ { internalType: 'bytes', name: 'signatureData', type: 'bytes' },
898
+ ],
899
+ name: 'sendTxWithGas',
900
+ outputs: [],
901
+ stateMutability: 'nonpayable',
902
+ type: 'function',
903
+ },
904
+ {
905
+ inputs: [{ internalType: 'uint256', name: 'cap1e18', type: 'uint256' }],
906
+ name: 'setBlockUsdCap',
907
+ outputs: [],
908
+ stateMutability: 'nonpayable',
909
+ type: 'function',
910
+ },
911
+ {
912
+ inputs: [
913
+ { internalType: 'uint256', name: 'minCapUsd', type: 'uint256' },
914
+ { internalType: 'uint256', name: 'maxCapUsd', type: 'uint256' },
915
+ ],
916
+ name: 'setCapsUSD',
917
+ outputs: [],
918
+ stateMutability: 'nonpayable',
919
+ type: 'function',
920
+ },
921
+ {
922
+ inputs: [
923
+ { internalType: 'uint256', name: 'stalePeriodSec', type: 'uint256' },
924
+ ],
925
+ name: 'setChainlinkStalePeriod',
926
+ outputs: [],
927
+ stateMutability: 'nonpayable',
928
+ type: 'function',
929
+ },
930
+ {
931
+ inputs: [{ internalType: 'uint256', name: 'deadlineSec', type: 'uint256' }],
932
+ name: 'setDefaultSwapDeadline',
933
+ outputs: [],
934
+ stateMutability: 'nonpayable',
935
+ type: 'function',
936
+ },
937
+ {
938
+ inputs: [{ internalType: 'address', name: 'feed', type: 'address' }],
939
+ name: 'setEthUsdFeed',
940
+ outputs: [],
941
+ stateMutability: 'nonpayable',
942
+ type: 'function',
943
+ },
944
+ {
945
+ inputs: [{ internalType: 'address', name: 'feed', type: 'address' }],
946
+ name: 'setL2SequencerFeed',
947
+ outputs: [],
948
+ stateMutability: 'nonpayable',
949
+ type: 'function',
950
+ },
951
+ {
952
+ inputs: [
953
+ { internalType: 'uint256', name: 'gracePeriodSec', type: 'uint256' },
954
+ ],
955
+ name: 'setL2SequencerGracePeriod',
956
+ outputs: [],
957
+ stateMutability: 'nonpayable',
958
+ type: 'function',
959
+ },
960
+ {
961
+ inputs: [
962
+ { internalType: 'address', name: 'factory', type: 'address' },
963
+ { internalType: 'address', name: 'router', type: 'address' },
964
+ ],
965
+ name: 'setRouters',
966
+ outputs: [],
967
+ stateMutability: 'nonpayable',
968
+ type: 'function',
969
+ },
970
+ {
971
+ inputs: [{ internalType: 'address', name: 'newTSS', type: 'address' }],
972
+ name: 'setTSSAddress',
973
+ outputs: [],
974
+ stateMutability: 'nonpayable',
975
+ type: 'function',
976
+ },
977
+ {
978
+ inputs: [
979
+ { internalType: 'address[]', name: 'tokens', type: 'address[]' },
980
+ { internalType: 'uint256[]', name: 'thresholds', type: 'uint256[]' },
981
+ ],
982
+ name: 'setTokenLimitThresholds',
983
+ outputs: [],
984
+ stateMutability: 'nonpayable',
985
+ type: 'function',
986
+ },
987
+ {
988
+ inputs: [
989
+ { internalType: 'uint24', name: 'a', type: 'uint24' },
990
+ { internalType: 'uint24', name: 'b', type: 'uint24' },
991
+ { internalType: 'uint24', name: 'c', type: 'uint24' },
992
+ ],
993
+ name: 'setV3FeeOrder',
994
+ outputs: [],
995
+ stateMutability: 'nonpayable',
996
+ type: 'function',
997
+ },
998
+ {
999
+ inputs: [{ internalType: 'bytes4', name: 'interfaceId', type: 'bytes4' }],
1000
+ name: 'supportsInterface',
1001
+ outputs: [{ internalType: 'bool', name: '', type: 'bool' }],
1002
+ stateMutability: 'view',
1003
+ type: 'function',
1004
+ },
1005
+ {
1006
+ inputs: [{ internalType: 'address', name: '', type: 'address' }],
1007
+ name: 'tokenToLimitThreshold',
1008
+ outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }],
1009
+ stateMutability: 'view',
1010
+ type: 'function',
1011
+ },
1012
+ {
1013
+ inputs: [],
1014
+ name: 'uniV3Factory',
1015
+ outputs: [
1016
+ { internalType: 'contract IUniswapV3Factory', name: '', type: 'address' },
1017
+ ],
1018
+ stateMutability: 'view',
1019
+ type: 'function',
1020
+ },
1021
+ {
1022
+ inputs: [],
1023
+ name: 'uniV3Router',
1024
+ outputs: [
1025
+ {
1026
+ internalType: 'contract ISwapRouterSepolia',
1027
+ name: '',
1028
+ type: 'address',
1029
+ },
1030
+ ],
1031
+ stateMutability: 'view',
1032
+ type: 'function',
1033
+ },
1034
+ {
1035
+ inputs: [],
1036
+ name: 'unpause',
1037
+ outputs: [],
1038
+ stateMutability: 'nonpayable',
1039
+ type: 'function',
1040
+ },
1041
+ {
1042
+ inputs: [
1043
+ { internalType: 'uint256', name: 'newDurationSec', type: 'uint256' },
1044
+ ],
1045
+ name: 'updateEpochDuration',
1046
+ outputs: [],
1047
+ stateMutability: 'nonpayable',
1048
+ type: 'function',
1049
+ },
1050
+ {
1051
+ inputs: [
1052
+ { internalType: 'address[]', name: 'tokens', type: 'address[]' },
1053
+ { internalType: 'uint256[]', name: 'thresholds', type: 'uint256[]' },
1054
+ ],
1055
+ name: 'updateTokenLimitThreshold',
1056
+ outputs: [],
1057
+ stateMutability: 'nonpayable',
1058
+ type: 'function',
1059
+ },
1060
+ {
1061
+ inputs: [],
1062
+ name: 'usdtUsdPriceFeed',
1063
+ outputs: [
1064
+ {
1065
+ internalType: 'contract AggregatorV3Interface',
1066
+ name: '',
1067
+ type: 'address',
134
1068
  },
135
- { name: 'signatureData', type: 'bytes', internalType: 'bytes' },
136
1069
  ],
1070
+ stateMutability: 'view',
1071
+ type: 'function',
1072
+ },
1073
+ {
1074
+ inputs: [{ internalType: 'uint256', name: '', type: 'uint256' }],
1075
+ name: 'v3FeeOrder',
1076
+ outputs: [{ internalType: 'uint24', name: '', type: 'uint24' }],
1077
+ stateMutability: 'view',
1078
+ type: 'function',
1079
+ },
1080
+ {
1081
+ inputs: [],
1082
+ name: 'version',
1083
+ outputs: [{ internalType: 'string', name: '', type: 'string' }],
1084
+ stateMutability: 'pure',
1085
+ type: 'function',
1086
+ },
1087
+ {
1088
+ inputs: [
1089
+ { internalType: 'address', name: 'recipient', type: 'address' },
1090
+ { internalType: 'address', name: 'token', type: 'address' },
1091
+ { internalType: 'uint256', name: 'amount', type: 'uint256' },
1092
+ ],
1093
+ name: 'withdrawFunds',
137
1094
  outputs: [],
138
1095
  stateMutability: 'nonpayable',
1096
+ type: 'function',
139
1097
  },
1098
+ { stateMutability: 'payable', type: 'receive' },
140
1099
  ];
141
1100
  //# sourceMappingURL=universalGatewayV0.evm.js.map