@varun-ai07/covenant-mcp 1.2.0 → 1.2.1

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 +451 -366
  2. package/dist/abis/AgentWallet.json +415 -0
  3. package/dist/abis/COVENANTRouter.json +173 -0
  4. package/dist/abis/CapabilityVerifier.json +213 -0
  5. package/dist/abis/Groth16Verifier.json +36 -0
  6. package/dist/abis/Groth16VerifierCapability.json +36 -0
  7. package/dist/abis/Groth16VerifierReputation.json +36 -0
  8. package/dist/abis/LitProtocolIntegration.json +703 -0
  9. package/dist/abis/ReputationVerifier.json +213 -0
  10. package/dist/config.d.ts.map +1 -1
  11. package/dist/config.js +38 -1
  12. package/dist/config.js.map +1 -1
  13. package/dist/handlers/transactions.d.ts.map +1 -1
  14. package/dist/handlers/transactions.js +274 -27
  15. package/dist/handlers/transactions.js.map +1 -1
  16. package/dist/handlers/wallet.d.ts +3 -1
  17. package/dist/handlers/wallet.d.ts.map +1 -1
  18. package/dist/handlers/wallet.js +82 -2
  19. package/dist/handlers/wallet.js.map +1 -1
  20. package/dist/lib/cache.d.ts +53 -0
  21. package/dist/lib/cache.d.ts.map +1 -0
  22. package/dist/lib/cache.js +154 -0
  23. package/dist/lib/cache.js.map +1 -0
  24. package/dist/lib/events.d.ts +73 -0
  25. package/dist/lib/events.d.ts.map +1 -0
  26. package/dist/lib/events.js +203 -0
  27. package/dist/lib/events.js.map +1 -0
  28. package/dist/tools/batches.d.ts.map +1 -1
  29. package/dist/tools/batches.js +4 -3
  30. package/dist/tools/batches.js.map +1 -1
  31. package/dist/tools/collectives.d.ts.map +1 -1
  32. package/dist/tools/collectives.js +15 -6
  33. package/dist/tools/collectives.js.map +1 -1
  34. package/dist/tools/escrow.d.ts.map +1 -1
  35. package/dist/tools/escrow.js +8 -6
  36. package/dist/tools/escrow.js.map +1 -1
  37. package/dist/tools/insurance.d.ts.map +1 -1
  38. package/dist/tools/insurance.js +7 -4
  39. package/dist/tools/insurance.js.map +1 -1
  40. package/dist/tools/receipts.d.ts.map +1 -1
  41. package/dist/tools/receipts.js +49 -61
  42. package/dist/tools/receipts.js.map +1 -1
  43. package/dist/types.d.ts +7 -0
  44. package/dist/types.d.ts.map +1 -1
  45. package/dist/utils.d.ts +52 -0
  46. package/dist/utils.d.ts.map +1 -0
  47. package/dist/utils.js +217 -0
  48. package/dist/utils.js.map +1 -0
  49. package/package.json +1 -1
