402mob-merchant-sdk 0.4.2 → 0.6.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.
@@ -0,0 +1,3117 @@
1
+ // Generated by scripts/update-inspection-sdk.mjs from public/openapi.json.
2
+ export const inspectionSchemaHash = '8ce432ff8bb61355db7c2d01e7a5048ec20ed0688087df7094134788a81c81e7';
3
+ export const inspectionSchemas = {
4
+ "ProtectedInspectionPrepareRequest": {
5
+ "type": "object",
6
+ "properties": {
7
+ "task": {
8
+ "type": "object",
9
+ "properties": {
10
+ "version": {
11
+ "type": "string",
12
+ "const": "funded-inspection-v1"
13
+ },
14
+ "requestId": {
15
+ "type": "string",
16
+ "format": "uuid",
17
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
18
+ },
19
+ "proposalId": {
20
+ "type": "string",
21
+ "format": "uuid",
22
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
23
+ },
24
+ "proposalTermsHash": {
25
+ "type": "string",
26
+ "pattern": "^[a-f0-9]{64}$"
27
+ },
28
+ "plan": {
29
+ "type": "object",
30
+ "properties": {
31
+ "version": {
32
+ "type": "string",
33
+ "const": "buyer-probe-v1"
34
+ },
35
+ "targetUrl": {
36
+ "type": "string",
37
+ "maxLength": 2048,
38
+ "format": "uri"
39
+ },
40
+ "method": {
41
+ "type": "string",
42
+ "const": "GET"
43
+ },
44
+ "paymentRecipient": {
45
+ "type": "string",
46
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
47
+ },
48
+ "maxTestAmountAtomic": {
49
+ "type": "string",
50
+ "pattern": "^(?:0|[1-9][0-9]{0,5}|1000000)$"
51
+ },
52
+ "maxPaidAttempts": {
53
+ "type": "number",
54
+ "const": 1
55
+ }
56
+ },
57
+ "required": [
58
+ "version",
59
+ "targetUrl",
60
+ "method",
61
+ "paymentRecipient",
62
+ "maxTestAmountAtomic",
63
+ "maxPaidAttempts"
64
+ ],
65
+ "additionalProperties": false
66
+ }
67
+ },
68
+ "required": [
69
+ "version",
70
+ "requestId",
71
+ "proposalId",
72
+ "proposalTermsHash",
73
+ "plan"
74
+ ],
75
+ "additionalProperties": false
76
+ },
77
+ "terms": {
78
+ "type": "object",
79
+ "properties": {
80
+ "buyer": {
81
+ "type": "string",
82
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
83
+ },
84
+ "seller": {
85
+ "type": "string",
86
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
87
+ },
88
+ "amount": {
89
+ "type": "string",
90
+ "pattern": "^(?:[1-9][0-9]{0,7}|100000000)$"
91
+ },
92
+ "deliveryDeadline": {
93
+ "type": "integer",
94
+ "exclusiveMinimum": 0,
95
+ "maximum": 9007199254740991
96
+ },
97
+ "evaluationPeriod": {
98
+ "type": "integer",
99
+ "minimum": 300,
100
+ "maximum": 86400
101
+ },
102
+ "correctionPeriod": {
103
+ "type": "integer",
104
+ "minimum": 300,
105
+ "maximum": 86400
106
+ },
107
+ "resolutionDeadline": {
108
+ "type": "integer",
109
+ "exclusiveMinimum": 0,
110
+ "maximum": 9007199254740991
111
+ },
112
+ "reviewPeriod": {
113
+ "type": "integer",
114
+ "minimum": 300,
115
+ "maximum": 86400
116
+ },
117
+ "appealPeriod": {
118
+ "type": "integer",
119
+ "minimum": 300,
120
+ "maximum": 86400
121
+ },
122
+ "appealVerifier": {
123
+ "type": "string",
124
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
125
+ },
126
+ "fallbackVerifier": {
127
+ "type": "string",
128
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
129
+ },
130
+ "appealOriginHash": {
131
+ "type": "string",
132
+ "pattern": "^0x[0-9a-f]{64}$"
133
+ },
134
+ "fallbackOriginHash": {
135
+ "type": "string",
136
+ "pattern": "^0x[0-9a-f]{64}$"
137
+ },
138
+ "nonce": {
139
+ "type": "string",
140
+ "pattern": "^0x[0-9a-f]{64}$"
141
+ }
142
+ },
143
+ "required": [
144
+ "buyer",
145
+ "seller",
146
+ "amount",
147
+ "deliveryDeadline",
148
+ "evaluationPeriod",
149
+ "correctionPeriod",
150
+ "resolutionDeadline",
151
+ "reviewPeriod",
152
+ "appealPeriod",
153
+ "appealVerifier",
154
+ "fallbackVerifier",
155
+ "appealOriginHash",
156
+ "fallbackOriginHash",
157
+ "nonce"
158
+ ],
159
+ "additionalProperties": false
160
+ }
161
+ },
162
+ "required": [
163
+ "task",
164
+ "terms"
165
+ ],
166
+ "additionalProperties": false
167
+ },
168
+ "ProtectedInspectionFundingRequest": {
169
+ "type": "object",
170
+ "properties": {
171
+ "terms": {
172
+ "type": "object",
173
+ "properties": {
174
+ "buyer": {
175
+ "type": "string",
176
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
177
+ },
178
+ "seller": {
179
+ "type": "string",
180
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
181
+ },
182
+ "amount": {
183
+ "type": "string",
184
+ "pattern": "^(?:[1-9][0-9]{0,7}|100000000)$"
185
+ },
186
+ "workHash": {
187
+ "type": "string",
188
+ "pattern": "^0x[0-9a-f]{64}$"
189
+ },
190
+ "deliveryDeadline": {
191
+ "type": "integer",
192
+ "exclusiveMinimum": 0,
193
+ "maximum": 9007199254740991
194
+ },
195
+ "evaluationPeriod": {
196
+ "type": "integer",
197
+ "minimum": 300,
198
+ "maximum": 86400
199
+ },
200
+ "correctionPeriod": {
201
+ "type": "integer",
202
+ "minimum": 300,
203
+ "maximum": 86400
204
+ },
205
+ "resolutionDeadline": {
206
+ "type": "integer",
207
+ "exclusiveMinimum": 0,
208
+ "maximum": 9007199254740991
209
+ },
210
+ "reviewPeriod": {
211
+ "type": "integer",
212
+ "minimum": 300,
213
+ "maximum": 86400
214
+ },
215
+ "appealPeriod": {
216
+ "type": "integer",
217
+ "minimum": 300,
218
+ "maximum": 86400
219
+ },
220
+ "appealVerifier": {
221
+ "type": "string",
222
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
223
+ },
224
+ "fallbackVerifier": {
225
+ "type": "string",
226
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
227
+ },
228
+ "appealOriginHash": {
229
+ "type": "string",
230
+ "pattern": "^0x[0-9a-f]{64}$"
231
+ },
232
+ "fallbackOriginHash": {
233
+ "type": "string",
234
+ "pattern": "^0x[0-9a-f]{64}$"
235
+ },
236
+ "verifierHash": {
237
+ "type": "string",
238
+ "const": "0x9ab07031c15c8a11071e8e65aaeabfb4d11160466bb76c5733477d6436757312"
239
+ },
240
+ "nonce": {
241
+ "type": "string",
242
+ "pattern": "^0x[0-9a-f]{64}$"
243
+ }
244
+ },
245
+ "required": [
246
+ "buyer",
247
+ "seller",
248
+ "amount",
249
+ "workHash",
250
+ "deliveryDeadline",
251
+ "evaluationPeriod",
252
+ "correctionPeriod",
253
+ "resolutionDeadline",
254
+ "reviewPeriod",
255
+ "appealPeriod",
256
+ "appealVerifier",
257
+ "fallbackVerifier",
258
+ "appealOriginHash",
259
+ "fallbackOriginHash",
260
+ "verifierHash",
261
+ "nonce"
262
+ ],
263
+ "additionalProperties": false
264
+ },
265
+ "sellerSignature": {
266
+ "type": "string",
267
+ "pattern": "^0x[0-9a-fA-F]{130}$"
268
+ },
269
+ "consentUntil": {
270
+ "type": "integer",
271
+ "exclusiveMinimum": 0,
272
+ "maximum": 9007199254740991
273
+ },
274
+ "appealConsent": {
275
+ "type": "string",
276
+ "pattern": "^0x[0-9a-fA-F]{130}$"
277
+ },
278
+ "fallbackConsent": {
279
+ "type": "string",
280
+ "pattern": "^0x[0-9a-fA-F]{130}$"
281
+ },
282
+ "task": {
283
+ "type": "object",
284
+ "properties": {
285
+ "version": {
286
+ "type": "string",
287
+ "const": "funded-inspection-v1"
288
+ },
289
+ "requestId": {
290
+ "type": "string",
291
+ "format": "uuid",
292
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
293
+ },
294
+ "proposalId": {
295
+ "type": "string",
296
+ "format": "uuid",
297
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
298
+ },
299
+ "proposalTermsHash": {
300
+ "type": "string",
301
+ "pattern": "^[a-f0-9]{64}$"
302
+ },
303
+ "plan": {
304
+ "type": "object",
305
+ "properties": {
306
+ "version": {
307
+ "type": "string",
308
+ "const": "buyer-probe-v1"
309
+ },
310
+ "targetUrl": {
311
+ "type": "string",
312
+ "maxLength": 2048,
313
+ "format": "uri"
314
+ },
315
+ "method": {
316
+ "type": "string",
317
+ "const": "GET"
318
+ },
319
+ "paymentRecipient": {
320
+ "type": "string",
321
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
322
+ },
323
+ "maxTestAmountAtomic": {
324
+ "type": "string",
325
+ "pattern": "^(?:0|[1-9][0-9]{0,5}|1000000)$"
326
+ },
327
+ "maxPaidAttempts": {
328
+ "type": "number",
329
+ "const": 1
330
+ }
331
+ },
332
+ "required": [
333
+ "version",
334
+ "targetUrl",
335
+ "method",
336
+ "paymentRecipient",
337
+ "maxTestAmountAtomic",
338
+ "maxPaidAttempts"
339
+ ],
340
+ "additionalProperties": false
341
+ }
342
+ },
343
+ "required": [
344
+ "version",
345
+ "requestId",
346
+ "proposalId",
347
+ "proposalTermsHash",
348
+ "plan"
349
+ ],
350
+ "additionalProperties": false
351
+ }
352
+ },
353
+ "required": [
354
+ "terms",
355
+ "sellerSignature",
356
+ "consentUntil",
357
+ "appealConsent",
358
+ "fallbackConsent",
359
+ "task"
360
+ ],
361
+ "additionalProperties": false
362
+ },
363
+ "ProtectedInspectionChallengeRequest": {
364
+ "type": "object",
365
+ "properties": {
366
+ "action": {
367
+ "type": "string",
368
+ "const": "read"
369
+ },
370
+ "wallet": {
371
+ "type": "string",
372
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
373
+ }
374
+ },
375
+ "required": [
376
+ "action",
377
+ "wallet"
378
+ ],
379
+ "additionalProperties": false
380
+ },
381
+ "ProtectedInspectionSubmissionRequest": {
382
+ "type": "object",
383
+ "properties": {
384
+ "task": {
385
+ "type": "object",
386
+ "properties": {
387
+ "version": {
388
+ "type": "string",
389
+ "const": "funded-inspection-v1"
390
+ },
391
+ "requestId": {
392
+ "type": "string",
393
+ "format": "uuid",
394
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
395
+ },
396
+ "proposalId": {
397
+ "type": "string",
398
+ "format": "uuid",
399
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
400
+ },
401
+ "proposalTermsHash": {
402
+ "type": "string",
403
+ "pattern": "^[a-f0-9]{64}$"
404
+ },
405
+ "plan": {
406
+ "type": "object",
407
+ "properties": {
408
+ "version": {
409
+ "type": "string",
410
+ "const": "buyer-probe-v1"
411
+ },
412
+ "targetUrl": {
413
+ "type": "string",
414
+ "maxLength": 2048,
415
+ "format": "uri"
416
+ },
417
+ "method": {
418
+ "type": "string",
419
+ "const": "GET"
420
+ },
421
+ "paymentRecipient": {
422
+ "type": "string",
423
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
424
+ },
425
+ "maxTestAmountAtomic": {
426
+ "type": "string",
427
+ "pattern": "^(?:0|[1-9][0-9]{0,5}|1000000)$"
428
+ },
429
+ "maxPaidAttempts": {
430
+ "type": "number",
431
+ "const": 1
432
+ }
433
+ },
434
+ "required": [
435
+ "version",
436
+ "targetUrl",
437
+ "method",
438
+ "paymentRecipient",
439
+ "maxTestAmountAtomic",
440
+ "maxPaidAttempts"
441
+ ],
442
+ "additionalProperties": false
443
+ }
444
+ },
445
+ "required": [
446
+ "version",
447
+ "requestId",
448
+ "proposalId",
449
+ "proposalTermsHash",
450
+ "plan"
451
+ ],
452
+ "additionalProperties": false
453
+ },
454
+ "result": {},
455
+ "attempt": {
456
+ "type": "integer",
457
+ "minimum": 1,
458
+ "maximum": 2
459
+ },
460
+ "signature": {
461
+ "type": "string",
462
+ "pattern": "^0x[0-9a-fA-F]{130}$"
463
+ }
464
+ },
465
+ "required": [
466
+ "task",
467
+ "result",
468
+ "attempt",
469
+ "signature"
470
+ ],
471
+ "additionalProperties": false
472
+ },
473
+ "ProtectedInspectionResultRequest": {
474
+ "type": "object",
475
+ "properties": {
476
+ "proof": {
477
+ "type": "object",
478
+ "properties": {
479
+ "wallet": {
480
+ "type": "string",
481
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
482
+ },
483
+ "expiresAt": {
484
+ "type": "integer",
485
+ "exclusiveMinimum": 0,
486
+ "maximum": 9007199254740991
487
+ },
488
+ "signature": {
489
+ "type": "string",
490
+ "pattern": "^0x[0-9a-fA-F]{130}$"
491
+ }
492
+ },
493
+ "required": [
494
+ "wallet",
495
+ "expiresAt",
496
+ "signature"
497
+ ],
498
+ "additionalProperties": false
499
+ }
500
+ },
501
+ "required": [
502
+ "proof"
503
+ ],
504
+ "additionalProperties": false
505
+ },
506
+ "ProtectedInspectionPrepareResponse": {
507
+ "type": "object",
508
+ "properties": {
509
+ "jobId": {
510
+ "type": "string",
511
+ "pattern": "^0x[0-9a-f]{64}$"
512
+ },
513
+ "terms": {
514
+ "type": "object",
515
+ "properties": {
516
+ "buyer": {
517
+ "type": "string",
518
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
519
+ },
520
+ "seller": {
521
+ "type": "string",
522
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
523
+ },
524
+ "amount": {
525
+ "type": "string",
526
+ "pattern": "^(?:[1-9][0-9]{0,7}|100000000)$"
527
+ },
528
+ "workHash": {
529
+ "type": "string",
530
+ "pattern": "^0x[0-9a-f]{64}$"
531
+ },
532
+ "deliveryDeadline": {
533
+ "type": "integer",
534
+ "exclusiveMinimum": 0,
535
+ "maximum": 9007199254740991
536
+ },
537
+ "evaluationPeriod": {
538
+ "type": "integer",
539
+ "minimum": 300,
540
+ "maximum": 86400
541
+ },
542
+ "correctionPeriod": {
543
+ "type": "integer",
544
+ "minimum": 300,
545
+ "maximum": 86400
546
+ },
547
+ "resolutionDeadline": {
548
+ "type": "integer",
549
+ "exclusiveMinimum": 0,
550
+ "maximum": 9007199254740991
551
+ },
552
+ "reviewPeriod": {
553
+ "type": "integer",
554
+ "minimum": 300,
555
+ "maximum": 86400
556
+ },
557
+ "appealPeriod": {
558
+ "type": "integer",
559
+ "minimum": 300,
560
+ "maximum": 86400
561
+ },
562
+ "appealVerifier": {
563
+ "type": "string",
564
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
565
+ },
566
+ "fallbackVerifier": {
567
+ "type": "string",
568
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
569
+ },
570
+ "appealOriginHash": {
571
+ "type": "string",
572
+ "pattern": "^0x[0-9a-f]{64}$"
573
+ },
574
+ "fallbackOriginHash": {
575
+ "type": "string",
576
+ "pattern": "^0x[0-9a-f]{64}$"
577
+ },
578
+ "verifierHash": {
579
+ "type": "string",
580
+ "const": "0x9ab07031c15c8a11071e8e65aaeabfb4d11160466bb76c5733477d6436757312"
581
+ },
582
+ "nonce": {
583
+ "type": "string",
584
+ "pattern": "^0x[0-9a-f]{64}$"
585
+ }
586
+ },
587
+ "required": [
588
+ "buyer",
589
+ "seller",
590
+ "amount",
591
+ "workHash",
592
+ "deliveryDeadline",
593
+ "evaluationPeriod",
594
+ "correctionPeriod",
595
+ "resolutionDeadline",
596
+ "reviewPeriod",
597
+ "appealPeriod",
598
+ "appealVerifier",
599
+ "fallbackVerifier",
600
+ "appealOriginHash",
601
+ "fallbackOriginHash",
602
+ "verifierHash",
603
+ "nonce"
604
+ ],
605
+ "additionalProperties": false
606
+ },
607
+ "workHash": {
608
+ "type": "string",
609
+ "pattern": "^0x[0-9a-f]{64}$"
610
+ },
611
+ "sellerSigning": {
612
+ "type": "object",
613
+ "properties": {
614
+ "domain": {
615
+ "type": "object",
616
+ "properties": {
617
+ "name": {
618
+ "type": "string",
619
+ "const": "402Mob Protected Work"
620
+ },
621
+ "version": {
622
+ "type": "string",
623
+ "const": "3"
624
+ },
625
+ "chainId": {
626
+ "type": "number",
627
+ "const": 8453
628
+ },
629
+ "verifyingContract": {
630
+ "type": "string",
631
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
632
+ }
633
+ },
634
+ "required": [
635
+ "name",
636
+ "version",
637
+ "chainId",
638
+ "verifyingContract"
639
+ ],
640
+ "additionalProperties": false
641
+ },
642
+ "types": {
643
+ "type": "object",
644
+ "properties": {
645
+ "Terms": {
646
+ "const": [
647
+ {
648
+ "name": "buyer",
649
+ "type": "address"
650
+ },
651
+ {
652
+ "name": "seller",
653
+ "type": "address"
654
+ },
655
+ {
656
+ "name": "amount",
657
+ "type": "uint256"
658
+ },
659
+ {
660
+ "name": "workHash",
661
+ "type": "bytes32"
662
+ },
663
+ {
664
+ "name": "deliveryDeadline",
665
+ "type": "uint256"
666
+ },
667
+ {
668
+ "name": "evaluationPeriod",
669
+ "type": "uint256"
670
+ },
671
+ {
672
+ "name": "correctionPeriod",
673
+ "type": "uint256"
674
+ },
675
+ {
676
+ "name": "resolutionDeadline",
677
+ "type": "uint256"
678
+ },
679
+ {
680
+ "name": "reviewPeriod",
681
+ "type": "uint256"
682
+ },
683
+ {
684
+ "name": "appealPeriod",
685
+ "type": "uint256"
686
+ },
687
+ {
688
+ "name": "appealVerifier",
689
+ "type": "address"
690
+ },
691
+ {
692
+ "name": "fallbackVerifier",
693
+ "type": "address"
694
+ },
695
+ {
696
+ "name": "appealOriginHash",
697
+ "type": "bytes32"
698
+ },
699
+ {
700
+ "name": "fallbackOriginHash",
701
+ "type": "bytes32"
702
+ },
703
+ {
704
+ "name": "verifierHash",
705
+ "type": "bytes32"
706
+ },
707
+ {
708
+ "name": "nonce",
709
+ "type": "bytes32"
710
+ }
711
+ ]
712
+ }
713
+ },
714
+ "required": [
715
+ "Terms"
716
+ ],
717
+ "additionalProperties": false
718
+ },
719
+ "primaryType": {
720
+ "type": "string",
721
+ "const": "Terms"
722
+ },
723
+ "message": {
724
+ "type": "object",
725
+ "properties": {
726
+ "buyer": {
727
+ "type": "string",
728
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
729
+ },
730
+ "seller": {
731
+ "type": "string",
732
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
733
+ },
734
+ "amount": {
735
+ "type": "string",
736
+ "pattern": "^(?:[1-9][0-9]{0,7}|100000000)$"
737
+ },
738
+ "workHash": {
739
+ "type": "string",
740
+ "pattern": "^0x[0-9a-f]{64}$"
741
+ },
742
+ "deliveryDeadline": {
743
+ "type": "integer",
744
+ "exclusiveMinimum": 0,
745
+ "maximum": 9007199254740991
746
+ },
747
+ "evaluationPeriod": {
748
+ "type": "integer",
749
+ "minimum": 300,
750
+ "maximum": 86400
751
+ },
752
+ "correctionPeriod": {
753
+ "type": "integer",
754
+ "minimum": 300,
755
+ "maximum": 86400
756
+ },
757
+ "resolutionDeadline": {
758
+ "type": "integer",
759
+ "exclusiveMinimum": 0,
760
+ "maximum": 9007199254740991
761
+ },
762
+ "reviewPeriod": {
763
+ "type": "integer",
764
+ "minimum": 300,
765
+ "maximum": 86400
766
+ },
767
+ "appealPeriod": {
768
+ "type": "integer",
769
+ "minimum": 300,
770
+ "maximum": 86400
771
+ },
772
+ "appealVerifier": {
773
+ "type": "string",
774
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
775
+ },
776
+ "fallbackVerifier": {
777
+ "type": "string",
778
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
779
+ },
780
+ "appealOriginHash": {
781
+ "type": "string",
782
+ "pattern": "^0x[0-9a-f]{64}$"
783
+ },
784
+ "fallbackOriginHash": {
785
+ "type": "string",
786
+ "pattern": "^0x[0-9a-f]{64}$"
787
+ },
788
+ "verifierHash": {
789
+ "type": "string",
790
+ "const": "0x9ab07031c15c8a11071e8e65aaeabfb4d11160466bb76c5733477d6436757312"
791
+ },
792
+ "nonce": {
793
+ "type": "string",
794
+ "pattern": "^0x[0-9a-f]{64}$"
795
+ }
796
+ },
797
+ "required": [
798
+ "buyer",
799
+ "seller",
800
+ "amount",
801
+ "workHash",
802
+ "deliveryDeadline",
803
+ "evaluationPeriod",
804
+ "correctionPeriod",
805
+ "resolutionDeadline",
806
+ "reviewPeriod",
807
+ "appealPeriod",
808
+ "appealVerifier",
809
+ "fallbackVerifier",
810
+ "appealOriginHash",
811
+ "fallbackOriginHash",
812
+ "verifierHash",
813
+ "nonce"
814
+ ],
815
+ "additionalProperties": false
816
+ }
817
+ },
818
+ "required": [
819
+ "domain",
820
+ "types",
821
+ "primaryType",
822
+ "message"
823
+ ],
824
+ "additionalProperties": false
825
+ }
826
+ },
827
+ "required": [
828
+ "jobId",
829
+ "terms",
830
+ "workHash",
831
+ "sellerSigning"
832
+ ],
833
+ "additionalProperties": false
834
+ },
835
+ "ProtectedInspectionFundingResponse": {
836
+ "type": "object",
837
+ "properties": {
838
+ "jobId": {
839
+ "type": "string",
840
+ "pattern": "^0x[0-9a-f]{64}$"
841
+ },
842
+ "transactions": {
843
+ "minItems": 2,
844
+ "maxItems": 2,
845
+ "type": "array",
846
+ "items": {
847
+ "type": "object",
848
+ "properties": {
849
+ "chainId": {
850
+ "type": "number",
851
+ "const": 8453
852
+ },
853
+ "to": {
854
+ "type": "string",
855
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
856
+ },
857
+ "data": {
858
+ "type": "string",
859
+ "pattern": "^0x[0-9a-fA-F]+$"
860
+ },
861
+ "value": {
862
+ "type": "string",
863
+ "const": "0"
864
+ },
865
+ "from": {
866
+ "type": "string",
867
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
868
+ }
869
+ },
870
+ "required": [
871
+ "chainId",
872
+ "to",
873
+ "data",
874
+ "value"
875
+ ],
876
+ "additionalProperties": false
877
+ }
878
+ },
879
+ "instruction": {
880
+ "type": "string"
881
+ }
882
+ },
883
+ "required": [
884
+ "jobId",
885
+ "transactions",
886
+ "instruction"
887
+ ],
888
+ "additionalProperties": false
889
+ },
890
+ "ProtectedInspectionStatus": {
891
+ "type": "object",
892
+ "properties": {
893
+ "jobId": {
894
+ "type": "string",
895
+ "pattern": "^0x[0-9a-f]{64}$"
896
+ },
897
+ "terms": {
898
+ "type": "object",
899
+ "properties": {
900
+ "buyer": {
901
+ "type": "string",
902
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
903
+ },
904
+ "seller": {
905
+ "type": "string",
906
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
907
+ },
908
+ "amount": {
909
+ "type": "string",
910
+ "pattern": "^(?:[1-9][0-9]{0,7}|100000000)$"
911
+ },
912
+ "workHash": {
913
+ "type": "string",
914
+ "pattern": "^0x[0-9a-f]{64}$"
915
+ },
916
+ "deliveryDeadline": {
917
+ "type": "integer",
918
+ "exclusiveMinimum": 0,
919
+ "maximum": 9007199254740991
920
+ },
921
+ "evaluationPeriod": {
922
+ "type": "integer",
923
+ "minimum": 300,
924
+ "maximum": 86400
925
+ },
926
+ "correctionPeriod": {
927
+ "type": "integer",
928
+ "minimum": 300,
929
+ "maximum": 86400
930
+ },
931
+ "resolutionDeadline": {
932
+ "type": "integer",
933
+ "exclusiveMinimum": 0,
934
+ "maximum": 9007199254740991
935
+ },
936
+ "reviewPeriod": {
937
+ "type": "integer",
938
+ "minimum": 300,
939
+ "maximum": 86400
940
+ },
941
+ "appealPeriod": {
942
+ "type": "integer",
943
+ "minimum": 300,
944
+ "maximum": 86400
945
+ },
946
+ "appealVerifier": {
947
+ "type": "string",
948
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
949
+ },
950
+ "fallbackVerifier": {
951
+ "type": "string",
952
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
953
+ },
954
+ "appealOriginHash": {
955
+ "type": "string",
956
+ "pattern": "^0x[0-9a-f]{64}$"
957
+ },
958
+ "fallbackOriginHash": {
959
+ "type": "string",
960
+ "pattern": "^0x[0-9a-f]{64}$"
961
+ },
962
+ "verifierHash": {
963
+ "type": "string",
964
+ "const": "0x9ab07031c15c8a11071e8e65aaeabfb4d11160466bb76c5733477d6436757312"
965
+ },
966
+ "nonce": {
967
+ "type": "string",
968
+ "pattern": "^0x[0-9a-f]{64}$"
969
+ }
970
+ },
971
+ "required": [
972
+ "buyer",
973
+ "seller",
974
+ "amount",
975
+ "workHash",
976
+ "deliveryDeadline",
977
+ "evaluationPeriod",
978
+ "correctionPeriod",
979
+ "resolutionDeadline",
980
+ "reviewPeriod",
981
+ "appealPeriod",
982
+ "appealVerifier",
983
+ "fallbackVerifier",
984
+ "appealOriginHash",
985
+ "fallbackOriginHash",
986
+ "verifierHash",
987
+ "nonce"
988
+ ],
989
+ "additionalProperties": false
990
+ },
991
+ "state": {
992
+ "type": "string",
993
+ "enum": [
994
+ "unknown",
995
+ "funded",
996
+ "submitted",
997
+ "rejected",
998
+ "review",
999
+ "challenged",
1000
+ "approved",
1001
+ "completed",
1002
+ "refunded"
1003
+ ]
1004
+ },
1005
+ "attempt": {
1006
+ "type": "integer",
1007
+ "minimum": 0,
1008
+ "maximum": 2
1009
+ },
1010
+ "resultHash": {
1011
+ "anyOf": [
1012
+ {
1013
+ "type": "string",
1014
+ "pattern": "^0x[0-9a-f]{64}$"
1015
+ },
1016
+ {
1017
+ "type": "null"
1018
+ }
1019
+ ]
1020
+ },
1021
+ "evaluationUntil": {
1022
+ "type": "integer",
1023
+ "minimum": -9007199254740991,
1024
+ "maximum": 9007199254740991
1025
+ },
1026
+ "correctionUntil": {
1027
+ "type": "integer",
1028
+ "minimum": -9007199254740991,
1029
+ "maximum": 9007199254740991
1030
+ },
1031
+ "fallbackUntil": {
1032
+ "type": "integer",
1033
+ "minimum": -9007199254740991,
1034
+ "maximum": 9007199254740991
1035
+ },
1036
+ "buyerReceived": {
1037
+ "type": "boolean"
1038
+ },
1039
+ "outcome": {
1040
+ "type": "string",
1041
+ "enum": [
1042
+ "none",
1043
+ "buyer_accepted",
1044
+ "review_elapsed",
1045
+ "appeal_approved",
1046
+ "verifier_rejected",
1047
+ "no_submission",
1048
+ "evaluation_timeout",
1049
+ "uncorrected_rejection",
1050
+ "verifiers_unavailable"
1051
+ ]
1052
+ },
1053
+ "activeAppealRound": {
1054
+ "anyOf": [
1055
+ {
1056
+ "type": "integer",
1057
+ "minimum": 1,
1058
+ "maximum": 2
1059
+ },
1060
+ {
1061
+ "type": "null"
1062
+ }
1063
+ ]
1064
+ },
1065
+ "reviewUntil": {
1066
+ "type": "integer",
1067
+ "minimum": -9007199254740991,
1068
+ "maximum": 9007199254740991
1069
+ },
1070
+ "appealUntil": {
1071
+ "type": "integer",
1072
+ "minimum": -9007199254740991,
1073
+ "maximum": 9007199254740991
1074
+ },
1075
+ "appealUsed": {
1076
+ "type": "boolean"
1077
+ },
1078
+ "reason": {
1079
+ "type": "integer",
1080
+ "minimum": 0,
1081
+ "maximum": 4
1082
+ },
1083
+ "evidenceHash": {
1084
+ "type": "string",
1085
+ "pattern": "^0x[0-9a-f]{64}$"
1086
+ },
1087
+ "chainTimestamp": {
1088
+ "type": "integer",
1089
+ "minimum": -9007199254740991,
1090
+ "maximum": 9007199254740991
1091
+ },
1092
+ "refundEligible": {
1093
+ "type": "boolean"
1094
+ },
1095
+ "payoutEligible": {
1096
+ "type": "boolean"
1097
+ },
1098
+ "refundTransaction": {
1099
+ "type": "object",
1100
+ "properties": {
1101
+ "chainId": {
1102
+ "type": "number",
1103
+ "const": 8453
1104
+ },
1105
+ "to": {
1106
+ "type": "string",
1107
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
1108
+ },
1109
+ "data": {
1110
+ "type": "string",
1111
+ "pattern": "^0x[0-9a-fA-F]+$"
1112
+ },
1113
+ "value": {
1114
+ "type": "string",
1115
+ "const": "0"
1116
+ },
1117
+ "from": {
1118
+ "type": "string",
1119
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
1120
+ }
1121
+ },
1122
+ "required": [
1123
+ "chainId",
1124
+ "to",
1125
+ "data",
1126
+ "value"
1127
+ ],
1128
+ "additionalProperties": false
1129
+ },
1130
+ "finalizeTransaction": {
1131
+ "type": "object",
1132
+ "properties": {
1133
+ "chainId": {
1134
+ "type": "number",
1135
+ "const": 8453
1136
+ },
1137
+ "to": {
1138
+ "type": "string",
1139
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
1140
+ },
1141
+ "data": {
1142
+ "type": "string",
1143
+ "pattern": "^0x[0-9a-fA-F]+$"
1144
+ },
1145
+ "value": {
1146
+ "type": "string",
1147
+ "const": "0"
1148
+ },
1149
+ "from": {
1150
+ "type": "string",
1151
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
1152
+ }
1153
+ },
1154
+ "required": [
1155
+ "chainId",
1156
+ "to",
1157
+ "data",
1158
+ "value"
1159
+ ],
1160
+ "additionalProperties": false
1161
+ }
1162
+ },
1163
+ "required": [
1164
+ "jobId",
1165
+ "terms",
1166
+ "state",
1167
+ "attempt",
1168
+ "resultHash",
1169
+ "evaluationUntil",
1170
+ "correctionUntil",
1171
+ "fallbackUntil",
1172
+ "buyerReceived",
1173
+ "outcome",
1174
+ "activeAppealRound",
1175
+ "reviewUntil",
1176
+ "appealUntil",
1177
+ "appealUsed",
1178
+ "reason",
1179
+ "evidenceHash",
1180
+ "chainTimestamp",
1181
+ "refundEligible",
1182
+ "payoutEligible",
1183
+ "refundTransaction",
1184
+ "finalizeTransaction"
1185
+ ],
1186
+ "additionalProperties": false
1187
+ },
1188
+ "ProtectedInspectionChallenge": {
1189
+ "type": "object",
1190
+ "properties": {
1191
+ "message": {
1192
+ "type": "string"
1193
+ },
1194
+ "expiresAt": {
1195
+ "type": "integer",
1196
+ "minimum": -9007199254740991,
1197
+ "maximum": 9007199254740991
1198
+ },
1199
+ "wallet": {
1200
+ "type": "string",
1201
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
1202
+ },
1203
+ "action": {
1204
+ "type": "string",
1205
+ "const": "read"
1206
+ }
1207
+ },
1208
+ "required": [
1209
+ "message",
1210
+ "expiresAt",
1211
+ "wallet",
1212
+ "action"
1213
+ ],
1214
+ "additionalProperties": false
1215
+ },
1216
+ "ProtectedInspectionSubmissionResponse": {
1217
+ "type": "object",
1218
+ "properties": {
1219
+ "jobId": {
1220
+ "type": "string",
1221
+ "pattern": "^0x[0-9a-f]{64}$"
1222
+ },
1223
+ "resultHash": {
1224
+ "type": "string",
1225
+ "pattern": "^0x[0-9a-f]{64}$"
1226
+ },
1227
+ "attempt": {
1228
+ "type": "integer",
1229
+ "minimum": 1,
1230
+ "maximum": 2
1231
+ },
1232
+ "replay": {
1233
+ "type": "boolean"
1234
+ },
1235
+ "submissionTransaction": {
1236
+ "anyOf": [
1237
+ {
1238
+ "type": "object",
1239
+ "properties": {
1240
+ "chainId": {
1241
+ "type": "number",
1242
+ "const": 8453
1243
+ },
1244
+ "to": {
1245
+ "type": "string",
1246
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
1247
+ },
1248
+ "data": {
1249
+ "type": "string",
1250
+ "pattern": "^0x[0-9a-fA-F]+$"
1251
+ },
1252
+ "value": {
1253
+ "type": "string",
1254
+ "const": "0"
1255
+ },
1256
+ "from": {
1257
+ "type": "string",
1258
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
1259
+ }
1260
+ },
1261
+ "required": [
1262
+ "chainId",
1263
+ "to",
1264
+ "data",
1265
+ "value"
1266
+ ],
1267
+ "additionalProperties": false
1268
+ },
1269
+ {
1270
+ "type": "null"
1271
+ }
1272
+ ]
1273
+ },
1274
+ "relay": {
1275
+ "type": "object",
1276
+ "properties": {
1277
+ "queued": {
1278
+ "type": "boolean"
1279
+ },
1280
+ "id": {
1281
+ "anyOf": [
1282
+ {
1283
+ "type": "string",
1284
+ "pattern": "^[a-f0-9]{64}$"
1285
+ },
1286
+ {
1287
+ "type": "null"
1288
+ }
1289
+ ]
1290
+ }
1291
+ },
1292
+ "required": [
1293
+ "queued",
1294
+ "id"
1295
+ ],
1296
+ "additionalProperties": false
1297
+ },
1298
+ "retainedUntil": {
1299
+ "type": "string",
1300
+ "format": "date-time",
1301
+ "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$"
1302
+ }
1303
+ },
1304
+ "required": [
1305
+ "jobId",
1306
+ "resultHash",
1307
+ "attempt",
1308
+ "replay",
1309
+ "submissionTransaction",
1310
+ "relay",
1311
+ "retainedUntil"
1312
+ ],
1313
+ "additionalProperties": false
1314
+ },
1315
+ "ProtectedInspectionResult": {
1316
+ "type": "object",
1317
+ "properties": {
1318
+ "jobId": {
1319
+ "type": "string",
1320
+ "pattern": "^0x[0-9a-f]{64}$"
1321
+ },
1322
+ "state": {
1323
+ "type": "string",
1324
+ "enum": [
1325
+ "unknown",
1326
+ "funded",
1327
+ "submitted",
1328
+ "rejected",
1329
+ "review",
1330
+ "challenged",
1331
+ "approved",
1332
+ "completed",
1333
+ "refunded"
1334
+ ]
1335
+ },
1336
+ "attempt": {
1337
+ "type": "integer",
1338
+ "minimum": 1,
1339
+ "maximum": 2
1340
+ },
1341
+ "resultHash": {
1342
+ "type": "string",
1343
+ "pattern": "^0x[0-9a-f]{64}$"
1344
+ },
1345
+ "task": {
1346
+ "type": "object",
1347
+ "properties": {
1348
+ "version": {
1349
+ "type": "string",
1350
+ "const": "funded-inspection-v1"
1351
+ },
1352
+ "requestId": {
1353
+ "type": "string",
1354
+ "format": "uuid",
1355
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
1356
+ },
1357
+ "proposalId": {
1358
+ "type": "string",
1359
+ "format": "uuid",
1360
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
1361
+ },
1362
+ "proposalTermsHash": {
1363
+ "type": "string",
1364
+ "pattern": "^[a-f0-9]{64}$"
1365
+ },
1366
+ "plan": {
1367
+ "type": "object",
1368
+ "properties": {
1369
+ "version": {
1370
+ "type": "string",
1371
+ "const": "buyer-probe-v1"
1372
+ },
1373
+ "targetUrl": {
1374
+ "type": "string",
1375
+ "maxLength": 2048,
1376
+ "format": "uri"
1377
+ },
1378
+ "method": {
1379
+ "type": "string",
1380
+ "const": "GET"
1381
+ },
1382
+ "paymentRecipient": {
1383
+ "type": "string",
1384
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
1385
+ },
1386
+ "maxTestAmountAtomic": {
1387
+ "type": "string",
1388
+ "pattern": "^(?:0|[1-9][0-9]{0,5}|1000000)$"
1389
+ },
1390
+ "maxPaidAttempts": {
1391
+ "type": "number",
1392
+ "const": 1
1393
+ }
1394
+ },
1395
+ "required": [
1396
+ "version",
1397
+ "targetUrl",
1398
+ "method",
1399
+ "paymentRecipient",
1400
+ "maxTestAmountAtomic",
1401
+ "maxPaidAttempts"
1402
+ ],
1403
+ "additionalProperties": false
1404
+ }
1405
+ },
1406
+ "required": [
1407
+ "version",
1408
+ "requestId",
1409
+ "proposalId",
1410
+ "proposalTermsHash",
1411
+ "plan"
1412
+ ],
1413
+ "additionalProperties": false
1414
+ },
1415
+ "result": {}
1416
+ },
1417
+ "required": [
1418
+ "jobId",
1419
+ "state",
1420
+ "attempt",
1421
+ "resultHash",
1422
+ "task",
1423
+ "result"
1424
+ ],
1425
+ "additionalProperties": false
1426
+ },
1427
+ "ProtectedInspectionCapability": {
1428
+ "type": "object",
1429
+ "properties": {
1430
+ "protocol": {
1431
+ "type": "string"
1432
+ },
1433
+ "configured": {
1434
+ "type": "boolean"
1435
+ },
1436
+ "status": {
1437
+ "type": "string"
1438
+ },
1439
+ "descriptor": {
1440
+ "type": "string"
1441
+ },
1442
+ "guide": {
1443
+ "type": "string"
1444
+ },
1445
+ "verifierHash": {
1446
+ "type": "string"
1447
+ },
1448
+ "task": {
1449
+ "type": "string"
1450
+ },
1451
+ "network": {
1452
+ "type": "string"
1453
+ },
1454
+ "asset": {
1455
+ "type": "string"
1456
+ },
1457
+ "settlement": {
1458
+ "type": "string"
1459
+ },
1460
+ "serviceFeeMaximumAtomic": {
1461
+ "type": "string"
1462
+ },
1463
+ "testBudgetMaximumAtomic": {
1464
+ "type": "string"
1465
+ },
1466
+ "maxPaidAttempts": {
1467
+ "type": "number"
1468
+ },
1469
+ "verification": {
1470
+ "type": "string"
1471
+ },
1472
+ "startGate": {
1473
+ "type": "string"
1474
+ },
1475
+ "runtime": {
1476
+ "type": "string"
1477
+ },
1478
+ "clients": {
1479
+ "type": "string"
1480
+ },
1481
+ "relayEnabled": {
1482
+ "type": "boolean"
1483
+ },
1484
+ "productionValidated": {
1485
+ "type": "boolean"
1486
+ }
1487
+ },
1488
+ "required": [
1489
+ "protocol",
1490
+ "configured",
1491
+ "status",
1492
+ "descriptor",
1493
+ "guide",
1494
+ "verifierHash",
1495
+ "task",
1496
+ "network",
1497
+ "asset",
1498
+ "settlement",
1499
+ "serviceFeeMaximumAtomic",
1500
+ "testBudgetMaximumAtomic",
1501
+ "maxPaidAttempts",
1502
+ "verification",
1503
+ "startGate",
1504
+ "runtime",
1505
+ "clients",
1506
+ "relayEnabled",
1507
+ "productionValidated"
1508
+ ],
1509
+ "additionalProperties": false
1510
+ },
1511
+ "ProtectedInspectionCandidateRequest": {
1512
+ "type": "object",
1513
+ "properties": {
1514
+ "attempt": {
1515
+ "type": "integer",
1516
+ "minimum": 1,
1517
+ "maximum": 2
1518
+ },
1519
+ "resultHash": {
1520
+ "type": "string",
1521
+ "pattern": "^0x[0-9a-f]{64}$"
1522
+ }
1523
+ },
1524
+ "required": [
1525
+ "attempt",
1526
+ "resultHash"
1527
+ ],
1528
+ "additionalProperties": false
1529
+ },
1530
+ "ProtectedInspectionActionRequest": {
1531
+ "oneOf": [
1532
+ {
1533
+ "type": "object",
1534
+ "properties": {
1535
+ "action": {
1536
+ "type": "string",
1537
+ "const": "receipt"
1538
+ },
1539
+ "signature": {
1540
+ "type": "string",
1541
+ "pattern": "^0x[0-9a-fA-F]{130}$"
1542
+ }
1543
+ },
1544
+ "required": [
1545
+ "action"
1546
+ ],
1547
+ "additionalProperties": false
1548
+ },
1549
+ {
1550
+ "type": "object",
1551
+ "properties": {
1552
+ "action": {
1553
+ "type": "string",
1554
+ "const": "accept"
1555
+ },
1556
+ "signature": {
1557
+ "type": "string",
1558
+ "pattern": "^0x[0-9a-fA-F]{130}$"
1559
+ }
1560
+ },
1561
+ "required": [
1562
+ "action"
1563
+ ],
1564
+ "additionalProperties": false
1565
+ },
1566
+ {
1567
+ "type": "object",
1568
+ "properties": {
1569
+ "action": {
1570
+ "type": "string",
1571
+ "const": "challenge"
1572
+ },
1573
+ "reason": {
1574
+ "type": "string",
1575
+ "enum": [
1576
+ "wrong_output",
1577
+ "rules_mismatch",
1578
+ "result_unavailable",
1579
+ "evaluator_timeout"
1580
+ ]
1581
+ },
1582
+ "evidenceHash": {
1583
+ "type": "string",
1584
+ "pattern": "^0x[0-9a-f]{64}$"
1585
+ },
1586
+ "signature": {
1587
+ "type": "string",
1588
+ "pattern": "^0x[0-9a-fA-F]{130}$"
1589
+ }
1590
+ },
1591
+ "required": [
1592
+ "action",
1593
+ "reason",
1594
+ "evidenceHash"
1595
+ ],
1596
+ "additionalProperties": false
1597
+ },
1598
+ {
1599
+ "type": "object",
1600
+ "properties": {
1601
+ "action": {
1602
+ "type": "string",
1603
+ "const": "finalize"
1604
+ }
1605
+ },
1606
+ "required": [
1607
+ "action"
1608
+ ],
1609
+ "additionalProperties": false
1610
+ },
1611
+ {
1612
+ "type": "object",
1613
+ "properties": {
1614
+ "action": {
1615
+ "type": "string",
1616
+ "const": "refund"
1617
+ }
1618
+ },
1619
+ "required": [
1620
+ "action"
1621
+ ],
1622
+ "additionalProperties": false
1623
+ }
1624
+ ]
1625
+ },
1626
+ "ProtectedInspectionAppealRequest": {
1627
+ "type": "object",
1628
+ "properties": {
1629
+ "round": {
1630
+ "type": "integer",
1631
+ "minimum": 1,
1632
+ "maximum": 2
1633
+ },
1634
+ "valid": {
1635
+ "type": "boolean"
1636
+ },
1637
+ "signature": {
1638
+ "type": "string",
1639
+ "pattern": "^0x[0-9a-fA-F]{130}$"
1640
+ }
1641
+ },
1642
+ "required": [
1643
+ "round",
1644
+ "valid",
1645
+ "signature"
1646
+ ],
1647
+ "additionalProperties": false
1648
+ },
1649
+ "ProtectedInspectionEvaluationRequest": {
1650
+ "type": "object",
1651
+ "properties": {},
1652
+ "additionalProperties": false
1653
+ },
1654
+ "ProtectedInspectionCandidateSigning": {
1655
+ "type": "object",
1656
+ "properties": {
1657
+ "signing": {
1658
+ "type": "object",
1659
+ "properties": {
1660
+ "domain": {
1661
+ "type": "object",
1662
+ "properties": {
1663
+ "name": {
1664
+ "type": "string",
1665
+ "const": "402Mob Protected Work"
1666
+ },
1667
+ "version": {
1668
+ "type": "string",
1669
+ "const": "3"
1670
+ },
1671
+ "chainId": {
1672
+ "type": "number",
1673
+ "const": 8453
1674
+ },
1675
+ "verifyingContract": {
1676
+ "type": "string",
1677
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
1678
+ }
1679
+ },
1680
+ "required": [
1681
+ "name",
1682
+ "version",
1683
+ "chainId",
1684
+ "verifyingContract"
1685
+ ],
1686
+ "additionalProperties": false
1687
+ },
1688
+ "types": {
1689
+ "type": "object",
1690
+ "properties": {
1691
+ "Candidate": {
1692
+ "type": "array",
1693
+ "prefixItems": [
1694
+ {
1695
+ "type": "object",
1696
+ "properties": {
1697
+ "name": {
1698
+ "type": "string",
1699
+ "const": "jobId"
1700
+ },
1701
+ "type": {
1702
+ "type": "string",
1703
+ "const": "bytes32"
1704
+ }
1705
+ },
1706
+ "required": [
1707
+ "name",
1708
+ "type"
1709
+ ],
1710
+ "additionalProperties": false
1711
+ },
1712
+ {
1713
+ "type": "object",
1714
+ "properties": {
1715
+ "name": {
1716
+ "type": "string",
1717
+ "const": "attempt"
1718
+ },
1719
+ "type": {
1720
+ "type": "string",
1721
+ "const": "uint256"
1722
+ }
1723
+ },
1724
+ "required": [
1725
+ "name",
1726
+ "type"
1727
+ ],
1728
+ "additionalProperties": false
1729
+ },
1730
+ {
1731
+ "type": "object",
1732
+ "properties": {
1733
+ "name": {
1734
+ "type": "string",
1735
+ "const": "resultHash"
1736
+ },
1737
+ "type": {
1738
+ "type": "string",
1739
+ "const": "bytes32"
1740
+ }
1741
+ },
1742
+ "required": [
1743
+ "name",
1744
+ "type"
1745
+ ],
1746
+ "additionalProperties": false
1747
+ }
1748
+ ],
1749
+ "items": false,
1750
+ "minItems": 3,
1751
+ "maxItems": 3
1752
+ }
1753
+ },
1754
+ "required": [
1755
+ "Candidate"
1756
+ ],
1757
+ "additionalProperties": false
1758
+ },
1759
+ "primaryType": {
1760
+ "type": "string",
1761
+ "const": "Candidate"
1762
+ },
1763
+ "message": {
1764
+ "type": "object",
1765
+ "properties": {
1766
+ "jobId": {
1767
+ "type": "string",
1768
+ "pattern": "^0x[0-9a-f]{64}$"
1769
+ },
1770
+ "attempt": {
1771
+ "type": "integer",
1772
+ "minimum": 1,
1773
+ "maximum": 2
1774
+ },
1775
+ "resultHash": {
1776
+ "type": "string",
1777
+ "pattern": "^0x[0-9a-f]{64}$"
1778
+ }
1779
+ },
1780
+ "required": [
1781
+ "jobId",
1782
+ "attempt",
1783
+ "resultHash"
1784
+ ],
1785
+ "additionalProperties": false
1786
+ }
1787
+ },
1788
+ "required": [
1789
+ "domain",
1790
+ "types",
1791
+ "primaryType",
1792
+ "message"
1793
+ ],
1794
+ "additionalProperties": false
1795
+ }
1796
+ },
1797
+ "required": [
1798
+ "signing"
1799
+ ],
1800
+ "additionalProperties": false
1801
+ },
1802
+ "ProtectedInspectionEvaluationResponse": {
1803
+ "type": "object",
1804
+ "properties": {
1805
+ "jobId": {
1806
+ "type": "string",
1807
+ "pattern": "^0x[0-9a-f]{64}$"
1808
+ },
1809
+ "resultHash": {
1810
+ "type": "string",
1811
+ "pattern": "^0x[0-9a-f]{64}$"
1812
+ },
1813
+ "attempt": {
1814
+ "type": "integer",
1815
+ "minimum": 1,
1816
+ "maximum": 2
1817
+ },
1818
+ "valid": {
1819
+ "type": "boolean"
1820
+ },
1821
+ "evaluationTransaction": {
1822
+ "type": "object",
1823
+ "properties": {
1824
+ "chainId": {
1825
+ "type": "number",
1826
+ "const": 8453
1827
+ },
1828
+ "to": {
1829
+ "type": "string",
1830
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
1831
+ },
1832
+ "data": {
1833
+ "type": "string",
1834
+ "pattern": "^0x[0-9a-fA-F]+$"
1835
+ },
1836
+ "value": {
1837
+ "type": "string",
1838
+ "const": "0"
1839
+ },
1840
+ "from": {
1841
+ "type": "string",
1842
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
1843
+ }
1844
+ },
1845
+ "required": [
1846
+ "chainId",
1847
+ "to",
1848
+ "data",
1849
+ "value"
1850
+ ],
1851
+ "additionalProperties": false
1852
+ },
1853
+ "relay": {
1854
+ "type": "object",
1855
+ "properties": {
1856
+ "queued": {
1857
+ "type": "boolean"
1858
+ },
1859
+ "id": {
1860
+ "anyOf": [
1861
+ {
1862
+ "type": "string",
1863
+ "pattern": "^[a-f0-9]{64}$"
1864
+ },
1865
+ {
1866
+ "type": "null"
1867
+ }
1868
+ ]
1869
+ }
1870
+ },
1871
+ "required": [
1872
+ "queued",
1873
+ "id"
1874
+ ],
1875
+ "additionalProperties": false
1876
+ }
1877
+ },
1878
+ "required": [
1879
+ "jobId",
1880
+ "resultHash",
1881
+ "attempt",
1882
+ "valid",
1883
+ "evaluationTransaction",
1884
+ "relay"
1885
+ ],
1886
+ "additionalProperties": false
1887
+ },
1888
+ "ProtectedInspectionActionResponse": {
1889
+ "anyOf": [
1890
+ {
1891
+ "type": "object",
1892
+ "properties": {
1893
+ "signing": {
1894
+ "anyOf": [
1895
+ {
1896
+ "type": "object",
1897
+ "properties": {
1898
+ "domain": {
1899
+ "type": "object",
1900
+ "properties": {
1901
+ "name": {
1902
+ "type": "string",
1903
+ "const": "402Mob Protected Work"
1904
+ },
1905
+ "version": {
1906
+ "type": "string",
1907
+ "const": "3"
1908
+ },
1909
+ "chainId": {
1910
+ "type": "number",
1911
+ "const": 8453
1912
+ },
1913
+ "verifyingContract": {
1914
+ "type": "string",
1915
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
1916
+ }
1917
+ },
1918
+ "required": [
1919
+ "name",
1920
+ "version",
1921
+ "chainId",
1922
+ "verifyingContract"
1923
+ ],
1924
+ "additionalProperties": false
1925
+ },
1926
+ "types": {
1927
+ "type": "object",
1928
+ "properties": {
1929
+ "Accept": {
1930
+ "type": "array",
1931
+ "prefixItems": [
1932
+ {
1933
+ "type": "object",
1934
+ "properties": {
1935
+ "name": {
1936
+ "type": "string",
1937
+ "const": "jobId"
1938
+ },
1939
+ "type": {
1940
+ "type": "string",
1941
+ "const": "bytes32"
1942
+ }
1943
+ },
1944
+ "required": [
1945
+ "name",
1946
+ "type"
1947
+ ],
1948
+ "additionalProperties": false
1949
+ },
1950
+ {
1951
+ "type": "object",
1952
+ "properties": {
1953
+ "name": {
1954
+ "type": "string",
1955
+ "const": "attempt"
1956
+ },
1957
+ "type": {
1958
+ "type": "string",
1959
+ "const": "uint256"
1960
+ }
1961
+ },
1962
+ "required": [
1963
+ "name",
1964
+ "type"
1965
+ ],
1966
+ "additionalProperties": false
1967
+ },
1968
+ {
1969
+ "type": "object",
1970
+ "properties": {
1971
+ "name": {
1972
+ "type": "string",
1973
+ "const": "resultHash"
1974
+ },
1975
+ "type": {
1976
+ "type": "string",
1977
+ "const": "bytes32"
1978
+ }
1979
+ },
1980
+ "required": [
1981
+ "name",
1982
+ "type"
1983
+ ],
1984
+ "additionalProperties": false
1985
+ }
1986
+ ],
1987
+ "items": false,
1988
+ "minItems": 3,
1989
+ "maxItems": 3
1990
+ }
1991
+ },
1992
+ "required": [
1993
+ "Accept"
1994
+ ],
1995
+ "additionalProperties": false
1996
+ },
1997
+ "primaryType": {
1998
+ "type": "string",
1999
+ "const": "Accept"
2000
+ },
2001
+ "message": {
2002
+ "type": "object",
2003
+ "properties": {
2004
+ "jobId": {
2005
+ "type": "string",
2006
+ "pattern": "^0x[0-9a-f]{64}$"
2007
+ },
2008
+ "attempt": {
2009
+ "type": "integer",
2010
+ "minimum": 1,
2011
+ "maximum": 2
2012
+ },
2013
+ "resultHash": {
2014
+ "type": "string",
2015
+ "pattern": "^0x[0-9a-f]{64}$"
2016
+ }
2017
+ },
2018
+ "required": [
2019
+ "jobId",
2020
+ "attempt",
2021
+ "resultHash"
2022
+ ],
2023
+ "additionalProperties": false
2024
+ }
2025
+ },
2026
+ "required": [
2027
+ "domain",
2028
+ "types",
2029
+ "primaryType",
2030
+ "message"
2031
+ ],
2032
+ "additionalProperties": false
2033
+ },
2034
+ {
2035
+ "type": "object",
2036
+ "properties": {
2037
+ "domain": {
2038
+ "type": "object",
2039
+ "properties": {
2040
+ "name": {
2041
+ "type": "string",
2042
+ "const": "402Mob Protected Work"
2043
+ },
2044
+ "version": {
2045
+ "type": "string",
2046
+ "const": "3"
2047
+ },
2048
+ "chainId": {
2049
+ "type": "number",
2050
+ "const": 8453
2051
+ },
2052
+ "verifyingContract": {
2053
+ "type": "string",
2054
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
2055
+ }
2056
+ },
2057
+ "required": [
2058
+ "name",
2059
+ "version",
2060
+ "chainId",
2061
+ "verifyingContract"
2062
+ ],
2063
+ "additionalProperties": false
2064
+ },
2065
+ "types": {
2066
+ "type": "object",
2067
+ "properties": {
2068
+ "Challenge": {
2069
+ "type": "array",
2070
+ "prefixItems": [
2071
+ {
2072
+ "type": "object",
2073
+ "properties": {
2074
+ "name": {
2075
+ "type": "string",
2076
+ "const": "jobId"
2077
+ },
2078
+ "type": {
2079
+ "type": "string",
2080
+ "const": "bytes32"
2081
+ }
2082
+ },
2083
+ "required": [
2084
+ "name",
2085
+ "type"
2086
+ ],
2087
+ "additionalProperties": false
2088
+ },
2089
+ {
2090
+ "type": "object",
2091
+ "properties": {
2092
+ "name": {
2093
+ "type": "string",
2094
+ "const": "attempt"
2095
+ },
2096
+ "type": {
2097
+ "type": "string",
2098
+ "const": "uint256"
2099
+ }
2100
+ },
2101
+ "required": [
2102
+ "name",
2103
+ "type"
2104
+ ],
2105
+ "additionalProperties": false
2106
+ },
2107
+ {
2108
+ "type": "object",
2109
+ "properties": {
2110
+ "name": {
2111
+ "type": "string",
2112
+ "const": "resultHash"
2113
+ },
2114
+ "type": {
2115
+ "type": "string",
2116
+ "const": "bytes32"
2117
+ }
2118
+ },
2119
+ "required": [
2120
+ "name",
2121
+ "type"
2122
+ ],
2123
+ "additionalProperties": false
2124
+ },
2125
+ {
2126
+ "type": "object",
2127
+ "properties": {
2128
+ "name": {
2129
+ "type": "string",
2130
+ "const": "reason"
2131
+ },
2132
+ "type": {
2133
+ "type": "string",
2134
+ "const": "uint8"
2135
+ }
2136
+ },
2137
+ "required": [
2138
+ "name",
2139
+ "type"
2140
+ ],
2141
+ "additionalProperties": false
2142
+ },
2143
+ {
2144
+ "type": "object",
2145
+ "properties": {
2146
+ "name": {
2147
+ "type": "string",
2148
+ "const": "evidenceHash"
2149
+ },
2150
+ "type": {
2151
+ "type": "string",
2152
+ "const": "bytes32"
2153
+ }
2154
+ },
2155
+ "required": [
2156
+ "name",
2157
+ "type"
2158
+ ],
2159
+ "additionalProperties": false
2160
+ }
2161
+ ],
2162
+ "items": false,
2163
+ "minItems": 5,
2164
+ "maxItems": 5
2165
+ }
2166
+ },
2167
+ "required": [
2168
+ "Challenge"
2169
+ ],
2170
+ "additionalProperties": false
2171
+ },
2172
+ "primaryType": {
2173
+ "type": "string",
2174
+ "const": "Challenge"
2175
+ },
2176
+ "message": {
2177
+ "type": "object",
2178
+ "properties": {
2179
+ "jobId": {
2180
+ "type": "string",
2181
+ "pattern": "^0x[0-9a-f]{64}$"
2182
+ },
2183
+ "attempt": {
2184
+ "type": "integer",
2185
+ "minimum": 1,
2186
+ "maximum": 2
2187
+ },
2188
+ "resultHash": {
2189
+ "type": "string",
2190
+ "pattern": "^0x[0-9a-f]{64}$"
2191
+ },
2192
+ "reason": {
2193
+ "type": "integer",
2194
+ "minimum": 1,
2195
+ "maximum": 4
2196
+ },
2197
+ "evidenceHash": {
2198
+ "type": "string",
2199
+ "pattern": "^0x[0-9a-f]{64}$"
2200
+ }
2201
+ },
2202
+ "required": [
2203
+ "jobId",
2204
+ "attempt",
2205
+ "resultHash",
2206
+ "reason",
2207
+ "evidenceHash"
2208
+ ],
2209
+ "additionalProperties": false
2210
+ }
2211
+ },
2212
+ "required": [
2213
+ "domain",
2214
+ "types",
2215
+ "primaryType",
2216
+ "message"
2217
+ ],
2218
+ "additionalProperties": false
2219
+ },
2220
+ {
2221
+ "type": "object",
2222
+ "properties": {
2223
+ "domain": {
2224
+ "type": "object",
2225
+ "properties": {
2226
+ "name": {
2227
+ "type": "string",
2228
+ "const": "402Mob Protected Work"
2229
+ },
2230
+ "version": {
2231
+ "type": "string",
2232
+ "const": "3"
2233
+ },
2234
+ "chainId": {
2235
+ "type": "number",
2236
+ "const": 8453
2237
+ },
2238
+ "verifyingContract": {
2239
+ "type": "string",
2240
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
2241
+ }
2242
+ },
2243
+ "required": [
2244
+ "name",
2245
+ "version",
2246
+ "chainId",
2247
+ "verifyingContract"
2248
+ ],
2249
+ "additionalProperties": false
2250
+ },
2251
+ "types": {
2252
+ "type": "object",
2253
+ "properties": {
2254
+ "Receipt": {
2255
+ "type": "array",
2256
+ "prefixItems": [
2257
+ {
2258
+ "type": "object",
2259
+ "properties": {
2260
+ "name": {
2261
+ "type": "string",
2262
+ "const": "jobId"
2263
+ },
2264
+ "type": {
2265
+ "type": "string",
2266
+ "const": "bytes32"
2267
+ }
2268
+ },
2269
+ "required": [
2270
+ "name",
2271
+ "type"
2272
+ ],
2273
+ "additionalProperties": false
2274
+ },
2275
+ {
2276
+ "type": "object",
2277
+ "properties": {
2278
+ "name": {
2279
+ "type": "string",
2280
+ "const": "attempt"
2281
+ },
2282
+ "type": {
2283
+ "type": "string",
2284
+ "const": "uint256"
2285
+ }
2286
+ },
2287
+ "required": [
2288
+ "name",
2289
+ "type"
2290
+ ],
2291
+ "additionalProperties": false
2292
+ },
2293
+ {
2294
+ "type": "object",
2295
+ "properties": {
2296
+ "name": {
2297
+ "type": "string",
2298
+ "const": "resultHash"
2299
+ },
2300
+ "type": {
2301
+ "type": "string",
2302
+ "const": "bytes32"
2303
+ }
2304
+ },
2305
+ "required": [
2306
+ "name",
2307
+ "type"
2308
+ ],
2309
+ "additionalProperties": false
2310
+ }
2311
+ ],
2312
+ "items": false,
2313
+ "minItems": 3,
2314
+ "maxItems": 3
2315
+ }
2316
+ },
2317
+ "required": [
2318
+ "Receipt"
2319
+ ],
2320
+ "additionalProperties": false
2321
+ },
2322
+ "primaryType": {
2323
+ "type": "string",
2324
+ "const": "Receipt"
2325
+ },
2326
+ "message": {
2327
+ "type": "object",
2328
+ "properties": {
2329
+ "jobId": {
2330
+ "type": "string",
2331
+ "pattern": "^0x[0-9a-f]{64}$"
2332
+ },
2333
+ "attempt": {
2334
+ "type": "integer",
2335
+ "minimum": 1,
2336
+ "maximum": 2
2337
+ },
2338
+ "resultHash": {
2339
+ "type": "string",
2340
+ "pattern": "^0x[0-9a-f]{64}$"
2341
+ }
2342
+ },
2343
+ "required": [
2344
+ "jobId",
2345
+ "attempt",
2346
+ "resultHash"
2347
+ ],
2348
+ "additionalProperties": false
2349
+ }
2350
+ },
2351
+ "required": [
2352
+ "domain",
2353
+ "types",
2354
+ "primaryType",
2355
+ "message"
2356
+ ],
2357
+ "additionalProperties": false
2358
+ }
2359
+ ]
2360
+ },
2361
+ "transaction": {
2362
+ "type": "null"
2363
+ },
2364
+ "relay": {
2365
+ "type": "object",
2366
+ "properties": {
2367
+ "queued": {
2368
+ "type": "boolean"
2369
+ },
2370
+ "id": {
2371
+ "anyOf": [
2372
+ {
2373
+ "type": "string",
2374
+ "pattern": "^[a-f0-9]{64}$"
2375
+ },
2376
+ {
2377
+ "type": "null"
2378
+ }
2379
+ ]
2380
+ }
2381
+ },
2382
+ "required": [
2383
+ "queued",
2384
+ "id"
2385
+ ],
2386
+ "additionalProperties": false
2387
+ }
2388
+ },
2389
+ "required": [
2390
+ "signing",
2391
+ "transaction",
2392
+ "relay"
2393
+ ],
2394
+ "additionalProperties": false
2395
+ },
2396
+ {
2397
+ "type": "object",
2398
+ "properties": {
2399
+ "signing": {
2400
+ "type": "null"
2401
+ },
2402
+ "transaction": {
2403
+ "type": "object",
2404
+ "properties": {
2405
+ "chainId": {
2406
+ "type": "number",
2407
+ "const": 8453
2408
+ },
2409
+ "to": {
2410
+ "type": "string",
2411
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
2412
+ },
2413
+ "data": {
2414
+ "type": "string",
2415
+ "pattern": "^0x[0-9a-fA-F]+$"
2416
+ },
2417
+ "value": {
2418
+ "type": "string",
2419
+ "const": "0"
2420
+ },
2421
+ "from": {
2422
+ "type": "string",
2423
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
2424
+ }
2425
+ },
2426
+ "required": [
2427
+ "chainId",
2428
+ "to",
2429
+ "data",
2430
+ "value"
2431
+ ],
2432
+ "additionalProperties": false
2433
+ },
2434
+ "relay": {
2435
+ "type": "object",
2436
+ "properties": {
2437
+ "queued": {
2438
+ "type": "boolean"
2439
+ },
2440
+ "id": {
2441
+ "anyOf": [
2442
+ {
2443
+ "type": "string",
2444
+ "pattern": "^[a-f0-9]{64}$"
2445
+ },
2446
+ {
2447
+ "type": "null"
2448
+ }
2449
+ ]
2450
+ }
2451
+ },
2452
+ "required": [
2453
+ "queued",
2454
+ "id"
2455
+ ],
2456
+ "additionalProperties": false
2457
+ }
2458
+ },
2459
+ "required": [
2460
+ "signing",
2461
+ "transaction",
2462
+ "relay"
2463
+ ],
2464
+ "additionalProperties": false
2465
+ }
2466
+ ]
2467
+ },
2468
+ "ProtectedInspectionAppealResponse": {
2469
+ "type": "object",
2470
+ "properties": {
2471
+ "transaction": {
2472
+ "type": "object",
2473
+ "properties": {
2474
+ "chainId": {
2475
+ "type": "number",
2476
+ "const": 8453
2477
+ },
2478
+ "to": {
2479
+ "type": "string",
2480
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
2481
+ },
2482
+ "data": {
2483
+ "type": "string",
2484
+ "pattern": "^0x[0-9a-fA-F]+$"
2485
+ },
2486
+ "value": {
2487
+ "type": "string",
2488
+ "const": "0"
2489
+ },
2490
+ "from": {
2491
+ "type": "string",
2492
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
2493
+ }
2494
+ },
2495
+ "required": [
2496
+ "chainId",
2497
+ "to",
2498
+ "data",
2499
+ "value"
2500
+ ],
2501
+ "additionalProperties": false
2502
+ },
2503
+ "relay": {
2504
+ "type": "object",
2505
+ "properties": {
2506
+ "queued": {
2507
+ "type": "boolean"
2508
+ },
2509
+ "id": {
2510
+ "anyOf": [
2511
+ {
2512
+ "type": "string",
2513
+ "pattern": "^[a-f0-9]{64}$"
2514
+ },
2515
+ {
2516
+ "type": "null"
2517
+ }
2518
+ ]
2519
+ }
2520
+ },
2521
+ "required": [
2522
+ "queued",
2523
+ "id"
2524
+ ],
2525
+ "additionalProperties": false
2526
+ }
2527
+ },
2528
+ "required": [
2529
+ "transaction",
2530
+ "relay"
2531
+ ],
2532
+ "additionalProperties": false
2533
+ },
2534
+ "ProtectedInspectionReplicasRequest": {
2535
+ "type": "object",
2536
+ "properties": {
2537
+ "attempt": {
2538
+ "type": "integer",
2539
+ "minimum": 1,
2540
+ "maximum": 2
2541
+ },
2542
+ "resultHash": {
2543
+ "type": "string",
2544
+ "pattern": "^0x[0-9a-f]{64}$"
2545
+ },
2546
+ "replicaA": {
2547
+ "type": "string",
2548
+ "pattern": "^0x[0-9a-fA-F]{130}$"
2549
+ },
2550
+ "replicaB": {
2551
+ "type": "string",
2552
+ "pattern": "^0x[0-9a-fA-F]{130}$"
2553
+ }
2554
+ },
2555
+ "required": [
2556
+ "attempt",
2557
+ "resultHash",
2558
+ "replicaA",
2559
+ "replicaB"
2560
+ ],
2561
+ "additionalProperties": false
2562
+ },
2563
+ "ProtectedInspectionReplicasResponse": {
2564
+ "type": "object",
2565
+ "properties": {
2566
+ "jobId": {
2567
+ "type": "string",
2568
+ "pattern": "^0x[0-9a-f]{64}$"
2569
+ },
2570
+ "attempt": {
2571
+ "type": "integer",
2572
+ "minimum": 1,
2573
+ "maximum": 2
2574
+ },
2575
+ "resultHash": {
2576
+ "type": "string",
2577
+ "pattern": "^0x[0-9a-f]{64}$"
2578
+ },
2579
+ "replicated": {
2580
+ "type": "boolean",
2581
+ "const": true
2582
+ }
2583
+ },
2584
+ "required": [
2585
+ "jobId",
2586
+ "attempt",
2587
+ "resultHash",
2588
+ "replicated"
2589
+ ],
2590
+ "additionalProperties": false
2591
+ },
2592
+ "ProtectedInspectionObservationRequest": {
2593
+ "type": "object",
2594
+ "properties": {
2595
+ "task": {
2596
+ "type": "object",
2597
+ "properties": {
2598
+ "version": {
2599
+ "type": "string",
2600
+ "const": "funded-inspection-v1"
2601
+ },
2602
+ "requestId": {
2603
+ "type": "string",
2604
+ "format": "uuid",
2605
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
2606
+ },
2607
+ "proposalId": {
2608
+ "type": "string",
2609
+ "format": "uuid",
2610
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
2611
+ },
2612
+ "proposalTermsHash": {
2613
+ "type": "string",
2614
+ "pattern": "^[a-f0-9]{64}$"
2615
+ },
2616
+ "plan": {
2617
+ "type": "object",
2618
+ "properties": {
2619
+ "version": {
2620
+ "type": "string",
2621
+ "const": "buyer-probe-v1"
2622
+ },
2623
+ "targetUrl": {
2624
+ "type": "string",
2625
+ "maxLength": 2048,
2626
+ "format": "uri"
2627
+ },
2628
+ "method": {
2629
+ "type": "string",
2630
+ "const": "GET"
2631
+ },
2632
+ "paymentRecipient": {
2633
+ "type": "string",
2634
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
2635
+ },
2636
+ "maxTestAmountAtomic": {
2637
+ "type": "string",
2638
+ "pattern": "^(?:0|[1-9][0-9]{0,5}|1000000)$"
2639
+ },
2640
+ "maxPaidAttempts": {
2641
+ "type": "number",
2642
+ "const": 1
2643
+ }
2644
+ },
2645
+ "required": [
2646
+ "version",
2647
+ "targetUrl",
2648
+ "method",
2649
+ "paymentRecipient",
2650
+ "maxTestAmountAtomic",
2651
+ "maxPaidAttempts"
2652
+ ],
2653
+ "additionalProperties": false
2654
+ }
2655
+ },
2656
+ "required": [
2657
+ "version",
2658
+ "requestId",
2659
+ "proposalId",
2660
+ "proposalTermsHash",
2661
+ "plan"
2662
+ ],
2663
+ "additionalProperties": false
2664
+ },
2665
+ "evidence": {
2666
+ "type": "object",
2667
+ "properties": {
2668
+ "version": {
2669
+ "type": "string",
2670
+ "const": "inspection-result-v1"
2671
+ },
2672
+ "observation": {
2673
+ "type": "object",
2674
+ "properties": {
2675
+ "observedAt": {
2676
+ "type": "integer",
2677
+ "exclusiveMinimum": 0,
2678
+ "maximum": 9007199254740991
2679
+ },
2680
+ "probeNonce": {
2681
+ "type": "string",
2682
+ "pattern": "^0x[0-9a-f]{64}$"
2683
+ },
2684
+ "transport": {
2685
+ "type": "string",
2686
+ "enum": [
2687
+ "http",
2688
+ "error"
2689
+ ]
2690
+ },
2691
+ "statusCode": {
2692
+ "anyOf": [
2693
+ {
2694
+ "type": "integer",
2695
+ "minimum": 100,
2696
+ "maximum": 599
2697
+ },
2698
+ {
2699
+ "type": "null"
2700
+ }
2701
+ ]
2702
+ },
2703
+ "responseHash": {
2704
+ "anyOf": [
2705
+ {
2706
+ "type": "string",
2707
+ "pattern": "^0x[0-9a-f]{64}$"
2708
+ },
2709
+ {
2710
+ "type": "null"
2711
+ }
2712
+ ]
2713
+ },
2714
+ "authorizationIssued": {
2715
+ "type": "boolean"
2716
+ },
2717
+ "paymentAmountAtomic": {
2718
+ "type": "string",
2719
+ "pattern": "^(?:0|[1-9][0-9]{0,5}|1000000)$"
2720
+ },
2721
+ "paymentTransaction": {
2722
+ "anyOf": [
2723
+ {
2724
+ "type": "string",
2725
+ "pattern": "^0x[0-9a-f]{64}$"
2726
+ },
2727
+ {
2728
+ "type": "null"
2729
+ }
2730
+ ]
2731
+ }
2732
+ },
2733
+ "required": [
2734
+ "observedAt",
2735
+ "probeNonce",
2736
+ "transport",
2737
+ "statusCode",
2738
+ "responseHash",
2739
+ "authorizationIssued",
2740
+ "paymentAmountAtomic",
2741
+ "paymentTransaction"
2742
+ ],
2743
+ "additionalProperties": false
2744
+ },
2745
+ "buyerSignature": {
2746
+ "type": "string",
2747
+ "pattern": "^0x[0-9a-fA-F]{130}$"
2748
+ },
2749
+ "classification": {
2750
+ "type": "string",
2751
+ "enum": [
2752
+ "payment_confirmed_response_received",
2753
+ "payment_confirmed_endpoint_failure",
2754
+ "payment_outcome_unresolved",
2755
+ "unpaid_response",
2756
+ "transport_failure"
2757
+ ]
2758
+ }
2759
+ },
2760
+ "required": [
2761
+ "version",
2762
+ "observation",
2763
+ "buyerSignature",
2764
+ "classification"
2765
+ ],
2766
+ "additionalProperties": false
2767
+ }
2768
+ },
2769
+ "required": [
2770
+ "task",
2771
+ "evidence"
2772
+ ],
2773
+ "additionalProperties": false
2774
+ },
2775
+ "ProtectedInspectionObservationResponse": {
2776
+ "type": "object",
2777
+ "properties": {
2778
+ "jobId": {
2779
+ "type": "string",
2780
+ "pattern": "^0x[0-9a-f]{64}$"
2781
+ },
2782
+ "retained": {
2783
+ "type": "boolean",
2784
+ "const": true
2785
+ },
2786
+ "replay": {
2787
+ "type": "boolean"
2788
+ }
2789
+ },
2790
+ "required": [
2791
+ "jobId",
2792
+ "retained",
2793
+ "replay"
2794
+ ],
2795
+ "additionalProperties": false
2796
+ },
2797
+ "ProtectedInspectionStartRequest": {
2798
+ "type": "object",
2799
+ "properties": {
2800
+ "proof": {
2801
+ "type": "object",
2802
+ "properties": {
2803
+ "wallet": {
2804
+ "type": "string",
2805
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
2806
+ },
2807
+ "expiresAt": {
2808
+ "type": "integer",
2809
+ "exclusiveMinimum": 0,
2810
+ "maximum": 9007199254740991
2811
+ },
2812
+ "signature": {
2813
+ "type": "string",
2814
+ "pattern": "^0x[0-9a-fA-F]{130}$"
2815
+ }
2816
+ },
2817
+ "required": [
2818
+ "wallet",
2819
+ "expiresAt",
2820
+ "signature"
2821
+ ],
2822
+ "additionalProperties": false
2823
+ }
2824
+ },
2825
+ "required": [
2826
+ "proof"
2827
+ ],
2828
+ "additionalProperties": false
2829
+ },
2830
+ "ProtectedInspectionStartResponse": {
2831
+ "type": "object",
2832
+ "properties": {
2833
+ "jobId": {
2834
+ "type": "string",
2835
+ "pattern": "^0x[0-9a-f]{64}$"
2836
+ },
2837
+ "startAllowed": {
2838
+ "const": true
2839
+ },
2840
+ "task": {
2841
+ "type": "object",
2842
+ "properties": {
2843
+ "version": {
2844
+ "type": "string",
2845
+ "const": "funded-inspection-v1"
2846
+ },
2847
+ "requestId": {
2848
+ "type": "string",
2849
+ "format": "uuid",
2850
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
2851
+ },
2852
+ "proposalId": {
2853
+ "type": "string",
2854
+ "format": "uuid",
2855
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
2856
+ },
2857
+ "proposalTermsHash": {
2858
+ "type": "string",
2859
+ "pattern": "^[a-f0-9]{64}$"
2860
+ },
2861
+ "plan": {
2862
+ "type": "object",
2863
+ "properties": {
2864
+ "version": {
2865
+ "type": "string",
2866
+ "const": "buyer-probe-v1"
2867
+ },
2868
+ "targetUrl": {
2869
+ "type": "string",
2870
+ "maxLength": 2048,
2871
+ "format": "uri"
2872
+ },
2873
+ "method": {
2874
+ "type": "string",
2875
+ "const": "GET"
2876
+ },
2877
+ "paymentRecipient": {
2878
+ "type": "string",
2879
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
2880
+ },
2881
+ "maxTestAmountAtomic": {
2882
+ "type": "string",
2883
+ "pattern": "^(?:0|[1-9][0-9]{0,5}|1000000)$"
2884
+ },
2885
+ "maxPaidAttempts": {
2886
+ "type": "number",
2887
+ "const": 1
2888
+ }
2889
+ },
2890
+ "required": [
2891
+ "version",
2892
+ "targetUrl",
2893
+ "method",
2894
+ "paymentRecipient",
2895
+ "maxTestAmountAtomic",
2896
+ "maxPaidAttempts"
2897
+ ],
2898
+ "additionalProperties": false
2899
+ }
2900
+ },
2901
+ "required": [
2902
+ "version",
2903
+ "requestId",
2904
+ "proposalId",
2905
+ "proposalTermsHash",
2906
+ "plan"
2907
+ ],
2908
+ "additionalProperties": false
2909
+ },
2910
+ "evidence": {
2911
+ "type": "object",
2912
+ "properties": {
2913
+ "version": {
2914
+ "type": "string",
2915
+ "const": "inspection-result-v1"
2916
+ },
2917
+ "observation": {
2918
+ "type": "object",
2919
+ "properties": {
2920
+ "observedAt": {
2921
+ "type": "integer",
2922
+ "exclusiveMinimum": 0,
2923
+ "maximum": 9007199254740991
2924
+ },
2925
+ "probeNonce": {
2926
+ "type": "string",
2927
+ "pattern": "^0x[0-9a-f]{64}$"
2928
+ },
2929
+ "transport": {
2930
+ "type": "string",
2931
+ "enum": [
2932
+ "http",
2933
+ "error"
2934
+ ]
2935
+ },
2936
+ "statusCode": {
2937
+ "anyOf": [
2938
+ {
2939
+ "type": "integer",
2940
+ "minimum": 100,
2941
+ "maximum": 599
2942
+ },
2943
+ {
2944
+ "type": "null"
2945
+ }
2946
+ ]
2947
+ },
2948
+ "responseHash": {
2949
+ "anyOf": [
2950
+ {
2951
+ "type": "string",
2952
+ "pattern": "^0x[0-9a-f]{64}$"
2953
+ },
2954
+ {
2955
+ "type": "null"
2956
+ }
2957
+ ]
2958
+ },
2959
+ "authorizationIssued": {
2960
+ "type": "boolean"
2961
+ },
2962
+ "paymentAmountAtomic": {
2963
+ "type": "string",
2964
+ "pattern": "^(?:0|[1-9][0-9]{0,5}|1000000)$"
2965
+ },
2966
+ "paymentTransaction": {
2967
+ "anyOf": [
2968
+ {
2969
+ "type": "string",
2970
+ "pattern": "^0x[0-9a-f]{64}$"
2971
+ },
2972
+ {
2973
+ "type": "null"
2974
+ }
2975
+ ]
2976
+ }
2977
+ },
2978
+ "required": [
2979
+ "observedAt",
2980
+ "probeNonce",
2981
+ "transport",
2982
+ "statusCode",
2983
+ "responseHash",
2984
+ "authorizationIssued",
2985
+ "paymentAmountAtomic",
2986
+ "paymentTransaction"
2987
+ ],
2988
+ "additionalProperties": false
2989
+ },
2990
+ "buyerSignature": {
2991
+ "type": "string",
2992
+ "pattern": "^0x[0-9a-fA-F]{130}$"
2993
+ },
2994
+ "classification": {
2995
+ "type": "string",
2996
+ "enum": [
2997
+ "payment_confirmed_response_received",
2998
+ "payment_confirmed_endpoint_failure",
2999
+ "payment_outcome_unresolved",
3000
+ "unpaid_response",
3001
+ "transport_failure"
3002
+ ]
3003
+ }
3004
+ },
3005
+ "required": [
3006
+ "version",
3007
+ "observation",
3008
+ "buyerSignature",
3009
+ "classification"
3010
+ ],
3011
+ "additionalProperties": false
3012
+ },
3013
+ "terms": {
3014
+ "type": "object",
3015
+ "properties": {
3016
+ "buyer": {
3017
+ "type": "string",
3018
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
3019
+ },
3020
+ "seller": {
3021
+ "type": "string",
3022
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
3023
+ },
3024
+ "amount": {
3025
+ "type": "string",
3026
+ "pattern": "^(?:[1-9][0-9]{0,7}|100000000)$"
3027
+ },
3028
+ "workHash": {
3029
+ "type": "string",
3030
+ "pattern": "^0x[0-9a-f]{64}$"
3031
+ },
3032
+ "deliveryDeadline": {
3033
+ "type": "integer",
3034
+ "exclusiveMinimum": 0,
3035
+ "maximum": 9007199254740991
3036
+ },
3037
+ "evaluationPeriod": {
3038
+ "type": "integer",
3039
+ "minimum": 300,
3040
+ "maximum": 86400
3041
+ },
3042
+ "correctionPeriod": {
3043
+ "type": "integer",
3044
+ "minimum": 300,
3045
+ "maximum": 86400
3046
+ },
3047
+ "resolutionDeadline": {
3048
+ "type": "integer",
3049
+ "exclusiveMinimum": 0,
3050
+ "maximum": 9007199254740991
3051
+ },
3052
+ "reviewPeriod": {
3053
+ "type": "integer",
3054
+ "minimum": 300,
3055
+ "maximum": 86400
3056
+ },
3057
+ "appealPeriod": {
3058
+ "type": "integer",
3059
+ "minimum": 300,
3060
+ "maximum": 86400
3061
+ },
3062
+ "appealVerifier": {
3063
+ "type": "string",
3064
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
3065
+ },
3066
+ "fallbackVerifier": {
3067
+ "type": "string",
3068
+ "pattern": "^0x(?!0{40}$)[0-9a-fA-F]{40}$"
3069
+ },
3070
+ "appealOriginHash": {
3071
+ "type": "string",
3072
+ "pattern": "^0x[0-9a-f]{64}$"
3073
+ },
3074
+ "fallbackOriginHash": {
3075
+ "type": "string",
3076
+ "pattern": "^0x[0-9a-f]{64}$"
3077
+ },
3078
+ "verifierHash": {
3079
+ "type": "string",
3080
+ "const": "0x9ab07031c15c8a11071e8e65aaeabfb4d11160466bb76c5733477d6436757312"
3081
+ },
3082
+ "nonce": {
3083
+ "type": "string",
3084
+ "pattern": "^0x[0-9a-f]{64}$"
3085
+ }
3086
+ },
3087
+ "required": [
3088
+ "buyer",
3089
+ "seller",
3090
+ "amount",
3091
+ "workHash",
3092
+ "deliveryDeadline",
3093
+ "evaluationPeriod",
3094
+ "correctionPeriod",
3095
+ "resolutionDeadline",
3096
+ "reviewPeriod",
3097
+ "appealPeriod",
3098
+ "appealVerifier",
3099
+ "fallbackVerifier",
3100
+ "appealOriginHash",
3101
+ "fallbackOriginHash",
3102
+ "verifierHash",
3103
+ "nonce"
3104
+ ],
3105
+ "additionalProperties": false
3106
+ }
3107
+ },
3108
+ "required": [
3109
+ "jobId",
3110
+ "startAllowed",
3111
+ "task",
3112
+ "evidence",
3113
+ "terms"
3114
+ ],
3115
+ "additionalProperties": false
3116
+ }
3117
+ };