@blindmarket/sdk 0.1.8 → 0.4.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 (87) hide show
  1. package/dist/executor/WorkerRuntime.d.ts +21 -0
  2. package/dist/executor/WorkerRuntime.js +56 -27
  3. package/dist/index.d.ts +75 -9
  4. package/dist/index.js +52 -3
  5. package/package.json +8 -1
  6. package/biome.json +0 -19
  7. package/examples/agent-demo.ts +0 -121
  8. package/scripts/gen-crypto-fixtures.mjs +0 -72
  9. package/src/agent/Agent.ts +0 -122
  10. package/src/agent/index.ts +0 -1
  11. package/src/api/index.ts +0 -1
  12. package/src/chain/BlindEscrowClient.ts +0 -196
  13. package/src/chain/BlindReputationClient.ts +0 -60
  14. package/src/chain/ChainClient.ts +0 -65
  15. package/src/chain/IBlindMarketChain.ts +0 -109
  16. package/src/chain/TaskRegistryClient.ts +0 -91
  17. package/src/chain/abi/BlindEscrow.json +0 -1113
  18. package/src/chain/abi/BlindReputation.json +0 -447
  19. package/src/chain/abi/TaskRegistry.json +0 -586
  20. package/src/chain/abi/index.ts +0 -5
  21. package/src/chain/createChainAdapter.ts +0 -40
  22. package/src/chain/domain-types.ts +0 -92
  23. package/src/chain/errors.ts +0 -43
  24. package/src/chain/evm/EVMChainAdapter.ts +0 -212
  25. package/src/chain/evm/index.ts +0 -1
  26. package/src/chain/index.ts +0 -12
  27. package/src/compute/index.ts +0 -1
  28. package/src/crypto/aes.ts +0 -104
  29. package/src/crypto/constants.ts +0 -7
  30. package/src/crypto/ecies.ts +0 -60
  31. package/src/crypto/envelope.ts +0 -131
  32. package/src/crypto/hkdf.ts +0 -45
  33. package/src/crypto/index.ts +0 -6
  34. package/src/crypto/keys.ts +0 -56
  35. package/src/errors/BlindMarketError.ts +0 -38
  36. package/src/errors/codes.ts +0 -67
  37. package/src/errors/index.ts +0 -3
  38. package/src/errors/subclasses.ts +0 -59
  39. package/src/events/EventBus.ts +0 -45
  40. package/src/events/index.ts +0 -2
  41. package/src/events/types.ts +0 -13
  42. package/src/executor/WorkerRuntime.ts +0 -338
  43. package/src/executor/index.ts +0 -8
  44. package/src/index.ts +0 -636
  45. package/src/keystore/InMemoryKeyStore.ts +0 -146
  46. package/src/keystore/KeyStore.ts +0 -19
  47. package/src/keystore/index.ts +0 -2
  48. package/src/network/index.ts +0 -3
  49. package/src/network/presets.ts +0 -66
  50. package/src/network/resolve.ts +0 -31
  51. package/src/network/types.ts +0 -20
  52. package/src/signer/EthersSigner.ts +0 -82
  53. package/src/signer/PrivateKeySigner.ts +0 -19
  54. package/src/signer/Signer.ts +0 -40
  55. package/src/signer/index.ts +0 -3
  56. package/src/storage/MemoryStorage.ts +0 -49
  57. package/src/storage/Storage.ts +0 -15
  58. package/src/storage/ZgStorage.ts +0 -124
  59. package/src/storage/index.ts +0 -3
  60. package/src/testing/index.ts +0 -1
  61. package/src/tools/adapters.ts +0 -177
  62. package/src/tools/helpers.ts +0 -199
  63. package/src/tools/index.ts +0 -59
  64. package/src/tools/types.ts +0 -47
  65. package/src/types.ts +0 -297
  66. package/src/verifier/index.ts +0 -1
  67. package/src/worker/Worker.ts +0 -98
  68. package/src/worker/index.ts +0 -1
  69. package/test/agent.test.ts +0 -193
  70. package/test/chain.test.ts +0 -145
  71. package/test/crypto.aes.test.ts +0 -81
  72. package/test/crypto.compat.test.ts +0 -33
  73. package/test/crypto.ecies.test.ts +0 -64
  74. package/test/envelope.test.ts +0 -82
  75. package/test/errors.test.ts +0 -64
  76. package/test/events.test.ts +0 -59
  77. package/test/fixtures/crypto.json +0 -16
  78. package/test/keystore.test.ts +0 -103
  79. package/test/network.test.ts +0 -53
  80. package/test/signer.test.ts +0 -66
  81. package/test/smoke.test.ts +0 -7
  82. package/test/storage.test.ts +0 -55
  83. package/test/worker.test.ts +0 -181
  84. package/tsconfig.build.json +0 -1
  85. package/tsconfig.json +0 -14
  86. package/tsup.config.ts +0 -32
  87. package/vitest.config.ts +0 -17
