@peac/schema 0.10.14 → 0.11.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.
@@ -124,224 +124,115 @@ export declare const DIGEST_VALUE_PATTERN: RegExp;
124
124
  /**
125
125
  * Digest algorithm schema - strict canonical set
126
126
  */
127
- export declare const DigestAlgSchema: z.ZodEnum<["sha-256", "sha-256:trunc-64k", "sha-256:trunc-1m"]>;
127
+ export declare const DigestAlgSchema: z.ZodEnum<{
128
+ "sha-256": "sha-256";
129
+ "sha-256:trunc-64k": "sha-256:trunc-64k";
130
+ "sha-256:trunc-1m": "sha-256:trunc-1m";
131
+ }>;
128
132
  /**
129
133
  * Digest schema for privacy-preserving content hashing
130
134
  */
131
135
  export declare const DigestSchema: z.ZodObject<{
132
- /** Algorithm: 'sha-256' (full) or 'sha-256:trunc-{size}' (truncated) */
133
- alg: z.ZodEnum<["sha-256", "sha-256:trunc-64k", "sha-256:trunc-1m"]>;
134
- /** 64 lowercase hex chars (SHA-256 output) */
136
+ alg: z.ZodEnum<{
137
+ "sha-256": "sha-256";
138
+ "sha-256:trunc-64k": "sha-256:trunc-64k";
139
+ "sha-256:trunc-1m": "sha-256:trunc-1m";
140
+ }>;
135
141
  value: z.ZodString;
136
- /** Original byte length before any truncation (REQUIRED) */
137
142
  bytes: z.ZodNumber;
138
- }, "strict", z.ZodTypeAny, {
139
- value: string;
140
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
141
- bytes: number;
142
- }, {
143
- value: string;
144
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
145
- bytes: number;
146
- }>;
143
+ }, z.core.$strict>;
147
144
  /**
148
145
  * Payload reference schema (on-wire, portable)
149
146
  */
150
147
  export declare const PayloadRefSchema: z.ZodObject<{
151
- /** Content digest */
152
148
  digest: z.ZodObject<{
153
- /** Algorithm: 'sha-256' (full) or 'sha-256:trunc-{size}' (truncated) */
154
- alg: z.ZodEnum<["sha-256", "sha-256:trunc-64k", "sha-256:trunc-1m"]>;
155
- /** 64 lowercase hex chars (SHA-256 output) */
149
+ alg: z.ZodEnum<{
150
+ "sha-256": "sha-256";
151
+ "sha-256:trunc-64k": "sha-256:trunc-64k";
152
+ "sha-256:trunc-1m": "sha-256:trunc-1m";
153
+ }>;
156
154
  value: z.ZodString;
157
- /** Original byte length before any truncation (REQUIRED) */
158
155
  bytes: z.ZodNumber;
159
- }, "strict", z.ZodTypeAny, {
160
- value: string;
161
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
162
- bytes: number;
163
- }, {
164
- value: string;
165
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
166
- bytes: number;
156
+ }, z.core.$strict>;
157
+ redaction: z.ZodEnum<{
158
+ hash_only: "hash_only";
159
+ redacted: "redacted";
160
+ plaintext_allowlisted: "plaintext_allowlisted";
167
161
  }>;
168
- /** Redaction mode */
169
- redaction: z.ZodEnum<["hash_only", "redacted", "plaintext_allowlisted"]>;
170
- }, "strict", z.ZodTypeAny, {
171
- digest: {
172
- value: string;
173
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
174
- bytes: number;
175
- };
176
- redaction: "hash_only" | "redacted" | "plaintext_allowlisted";
177
- }, {
178
- digest: {
179
- value: string;
180
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
181
- bytes: number;
182
- };
183
- redaction: "hash_only" | "redacted" | "plaintext_allowlisted";
184
- }>;
162
+ }, z.core.$strict>;
185
163
  /**
186
164
  * Executor identity schema (who ran this)
187
165
  */
