remesso-sdk 0.0.0-stage → 0.2.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 (55) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +379 -2
  3. package/dist/abi.d.ts +63 -0
  4. package/dist/abi.js +14 -0
  5. package/dist/agents.d.ts +15 -0
  6. package/dist/agents.js +39 -0
  7. package/dist/attribution.d.ts +3 -0
  8. package/dist/attribution.js +29 -0
  9. package/dist/client.d.ts +75 -0
  10. package/dist/client.js +60 -0
  11. package/dist/context.d.ts +42 -0
  12. package/dist/context.js +157 -0
  13. package/dist/deployment.d.ts +19 -0
  14. package/dist/deployment.js +80 -0
  15. package/dist/errors.d.ts +30 -0
  16. package/dist/errors.js +10 -0
  17. package/dist/events.d.ts +59 -0
  18. package/dist/events.js +53 -0
  19. package/dist/generated/abi.d.ts +1543 -0
  20. package/dist/generated/abi.js +1979 -0
  21. package/dist/generated/deployment.d.ts +114 -0
  22. package/dist/generated/deployment.js +127 -0
  23. package/dist/index.d.ts +16 -0
  24. package/dist/index.js +15 -0
  25. package/dist/links.d.ts +25 -0
  26. package/dist/links.js +60 -0
  27. package/dist/node.d.ts +5 -0
  28. package/dist/node.js +60 -0
  29. package/dist/payments.d.ts +39 -0
  30. package/dist/payments.js +232 -0
  31. package/dist/policies.d.ts +54 -0
  32. package/dist/policies.js +148 -0
  33. package/dist/requests.d.ts +103 -0
  34. package/dist/requests.js +145 -0
  35. package/dist/schedules.d.ts +111 -0
  36. package/dist/schedules.js +232 -0
  37. package/dist/store.d.ts +24 -0
  38. package/dist/store.js +19 -0
  39. package/dist/vendor/erc8021.d.ts +9 -0
  40. package/dist/vendor/erc8021.js +82 -0
  41. package/dist/vendor/fee.d.ts +3 -0
  42. package/dist/vendor/fee.js +40 -0
  43. package/dist/vendor/payee-profile.d.ts +27 -0
  44. package/dist/vendor/payee-profile.js +73 -0
  45. package/dist/vendor/request-decline.d.ts +55 -0
  46. package/dist/vendor/request-decline.js +60 -0
  47. package/dist/vendor/safe-fetch.d.ts +2 -0
  48. package/dist/vendor/safe-fetch.js +154 -0
  49. package/dist/vendor/standard-webhooks.d.ts +8 -0
  50. package/dist/vendor/standard-webhooks.js +83 -0
  51. package/dist/vendor/webhook-actions.d.ts +84 -0
  52. package/dist/vendor/webhook-actions.js +123 -0
  53. package/dist/webhooks.d.ts +88 -0
  54. package/dist/webhooks.js +113 -0
  55. package/package.json +58 -4