@@ -1,1113 +0,0 @@
1
- [
2
- {
3
- "inputs": [
4
- {
5
- "internalType": "address",
6
- "name": "_treasury",
7
- "type": "address"
8
- },
9
- {
10
- "internalType": "address",
11
- "name": "_verifier",
12
- "type": "address"
13
- }
14
- ],
15
- "stateMutability": "nonpayable",
16
- "type": "constructor"
17
- },
18
- {
19
- "inputs": [],
20
- "name": "DeadlineNotReached",
21
- "type": "error"
22
- },
23
- {
24
- "inputs": [],
25
- "name": "DeadlineReached",
26
- "type": "error"
27
- },
28
- {
29
- "inputs": [],
30
- "name": "EmptyHash",
31
- "type": "error"
32
- },
33
- {
34
- "inputs": [],
35
- "name": "EnforcedPause",
36
- "type": "error"
37
- },
38
- {
39
- "inputs": [],
40
- "name": "ExpectedPause",
41
- "type": "error"
42
- },
43
- {
44
- "inputs": [],
45
- "name": "FeeExceedsMax",
46
- "type": "error"
47
- },
48
- {
49
- "inputs": [],
50
- "name": "InvalidDeadline",
51
- "type": "error"
52
- },
53
- {
54
- "inputs": [
55
- {
56
- "internalType": "enum BlindEscrow.TaskStatus",
57
- "name": "current",
58
- "type": "uint8"
59
- },
60
- {
61
- "internalType": "enum BlindEscrow.TaskStatus",
62
- "name": "required",
63
- "type": "uint8"
64
- }
65
- ],
66
- "name": "InvalidStatus",
67
- "type": "error"
68
- },
69
- {
70
- "inputs": [],
71
- "name": "MaxSubmissionAttemptsReached",
72
- "type": "error"
73
- },
74
- {
75
- "inputs": [],
76
- "name": "NotAdmin",
77
- "type": "error"
78
- },
79
- {
80
- "inputs": [],
81
- "name": "NotAgent",
82
- "type": "error"
83
- },
84
- {
85
- "inputs": [],
86
- "name": "NotPendingAdmin",
87
- "type": "error"
88
- },
89
- {
90
- "inputs": [],
91
- "name": "NotVerifier",
92
- "type": "error"
93
- },
94
- {
95
- "inputs": [],
96
- "name": "NotWorker",
97
- "type": "error"
98
- },
99
- {
100
- "inputs": [],
101
- "name": "ReentrancyGuardReentrantCall",
102
- "type": "error"
103
- },
104
- {
105
- "inputs": [
106
- {
107
- "internalType": "address",
108
- "name": "token",
109
- "type": "address"
110
- }
111
- ],
112
- "name": "SafeERC20FailedOperation",
113
- "type": "error"
114
- },
115
- {
116
- "inputs": [],
117
- "name": "SelfAssignment",
118
- "type": "error"
119
- },
120
- {
121
- "inputs": [],
122
- "name": "TokenNotAllowed",
123
- "type": "error"
124
- },
125
- {
126
- "inputs": [],
127
- "name": "ZeroAddress",
128
- "type": "error"
129
- },
130
- {
131
- "inputs": [],
132
- "name": "ZeroAmount",
133
- "type": "error"
134
- },
135
- {
136
- "anonymous": false,
137
- "inputs": [
138
- {
139
- "indexed": true,
140
- "internalType": "address",
141
- "name": "oldAdmin",
142
- "type": "address"
143
- },
144
- {
145
- "indexed": true,
146
- "internalType": "address",
147
- "name": "newAdmin",
148
- "type": "address"
149
- }
150
- ],
151
- "name": "AdminTransferCompleted",
152
- "type": "event"
153
- },
154
- {
155
- "anonymous": false,
156
- "inputs": [
157
- {
158
- "indexed": true,
159
- "internalType": "address",
160
- "name": "currentAdmin",
161
- "type": "address"
162
- },
163
- {
164
- "indexed": true,
165
- "internalType": "address",
166
- "name": "pendingAdmin",
167
- "type": "address"
168
- }
169
- ],
170
- "name": "AdminTransferProposed",
171
- "type": "event"
172
- },
173
- {
174
- "anonymous": false,
175
- "inputs": [
176
- {
177
- "indexed": true,
178
- "internalType": "uint256",
179
- "name": "taskId",
180
- "type": "uint256"
181
- },
182
- {
183
- "indexed": false,
184
- "internalType": "uint256",
185
- "name": "refundAmount",
186
- "type": "uint256"
187
- }
188
- ],
189
- "name": "DeadlineExpired",
190
- "type": "event"
191
- },
192
- {
193
- "anonymous": false,
194
- "inputs": [
195
- {
196
- "indexed": true,
197
- "internalType": "uint256",
198
- "name": "taskId",
199
- "type": "uint256"
200
- },
201
- {
202
- "indexed": false,
203
- "internalType": "bool",
204
- "name": "workerFavored",
205
- "type": "bool"
206
- }
207
- ],
208
- "name": "DisputeResolved",
209
- "type": "event"
210
- },
211
- {
212
- "anonymous": false,
213
- "inputs": [
214
- {
215
- "indexed": true,
216
- "internalType": "uint256",
217
- "name": "taskId",
218
- "type": "uint256"
219
- },
220
- {
221
- "indexed": true,
222
- "internalType": "address",
223
- "name": "worker",
224
- "type": "address"
225
- },
226
- {
227
- "indexed": false,
228
- "internalType": "bytes32",
229
- "name": "evidenceHash",
230
- "type": "bytes32"
231
- },
232
- {
233
- "indexed": false,
234
- "internalType": "uint8",
235
- "name": "attempt",
236
- "type": "uint8"
237
- }
238
- ],
239
- "name": "EvidenceSubmitted",
240
- "type": "event"
241
- },
242
- {
243
- "anonymous": false,
244
- "inputs": [
245
- {
246
- "indexed": false,
247
- "internalType": "uint256",
248
- "name": "oldFeeBps",
249
- "type": "uint256"
250
- },
251
- {
252
- "indexed": false,
253
- "internalType": "uint256",
254
- "name": "newFeeBps",
255
- "type": "uint256"
256
- }
257
- ],
258
- "name": "FeeBpsUpdated",
259
- "type": "event"
260
- },
261
- {
262
- "anonymous": false,
263
- "inputs": [
264
- {
265
- "indexed": false,
266
- "internalType": "address",
267
- "name": "account",
268
- "type": "address"
269
- }
270
- ],
271
- "name": "Paused",
272
- "type": "event"
273
- },
274
- {
275
- "anonymous": false,
276
- "inputs": [
277
- {
278
- "indexed": true,
279
- "internalType": "address",
280
- "name": "oldContract",
281
- "type": "address"
282
- },
283
- {
284
- "indexed": true,
285
- "internalType": "address",
286
- "name": "newContract",
287
- "type": "address"
288
- }
289
- ],
290
- "name": "ReputationContractUpdated",
291
- "type": "event"
292
- },
293
- {
294
- "anonymous": false,
295
- "inputs": [
296
- {
297
- "indexed": true,
298
- "internalType": "uint256",
299
- "name": "taskId",
300
- "type": "uint256"
301
- },
302
- {
303
- "indexed": false,
304
- "internalType": "uint256",
305
- "name": "refundAmount",
306
- "type": "uint256"
307
- }
308
- ],
309
- "name": "TaskCancelled",
310
- "type": "event"
311
- },
312
- {
313
- "anonymous": false,
314
- "inputs": [
315
- {
316
- "indexed": true,
317
- "internalType": "uint256",
318
- "name": "taskId",
319
- "type": "uint256"
320
- },
321
- {
322
- "indexed": false,
323
- "internalType": "uint256",
324
- "name": "workerPayout",
325
- "type": "uint256"
326
- },
327
- {
328
- "indexed": false,
329
- "internalType": "uint256",
330
- "name": "platformFee",
331
- "type": "uint256"
332
- }
333
- ],
334
- "name": "TaskCompleted",
335
- "type": "event"
336
- },
337
- {
338
- "anonymous": false,
339
- "inputs": [
340
- {
341
- "indexed": true,
342
- "internalType": "uint256",
343
- "name": "taskId",
344
- "type": "uint256"
345
- },
346
- {
347
- "indexed": true,
348
- "internalType": "address",
349
- "name": "agent",
350
- "type": "address"
351
- },
352
- {
353
- "indexed": false,
354
- "internalType": "address",
355
- "name": "token",
356
- "type": "address"
357
- },
358
- {
359
- "indexed": false,
360
- "internalType": "uint256",
361
- "name": "amount",
362
- "type": "uint256"
363
- },
364
- {
365
- "indexed": false,
366
- "internalType": "bytes32",
367
- "name": "taskHash",
368
- "type": "bytes32"
369
- },
370
- {
371
- "indexed": false,
372
- "internalType": "string",
373
- "name": "category",
374
- "type": "string"
375
- },
376
- {
377
- "indexed": false,
378
- "internalType": "string",
379
- "name": "locationZone",
380
- "type": "string"
381
- },
382
- {
383
- "indexed": false,
384
- "internalType": "uint256",
385
- "name": "deadline",
386
- "type": "uint256"
387
- }
388
- ],
389
- "name": "TaskCreated",
390
- "type": "event"
391
- },
392
- {
393
- "anonymous": false,
394
- "inputs": [
395
- {
396
- "indexed": true,
397
- "internalType": "uint256",
398
- "name": "taskId",
399
- "type": "uint256"
400
- },
401
- {
402
- "indexed": true,
403
- "internalType": "address",
404
- "name": "initiator",
405
- "type": "address"
406
- }
407
- ],
408
- "name": "TaskDisputed",
409
- "type": "event"
410
- },
411
- {
412
- "anonymous": false,
413
- "inputs": [
414
- {
415
- "indexed": true,
416
- "internalType": "address",
417
- "name": "oldRegistry",
418
- "type": "address"
419
- },
420
- {
421
- "indexed": true,
422
- "internalType": "address",
423
- "name": "newRegistry",
424
- "type": "address"
425
- }
426
- ],
427
- "name": "TaskRegistryUpdated",
428
- "type": "event"
429
- },
430
- {
431
- "anonymous": false,
432
- "inputs": [
433
- {
434
- "indexed": true,
435
- "internalType": "address",
436
- "name": "token",
437
- "type": "address"
438
- }
439
- ],
440
- "name": "TokenAllowed",
441
- "type": "event"
442
- },
443
- {
444
- "anonymous": false,
445
- "inputs": [
446
- {
447
- "indexed": true,
448
- "internalType": "address",
449
- "name": "token",
450
- "type": "address"
451
- }
452
- ],
453
- "name": "TokenDisallowed",
454
- "type": "event"
455
- },
456
- {
457
- "anonymous": false,
458
- "inputs": [
459
- {
460
- "indexed": true,
461
- "internalType": "address",
462
- "name": "oldTreasury",
463
- "type": "address"
464
- },
465
- {
466
- "indexed": true,
467
- "internalType": "address",
468
- "name": "newTreasury",
469
- "type": "address"
470
- }
471
- ],
472
- "name": "TreasuryUpdated",
473
- "type": "event"
474
- },
475
- {
476
- "anonymous": false,
477
- "inputs": [
478
- {
479
- "indexed": false,
480
- "internalType": "address",
481
- "name": "account",
482
- "type": "address"
483
- }
484
- ],
485
- "name": "Unpaused",
486
- "type": "event"
487
- },
488
- {
489
- "anonymous": false,
490
- "inputs": [
491
- {
492
- "indexed": true,
493
- "internalType": "uint256",
494
- "name": "taskId",
495
- "type": "uint256"
496
- },
497
- {
498
- "indexed": false,
499
- "internalType": "bool",
500
- "name": "passed",
501
- "type": "bool"
502
- }
503
- ],
504
- "name": "VerificationCompleted",
505
- "type": "event"
506
- },
507
- {
508
- "anonymous": false,
509
- "inputs": [
510
- {
511
- "indexed": true,
512
- "internalType": "address",
513
- "name": "oldVerifier",
514
- "type": "address"
515
- },
516
- {
517
- "indexed": true,
518
- "internalType": "address",
519
- "name": "newVerifier",
520
- "type": "address"
521
- }
522
- ],
523
- "name": "VerifierUpdated",
524
- "type": "event"
525
- },
526
- {
527
- "anonymous": false,
528
- "inputs": [
529
- {
530
- "indexed": true,
531
- "internalType": "uint256",
532
- "name": "taskId",
533
- "type": "uint256"
534
- },
535
- {
536
- "indexed": true,
537
- "internalType": "address",
538
- "name": "worker",
539
- "type": "address"
540
- }
541
- ],
542
- "name": "WorkerAssigned",
543
- "type": "event"
544
- },
545
- {
546
- "inputs": [],
547
- "name": "MAX_DEADLINE",
548
- "outputs": [
549
- {
550
- "internalType": "uint256",
551
- "name": "",
552
- "type": "uint256"
553
- }
554
- ],
555
- "stateMutability": "view",
556
- "type": "function"
557
- },
558
- {
559
- "inputs": [],
560
- "name": "MAX_FEE_BPS",
561
- "outputs": [
562
- {
563
- "internalType": "uint256",
564
- "name": "",
565
- "type": "uint256"
566
- }
567
- ],
568
- "stateMutability": "view",
569
- "type": "function"
570
- },
571
- {
572
- "inputs": [],
573
- "name": "MAX_SUBMISSION_ATTEMPTS",
574
- "outputs": [
575
- {
576
- "internalType": "uint8",
577
- "name": "",
578
- "type": "uint8"
579
- }
580
- ],
581
- "stateMutability": "view",
582
- "type": "function"
583
- },
584
- {
585
- "inputs": [],
586
- "name": "MIN_DEADLINE",
587
- "outputs": [
588
- {
589
- "internalType": "uint256",
590
- "name": "",
591
- "type": "uint256"
592
- }
593
- ],
594
- "stateMutability": "view",
595
- "type": "function"
596
- },
597
- {
598
- "inputs": [],
599
- "name": "acceptAdmin",
600
- "outputs": [],
601
- "stateMutability": "nonpayable",
602
- "type": "function"
603
- },
604
- {
605
- "inputs": [],
606
- "name": "admin",
607
- "outputs": [
608
- {
609
- "internalType": "address",
610
- "name": "",
611
- "type": "address"
612
- }
613
- ],
614
- "stateMutability": "view",
615
- "type": "function"
616
- },
617
- {
618
- "inputs": [
619
- {
620
- "internalType": "address",
621
- "name": "token",
622
- "type": "address"
623
- }
624
- ],
625
- "name": "allowToken",
626
- "outputs": [],
627
- "stateMutability": "nonpayable",
628
- "type": "function"
629
- },
630
- {
631
- "inputs": [
632
- {
633
- "internalType": "address",
634
- "name": "",
635
- "type": "address"
636
- }
637
- ],
638
- "name": "allowedTokens",
639
- "outputs": [
640
- {
641
- "internalType": "bool",
642
- "name": "",
643
- "type": "bool"
644
- }
645
- ],
646
- "stateMutability": "view",
647
- "type": "function"
648
- },
649
- {
650
- "inputs": [
651
- {
652
- "internalType": "uint256",
653
- "name": "taskId",
654
- "type": "uint256"
655
- },
656
- {
657
- "internalType": "address",
658
- "name": "worker",
659
- "type": "address"
660
- }
661
- ],
662
- "name": "assignWorker",
663
- "outputs": [],
664
- "stateMutability": "nonpayable",
665
- "type": "function"
666
- },
667
- {
668
- "inputs": [
669
- {
670
- "internalType": "uint256",
671
- "name": "taskId",
672
- "type": "uint256"
673
- }
674
- ],
675
- "name": "cancelTask",
676
- "outputs": [],
677
- "stateMutability": "nonpayable",
678
- "type": "function"
679
- },
680
- {
681
- "inputs": [
682
- {
683
- "internalType": "uint256",
684
- "name": "taskId",
685
- "type": "uint256"
686
- }
687
- ],
688
- "name": "claimTimeout",
689
- "outputs": [],
690
- "stateMutability": "nonpayable",
691
- "type": "function"
692
- },
693
- {
694
- "inputs": [
695
- {
696
- "internalType": "uint256",
697
- "name": "taskId",
698
- "type": "uint256"
699
- },
700
- {
701
- "internalType": "bool",
702
- "name": "passed",
703
- "type": "bool"
704
- }
705
- ],
706
- "name": "completeVerification",
707
- "outputs": [],
708
- "stateMutability": "nonpayable",
709
- "type": "function"
710
- },
711
- {
712
- "inputs": [
713
- {
714
- "internalType": "bytes32",
715
- "name": "taskHash",
716
- "type": "bytes32"
717
- },
718
- {
719
- "internalType": "address",
720
- "name": "token",
721
- "type": "address"
722
- },
723
- {
724
- "internalType": "uint256",
725
- "name": "amount",
726
- "type": "uint256"
727
- },
728
- {
729
- "internalType": "string",
730
- "name": "category",
731
- "type": "string"
732
- },
733
- {
734
- "internalType": "string",
735
- "name": "locationZone",
736
- "type": "string"
737
- },
738
- {
739
- "internalType": "uint256",
740
- "name": "duration",
741
- "type": "uint256"
742
- }
743
- ],
744
- "name": "createTask",
745
- "outputs": [
746
- {
747
- "internalType": "uint256",
748
- "name": "taskId",
749
- "type": "uint256"
750
- }
751
- ],
752
- "stateMutability": "nonpayable",
753
- "type": "function"
754
- },
755
- {
756
- "inputs": [
757
- {
758
- "internalType": "address",
759
- "name": "token",
760
- "type": "address"
761
- }
762
- ],
763
- "name": "disallowToken",
764
- "outputs": [],
765
- "stateMutability": "nonpayable",
766
- "type": "function"
767
- },
768
- {
769
- "inputs": [],
770
- "name": "feeBps",
771
- "outputs": [
772
- {
773
- "internalType": "uint256",
774
- "name": "",
775
- "type": "uint256"
776
- }
777
- ],
778
- "stateMutability": "view",
779
- "type": "function"
780
- },
781
- {
782
- "inputs": [
783
- {
784
- "internalType": "uint256",
785
- "name": "taskId",
786
- "type": "uint256"
787
- }
788
- ],
789
- "name": "getTask",
790
- "outputs": [
791
- {
792
- "components": [
793
- {
794
- "internalType": "address",
795
- "name": "agent",
796
- "type": "address"
797
- },
798
- {
799
- "internalType": "address",
800
- "name": "worker",
801
- "type": "address"
802
- },
803
- {
804
- "internalType": "address",
805
- "name": "token",
806
- "type": "address"
807
- },
808
- {
809
- "internalType": "uint256",
810
- "name": "amount",
811
- "type": "uint256"
812
- },
813
- {
814
- "internalType": "bytes32",
815
- "name": "taskHash",
816
- "type": "bytes32"
817
- },
818
- {
819
- "internalType": "bytes32",
820
- "name": "evidenceHash",
821
- "type": "bytes32"
822
- },
823
- {
824
- "internalType": "enum BlindEscrow.TaskStatus",
825
- "name": "status",
826
- "type": "uint8"
827
- },
828
- {
829
- "internalType": "string",
830
- "name": "category",
831
- "type": "string"
832
- },
833
- {
834
- "internalType": "string",
835
- "name": "locationZone",
836
- "type": "string"
837
- },
838
- {
839
- "internalType": "uint256",
840
- "name": "createdAt",
841
- "type": "uint256"
842
- },
843
- {
844
- "internalType": "uint256",
845
- "name": "deadline",
846
- "type": "uint256"
847
- },
848
- {
849
- "internalType": "uint8",
850
- "name": "submissionAttempts",
851
- "type": "uint8"
852
- }
853
- ],
854
- "internalType": "struct BlindEscrow.Task",
855
- "name": "",
856
- "type": "tuple"
857
- }
858
- ],
859
- "stateMutability": "view",
860
- "type": "function"
861
- },
862
- {
863
- "inputs": [
864
- {
865
- "internalType": "uint256",
866
- "name": "taskId",
867
- "type": "uint256"
868
- }
869
- ],
870
- "name": "isTaskExpired",
871
- "outputs": [
872
- {
873
- "internalType": "bool",
874
- "name": "",
875
- "type": "bool"
876
- }
877
- ],
878
- "stateMutability": "view",
879
- "type": "function"
880
- },
881
- {
882
- "inputs": [],
883
- "name": "nextTaskId",
884
- "outputs": [
885
- {
886
- "internalType": "uint256",
887
- "name": "",
888
- "type": "uint256"
889
- }
890
- ],
891
- "stateMutability": "view",
892
- "type": "function"
893
- },
894
- {
895
- "inputs": [],
896
- "name": "pause",
897
- "outputs": [],
898
- "stateMutability": "nonpayable",
899
- "type": "function"
900
- },
901
- {
902
- "inputs": [],
903
- "name": "paused",
904
- "outputs": [
905
- {
906
- "internalType": "bool",
907
- "name": "",
908
- "type": "bool"
909
- }
910
- ],
911
- "stateMutability": "view",
912
- "type": "function"
913
- },
914
- {
915
- "inputs": [],
916
- "name": "pendingAdmin",
917
- "outputs": [
918
- {
919
- "internalType": "address",
920
- "name": "",
921
- "type": "address"
922
- }
923
- ],
924
- "stateMutability": "view",
925
- "type": "function"
926
- },
927
- {
928
- "inputs": [
929
- {
930
- "internalType": "address",
931
- "name": "_newAdmin",
932
- "type": "address"
933
- }
934
- ],
935
- "name": "proposeAdmin",
936
- "outputs": [],
937
- "stateMutability": "nonpayable",
938
- "type": "function"
939
- },
940
- {
941
- "inputs": [
942
- {
943
- "internalType": "uint256",
944
- "name": "taskId",
945
- "type": "uint256"
946
- }
947
- ],
948
- "name": "raiseDispute",
949
- "outputs": [],
950
- "stateMutability": "nonpayable",
951
- "type": "function"
952
- },
953
- {
954
- "inputs": [],
955
- "name": "reputationContract",
956
- "outputs": [
957
- {
958
- "internalType": "contract IBlindReputation",
959
- "name": "",
960
- "type": "address"
961
- }
962
- ],
963
- "stateMutability": "view",
964
- "type": "function"
965
- },
966
- {
967
- "inputs": [
968
- {
969
- "internalType": "uint256",
970
- "name": "taskId",
971
- "type": "uint256"
972
- },
973
- {
974
- "internalType": "bool",
975
- "name": "workerFavored",
976
- "type": "bool"
977
- }
978
- ],
979
- "name": "resolveDispute",
980
- "outputs": [],
981
- "stateMutability": "nonpayable",
982
- "type": "function"
983
- },
984
- {
985
- "inputs": [
986
- {
987
- "internalType": "uint256",
988
- "name": "_feeBps",
989
- "type": "uint256"
990
- }
991
- ],
992
- "name": "setFeeBps",
993
- "outputs": [],
994
- "stateMutability": "nonpayable",
995
- "type": "function"
996
- },
997
- {
998
- "inputs": [
999
- {
1000
- "internalType": "address",
1001
- "name": "_reputation",
1002
- "type": "address"
1003
- }
1004
- ],
1005
- "name": "setReputationContract",
1006
- "outputs": [],
1007
- "stateMutability": "nonpayable",
1008
- "type": "function"
1009
- },
1010
- {
1011
- "inputs": [
1012
- {
1013
- "internalType": "address",
1014
- "name": "_registry",
1015
- "type": "address"
1016
- }
1017
- ],
1018
- "name": "setTaskRegistry",
1019
- "outputs": [],
1020
- "stateMutability": "nonpayable",
1021
- "type": "function"
1022
- },
1023
- {
1024
- "inputs": [
1025
- {
1026
- "internalType": "address",
1027
- "name": "_treasury",
1028
- "type": "address"
1029
- }
1030
- ],
1031
- "name": "setTreasury",
1032
- "outputs": [],
1033
- "stateMutability": "nonpayable",
1034
- "type": "function"
1035
- },
1036
- {
1037
- "inputs": [
1038
- {
1039
- "internalType": "address",
1040
- "name": "_verifier",
1041
- "type": "address"
1042
- }
1043
- ],
1044
- "name": "setVerifier",
1045
- "outputs": [],
1046
- "stateMutability": "nonpayable",
1047
- "type": "function"
1048
- },
1049
- {
1050
- "inputs": [
1051
- {
1052
- "internalType": "uint256",
1053
- "name": "taskId",
1054
- "type": "uint256"
1055
- },
1056
- {
1057
- "internalType": "bytes32",
1058
- "name": "evidenceHash",
1059
- "type": "bytes32"
1060
- }
1061
- ],
1062
- "name": "submitEvidence",
1063
- "outputs": [],
1064
- "stateMutability": "nonpayable",
1065
- "type": "function"
1066
- },
1067
- {
1068
- "inputs": [],
1069
- "name": "taskRegistry",
1070
- "outputs": [
1071
- {
1072
- "internalType": "contract ITaskRegistry",
1073
- "name": "",
1074
- "type": "address"
1075
- }
1076
- ],
1077
- "stateMutability": "view",
1078
- "type": "function"
1079
- },
1080
- {
1081
- "inputs": [],
1082
- "name": "treasury",
1083
- "outputs": [
1084
- {
1085
- "internalType": "address",
1086
- "name": "",
1087
- "type": "address"
1088
- }
1089
- ],
1090
- "stateMutability": "view",
1091
- "type": "function"
1092
- },
1093
- {
1094
- "inputs": [],
1095
- "name": "unpause",
1096
- "outputs": [],
1097
- "stateMutability": "nonpayable",
1098
- "type": "function"
1099
- },
1100
- {
1101
- "inputs": [],
1102
- "name": "verifier",
1103
- "outputs": [
1104
- {
1105
- "internalType": "address",
1106
- "name": "",
1107
- "type": "address"
1108
- }
1109
- ],
1110
- "stateMutability": "view",
1111
- "type": "function"
1112
- }
1113
- ]