188
166
  export declare const ExecutorSchema: z.ZodObject<{
189
- /** Platform identifier: 'openclaw', 'mcp', 'a2a', 'claude-code' */
190
167
  platform: z.ZodString;
191
- /** Platform version */
192
168
  version: z.ZodOptional<z.ZodString>;
193
- /** Plugin that captured this */
194
169
  plugin_id: z.ZodOptional<z.ZodString>;
195
- /** Hash of plugin package (provenance) */
196
170
  plugin_digest: z.ZodOptional<z.ZodObject<{
197
- /** Algorithm: 'sha-256' (full) or 'sha-256:trunc-{size}' (truncated) */
198
- alg: z.ZodEnum<["sha-256", "sha-256:trunc-64k", "sha-256:trunc-1m"]>;
199
- /** 64 lowercase hex chars (SHA-256 output) */
171
+ alg: z.ZodEnum<{
172
+ "sha-256": "sha-256";
173
+ "sha-256:trunc-64k": "sha-256:trunc-64k";
174
+ "sha-256:trunc-1m": "sha-256:trunc-1m";
175
+ }>;
200
176
  value: z.ZodString;
201
- /** Original byte length before any truncation (REQUIRED) */
202
177
  bytes: z.ZodNumber;
203
- }, "strict", z.ZodTypeAny, {
204
- value: string;
205
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
206
- bytes: number;
207
- }, {
208
- value: string;
209
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
210
- bytes: number;
211
- }>>;
212
- }, "strict", z.ZodTypeAny, {
213
- platform: string;
214
- version?: string | undefined;
215
- plugin_id?: string | undefined;
216
- plugin_digest?: {
217
- value: string;
218
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
219
- bytes: number;
220
- } | undefined;
221
- }, {
222
- platform: string;
223
- version?: string | undefined;
224
- plugin_id?: string | undefined;
225
- plugin_digest?: {
226
- value: string;
227
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
228
- bytes: number;
229
- } | undefined;
230
- }>;
178
+ }, z.core.$strict>>;
179
+ }, z.core.$strict>;
231
180
  /**
232
181
  * Tool target schema (for tool.call kind)
233
182
  */
234
183
  export declare const ToolTargetSchema: z.ZodObject<{
235
- /** Tool name */
236
184
  name: z.ZodString;
237
- /** Tool provider */
238
185
  provider: z.ZodOptional<z.ZodString>;
239
- /** Tool version */
240
186
  version: z.ZodOptional<z.ZodString>;
241
- }, "strict", z.ZodTypeAny, {
242
- name: string;
243
- version?: string | undefined;
244
- provider?: string | undefined;
245
- }, {
246
- name: string;
247
- version?: string | undefined;
248
- provider?: string | undefined;
249
- }>;
187
+ }, z.core.$strict>;
250
188
  /**
251
189
  * Resource target schema (for http/fs kinds)
252
190
  */
253
191
  export declare const ResourceTargetSchema: z.ZodObject<{
254
- /** Resource URI */
255
192
  uri: z.ZodOptional<z.ZodString>;
256
- /** HTTP method or operation */
257
193
  method: z.ZodOptional<z.ZodString>;
258
- }, "strict", z.ZodTypeAny, {
259
- method?: string | undefined;
260
- uri?: string | undefined;
261
- }, {
262
- method?: string | undefined;
263
- uri?: string | undefined;
264
- }>;
194
+ }, z.core.$strict>;
265
195
  /**
266
196
  * Execution result schema
267
197
  */