@@ -0,0 +1,1979 @@
1
+ // Copied from indexer/abis/ by scripts/build-sdk.ts. Edit the original and re-run;
2
+ // `build-sdk.ts --check` fails while the two differ.
3
+ export const executorAbi = [
4
+ {
5
+ "type": "constructor",
6
+ "inputs": [
7
+ {
8
+ "name": "_tokenIn",
9
+ "type": "address",
10
+ "internalType": "address"
11
+ },
12
+ {
13
+ "name": "_tokenOut",
14
+ "type": "address",
15
+ "internalType": "address"
16
+ },
17
+ {
18
+ "name": "_router",
19
+ "type": "address",
20
+ "internalType": "address"
21
+ },
22
+ {
23
+ "name": "_executor",
24
+ "type": "address",
25
+ "internalType": "address"
26
+ },
27
+ {
28
+ "name": "_poolFee",
29
+ "type": "uint24",
30
+ "internalType": "uint24"
31
+ },
32
+ {
33
+ "name": "_treasury",
34
+ "type": "address",
35
+ "internalType": "address"
36
+ },
37
+ {
38
+ "name": "_feeBps",
39
+ "type": "uint16",
40
+ "internalType": "uint16"
41
+ }
42
+ ],
43
+ "stateMutability": "nonpayable"
44
+ },
45
+ {
46
+ "type": "function",
47
+ "name": "CURRENT_EXECUTOR",
48
+ "inputs": [],
49
+ "outputs": [
50
+ {
51
+ "name": "",
52
+ "type": "address",
53
+ "internalType": "address"
54
+ }
55
+ ],
56
+ "stateMutability": "view"
57
+ },
58
+ {
59
+ "type": "function",
60
+ "name": "MAX_FEE_BPS",
61
+ "inputs": [],
62
+ "outputs": [
63
+ {
64
+ "name": "",
65
+ "type": "uint16",
66
+ "internalType": "uint16"
67
+ }
68
+ ],
69
+ "stateMutability": "view"
70
+ },
71
+ {
72
+ "type": "function",
73
+ "name": "MAX_INTERVAL",
74
+ "inputs": [],
75
+ "outputs": [
76
+ {
77
+ "name": "",
78
+ "type": "uint64",
79
+ "internalType": "uint64"
80
+ }
81
+ ],
82
+ "stateMutability": "view"
83
+ },
84
+ {
85
+ "type": "function",
86
+ "name": "MAX_LIFETIME",
87
+ "inputs": [],
88
+ "outputs": [
89
+ {
90
+ "name": "",
91
+ "type": "uint64",
92
+ "internalType": "uint64"
93
+ }
94
+ ],
95
+ "stateMutability": "view"
96
+ },
97
+ {
98
+ "type": "function",
99
+ "name": "MIN_TRIGGER_GAP",
100
+ "inputs": [],
101
+ "outputs": [
102
+ {
103
+ "name": "",
104
+ "type": "uint64",
105
+ "internalType": "uint64"
106
+ }
107
+ ],
108
+ "stateMutability": "view"
109
+ },
110
+ {
111
+ "type": "function",
112
+ "name": "acceptOwnership",
113
+ "inputs": [],
114
+ "outputs": [],
115
+ "stateMutability": "nonpayable"
116
+ },
117
+ {
118
+ "type": "function",
119
+ "name": "cancelSchedule",
120
+ "inputs": [
121
+ {
122
+ "name": "id",
123
+ "type": "uint256",
124
+ "internalType": "uint256"
125
+ }
126
+ ],
127
+ "outputs": [],
128
+ "stateMutability": "nonpayable"
129
+ },
130
+ {
131
+ "type": "function",
132
+ "name": "createSchedule",
133
+ "inputs": [
134
+ {
135
+ "name": "destination",
136
+ "type": "address",
137
+ "internalType": "address"
138
+ },
139
+ {
140
+ "name": "amountIn",
141
+ "type": "uint128",
142
+ "internalType": "uint128"
143
+ },
144
+ {
145
+ "name": "interval",
146
+ "type": "uint64",
147
+ "internalType": "uint64"
148
+ },
149
+ {
150
+ "name": "minRateE6",
151
+ "type": "uint96",
152
+ "internalType": "uint96"
153
+ },
154
+ {
155
+ "name": "maxRuns",
156
+ "type": "uint32",
157
+ "internalType": "uint32"
158
+ },
159
+ {
160
+ "name": "expiresAt",
161
+ "type": "uint64",
162
+ "internalType": "uint64"
163
+ },
164
+ {
165
+ "name": "firstRunAt",
166
+ "type": "uint64",
167
+ "internalType": "uint64"
168
+ },
169
+ {
170
+ "name": "payoutType",
171
+ "type": "uint8",
172
+ "internalType": "enum RemessoExecutorV5.PayoutType"
173
+ },
174
+ {
175
+ "name": "token",
176
+ "type": "address",
177
+ "internalType": "address"
178
+ },
179
+ {
180
+ "name": "payoutToken",
181
+ "type": "address",
182
+ "internalType": "address"
183
+ },
184
+ {
185
+ "name": "trigger",
186
+ "type": "address",
187
+ "internalType": "address"
188
+ },
189
+ {
190
+ "name": "triggersLeft",
191
+ "type": "uint16",
192
+ "internalType": "uint16"
193
+ }
194
+ ],
195
+ "outputs": [
196
+ {
197
+ "name": "id",
198
+ "type": "uint256",
199
+ "internalType": "uint256"
200
+ }
201
+ ],
202
+ "stateMutability": "nonpayable"
203
+ },
204
+ {
205
+ "type": "function",
206
+ "name": "directTokenAllowed",
207
+ "inputs": [
208
+ {
209
+ "name": "",
210
+ "type": "address",
211
+ "internalType": "address"
212
+ }
213
+ ],
214
+ "outputs": [
215
+ {
216
+ "name": "",
217
+ "type": "bool",
218
+ "internalType": "bool"
219
+ }
220
+ ],
221
+ "stateMutability": "view"
222
+ },
223
+ {
224
+ "type": "function",
225
+ "name": "executeRun",
226
+ "inputs": [
227
+ {
228
+ "name": "id",
229
+ "type": "uint256",
230
+ "internalType": "uint256"
231
+ },
232
+ {
233
+ "name": "amountOutMinimum",
234
+ "type": "uint256",
235
+ "internalType": "uint256"
236
+ }
237
+ ],
238
+ "outputs": [
239
+ {
240
+ "name": "amountOut",
241
+ "type": "uint256",
242
+ "internalType": "uint256"
243
+ }
244
+ ],
245
+ "stateMutability": "nonpayable"
246
+ },
247
+ {
248
+ "type": "function",
249
+ "name": "executor",
250
+ "inputs": [],
251
+ "outputs": [
252
+ {
253
+ "name": "",
254
+ "type": "address",
255
+ "internalType": "address"
256
+ }
257
+ ],
258
+ "stateMutability": "view"
259
+ },
260
+ {
261
+ "type": "function",
262
+ "name": "feeBps",
263
+ "inputs": [],
264
+ "outputs": [
265
+ {
266
+ "name": "",
267
+ "type": "uint16",
268
+ "internalType": "uint16"
269
+ }
270
+ ],
271
+ "stateMutability": "view"
272
+ },
273
+ {
274
+ "type": "function",
275
+ "name": "getSchedule",
276
+ "inputs": [
277
+ {
278
+ "name": "id",
279
+ "type": "uint256",
280
+ "internalType": "uint256"
281
+ }
282
+ ],
283
+ "outputs": [
284
+ {
285
+ "name": "",
286
+ "type": "tuple",
287
+ "internalType": "struct RemessoExecutorV5.Schedule",
288
+ "components": [
289
+ {
290
+ "name": "sender",
291
+ "type": "address",
292
+ "internalType": "address"
293
+ },
294
+ {
295
+ "name": "interval",
296
+ "type": "uint64",
297
+ "internalType": "uint64"
298
+ },
299
+ {
300
+ "name": "maxRuns",
301
+ "type": "uint32",
302
+ "internalType": "uint32"
303
+ },
304
+ {
305
+ "name": "destination",
306
+ "type": "address",
307
+ "internalType": "address"
308
+ },
309
+ {
310
+ "name": "nextRunAt",
311
+ "type": "uint64",
312
+ "internalType": "uint64"
313
+ },
314
+ {
315
+ "name": "runsExecuted",
316
+ "type": "uint32",
317
+ "internalType": "uint32"
318
+ },
319
+ {
320
+ "name": "amountIn",
321
+ "type": "uint128",
322
+ "internalType": "uint128"
323
+ },
324
+ {
325
+ "name": "minRateE6",
326
+ "type": "uint96",
327
+ "internalType": "uint96"
328
+ },
329
+ {
330
+ "name": "poolFee",
331
+ "type": "uint24",
332
+ "internalType": "uint24"
333
+ },
334
+ {
335
+ "name": "expiresAt",
336
+ "type": "uint64",
337
+ "internalType": "uint64"
338
+ },
339
+ {
340
+ "name": "payoutType",
341
+ "type": "uint8",
342
+ "internalType": "enum RemessoExecutorV5.PayoutType"
343
+ },
344
+ {
345
+ "name": "active",
346
+ "type": "bool",
347
+ "internalType": "bool"
348
+ },
349
+ {
350
+ "name": "cancelled",
351
+ "type": "bool",
352
+ "internalType": "bool"
353
+ },
354
+ {
355
+ "name": "token",
356
+ "type": "address",
357
+ "internalType": "address"
358
+ },
359
+ {
360
+ "name": "tokenOut",
361
+ "type": "address",
362
+ "internalType": "address"
363
+ },
364
+ {
365
+ "name": "feeBps",
366
+ "type": "uint16",
367
+ "internalType": "uint16"
368
+ },
369
+ {
370
+ "name": "lastRunAt",
371
+ "type": "uint64",
372
+ "internalType": "uint64"
373
+ },
374
+ {
375
+ "name": "triggersLeft",
376
+ "type": "uint16",
377
+ "internalType": "uint16"
378
+ },
379
+ {
380
+ "name": "trigger",
381
+ "type": "address",
382
+ "internalType": "address"
383
+ }
384
+ ]
385
+ }
386
+ ],
387
+ "stateMutability": "view"
388
+ },
389
+ {
390
+ "type": "function",
391
+ "name": "nextScheduleId",
392
+ "inputs": [],
393
+ "outputs": [
394
+ {
395
+ "name": "",
396
+ "type": "uint256",
397
+ "internalType": "uint256"
398
+ }
399
+ ],
400
+ "stateMutability": "view"
401
+ },
402
+ {
403
+ "type": "function",
404
+ "name": "owner",
405
+ "inputs": [],
406
+ "outputs": [
407
+ {
408
+ "name": "",
409
+ "type": "address",
410
+ "internalType": "address"
411
+ }
412
+ ],
413
+ "stateMutability": "view"
414
+ },
415
+ {
416
+ "type": "function",
417
+ "name": "pause",
418
+ "inputs": [],
419
+ "outputs": [],
420
+ "stateMutability": "nonpayable"
421
+ },
422
+ {
423
+ "type": "function",
424
+ "name": "paused",
425
+ "inputs": [],
426
+ "outputs": [
427
+ {
428
+ "name": "",
429
+ "type": "bool",
430
+ "internalType": "bool"
431
+ }
432
+ ],
433
+ "stateMutability": "view"
434
+ },
435
+ {
436
+ "type": "function",
437
+ "name": "pendingOwner",
438
+ "inputs": [],
439
+ "outputs": [
440
+ {
441
+ "name": "",
442
+ "type": "address",
443
+ "internalType": "address"
444
+ }
445
+ ],
446
+ "stateMutability": "view"
447
+ },
448
+ {
449
+ "type": "function",
450
+ "name": "poolFee",
451
+ "inputs": [],
452
+ "outputs": [
453
+ {
454
+ "name": "",
455
+ "type": "uint24",
456
+ "internalType": "uint24"
457
+ }
458
+ ],
459
+ "stateMutability": "view"
460
+ },
461
+ {
462
+ "type": "function",
463
+ "name": "renounceOwnership",
464
+ "inputs": [],
465
+ "outputs": [],
466
+ "stateMutability": "pure"
467
+ },
468
+ {
469
+ "type": "function",
470
+ "name": "rescueToken",
471
+ "inputs": [
472
+ {
473
+ "name": "token",
474
+ "type": "address",
475
+ "internalType": "address"
476
+ },
477
+ {
478
+ "name": "to",
479
+ "type": "address",
480
+ "internalType": "address"
481
+ },
482
+ {
483
+ "name": "amount",
484
+ "type": "uint256",
485
+ "internalType": "uint256"
486
+ }
487
+ ],
488
+ "outputs": [],
489
+ "stateMutability": "nonpayable"
490
+ },
491
+ {
492
+ "type": "function",
493
+ "name": "router",
494
+ "inputs": [],
495
+ "outputs": [
496
+ {
497
+ "name": "",
498
+ "type": "address",
499
+ "internalType": "contract ISwapRouter02"
500
+ }
501
+ ],
502
+ "stateMutability": "view"
503
+ },
504
+ {
505
+ "type": "function",
506
+ "name": "runNow",
507
+ "inputs": [
508
+ {
509
+ "name": "id",
510
+ "type": "uint256",
511
+ "internalType": "uint256"
512
+ },
513
+ {
514
+ "name": "amountOutMinimum",
515
+ "type": "uint256",
516
+ "internalType": "uint256"
517
+ }
518
+ ],
519
+ "outputs": [
520
+ {
521
+ "name": "amountOut",
522
+ "type": "uint256",
523
+ "internalType": "uint256"
524
+ }
525
+ ],
526
+ "stateMutability": "nonpayable"
527
+ },
528
+ {
529
+ "type": "function",
530
+ "name": "runnability",
531
+ "inputs": [
532
+ {
533
+ "name": "id",
534
+ "type": "uint256",
535
+ "internalType": "uint256"
536
+ }
537
+ ],
538
+ "outputs": [
539
+ {
540
+ "name": "due",
541
+ "type": "bool",
542
+ "internalType": "bool"
543
+ },
544
+ {
545
+ "name": "funded",
546
+ "type": "bool",
547
+ "internalType": "bool"
548
+ },
549
+ {
550
+ "name": "approved",
551
+ "type": "bool",
552
+ "internalType": "bool"
553
+ },
554
+ {
555
+ "name": "floor",
556
+ "type": "uint256",
557
+ "internalType": "uint256"
558
+ },
559
+ {
560
+ "name": "nextRunAt",
561
+ "type": "uint64",
562
+ "internalType": "uint64"
563
+ }
564
+ ],
565
+ "stateMutability": "view"
566
+ },
567
+ {
568
+ "type": "function",
569
+ "name": "schedulesOf",
570
+ "inputs": [
571
+ {
572
+ "name": "sender",
573
+ "type": "address",
574
+ "internalType": "address"
575
+ }
576
+ ],
577
+ "outputs": [
578
+ {
579
+ "name": "",
580
+ "type": "uint256[]",
581
+ "internalType": "uint256[]"
582
+ }
583
+ ],
584
+ "stateMutability": "view"
585
+ },
586
+ {
587
+ "type": "function",
588
+ "name": "setDirectToken",
589
+ "inputs": [
590
+ {
591
+ "name": "token",
592
+ "type": "address",
593
+ "internalType": "address"
594
+ },
595
+ {
596
+ "name": "allowed",
597
+ "type": "bool",
598
+ "internalType": "bool"
599
+ }
600
+ ],
601
+ "outputs": [],
602
+ "stateMutability": "nonpayable"
603
+ },
604
+ {
605
+ "type": "function",
606
+ "name": "setExecutor",
607
+ "inputs": [
608
+ {
609
+ "name": "_executor",
610
+ "type": "address",
611
+ "internalType": "address"
612
+ }
613
+ ],
614
+ "outputs": [],
615
+ "stateMutability": "nonpayable"
616
+ },
617
+ {
618
+ "type": "function",
619
+ "name": "setFeeBps",
620
+ "inputs": [
621
+ {
622
+ "name": "_feeBps",
623
+ "type": "uint16",
624
+ "internalType": "uint16"
625
+ }
626
+ ],
627
+ "outputs": [],
628
+ "stateMutability": "nonpayable"
629
+ },
630
+ {
631
+ "type": "function",
632
+ "name": "setMinRate",
633
+ "inputs": [
634
+ {
635
+ "name": "id",
636
+ "type": "uint256",
637
+ "internalType": "uint256"
638
+ },
639
+ {
640
+ "name": "minRateE6",
641
+ "type": "uint96",
642
+ "internalType": "uint96"
643
+ }
644
+ ],
645
+ "outputs": [],
646
+ "stateMutability": "nonpayable"
647
+ },
648
+ {
649
+ "type": "function",
650
+ "name": "setPoolFee",
651
+ "inputs": [
652
+ {
653
+ "name": "_poolFee",
654
+ "type": "uint24",
655
+ "internalType": "uint24"
656
+ }
657
+ ],
658
+ "outputs": [],
659
+ "stateMutability": "nonpayable"
660
+ },
661
+ {
662
+ "type": "function",
663
+ "name": "setScheduleActive",
664
+ "inputs": [
665
+ {
666
+ "name": "id",
667
+ "type": "uint256",
668
+ "internalType": "uint256"
669
+ },
670
+ {
671
+ "name": "active",
672
+ "type": "bool",
673
+ "internalType": "bool"
674
+ }
675
+ ],
676
+ "outputs": [],
677
+ "stateMutability": "nonpayable"
678
+ },
679
+ {
680
+ "type": "function",
681
+ "name": "setSwapToken",
682
+ "inputs": [
683
+ {
684
+ "name": "token",
685
+ "type": "address",
686
+ "internalType": "address"
687
+ },
688
+ {
689
+ "name": "allowed",
690
+ "type": "bool",
691
+ "internalType": "bool"
692
+ }
693
+ ],
694
+ "outputs": [],
695
+ "stateMutability": "nonpayable"
696
+ },
697
+ {
698
+ "type": "function",
699
+ "name": "setTreasury",
700
+ "inputs": [
701
+ {
702
+ "name": "_treasury",
703
+ "type": "address",
704
+ "internalType": "address"
705
+ }
706
+ ],
707
+ "outputs": [],
708
+ "stateMutability": "nonpayable"
709
+ },
710
+ {
711
+ "type": "function",
712
+ "name": "setTrigger",
713
+ "inputs": [
714
+ {
715
+ "name": "id",
716
+ "type": "uint256",
717
+ "internalType": "uint256"
718
+ },
719
+ {
720
+ "name": "trigger",
721
+ "type": "address",
722
+ "internalType": "address"
723
+ },
724
+ {
725
+ "name": "triggersLeft",
726
+ "type": "uint16",
727
+ "internalType": "uint16"
728
+ }
729
+ ],
730
+ "outputs": [],
731
+ "stateMutability": "nonpayable"
732
+ },
733
+ {
734
+ "type": "function",
735
+ "name": "swapTokenAllowed",
736
+ "inputs": [
737
+ {
738
+ "name": "",
739
+ "type": "address",
740
+ "internalType": "address"
741
+ }
742
+ ],
743
+ "outputs": [
744
+ {
745
+ "name": "",
746
+ "type": "bool",
747
+ "internalType": "bool"
748
+ }
749
+ ],
750
+ "stateMutability": "view"
751
+ },
752
+ {
753
+ "type": "function",
754
+ "name": "tokenIn",
755
+ "inputs": [],
756
+ "outputs": [
757
+ {
758
+ "name": "",
759
+ "type": "address",
760
+ "internalType": "contract IERC20"
761
+ }
762
+ ],
763
+ "stateMutability": "view"
764
+ },
765
+ {
766
+ "type": "function",
767
+ "name": "tokenOut",
768
+ "inputs": [],
769
+ "outputs": [
770
+ {
771
+ "name": "",
772
+ "type": "address",
773
+ "internalType": "contract IERC20"
774
+ }
775
+ ],
776
+ "stateMutability": "view"
777
+ },
778
+ {
779
+ "type": "function",
780
+ "name": "transferOwnership",
781
+ "inputs": [
782
+ {
783
+ "name": "newOwner",
784
+ "type": "address",
785
+ "internalType": "address"
786
+ }
787
+ ],
788
+ "outputs": [],
789
+ "stateMutability": "nonpayable"
790
+ },
791
+ {
792
+ "type": "function",
793
+ "name": "treasury",
794
+ "inputs": [],
795
+ "outputs": [
796
+ {
797
+ "name": "",
798
+ "type": "address",
799
+ "internalType": "address"
800
+ }
801
+ ],
802
+ "stateMutability": "view"
803
+ },
804
+ {
805
+ "type": "function",
806
+ "name": "triggerability",
807
+ "inputs": [
808
+ {
809
+ "name": "id",
810
+ "type": "uint256",
811
+ "internalType": "uint256"
812
+ },
813
+ {
814
+ "name": "caller",
815
+ "type": "address",
816
+ "internalType": "address"
817
+ }
818
+ ],
819
+ "outputs": [
820
+ {
821
+ "name": "canTrigger",
822
+ "type": "bool",
823
+ "internalType": "bool"
824
+ },
825
+ {
826
+ "name": "triggersLeft",
827
+ "type": "uint16",
828
+ "internalType": "uint16"
829
+ },
830
+ {
831
+ "name": "earliestTrigger",
832
+ "type": "uint64",
833
+ "internalType": "uint64"
834
+ }
835
+ ],
836
+ "stateMutability": "view"
837
+ },
838
+ {
839
+ "type": "function",
840
+ "name": "unpause",
841
+ "inputs": [],
842
+ "outputs": [],
843
+ "stateMutability": "nonpayable"
844
+ },
845
+ {
846
+ "type": "event",
847
+ "name": "DirectTokenSet",
848
+ "inputs": [
849
+ {
850
+ "name": "token",
851
+ "type": "address",
852
+ "indexed": true,
853
+ "internalType": "address"
854
+ },
855
+ {
856
+ "name": "allowed",
857
+ "type": "bool",
858
+ "indexed": false,
859
+ "internalType": "bool"
860
+ }
861
+ ],
862
+ "anonymous": false
863
+ },
864
+ {
865
+ "type": "event",
866
+ "name": "ExecutorUpdated",
867
+ "inputs": [
868
+ {
869
+ "name": "previous",
870
+ "type": "address",
871
+ "indexed": true,
872
+ "internalType": "address"
873
+ },
874
+ {
875
+ "name": "current",
876
+ "type": "address",
877
+ "indexed": true,
878
+ "internalType": "address"
879
+ }
880
+ ],
881
+ "anonymous": false
882
+ },
883
+ {
884
+ "type": "event",
885
+ "name": "FeeBpsUpdated",
886
+ "inputs": [
887
+ {
888
+ "name": "previous",
889
+ "type": "uint16",
890
+ "indexed": false,
891
+ "internalType": "uint16"
892
+ },
893
+ {
894
+ "name": "current",
895
+ "type": "uint16",
896
+ "indexed": false,
897
+ "internalType": "uint16"
898
+ }
899
+ ],
900
+ "anonymous": false
901
+ },
902
+ {
903
+ "type": "event",
904
+ "name": "FeeCharged",
905
+ "inputs": [
906
+ {
907
+ "name": "id",
908
+ "type": "uint256",
909
+ "indexed": true,
910
+ "internalType": "uint256"
911
+ },
912
+ {
913
+ "name": "token",
914
+ "type": "address",
915
+ "indexed": true,
916
+ "internalType": "address"
917
+ },
918
+ {
919
+ "name": "amount",
920
+ "type": "uint256",
921
+ "indexed": false,
922
+ "internalType": "uint256"
923
+ }
924
+ ],
925
+ "anonymous": false
926
+ },
927
+ {
928
+ "type": "event",
929
+ "name": "MinRateUpdated",
930
+ "inputs": [
931
+ {
932
+ "name": "id",
933
+ "type": "uint256",
934
+ "indexed": true,
935
+ "internalType": "uint256"
936
+ },
937
+ {
938
+ "name": "previous",
939
+ "type": "uint96",
940
+ "indexed": false,
941
+ "internalType": "uint96"
942
+ },
943
+ {
944
+ "name": "current",
945
+ "type": "uint96",
946
+ "indexed": false,
947
+ "internalType": "uint96"
948
+ }
949
+ ],
950
+ "anonymous": false
951
+ },
952
+ {
953
+ "type": "event",
954
+ "name": "OwnershipTransferStarted",
955
+ "inputs": [
956
+ {
957
+ "name": "previousOwner",
958
+ "type": "address",
959
+ "indexed": true,
960
+ "internalType": "address"
961
+ },
962
+ {
963
+ "name": "newOwner",
964
+ "type": "address",
965
+ "indexed": true,
966
+ "internalType": "address"
967
+ }
968
+ ],
969
+ "anonymous": false
970
+ },
971
+ {
972
+ "type": "event",
973
+ "name": "OwnershipTransferred",
974
+ "inputs": [
975
+ {
976
+ "name": "previousOwner",
977
+ "type": "address",
978
+ "indexed": true,
979
+ "internalType": "address"
980
+ },
981
+ {
982
+ "name": "newOwner",
983
+ "type": "address",
984
+ "indexed": true,
985
+ "internalType": "address"
986
+ }
987
+ ],
988
+ "anonymous": false
989
+ },
990
+ {
991
+ "type": "event",
992
+ "name": "Paused",
993
+ "inputs": [
994
+ {
995
+ "name": "account",
996
+ "type": "address",
997
+ "indexed": false,
998
+ "internalType": "address"
999
+ }
1000
+ ],
1001
+ "anonymous": false
1002
+ },
1003
+ {
1004
+ "type": "event",
1005
+ "name": "PoolFeeUpdated",
1006
+ "inputs": [
1007
+ {
1008
+ "name": "previous",
1009
+ "type": "uint24",
1010
+ "indexed": false,
1011
+ "internalType": "uint24"
1012
+ },
1013
+ {
1014
+ "name": "current",
1015
+ "type": "uint24",
1016
+ "indexed": false,
1017
+ "internalType": "uint24"
1018
+ }
1019
+ ],
1020
+ "anonymous": false
1021
+ },
1022
+ {
1023
+ "type": "event",
1024
+ "name": "RunExecuted",
1025
+ "inputs": [
1026
+ {
1027
+ "name": "id",
1028
+ "type": "uint256",
1029
+ "indexed": true,
1030
+ "internalType": "uint256"
1031
+ },
1032
+ {
1033
+ "name": "sender",
1034
+ "type": "address",
1035
+ "indexed": true,
1036
+ "internalType": "address"
1037
+ },
1038
+ {
1039
+ "name": "destination",
1040
+ "type": "address",
1041
+ "indexed": true,
1042
+ "internalType": "address"
1043
+ },
1044
+ {
1045
+ "name": "amountIn",
1046
+ "type": "uint128",
1047
+ "indexed": false,
1048
+ "internalType": "uint128"
1049
+ },
1050
+ {
1051
+ "name": "amountOut",
1052
+ "type": "uint256",
1053
+ "indexed": false,
1054
+ "internalType": "uint256"
1055
+ },
1056
+ {
1057
+ "name": "runsExecuted",
1058
+ "type": "uint32",
1059
+ "indexed": false,
1060
+ "internalType": "uint32"
1061
+ },
1062
+ {
1063
+ "name": "nextRunAt",
1064
+ "type": "uint64",
1065
+ "indexed": false,
1066
+ "internalType": "uint64"
1067
+ }
1068
+ ],
1069
+ "anonymous": false
1070
+ },
1071
+ {
1072
+ "type": "event",
1073
+ "name": "RunTriggered",
1074
+ "inputs": [
1075
+ {
1076
+ "name": "id",
1077
+ "type": "uint256",
1078
+ "indexed": true,
1079
+ "internalType": "uint256"
1080
+ },
1081
+ {
1082
+ "name": "by",
1083
+ "type": "address",
1084
+ "indexed": true,
1085
+ "internalType": "address"
1086
+ },
1087
+ {
1088
+ "name": "triggersLeft",
1089
+ "type": "uint16",
1090
+ "indexed": false,
1091
+ "internalType": "uint16"
1092
+ }
1093
+ ],
1094
+ "anonymous": false
1095
+ },
1096
+ {
1097
+ "type": "event",
1098
+ "name": "ScheduleActiveSet",
1099
+ "inputs": [
1100
+ {
1101
+ "name": "id",
1102
+ "type": "uint256",
1103
+ "indexed": true,
1104
+ "internalType": "uint256"
1105
+ },
1106
+ {
1107
+ "name": "active",
1108
+ "type": "bool",
1109
+ "indexed": false,
1110
+ "internalType": "bool"
1111
+ }
1112
+ ],
1113
+ "anonymous": false
1114
+ },
1115
+ {
1116
+ "type": "event",
1117
+ "name": "ScheduleCancelled",
1118
+ "inputs": [
1119
+ {
1120
+ "name": "id",
1121
+ "type": "uint256",
1122
+ "indexed": true,
1123
+ "internalType": "uint256"
1124
+ }
1125
+ ],
1126
+ "anonymous": false
1127
+ },
1128
+ {
1129
+ "type": "event",
1130
+ "name": "ScheduleCreated",
1131
+ "inputs": [
1132
+ {
1133
+ "name": "id",
1134
+ "type": "uint256",
1135
+ "indexed": true,
1136
+ "internalType": "uint256"
1137
+ },
1138
+ {
1139
+ "name": "sender",
1140
+ "type": "address",
1141
+ "indexed": true,
1142
+ "internalType": "address"
1143
+ },
1144
+ {
1145
+ "name": "destination",
1146
+ "type": "address",
1147
+ "indexed": true,
1148
+ "internalType": "address"
1149
+ },
1150
+ {
1151
+ "name": "amountIn",
1152
+ "type": "uint128",
1153
+ "indexed": false,
1154
+ "internalType": "uint128"
1155
+ },
1156
+ {
1157
+ "name": "interval",
1158
+ "type": "uint64",
1159
+ "indexed": false,
1160
+ "internalType": "uint64"
1161
+ },
1162
+ {
1163
+ "name": "minRateE6",
1164
+ "type": "uint96",
1165
+ "indexed": false,
1166
+ "internalType": "uint96"
1167
+ },
1168
+ {
1169
+ "name": "maxRuns",
1170
+ "type": "uint32",
1171
+ "indexed": false,
1172
+ "internalType": "uint32"
1173
+ },
1174
+ {
1175
+ "name": "expiresAt",
1176
+ "type": "uint64",
1177
+ "indexed": false,
1178
+ "internalType": "uint64"
1179
+ },
1180
+ {
1181
+ "name": "payoutType",
1182
+ "type": "uint8",
1183
+ "indexed": false,
1184
+ "internalType": "enum RemessoExecutorV5.PayoutType"
1185
+ }
1186
+ ],
1187
+ "anonymous": false
1188
+ },
1189
+ {
1190
+ "type": "event",
1191
+ "name": "SwapTokenSet",
1192
+ "inputs": [
1193
+ {
1194
+ "name": "token",
1195
+ "type": "address",
1196
+ "indexed": true,
1197
+ "internalType": "address"
1198
+ },
1199
+ {
1200
+ "name": "allowed",
1201
+ "type": "bool",
1202
+ "indexed": false,
1203
+ "internalType": "bool"
1204
+ }
1205
+ ],
1206
+ "anonymous": false
1207
+ },
1208
+ {
1209
+ "type": "event",
1210
+ "name": "TreasuryUpdated",
1211
+ "inputs": [
1212
+ {
1213
+ "name": "previous",
1214
+ "type": "address",
1215
+ "indexed": true,
1216
+ "internalType": "address"
1217
+ },
1218
+ {
1219
+ "name": "current",
1220
+ "type": "address",
1221
+ "indexed": true,
1222
+ "internalType": "address"
1223
+ }
1224
+ ],
1225
+ "anonymous": false
1226
+ },
1227
+ {
1228
+ "type": "event",
1229
+ "name": "TriggerSet",
1230
+ "inputs": [
1231
+ {
1232
+ "name": "id",
1233
+ "type": "uint256",
1234
+ "indexed": true,
1235
+ "internalType": "uint256"
1236
+ },
1237
+ {
1238
+ "name": "trigger",
1239
+ "type": "address",
1240
+ "indexed": true,
1241
+ "internalType": "address"
1242
+ },
1243
+ {
1244
+ "name": "triggersLeft",
1245
+ "type": "uint16",
1246
+ "indexed": false,
1247
+ "internalType": "uint16"
1248
+ }
1249
+ ],
1250
+ "anonymous": false
1251
+ },
1252
+ {
1253
+ "type": "event",
1254
+ "name": "Unpaused",
1255
+ "inputs": [
1256
+ {
1257
+ "name": "account",
1258
+ "type": "address",
1259
+ "indexed": false,
1260
+ "internalType": "address"
1261
+ }
1262
+ ],
1263
+ "anonymous": false
1264
+ },
1265
+ {
1266
+ "type": "error",
1267
+ "name": "DegenerateFloor",
1268
+ "inputs": []
1269
+ },
1270
+ {
1271
+ "type": "error",
1272
+ "name": "EnforcedPause",
1273
+ "inputs": []
1274
+ },
1275
+ {
1276
+ "type": "error",
1277
+ "name": "ExpectedPause",
1278
+ "inputs": []
1279
+ },
1280
+ {
1281
+ "type": "error",
1282
+ "name": "FeeTooHigh",
1283
+ "inputs": [
1284
+ {
1285
+ "name": "provided",
1286
+ "type": "uint16",
1287
+ "internalType": "uint16"
1288
+ },
1289
+ {
1290
+ "name": "max",
1291
+ "type": "uint16",
1292
+ "internalType": "uint16"
1293
+ }
1294
+ ]
1295
+ },
1296
+ {
1297
+ "type": "error",
1298
+ "name": "FirstRunAfterExpiry",
1299
+ "inputs": []
1300
+ },
1301
+ {
1302
+ "type": "error",
1303
+ "name": "InsufficientOutput",
1304
+ "inputs": [
1305
+ {
1306
+ "name": "received",
1307
+ "type": "uint256",
1308
+ "internalType": "uint256"
1309
+ },
1310
+ {
1311
+ "name": "floor",
1312
+ "type": "uint256",
1313
+ "internalType": "uint256"
1314
+ }
1315
+ ]
1316
+ },
1317
+ {
1318
+ "type": "error",
1319
+ "name": "InvalidAmount",
1320
+ "inputs": []
1321
+ },
1322
+ {
1323
+ "type": "error",
1324
+ "name": "InvalidDestination",
1325
+ "inputs": []
1326
+ },
1327
+ {
1328
+ "type": "error",
1329
+ "name": "InvalidInterval",
1330
+ "inputs": []
1331
+ },
1332
+ {
1333
+ "type": "error",
1334
+ "name": "InvalidRate",
1335
+ "inputs": []
1336
+ },
1337
+ {
1338
+ "type": "error",
1339
+ "name": "InvalidTrigger",
1340
+ "inputs": []
1341
+ },
1342
+ {
1343
+ "type": "error",
1344
+ "name": "NoFloorOnDirect",
1345
+ "inputs": []
1346
+ },
1347
+ {
1348
+ "type": "error",
1349
+ "name": "NoTriggersLeft",
1350
+ "inputs": []
1351
+ },
1352
+ {
1353
+ "type": "error",
1354
+ "name": "NotDue",
1355
+ "inputs": [
1356
+ {
1357
+ "name": "nextRunAt",
1358
+ "type": "uint64",
1359
+ "internalType": "uint64"
1360
+ }
1361
+ ]
1362
+ },
1363
+ {
1364
+ "type": "error",
1365
+ "name": "NotExecutor",
1366
+ "inputs": []
1367
+ },
1368
+ {
1369
+ "type": "error",
1370
+ "name": "NotScheduleOwner",
1371
+ "inputs": []
1372
+ },
1373
+ {
1374
+ "type": "error",
1375
+ "name": "NotTrigger",
1376
+ "inputs": []
1377
+ },
1378
+ {
1379
+ "type": "error",
1380
+ "name": "OwnableInvalidOwner",
1381
+ "inputs": [
1382
+ {
1383
+ "name": "owner",
1384
+ "type": "address",
1385
+ "internalType": "address"
1386
+ }
1387
+ ]
1388
+ },
1389
+ {
1390
+ "type": "error",
1391
+ "name": "OwnableUnauthorizedAccount",
1392
+ "inputs": [
1393
+ {
1394
+ "name": "account",
1395
+ "type": "address",
1396
+ "internalType": "address"
1397
+ }
1398
+ ]
1399
+ },
1400
+ {
1401
+ "type": "error",
1402
+ "name": "ReentrancyGuardReentrantCall",
1403
+ "inputs": []
1404
+ },
1405
+ {
1406
+ "type": "error",
1407
+ "name": "RenounceDisabled",
1408
+ "inputs": []
1409
+ },
1410
+ {
1411
+ "type": "error",
1412
+ "name": "RunCapReached",
1413
+ "inputs": []
1414
+ },
1415
+ {
1416
+ "type": "error",
1417
+ "name": "SafeERC20FailedOperation",
1418
+ "inputs": [
1419
+ {
1420
+ "name": "token",
1421
+ "type": "address",
1422
+ "internalType": "address"
1423
+ }
1424
+ ]
1425
+ },
1426
+ {
1427
+ "type": "error",
1428
+ "name": "SameToken",
1429
+ "inputs": []
1430
+ },
1431
+ {
1432
+ "type": "error",
1433
+ "name": "ScheduleExpired",
1434
+ "inputs": []
1435
+ },
1436
+ {
1437
+ "type": "error",
1438
+ "name": "ScheduleInactive",
1439
+ "inputs": []
1440
+ },
1441
+ {
1442
+ "type": "error",
1443
+ "name": "ScheduleIsCancelled",
1444
+ "inputs": []
1445
+ },
1446
+ {
1447
+ "type": "error",
1448
+ "name": "ScheduleLifetimeTooLong",
1449
+ "inputs": []
1450
+ },
1451
+ {
1452
+ "type": "error",
1453
+ "name": "SlippageBoundBelowFloor",
1454
+ "inputs": [
1455
+ {
1456
+ "name": "provided",
1457
+ "type": "uint256",
1458
+ "internalType": "uint256"
1459
+ },
1460
+ {
1461
+ "name": "floor",
1462
+ "type": "uint256",
1463
+ "internalType": "uint256"
1464
+ }
1465
+ ]
1466
+ },
1467
+ {
1468
+ "type": "error",
1469
+ "name": "TokenNotAllowed",
1470
+ "inputs": []
1471
+ },
1472
+ {
1473
+ "type": "error",
1474
+ "name": "TriggeredTooSoon",
1475
+ "inputs": [
1476
+ {
1477
+ "name": "nextAllowed",
1478
+ "type": "uint64",
1479
+ "internalType": "uint64"
1480
+ }
1481
+ ]
1482
+ },
1483
+ {
1484
+ "type": "error",
1485
+ "name": "WrongTokenForPayoutType",
1486
+ "inputs": []
1487
+ },
1488
+ {
1489
+ "type": "error",
1490
+ "name": "ZeroAddress",
1491
+ "inputs": []
1492
+ }
1493
+ ];
1494
+ export const allowanceAbi = [
1495
+ {
1496
+ "type": "function",
1497
+ "name": "MAX_DURATION",
1498
+ "inputs": [],
1499
+ "outputs": [
1500
+ {
1501
+ "name": "",
1502
+ "type": "uint256",
1503
+ "internalType": "uint256"
1504
+ }
1505
+ ],
1506
+ "stateMutability": "view"
1507
+ },
1508
+ {
1509
+ "type": "function",
1510
+ "name": "MAX_RECIPIENTS",
1511
+ "inputs": [],
1512
+ "outputs": [
1513
+ {
1514
+ "name": "",
1515
+ "type": "uint256",
1516
+ "internalType": "uint256"
1517
+ }
1518
+ ],
1519
+ "stateMutability": "view"
1520
+ },
1521
+ {
1522
+ "type": "function",
1523
+ "name": "WINDOW",
1524
+ "inputs": [],
1525
+ "outputs": [
1526
+ {
1527
+ "name": "",
1528
+ "type": "uint256",
1529
+ "internalType": "uint256"
1530
+ }
1531
+ ],
1532
+ "stateMutability": "view"
1533
+ },
1534
+ {
1535
+ "type": "function",
1536
+ "name": "allowed",
1537
+ "inputs": [
1538
+ {
1539
+ "name": "",
1540
+ "type": "uint256",
1541
+ "internalType": "uint256"
1542
+ },
1543
+ {
1544
+ "name": "",
1545
+ "type": "address",
1546
+ "internalType": "address"
1547
+ }
1548
+ ],
1549
+ "outputs": [
1550
+ {
1551
+ "name": "",
1552
+ "type": "bool",
1553
+ "internalType": "bool"
1554
+ }
1555
+ ],
1556
+ "stateMutability": "view"
1557
+ },
1558
+ {
1559
+ "type": "function",
1560
+ "name": "createPolicy",
1561
+ "inputs": [
1562
+ {
1563
+ "name": "agent",
1564
+ "type": "address",
1565
+ "internalType": "address"
1566
+ },
1567
+ {
1568
+ "name": "token",
1569
+ "type": "address",
1570
+ "internalType": "address"
1571
+ },
1572
+ {
1573
+ "name": "perPayment",
1574
+ "type": "uint128",
1575
+ "internalType": "uint128"
1576
+ },
1577
+ {
1578
+ "name": "perDay",
1579
+ "type": "uint128",
1580
+ "internalType": "uint128"
1581
+ },
1582
+ {
1583
+ "name": "expiresAt",
1584
+ "type": "uint64",
1585
+ "internalType": "uint64"
1586
+ },
1587
+ {
1588
+ "name": "allowlistOnly",
1589
+ "type": "bool",
1590
+ "internalType": "bool"
1591
+ },
1592
+ {
1593
+ "name": "recipients",
1594
+ "type": "address[]",
1595
+ "internalType": "address[]"
1596
+ }
1597
+ ],
1598
+ "outputs": [
1599
+ {
1600
+ "name": "id",
1601
+ "type": "uint256",
1602
+ "internalType": "uint256"
1603
+ }
1604
+ ],
1605
+ "stateMutability": "nonpayable"
1606
+ },
1607
+ {
1608
+ "type": "function",
1609
+ "name": "nextPolicyId",
1610
+ "inputs": [],
1611
+ "outputs": [
1612
+ {
1613
+ "name": "",
1614
+ "type": "uint256",
1615
+ "internalType": "uint256"
1616
+ }
1617
+ ],
1618
+ "stateMutability": "view"
1619
+ },
1620
+ {
1621
+ "type": "function",
1622
+ "name": "pay",
1623
+ "inputs": [
1624
+ {
1625
+ "name": "id",
1626
+ "type": "uint256",
1627
+ "internalType": "uint256"
1628
+ },
1629
+ {
1630
+ "name": "to",
1631
+ "type": "address",
1632
+ "internalType": "address"
1633
+ },
1634
+ {
1635
+ "name": "amount",
1636
+ "type": "uint256",
1637
+ "internalType": "uint256"
1638
+ },
1639
+ {
1640
+ "name": "memo",
1641
+ "type": "bytes32",
1642
+ "internalType": "bytes32"
1643
+ }
1644
+ ],
1645
+ "outputs": [],
1646
+ "stateMutability": "nonpayable"
1647
+ },
1648
+ {
1649
+ "type": "function",
1650
+ "name": "policy",
1651
+ "inputs": [
1652
+ {
1653
+ "name": "id",
1654
+ "type": "uint256",
1655
+ "internalType": "uint256"
1656
+ }
1657
+ ],
1658
+ "outputs": [
1659
+ {
1660
+ "name": "",
1661
+ "type": "tuple",
1662
+ "internalType": "struct RemessoAgentAllowance.Policy",
1663
+ "components": [
1664
+ {
1665
+ "name": "owner",
1666
+ "type": "address",
1667
+ "internalType": "address"
1668
+ },
1669
+ {
1670
+ "name": "agent",
1671
+ "type": "address",
1672
+ "internalType": "address"
1673
+ },
1674
+ {
1675
+ "name": "token",
1676
+ "type": "address",
1677
+ "internalType": "address"
1678
+ },
1679
+ {
1680
+ "name": "expiresAt",
1681
+ "type": "uint64",
1682
+ "internalType": "uint64"
1683
+ },
1684
+ {
1685
+ "name": "allowlistOnly",
1686
+ "type": "bool",
1687
+ "internalType": "bool"
1688
+ },
1689
+ {
1690
+ "name": "revoked",
1691
+ "type": "bool",
1692
+ "internalType": "bool"
1693
+ },
1694
+ {
1695
+ "name": "perPayment",
1696
+ "type": "uint128",
1697
+ "internalType": "uint128"
1698
+ },
1699
+ {
1700
+ "name": "perDay",
1701
+ "type": "uint128",
1702
+ "internalType": "uint128"
1703
+ },
1704
+ {
1705
+ "name": "spentInWindow",
1706
+ "type": "uint128",
1707
+ "internalType": "uint128"
1708
+ },
1709
+ {
1710
+ "name": "windowStart",
1711
+ "type": "uint64",
1712
+ "internalType": "uint64"
1713
+ }
1714
+ ]
1715
+ }
1716
+ ],
1717
+ "stateMutability": "view"
1718
+ },
1719
+ {
1720
+ "type": "function",
1721
+ "name": "remainingToday",
1722
+ "inputs": [
1723
+ {
1724
+ "name": "id",
1725
+ "type": "uint256",
1726
+ "internalType": "uint256"
1727
+ }
1728
+ ],
1729
+ "outputs": [
1730
+ {
1731
+ "name": "",
1732
+ "type": "uint256",
1733
+ "internalType": "uint256"
1734
+ }
1735
+ ],
1736
+ "stateMutability": "view"
1737
+ },
1738
+ {
1739
+ "type": "function",
1740
+ "name": "revoke",
1741
+ "inputs": [
1742
+ {
1743
+ "name": "id",
1744
+ "type": "uint256",
1745
+ "internalType": "uint256"
1746
+ }
1747
+ ],
1748
+ "outputs": [],
1749
+ "stateMutability": "nonpayable"
1750
+ },
1751
+ {
1752
+ "type": "function",
1753
+ "name": "setRecipient",
1754
+ "inputs": [
1755
+ {
1756
+ "name": "id",
1757
+ "type": "uint256",
1758
+ "internalType": "uint256"
1759
+ },
1760
+ {
1761
+ "name": "recipient",
1762
+ "type": "address",
1763
+ "internalType": "address"
1764
+ },
1765
+ {
1766
+ "name": "ok",
1767
+ "type": "bool",
1768
+ "internalType": "bool"
1769
+ }
1770
+ ],
1771
+ "outputs": [],
1772
+ "stateMutability": "nonpayable"
1773
+ },
1774
+ {
1775
+ "type": "event",
1776
+ "name": "Paid",
1777
+ "inputs": [
1778
+ {
1779
+ "name": "id",
1780
+ "type": "uint256",
1781
+ "indexed": true,
1782
+ "internalType": "uint256"
1783
+ },
1784
+ {
1785
+ "name": "to",
1786
+ "type": "address",
1787
+ "indexed": true,
1788
+ "internalType": "address"
1789
+ },
1790
+ {
1791
+ "name": "amount",
1792
+ "type": "uint256",
1793
+ "indexed": false,
1794
+ "internalType": "uint256"
1795
+ },
1796
+ {
1797
+ "name": "memo",
1798
+ "type": "bytes32",
1799
+ "indexed": false,
1800
+ "internalType": "bytes32"
1801
+ }
1802
+ ],
1803
+ "anonymous": false
1804
+ },
1805
+ {
1806
+ "type": "event",
1807
+ "name": "PolicyCreated",
1808
+ "inputs": [
1809
+ {
1810
+ "name": "id",
1811
+ "type": "uint256",
1812
+ "indexed": true,
1813
+ "internalType": "uint256"
1814
+ },
1815
+ {
1816
+ "name": "owner",
1817
+ "type": "address",
1818
+ "indexed": true,
1819
+ "internalType": "address"
1820
+ },
1821
+ {
1822
+ "name": "agent",
1823
+ "type": "address",
1824
+ "indexed": true,
1825
+ "internalType": "address"
1826
+ },
1827
+ {
1828
+ "name": "token",
1829
+ "type": "address",
1830
+ "indexed": false,
1831
+ "internalType": "address"
1832
+ },
1833
+ {
1834
+ "name": "perPayment",
1835
+ "type": "uint128",
1836
+ "indexed": false,
1837
+ "internalType": "uint128"
1838
+ },
1839
+ {
1840
+ "name": "perDay",
1841
+ "type": "uint128",
1842
+ "indexed": false,
1843
+ "internalType": "uint128"
1844
+ },
1845
+ {
1846
+ "name": "expiresAt",
1847
+ "type": "uint64",
1848
+ "indexed": false,
1849
+ "internalType": "uint64"
1850
+ },
1851
+ {
1852
+ "name": "allowlistOnly",
1853
+ "type": "bool",
1854
+ "indexed": false,
1855
+ "internalType": "bool"
1856
+ }
1857
+ ],
1858
+ "anonymous": false
1859
+ },
1860
+ {
1861
+ "type": "event",
1862
+ "name": "PolicyRevoked",
1863
+ "inputs": [
1864
+ {
1865
+ "name": "id",
1866
+ "type": "uint256",
1867
+ "indexed": true,
1868
+ "internalType": "uint256"
1869
+ }
1870
+ ],
1871
+ "anonymous": false
1872
+ },
1873
+ {
1874
+ "type": "event",
1875
+ "name": "RecipientSet",
1876
+ "inputs": [
1877
+ {
1878
+ "name": "id",
1879
+ "type": "uint256",
1880
+ "indexed": true,
1881
+ "internalType": "uint256"
1882
+ },
1883
+ {
1884
+ "name": "recipient",
1885
+ "type": "address",
1886
+ "indexed": true,
1887
+ "internalType": "address"
1888
+ },
1889
+ {
1890
+ "name": "allowed",
1891
+ "type": "bool",
1892
+ "indexed": false,
1893
+ "internalType": "bool"
1894
+ }
1895
+ ],
1896
+ "anonymous": false
1897
+ },
1898
+ {
1899
+ "type": "error",
1900
+ "name": "BadExpiry",
1901
+ "inputs": []
1902
+ },
1903
+ {
1904
+ "type": "error",
1905
+ "name": "BadLimits",
1906
+ "inputs": []
1907
+ },
1908
+ {
1909
+ "type": "error",
1910
+ "name": "Expired",
1911
+ "inputs": []
1912
+ },
1913
+ {
1914
+ "type": "error",
1915
+ "name": "NotAgent",
1916
+ "inputs": []
1917
+ },
1918
+ {
1919
+ "type": "error",
1920
+ "name": "NotOwner",
1921
+ "inputs": []
1922
+ },
1923
+ {
1924
+ "type": "error",
1925
+ "name": "OverPerDay",
1926
+ "inputs": []
1927
+ },
1928
+ {
1929
+ "type": "error",
1930
+ "name": "OverPerPayment",
1931
+ "inputs": []
1932
+ },
1933
+ {
1934
+ "type": "error",
1935
+ "name": "RecipientNotAllowed",
1936
+ "inputs": []
1937
+ },
1938
+ {
1939
+ "type": "error",
1940
+ "name": "ReentrancyGuardReentrantCall",
1941
+ "inputs": []
1942
+ },
1943
+ {
1944
+ "type": "error",
1945
+ "name": "Revoked",
1946
+ "inputs": []
1947
+ },
1948
+ {
1949
+ "type": "error",
1950
+ "name": "SafeERC20FailedOperation",
1951
+ "inputs": [
1952
+ {
1953
+ "name": "token",
1954
+ "type": "address",
1955
+ "internalType": "address"
1956
+ }
1957
+ ]
1958
+ },
1959
+ {
1960
+ "type": "error",
1961
+ "name": "SelfPayment",
1962
+ "inputs": []
1963
+ },
1964
+ {
1965
+ "type": "error",
1966
+ "name": "TooManyRecipients",
1967
+ "inputs": []
1968
+ },
1969
+ {
1970
+ "type": "error",
1971
+ "name": "ZeroAddress",
1972
+ "inputs": []
1973
+ },
1974
+ {
1975
+ "type": "error",
1976
+ "name": "ZeroAmount",
1977
+ "inputs": []
1978
+ }
1979
+ ];