@@ -0,0 +1,703 @@
1
+ [
2
+ {
3
+ "inputs": [
4
+ {
5
+ "internalType": "address",
6
+ "name": "_taskEscrow",
7
+ "type": "address"
8
+ },
9
+ {
10
+ "internalType": "address",
11
+ "name": "_agentRegistry",
12
+ "type": "address"
13
+ }
14
+ ],
15
+ "stateMutability": "nonpayable",
16
+ "type": "constructor"
17
+ },
18
+ {
19
+ "inputs": [],
20
+ "name": "AlreadyAuthorized",
21
+ "type": "error"
22
+ },
23
+ {
24
+ "inputs": [],
25
+ "name": "ConditionNotMet",
26
+ "type": "error"
27
+ },
28
+ {
29
+ "inputs": [],
30
+ "name": "DecryptionNotAllowed",
31
+ "type": "error"
32
+ },
33
+ {
34
+ "inputs": [],
35
+ "name": "InvalidAddress",
36
+ "type": "error"
37
+ },
38
+ {
39
+ "inputs": [],
40
+ "name": "InvalidCondition",
41
+ "type": "error"
42
+ },
43
+ {
44
+ "inputs": [],
45
+ "name": "NotAuthorized",
46
+ "type": "error"
47
+ },
48
+ {
49
+ "inputs": [
50
+ {
51
+ "internalType": "address",
52
+ "name": "owner",
53
+ "type": "address"
54
+ }
55
+ ],
56
+ "name": "OwnableInvalidOwner",
57
+ "type": "error"
58
+ },
59
+ {
60
+ "inputs": [
61
+ {
62
+ "internalType": "address",
63
+ "name": "account",
64
+ "type": "address"
65
+ }
66
+ ],
67
+ "name": "OwnableUnauthorizedAccount",
68
+ "type": "error"
69
+ },
70
+ {
71
+ "inputs": [],
72
+ "name": "TimeLockNotExpired",
73
+ "type": "error"
74
+ },
75
+ {
76
+ "anonymous": false,
77
+ "inputs": [
78
+ {
79
+ "indexed": true,
80
+ "internalType": "uint256",
81
+ "name": "conditionId",
82
+ "type": "uint256"
83
+ },
84
+ {
85
+ "indexed": true,
86
+ "internalType": "address",
87
+ "name": "verifier",
88
+ "type": "address"
89
+ },
90
+ {
91
+ "indexed": false,
92
+ "internalType": "bool",
93
+ "name": "result",
94
+ "type": "bool"
95
+ }
96
+ ],
97
+ "name": "ConditionVerified",
98
+ "type": "event"
99
+ },
100
+ {
101
+ "anonymous": false,
102
+ "inputs": [
103
+ {
104
+ "indexed": true,
105
+ "internalType": "uint256",
106
+ "name": "conditionId",
107
+ "type": "uint256"
108
+ },
109
+ {
110
+ "indexed": true,
111
+ "internalType": "address",
112
+ "name": "requester",
113
+ "type": "address"
114
+ },
115
+ {
116
+ "indexed": false,
117
+ "internalType": "bytes",
118
+ "name": "decryptionKey",
119
+ "type": "bytes"
120
+ }
121
+ ],
122
+ "name": "DecryptionAuthorized",
123
+ "type": "event"
124
+ },
125
+ {
126
+ "anonymous": false,
127
+ "inputs": [
128
+ {
129
+ "indexed": true,
130
+ "internalType": "uint256",
131
+ "name": "conditionId",
132
+ "type": "uint256"
133
+ },
134
+ {
135
+ "indexed": false,
136
+ "internalType": "enum LitProtocolIntegration.ConditionType",
137
+ "name": "conditionType",
138
+ "type": "uint8"
139
+ },
140
+ {
141
+ "indexed": false,
142
+ "internalType": "bytes",
143
+ "name": "encryptedData",
144
+ "type": "bytes"
145
+ }
146
+ ],
147
+ "name": "EncryptionConditionSet",
148
+ "type": "event"
149
+ },
150
+ {
151
+ "anonymous": false,
152
+ "inputs": [
153
+ {
154
+ "indexed": true,
155
+ "internalType": "address",
156
+ "name": "previousOwner",
157
+ "type": "address"
158
+ },
159
+ {
160
+ "indexed": true,
161
+ "internalType": "address",
162
+ "name": "newOwner",
163
+ "type": "address"
164
+ }
165
+ ],
166
+ "name": "OwnershipTransferred",
167
+ "type": "event"
168
+ },
169
+ {
170
+ "anonymous": false,
171
+ "inputs": [
172
+ {
173
+ "indexed": false,
174
+ "internalType": "uint256",
175
+ "name": "oldThreshold",
176
+ "type": "uint256"
177
+ },
178
+ {
179
+ "indexed": false,
180
+ "internalType": "uint256",
181
+ "name": "newThreshold",
182
+ "type": "uint256"
183
+ }
184
+ ],
185
+ "name": "ThresholdUpdated",
186
+ "type": "event"
187
+ },
188
+ {
189
+ "inputs": [
190
+ {
191
+ "internalType": "address",
192
+ "name": "verifier",
193
+ "type": "address"
194
+ }
195
+ ],
196
+ "name": "addTrustedVerifier",
197
+ "outputs": [],
198
+ "stateMutability": "nonpayable",
199
+ "type": "function"
200
+ },
201
+ {
202
+ "inputs": [],
203
+ "name": "agentRegistry",
204
+ "outputs": [
205
+ {
206
+ "internalType": "address",
207
+ "name": "",
208
+ "type": "address"
209
+ }
210
+ ],
211
+ "stateMutability": "view",
212
+ "type": "function"
213
+ },
214
+ {
215
+ "inputs": [
216
+ {
217
+ "internalType": "uint256",
218
+ "name": "",
219
+ "type": "uint256"
220
+ },
221
+ {
222
+ "internalType": "uint256",
223
+ "name": "",
224
+ "type": "uint256"
225
+ }
226
+ ],
227
+ "name": "authorizations",
228
+ "outputs": [
229
+ {
230
+ "internalType": "address",
231
+ "name": "requester",
232
+ "type": "address"
233
+ },
234
+ {
235
+ "internalType": "uint256",
236
+ "name": "conditionId",
237
+ "type": "uint256"
238
+ },
239
+ {
240
+ "internalType": "bool",
241
+ "name": "authorized",
242
+ "type": "bool"
243
+ },
244
+ {
245
+ "internalType": "uint256",
246
+ "name": "timestamp",
247
+ "type": "uint256"
248
+ }
249
+ ],
250
+ "stateMutability": "view",
251
+ "type": "function"
252
+ },
253
+ {
254
+ "inputs": [
255
+ {
256
+ "internalType": "uint256",
257
+ "name": "conditionId",
258
+ "type": "uint256"
259
+ },
260
+ {
261
+ "internalType": "address",
262
+ "name": "requester",
263
+ "type": "address"
264
+ }
265
+ ],
266
+ "name": "authorizeDecryption",
267
+ "outputs": [],
268
+ "stateMutability": "nonpayable",
269
+ "type": "function"
270
+ },
271
+ {
272
+ "inputs": [],
273
+ "name": "conditionCounter",
274
+ "outputs": [
275
+ {
276
+ "internalType": "uint256",
277
+ "name": "",
278
+ "type": "uint256"
279
+ }
280
+ ],
281
+ "stateMutability": "view",
282
+ "type": "function"
283
+ },
284
+ {
285
+ "inputs": [
286
+ {
287
+ "internalType": "uint256",
288
+ "name": "",
289
+ "type": "uint256"
290
+ }
291
+ ],
292
+ "name": "conditions",
293
+ "outputs": [
294
+ {
295
+ "internalType": "enum LitProtocolIntegration.ConditionType",
296
+ "name": "conditionType",
297
+ "type": "uint8"
298
+ },
299
+ {
300
+ "internalType": "uint256",
301
+ "name": "targetId",
302
+ "type": "uint256"
303
+ },
304
+ {
305
+ "internalType": "address",
306
+ "name": "targetContract",
307
+ "type": "address"
308
+ },
309
+ {
310
+ "internalType": "bytes",
311
+ "name": "encryptedSymmetricKey",
312
+ "type": "bytes"
313
+ },
314
+ {
315
+ "internalType": "bytes",
316
+ "name": "encryptedData",
317
+ "type": "bytes"
318
+ },
319
+ {
320
+ "internalType": "bool",
321
+ "name": "isDecrypted",
322
+ "type": "bool"
323
+ },
324
+ {
325
+ "internalType": "uint256",
326
+ "name": "createdAt",
327
+ "type": "uint256"
328
+ },
329
+ {
330
+ "internalType": "uint256",
331
+ "name": "decryptedAt",
332
+ "type": "uint256"
333
+ }
334
+ ],
335
+ "stateMutability": "view",
336
+ "type": "function"
337
+ },
338
+ {
339
+ "inputs": [],
340
+ "name": "decryptionThreshold",
341
+ "outputs": [
342
+ {
343
+ "internalType": "uint256",
344
+ "name": "",
345
+ "type": "uint256"
346
+ }
347
+ ],
348
+ "stateMutability": "view",
349
+ "type": "function"
350
+ },
351
+ {
352
+ "inputs": [
353
+ {
354
+ "internalType": "uint256",
355
+ "name": "conditionId",
356
+ "type": "uint256"
357
+ }
358
+ ],
359
+ "name": "getAuthorizationCount",
360
+ "outputs": [
361
+ {
362
+ "internalType": "uint256",
363
+ "name": "",
364
+ "type": "uint256"
365
+ }
366
+ ],
367
+ "stateMutability": "view",
368
+ "type": "function"
369
+ },
370
+ {
371
+ "inputs": [
372
+ {
373
+ "internalType": "uint256",
374
+ "name": "conditionId",
375
+ "type": "uint256"
376
+ }
377
+ ],
378
+ "name": "getCondition",
379
+ "outputs": [
380
+ {
381
+ "internalType": "enum LitProtocolIntegration.ConditionType",
382
+ "name": "conditionType",
383
+ "type": "uint8"
384
+ },
385
+ {
386
+ "internalType": "uint256",
387
+ "name": "targetId",
388
+ "type": "uint256"
389
+ },
390
+ {
391
+ "internalType": "address",
392
+ "name": "targetContract",
393
+ "type": "address"
394
+ },
395
+ {
396
+ "internalType": "bool",
397
+ "name": "isDecrypted",
398
+ "type": "bool"
399
+ },
400
+ {
401
+ "internalType": "uint256",
402
+ "name": "createdAt",
403
+ "type": "uint256"
404
+ },
405
+ {
406
+ "internalType": "uint256",
407
+ "name": "decryptedAt",
408
+ "type": "uint256"
409
+ }
410
+ ],
411
+ "stateMutability": "view",
412
+ "type": "function"
413
+ },
414
+ {
415
+ "inputs": [],
416
+ "name": "getTrustedVerifiers",
417
+ "outputs": [
418
+ {
419
+ "internalType": "address[]",
420
+ "name": "",
421
+ "type": "address[]"
422
+ }
423
+ ],
424
+ "stateMutability": "view",
425
+ "type": "function"
426
+ },
427
+ {
428
+ "inputs": [
429
+ {
430
+ "internalType": "uint256",
431
+ "name": "",
432
+ "type": "uint256"
433
+ },
434
+ {
435
+ "internalType": "address",
436
+ "name": "",
437
+ "type": "address"
438
+ }
439
+ ],
440
+ "name": "hasAuthorized",
441
+ "outputs": [
442
+ {
443
+ "internalType": "bool",
444
+ "name": "",
445
+ "type": "bool"
446
+ }
447
+ ],
448
+ "stateMutability": "view",
449
+ "type": "function"
450
+ },
451
+ {
452
+ "inputs": [
453
+ {
454
+ "internalType": "uint256",
455
+ "name": "conditionId",
456
+ "type": "uint256"
457
+ }
458
+ ],
459
+ "name": "isDecryptionAllowed",
460
+ "outputs": [
461
+ {
462
+ "internalType": "bool",
463
+ "name": "",
464
+ "type": "bool"
465
+ }
466
+ ],
467
+ "stateMutability": "view",
468
+ "type": "function"
469
+ },
470
+ {
471
+ "inputs": [
472
+ {
473
+ "internalType": "address",
474
+ "name": "",
475
+ "type": "address"
476
+ }
477
+ ],
478
+ "name": "isTrustedVerifier",
479
+ "outputs": [
480
+ {
481
+ "internalType": "bool",
482
+ "name": "",
483
+ "type": "bool"
484
+ }
485
+ ],
486
+ "stateMutability": "view",
487
+ "type": "function"
488
+ },
489
+ {
490
+ "inputs": [
491
+ {
492
+ "internalType": "uint256",
493
+ "name": "conditionId",
494
+ "type": "uint256"
495
+ }
496
+ ],
497
+ "name": "markDecrypted",
498
+ "outputs": [],
499
+ "stateMutability": "nonpayable",
500
+ "type": "function"
501
+ },
502
+ {
503
+ "inputs": [],
504
+ "name": "owner",
505
+ "outputs": [
506
+ {
507
+ "internalType": "address",
508
+ "name": "",
509
+ "type": "address"
510
+ }
511
+ ],
512
+ "stateMutability": "view",
513
+ "type": "function"
514
+ },
515
+ {
516
+ "inputs": [
517
+ {
518
+ "internalType": "address",
519
+ "name": "verifier",
520
+ "type": "address"
521
+ }
522
+ ],
523
+ "name": "removeTrustedVerifier",
524
+ "outputs": [],
525
+ "stateMutability": "nonpayable",
526
+ "type": "function"
527
+ },
528
+ {
529
+ "inputs": [],
530
+ "name": "renounceOwnership",
531
+ "outputs": [],
532
+ "stateMutability": "nonpayable",
533
+ "type": "function"
534
+ },
535
+ {
536
+ "inputs": [
537
+ {
538
+ "internalType": "address",
539
+ "name": "_taskEscrow",
540
+ "type": "address"
541
+ },
542
+ {
543
+ "internalType": "address",
544
+ "name": "_agentRegistry",
545
+ "type": "address"
546
+ }
547
+ ],
548
+ "name": "setContractAddresses",
549
+ "outputs": [],
550
+ "stateMutability": "nonpayable",
551
+ "type": "function"
552
+ },
553
+ {
554
+ "inputs": [
555
+ {
556
+ "internalType": "uint256",
557
+ "name": "newThreshold",
558
+ "type": "uint256"
559
+ }
560
+ ],
561
+ "name": "setDecryptionThreshold",
562
+ "outputs": [],
563
+ "stateMutability": "nonpayable",
564
+ "type": "function"
565
+ },
566
+ {
567
+ "inputs": [
568
+ {
569
+ "internalType": "enum LitProtocolIntegration.ConditionType",
570
+ "name": "conditionType",
571
+ "type": "uint8"
572
+ },
573
+ {
574
+ "internalType": "uint256",
575
+ "name": "targetId",
576
+ "type": "uint256"
577
+ },
578
+ {
579
+ "internalType": "bytes",
580
+ "name": "encryptedSymmetricKey",
581
+ "type": "bytes"
582
+ },
583
+ {
584
+ "internalType": "bytes",
585
+ "name": "encryptedData",
586
+ "type": "bytes"
587
+ }
588
+ ],
589
+ "name": "setEncryptionCondition",
590
+ "outputs": [
591
+ {
592
+ "internalType": "uint256",
593
+ "name": "",
594
+ "type": "uint256"
595
+ }
596
+ ],
597
+ "stateMutability": "nonpayable",
598
+ "type": "function"
599
+ },
600
+ {
601
+ "inputs": [
602
+ {
603
+ "internalType": "enum LitProtocolIntegration.ConditionType",
604
+ "name": "conditionType",
605
+ "type": "uint8"
606
+ },
607
+ {
608
+ "internalType": "uint256",
609
+ "name": "targetId",
610
+ "type": "uint256"
611
+ },
612
+ {
613
+ "internalType": "address",
614
+ "name": "targetContract",
615
+ "type": "address"
616
+ },
617
+ {
618
+ "internalType": "bytes",
619
+ "name": "encryptedSymmetricKey",
620
+ "type": "bytes"
621
+ },
622
+ {
623
+ "internalType": "bytes",
624
+ "name": "encryptedData",
625
+ "type": "bytes"
626
+ }
627
+ ],
628
+ "name": "setEncryptionConditionWithTarget",
629
+ "outputs": [
630
+ {
631
+ "internalType": "uint256",
632
+ "name": "",
633
+ "type": "uint256"
634
+ }
635
+ ],
636
+ "stateMutability": "nonpayable",
637
+ "type": "function"
638
+ },
639
+ {
640
+ "inputs": [],
641
+ "name": "taskEscrow",
642
+ "outputs": [
643
+ {
644
+ "internalType": "address",
645
+ "name": "",
646
+ "type": "address"
647
+ }
648
+ ],
649
+ "stateMutability": "view",
650
+ "type": "function"
651
+ },
652
+ {
653
+ "inputs": [
654
+ {
655
+ "internalType": "address",
656
+ "name": "newOwner",
657
+ "type": "address"
658
+ }
659
+ ],
660
+ "name": "transferOwnership",
661
+ "outputs": [],
662
+ "stateMutability": "nonpayable",
663
+ "type": "function"
664
+ },
665
+ {
666
+ "inputs": [
667
+ {
668
+ "internalType": "uint256",
669
+ "name": "",
670
+ "type": "uint256"
671
+ }
672
+ ],
673
+ "name": "trustedVerifiers",
674
+ "outputs": [
675
+ {
676
+ "internalType": "address",
677
+ "name": "",
678
+ "type": "address"
679
+ }
680
+ ],
681
+ "stateMutability": "view",
682
+ "type": "function"
683
+ },
684
+ {
685
+ "inputs": [
686
+ {
687
+ "internalType": "uint256",
688
+ "name": "conditionId",
689
+ "type": "uint256"
690
+ }
691
+ ],
692
+ "name": "verifyCondition",
693
+ "outputs": [
694
+ {
695
+ "internalType": "bool",
696
+ "name": "",
697
+ "type": "bool"
698
+ }
699
+ ],
700
+ "stateMutability": "nonpayable",
701
+ "type": "function"
702
+ }
703
+ ]