268
198
  export declare const ResultSchema: z.ZodObject<{
269
- /** Result status */
270
- status: z.ZodEnum<["ok", "error", "timeout", "canceled"]>;
271
- /** Error code (PEAC error code or namespaced) */
199
+ status: z.ZodEnum<{
200
+ error: "error";
201
+ ok: "ok";
202
+ timeout: "timeout";
203
+ canceled: "canceled";
204
+ }>;
272
205
  error_code: z.ZodOptional<z.ZodString>;
273
- /** Whether the operation can be retried */
274
206
  retryable: z.ZodOptional<z.ZodBoolean>;
275
- }, "strict", z.ZodTypeAny, {
276
- status: "error" | "ok" | "timeout" | "canceled";
277
- error_code?: string | undefined;
278
- retryable?: boolean | undefined;
279
- }, {
280
- status: "error" | "ok" | "timeout" | "canceled";
281
- error_code?: string | undefined;
282
- retryable?: boolean | undefined;
283
- }>;
207
+ }, z.core.$strict>;
284
208
  /**
285
209
  * Policy context schema (policy state at execution time)
286
210
  */
287
211
  export declare const PolicyContextSchema: z.ZodObject<{
288
- /** Policy decision */
289
- decision: z.ZodEnum<["allow", "deny", "constrained"]>;
290
- /** Whether sandbox mode was enabled */
212
+ decision: z.ZodEnum<{
213
+ allow: "allow";
214
+ deny: "deny";
215
+ constrained: "constrained";
216
+ }>;
291
217
  sandbox_enabled: z.ZodOptional<z.ZodBoolean>;
292
- /** Whether elevated permissions were granted */
293
218
  elevated: z.ZodOptional<z.ZodBoolean>;
294
- /** Hash of effective policy document */
295
219
  effective_policy_digest: z.ZodOptional<z.ZodObject<{
296
- /** Algorithm: 'sha-256' (full) or 'sha-256:trunc-{size}' (truncated) */
297
- alg: z.ZodEnum<["sha-256", "sha-256:trunc-64k", "sha-256:trunc-1m"]>;
298
- /** 64 lowercase hex chars (SHA-256 output) */
220
+ alg: z.ZodEnum<{
221
+ "sha-256": "sha-256";
222
+ "sha-256:trunc-64k": "sha-256:trunc-64k";
223
+ "sha-256:trunc-1m": "sha-256:trunc-1m";
224
+ }>;
299
225
  value: z.ZodString;
300
- /** Original byte length before any truncation (REQUIRED) */
301
226
  bytes: z.ZodNumber;
302
- }, "strict", z.ZodTypeAny, {
303
- value: string;
304
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
305
- bytes: number;
306
- }, {
307
- value: string;
308
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
309
- bytes: number;
310
- }>>;
311
- }, "strict", z.ZodTypeAny, {
312
- decision: "allow" | "deny" | "constrained";
313
- sandbox_enabled?: boolean | undefined;
314
- elevated?: boolean | undefined;
315
- effective_policy_digest?: {
316
- value: string;
317
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
318
- bytes: number;
319
- } | undefined;
320
- }, {
321
- decision: "allow" | "deny" | "constrained";
322
- sandbox_enabled?: boolean | undefined;
323
- elevated?: boolean | undefined;
324
- effective_policy_digest?: {
325
- value: string;
326
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
327
- bytes: number;
328
- } | undefined;
329
- }>;
227
+ }, z.core.$strict>>;
228
+ }, z.core.$strict>;
330
229
  /**
331
230
  * References schema (links to related evidence)
332
231
  */
333
232
  export declare const RefsSchema: z.ZodObject<{
334
- /** Links to evidence.payment.reference */
335
233
  payment_reference: z.ZodOptional<z.ZodString>;
336
- /** Correlation across receipts */
337
234
  related_receipt_rid: z.ZodOptional<z.ZodString>;
338
- }, "strict", z.ZodTypeAny, {
339
- payment_reference?: string | undefined;
340
- related_receipt_rid?: string | undefined;
341
- }, {
342
- payment_reference?: string | undefined;
343
- related_receipt_rid?: string | undefined;
344
- }>;
235
+ }, z.core.$strict>;
345
236
  /**
346
237
  * Kind schema with format validation
347
238
  */
@@ -353,484 +244,101 @@ export declare const KindSchema: z.ZodString;
353
244
  * both direct schema validation and ordered validation produce
354
245
  * consistent results.
355
246
  */
356
- export declare const InteractionEvidenceV01Schema: z.ZodEffects<z.ZodObject<{
357
- /** Stable ID for idempotency/dedupe (REQUIRED) */
247
+ export declare const InteractionEvidenceV01Schema: z.ZodObject<{
358
248
  interaction_id: z.ZodString;
359
- /** Event kind - open string, not closed enum (REQUIRED) */
360
249
  kind: z.ZodString;
361
- /** Executor identity (REQUIRED) */
362
250
  executor: z.ZodObject<{
363
- /** Platform identifier: 'openclaw', 'mcp', 'a2a', 'claude-code' */
364
251
  platform: z.ZodString;
365
- /** Platform version */
366
252
  version: z.ZodOptional<z.ZodString>;
367
- /** Plugin that captured this */
368
253
  plugin_id: z.ZodOptional<z.ZodString>;
369
- /** Hash of plugin package (provenance) */
370
254
  plugin_digest: z.ZodOptional<z.ZodObject<{
371
- /** Algorithm: 'sha-256' (full) or 'sha-256:trunc-{size}' (truncated) */
372
- alg: z.ZodEnum<["sha-256", "sha-256:trunc-64k", "sha-256:trunc-1m"]>;
373
- /** 64 lowercase hex chars (SHA-256 output) */
255
+ alg: z.ZodEnum<{
256
+ "sha-256": "sha-256";
257
+ "sha-256:trunc-64k": "sha-256:trunc-64k";
258
+ "sha-256:trunc-1m": "sha-256:trunc-1m";
259
+ }>;
374
260
  value: z.ZodString;
375
- /** Original byte length before any truncation (REQUIRED) */
376
261
  bytes: z.ZodNumber;
377
- }, "strict", z.ZodTypeAny, {
378
- value: string;
379
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
380
- bytes: number;
381
- }, {
382
- value: string;
383
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
384
- bytes: number;
385
- }>>;
386
- }, "strict", z.ZodTypeAny, {
387
- platform: string;
388
- version?: string | undefined;
389
- plugin_id?: string | undefined;
390
- plugin_digest?: {
391
- value: string;
392
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
393
- bytes: number;
394
- } | undefined;
395
- }, {
396
- platform: string;
397
- version?: string | undefined;
398
- plugin_id?: string | undefined;
399
- plugin_digest?: {
400
- value: string;
401
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
402
- bytes: number;
403
- } | undefined;
404
- }>;
405
- /** Tool target (when kind is tool-related) */
262
+ }, z.core.$strict>>;
263
+ }, z.core.$strict>;
406
264
  tool: z.ZodOptional<z.ZodObject<{
407
- /** Tool name */
408
265
  name: z.ZodString;
409
- /** Tool provider */
410
266
  provider: z.ZodOptional<z.ZodString>;
411
- /** Tool version */
412
267
  version: z.ZodOptional<z.ZodString>;
413
- }, "strict", z.ZodTypeAny, {
414
- name: string;
415
- version?: string | undefined;
416
- provider?: string | undefined;
417
- }, {
418
- name: string;
419
- version?: string | undefined;
420
- provider?: string | undefined;
421
- }>>;
422
- /** Resource target (when kind is http/fs-related) */
268
+ }, z.core.$strict>>;
423
269
  resource: z.ZodOptional<z.ZodObject<{
424
- /** Resource URI */
425
270
  uri: z.ZodOptional<z.ZodString>;
426
- /** HTTP method or operation */
427
271
  method: z.ZodOptional<z.ZodString>;
428
- }, "strict", z.ZodTypeAny, {
429
- method?: string | undefined;
430
- uri?: string | undefined;
431
- }, {
432
- method?: string | undefined;
433
- uri?: string | undefined;
434
- }>>;
435
- /** Input payload reference */
272
+ }, z.core.$strict>>;
436
273
  input: z.ZodOptional<z.ZodObject<{
437
- /** Content digest */
438
274
  digest: z.ZodObject<{
439
- /** Algorithm: 'sha-256' (full) or 'sha-256:trunc-{size}' (truncated) */
440
- alg: z.ZodEnum<["sha-256", "sha-256:trunc-64k", "sha-256:trunc-1m"]>;
441
- /** 64 lowercase hex chars (SHA-256 output) */
275
+ alg: z.ZodEnum<{
276
+ "sha-256": "sha-256";
277
+ "sha-256:trunc-64k": "sha-256:trunc-64k";
278
+ "sha-256:trunc-1m": "sha-256:trunc-1m";
279
+ }>;
442
280
  value: z.ZodString;
443
- /** Original byte length before any truncation (REQUIRED) */
444
281
  bytes: z.ZodNumber;
445
- }, "strict", z.ZodTypeAny, {
446
- value: string;
447
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
448
- bytes: number;
449
- }, {
450
- value: string;
451
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
452
- bytes: number;
282
+ }, z.core.$strict>;
283
+ redaction: z.ZodEnum<{
284
+ hash_only: "hash_only";
285
+ redacted: "redacted";
286
+ plaintext_allowlisted: "plaintext_allowlisted";
453
287
  }>;
454
- /** Redaction mode */
455
- redaction: z.ZodEnum<["hash_only", "redacted", "plaintext_allowlisted"]>;
456
- }, "strict", z.ZodTypeAny, {
457
- digest: {
458
- value: string;
459
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
460
- bytes: number;
461
- };
462
- redaction: "hash_only" | "redacted" | "plaintext_allowlisted";
463
- }, {
464
- digest: {
465
- value: string;
466
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
467
- bytes: number;
468
- };
469
- redaction: "hash_only" | "redacted" | "plaintext_allowlisted";
470
- }>>;
471
- /** Output payload reference */
288
+ }, z.core.$strict>>;
472
289
  output: z.ZodOptional<z.ZodObject<{
473
- /** Content digest */
474
290
  digest: z.ZodObject<{
475
- /** Algorithm: 'sha-256' (full) or 'sha-256:trunc-{size}' (truncated) */
476
- alg: z.ZodEnum<["sha-256", "sha-256:trunc-64k", "sha-256:trunc-1m"]>;
477
- /** 64 lowercase hex chars (SHA-256 output) */
291
+ alg: z.ZodEnum<{
292
+ "sha-256": "sha-256";
293
+ "sha-256:trunc-64k": "sha-256:trunc-64k";
294
+ "sha-256:trunc-1m": "sha-256:trunc-1m";
295
+ }>;
478
296
  value: z.ZodString;
479
- /** Original byte length before any truncation (REQUIRED) */
480
297
  bytes: z.ZodNumber;
481
- }, "strict", z.ZodTypeAny, {
482
- value: string;
483
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
484
- bytes: number;
485
- }, {
486
- value: string;
487
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
488
- bytes: number;
298
+ }, z.core.$strict>;
299
+ redaction: z.ZodEnum<{
300
+ hash_only: "hash_only";
301
+ redacted: "redacted";
302
+ plaintext_allowlisted: "plaintext_allowlisted";
489
303
  }>;
490
- /** Redaction mode */
491
- redaction: z.ZodEnum<["hash_only", "redacted", "plaintext_allowlisted"]>;
492
- }, "strict", z.ZodTypeAny, {
493
- digest: {
494
- value: string;
495
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
496
- bytes: number;
497
- };
498
- redaction: "hash_only" | "redacted" | "plaintext_allowlisted";
499
- }, {
500
- digest: {
501
- value: string;
502
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
503
- bytes: number;
504
- };
505
- redaction: "hash_only" | "redacted" | "plaintext_allowlisted";
506
- }>>;
507
- /** Start time (RFC 3339) (REQUIRED) */
304
+ }, z.core.$strict>>;
508
305
  started_at: z.ZodString;
509
- /** Completion time (RFC 3339) */
510
306
  completed_at: z.ZodOptional<z.ZodString>;
511
- /** Duration in milliseconds (OPTIONAL, non-normative) */
512
307
  duration_ms: z.ZodOptional<z.ZodNumber>;
513
- /** Execution outcome */
514
308
  result: z.ZodOptional<z.ZodObject<{
515
- /** Result status */
516
- status: z.ZodEnum<["ok", "error", "timeout", "canceled"]>;
517
- /** Error code (PEAC error code or namespaced) */
309
+ status: z.ZodEnum<{
310
+ error: "error";
311
+ ok: "ok";
312
+ timeout: "timeout";
313
+ canceled: "canceled";
314
+ }>;
518
315
  error_code: z.ZodOptional<z.ZodString>;
519
- /** Whether the operation can be retried */
520
316
  retryable: z.ZodOptional<z.ZodBoolean>;
521
- }, "strict", z.ZodTypeAny, {
522
- status: "error" | "ok" | "timeout" | "canceled";
523
- error_code?: string | undefined;
524
- retryable?: boolean | undefined;
525
- }, {
526
- status: "error" | "ok" | "timeout" | "canceled";
527
- error_code?: string | undefined;
528
- retryable?: boolean | undefined;
529
- }>>;
530
- /** Policy context at execution */
317
+ }, z.core.$strict>>;
531
318
  policy: z.ZodOptional<z.ZodObject<{
532
- /** Policy decision */
533
- decision: z.ZodEnum<["allow", "deny", "constrained"]>;
534
- /** Whether sandbox mode was enabled */
319
+ decision: z.ZodEnum<{
320
+ allow: "allow";
321
+ deny: "deny";
322
+ constrained: "constrained";
323
+ }>;
535
324
  sandbox_enabled: z.ZodOptional<z.ZodBoolean>;
536
- /** Whether elevated permissions were granted */
537
325
  elevated: z.ZodOptional<z.ZodBoolean>;
538
- /** Hash of effective policy document */
539
326
  effective_policy_digest: z.ZodOptional<z.ZodObject<{
540
- /** Algorithm: 'sha-256' (full) or 'sha-256:trunc-{size}' (truncated) */
541
- alg: z.ZodEnum<["sha-256", "sha-256:trunc-64k", "sha-256:trunc-1m"]>;
542
- /** 64 lowercase hex chars (SHA-256 output) */
327
+ alg: z.ZodEnum<{
328
+ "sha-256": "sha-256";
329
+ "sha-256:trunc-64k": "sha-256:trunc-64k";
330
+ "sha-256:trunc-1m": "sha-256:trunc-1m";
331
+ }>;
543
332
  value: z.ZodString;
544
- /** Original byte length before any truncation (REQUIRED) */
545
333
  bytes: z.ZodNumber;
546
- }, "strict", z.ZodTypeAny, {
547
- value: string;
548
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
549
- bytes: number;
550
- }, {
551
- value: string;
552
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
553
- bytes: number;
554
- }>>;
555
- }, "strict", z.ZodTypeAny, {
556
- decision: "allow" | "deny" | "constrained";
557
- sandbox_enabled?: boolean | undefined;
558
- elevated?: boolean | undefined;
559
- effective_policy_digest?: {
560
- value: string;
561
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
562
- bytes: number;
563
- } | undefined;
564
- }, {
565
- decision: "allow" | "deny" | "constrained";
566
- sandbox_enabled?: boolean | undefined;
567
- elevated?: boolean | undefined;
568
- effective_policy_digest?: {
569
- value: string;
570
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
571
- bytes: number;
572
- } | undefined;
573
- }>>;
574
- /** References to related evidence */
334
+ }, z.core.$strict>>;
335
+ }, z.core.$strict>>;
575
336
  refs: z.ZodOptional<z.ZodObject<{
576
- /** Links to evidence.payment.reference */
577
337
  payment_reference: z.ZodOptional<z.ZodString>;
578
- /** Correlation across receipts */
579
338
  related_receipt_rid: z.ZodOptional<z.ZodString>;
580
- }, "strict", z.ZodTypeAny, {
581
- payment_reference?: string | undefined;
582
- related_receipt_rid?: string | undefined;
583
- }, {
584
- payment_reference?: string | undefined;
585
- related_receipt_rid?: string | undefined;
586
- }>>;
587
- /** Platform-specific extensions (MUST be namespaced) */
339
+ }, z.core.$strict>>;
588
340
  extensions: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
589
- }, "strict", z.ZodTypeAny, {
590
- started_at: string;
591
- interaction_id: string;
592
- kind: string;
593
- executor: {
594
- platform: string;
595
- version?: string | undefined;
596
- plugin_id?: string | undefined;
597
- plugin_digest?: {
598
- value: string;
599
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
600
- bytes: number;
601
- } | undefined;
602
- };
603
- policy?: {
604
- decision: "allow" | "deny" | "constrained";
605
- sandbox_enabled?: boolean | undefined;
606
- elevated?: boolean | undefined;
607
- effective_policy_digest?: {
608
- value: string;
609
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
610
- bytes: number;
611
- } | undefined;
612
- } | undefined;
613
- resource?: {
614
- method?: string | undefined;
615
- uri?: string | undefined;
616
- } | undefined;
617
- result?: {
618
- status: "error" | "ok" | "timeout" | "canceled";
619
- error_code?: string | undefined;
620
- retryable?: boolean | undefined;
621
- } | undefined;
622
- completed_at?: string | undefined;
623
- tool?: {
624
- name: string;
625
- version?: string | undefined;
626
- provider?: string | undefined;
627
- } | undefined;
628
- input?: {
629
- digest: {
630
- value: string;
631
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
632
- bytes: number;
633
- };
634
- redaction: "hash_only" | "redacted" | "plaintext_allowlisted";
635
- } | undefined;
636
- output?: {
637
- digest: {
638
- value: string;
639
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
640
- bytes: number;
641
- };
642
- redaction: "hash_only" | "redacted" | "plaintext_allowlisted";
643
- } | undefined;
644
- duration_ms?: number | undefined;
645
- refs?: {
646
- payment_reference?: string | undefined;
647
- related_receipt_rid?: string | undefined;
648
- } | undefined;
649
- extensions?: Record<string, unknown> | undefined;
650
- }, {
651
- started_at: string;
652
- interaction_id: string;
653
- kind: string;
654
- executor: {
655
- platform: string;
656
- version?: string | undefined;
657
- plugin_id?: string | undefined;
658
- plugin_digest?: {
659
- value: string;
660
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
661
- bytes: number;
662
- } | undefined;
663
- };
664
- policy?: {
665
- decision: "allow" | "deny" | "constrained";
666
- sandbox_enabled?: boolean | undefined;
667
- elevated?: boolean | undefined;
668
- effective_policy_digest?: {
669
- value: string;
670
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
671
- bytes: number;
672
- } | undefined;
673
- } | undefined;
674
- resource?: {
675
- method?: string | undefined;
676
- uri?: string | undefined;
677
- } | undefined;
678
- result?: {
679
- status: "error" | "ok" | "timeout" | "canceled";
680
- error_code?: string | undefined;
681
- retryable?: boolean | undefined;
682
- } | undefined;
683
- completed_at?: string | undefined;
684
- tool?: {
685
- name: string;
686
- version?: string | undefined;
687
- provider?: string | undefined;
688
- } | undefined;
689
- input?: {
690
- digest: {
691
- value: string;
692
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
693
- bytes: number;
694
- };
695
- redaction: "hash_only" | "redacted" | "plaintext_allowlisted";
696
- } | undefined;
697
- output?: {
698
- digest: {
699
- value: string;
700
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
701
- bytes: number;
702
- };
703
- redaction: "hash_only" | "redacted" | "plaintext_allowlisted";
704
- } | undefined;
705
- duration_ms?: number | undefined;
706
- refs?: {
707
- payment_reference?: string | undefined;
708
- related_receipt_rid?: string | undefined;
709
- } | undefined;
710
- extensions?: Record<string, unknown> | undefined;
711
- }>, {
712
- started_at: string;
713
- interaction_id: string;
714
- kind: string;
715
- executor: {
716
- platform: string;
717
- version?: string | undefined;
718
- plugin_id?: string | undefined;
719
- plugin_digest?: {
720
- value: string;
721
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
722
- bytes: number;
723
- } | undefined;
724
- };
725
- policy?: {
726
- decision: "allow" | "deny" | "constrained";
727
- sandbox_enabled?: boolean | undefined;
728
- elevated?: boolean | undefined;
729
- effective_policy_digest?: {
730
- value: string;
731
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
732
- bytes: number;
733
- } | undefined;
734
- } | undefined;
735
- resource?: {
736
- method?: string | undefined;
737
- uri?: string | undefined;
738
- } | undefined;
739
- result?: {
740
- status: "error" | "ok" | "timeout" | "canceled";
741
- error_code?: string | undefined;
742
- retryable?: boolean | undefined;
743
- } | undefined;
744
- completed_at?: string | undefined;
745
- tool?: {
746
- name: string;
747
- version?: string | undefined;
748
- provider?: string | undefined;
749
- } | undefined;
750
- input?: {
751
- digest: {
752
- value: string;
753
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
754
- bytes: number;
755
- };
756
- redaction: "hash_only" | "redacted" | "plaintext_allowlisted";
757
- } | undefined;
758
- output?: {
759
- digest: {
760
- value: string;
761
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
762
- bytes: number;
763
- };
764
- redaction: "hash_only" | "redacted" | "plaintext_allowlisted";
765
- } | undefined;
766
- duration_ms?: number | undefined;
767
- refs?: {
768
- payment_reference?: string | undefined;
769
- related_receipt_rid?: string | undefined;
770
- } | undefined;
771
- extensions?: Record<string, unknown> | undefined;
772
- }, {
773
- started_at: string;
774
- interaction_id: string;
775
- kind: string;
776
- executor: {
777
- platform: string;
778
- version?: string | undefined;
779
- plugin_id?: string | undefined;
780
- plugin_digest?: {
781
- value: string;
782
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
783
- bytes: number;
784
- } | undefined;
785
- };
786
- policy?: {
787
- decision: "allow" | "deny" | "constrained";
788
- sandbox_enabled?: boolean | undefined;
789
- elevated?: boolean | undefined;
790
- effective_policy_digest?: {
791
- value: string;
792
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
793
- bytes: number;
794
- } | undefined;
795
- } | undefined;
796
- resource?: {
797
- method?: string | undefined;
798
- uri?: string | undefined;
799
- } | undefined;
800
- result?: {
801
- status: "error" | "ok" | "timeout" | "canceled";
802
- error_code?: string | undefined;
803
- retryable?: boolean | undefined;
804
- } | undefined;
805
- completed_at?: string | undefined;
806
- tool?: {
807
- name: string;
808
- version?: string | undefined;
809
- provider?: string | undefined;
810
- } | undefined;
811
- input?: {
812
- digest: {
813
- value: string;
814
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
815
- bytes: number;
816
- };
817
- redaction: "hash_only" | "redacted" | "plaintext_allowlisted";
818
- } | undefined;
819
- output?: {
820
- digest: {
821
- value: string;
822
- alg: "sha-256" | "sha-256:trunc-64k" | "sha-256:trunc-1m";
823
- bytes: number;
824
- };
825
- redaction: "hash_only" | "redacted" | "plaintext_allowlisted";
826
- } | undefined;
827
- duration_ms?: number | undefined;
828
- refs?: {
829
- payment_reference?: string | undefined;
830
- related_receipt_rid?: string | undefined;
831
- } | undefined;
832
- extensions?: Record<string, unknown> | undefined;
833
- }>;
341
+ }, z.core.$strict>;
834
342
  export type DigestAlg = z.infer<typeof DigestAlgSchema>;
835
343
  export type Digest = z.infer<typeof DigestSchema>;
836
344
  export type PayloadRef = z.infer<typeof PayloadRefSchema>;