runtape 0.1.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,863 @@
1
+ import { z } from 'zod';
2
+
3
+ declare const SessionStartEvent: z.ZodObject<{
4
+ session_id: z.ZodString;
5
+ transcript_path: z.ZodString;
6
+ cwd: z.ZodString;
7
+ hook_event_name: z.ZodString;
8
+ permission_mode: z.ZodOptional<z.ZodString>;
9
+ } & {
10
+ wall_ts: z.ZodString;
11
+ sequence: z.ZodNumber;
12
+ } & {
13
+ type: z.ZodLiteral<"session_start">;
14
+ source: z.ZodString;
15
+ }, "strip", z.ZodTypeAny, {
16
+ type: "session_start";
17
+ session_id: string;
18
+ transcript_path: string;
19
+ cwd: string;
20
+ hook_event_name: string;
21
+ wall_ts: string;
22
+ sequence: number;
23
+ source: string;
24
+ permission_mode?: string | undefined;
25
+ }, {
26
+ type: "session_start";
27
+ session_id: string;
28
+ transcript_path: string;
29
+ cwd: string;
30
+ hook_event_name: string;
31
+ wall_ts: string;
32
+ sequence: number;
33
+ source: string;
34
+ permission_mode?: string | undefined;
35
+ }>;
36
+ declare const UserPromptEvent: z.ZodObject<{
37
+ session_id: z.ZodString;
38
+ transcript_path: z.ZodString;
39
+ cwd: z.ZodString;
40
+ hook_event_name: z.ZodString;
41
+ permission_mode: z.ZodOptional<z.ZodString>;
42
+ } & {
43
+ wall_ts: z.ZodString;
44
+ sequence: z.ZodNumber;
45
+ } & {
46
+ type: z.ZodLiteral<"user_prompt">;
47
+ prompt: z.ZodString;
48
+ }, "strip", z.ZodTypeAny, {
49
+ type: "user_prompt";
50
+ session_id: string;
51
+ transcript_path: string;
52
+ cwd: string;
53
+ hook_event_name: string;
54
+ wall_ts: string;
55
+ sequence: number;
56
+ prompt: string;
57
+ permission_mode?: string | undefined;
58
+ }, {
59
+ type: "user_prompt";
60
+ session_id: string;
61
+ transcript_path: string;
62
+ cwd: string;
63
+ hook_event_name: string;
64
+ wall_ts: string;
65
+ sequence: number;
66
+ prompt: string;
67
+ permission_mode?: string | undefined;
68
+ }>;
69
+ declare const ToolAttemptEvent: z.ZodObject<{
70
+ session_id: z.ZodString;
71
+ transcript_path: z.ZodString;
72
+ cwd: z.ZodString;
73
+ hook_event_name: z.ZodString;
74
+ permission_mode: z.ZodOptional<z.ZodString>;
75
+ } & {
76
+ wall_ts: z.ZodString;
77
+ sequence: z.ZodNumber;
78
+ } & {
79
+ type: z.ZodLiteral<"tool_attempt">;
80
+ tool_name: z.ZodString;
81
+ tool_input: z.ZodUnknown;
82
+ tool_use_id: z.ZodString;
83
+ }, "strip", z.ZodTypeAny, {
84
+ type: "tool_attempt";
85
+ session_id: string;
86
+ transcript_path: string;
87
+ cwd: string;
88
+ hook_event_name: string;
89
+ wall_ts: string;
90
+ sequence: number;
91
+ tool_name: string;
92
+ tool_use_id: string;
93
+ permission_mode?: string | undefined;
94
+ tool_input?: unknown;
95
+ }, {
96
+ type: "tool_attempt";
97
+ session_id: string;
98
+ transcript_path: string;
99
+ cwd: string;
100
+ hook_event_name: string;
101
+ wall_ts: string;
102
+ sequence: number;
103
+ tool_name: string;
104
+ tool_use_id: string;
105
+ permission_mode?: string | undefined;
106
+ tool_input?: unknown;
107
+ }>;
108
+ declare const ToolCallEvent: z.ZodObject<{
109
+ session_id: z.ZodString;
110
+ transcript_path: z.ZodString;
111
+ cwd: z.ZodString;
112
+ hook_event_name: z.ZodString;
113
+ permission_mode: z.ZodOptional<z.ZodString>;
114
+ } & {
115
+ wall_ts: z.ZodString;
116
+ sequence: z.ZodNumber;
117
+ } & {
118
+ type: z.ZodLiteral<"tool_call">;
119
+ tool_name: z.ZodString;
120
+ tool_input: z.ZodUnknown;
121
+ tool_response: z.ZodUnknown;
122
+ tool_use_id: z.ZodString;
123
+ duration_ms: z.ZodNumber;
124
+ }, "strip", z.ZodTypeAny, {
125
+ type: "tool_call";
126
+ session_id: string;
127
+ transcript_path: string;
128
+ cwd: string;
129
+ hook_event_name: string;
130
+ wall_ts: string;
131
+ sequence: number;
132
+ tool_name: string;
133
+ tool_use_id: string;
134
+ duration_ms: number;
135
+ permission_mode?: string | undefined;
136
+ tool_input?: unknown;
137
+ tool_response?: unknown;
138
+ }, {
139
+ type: "tool_call";
140
+ session_id: string;
141
+ transcript_path: string;
142
+ cwd: string;
143
+ hook_event_name: string;
144
+ wall_ts: string;
145
+ sequence: number;
146
+ tool_name: string;
147
+ tool_use_id: string;
148
+ duration_ms: number;
149
+ permission_mode?: string | undefined;
150
+ tool_input?: unknown;
151
+ tool_response?: unknown;
152
+ }>;
153
+ declare const SubagentEndEvent: z.ZodObject<{
154
+ session_id: z.ZodString;
155
+ transcript_path: z.ZodString;
156
+ cwd: z.ZodString;
157
+ hook_event_name: z.ZodString;
158
+ permission_mode: z.ZodOptional<z.ZodString>;
159
+ } & {
160
+ wall_ts: z.ZodString;
161
+ sequence: z.ZodNumber;
162
+ } & {
163
+ type: z.ZodLiteral<"subagent_end">;
164
+ agent_id: z.ZodString;
165
+ agent_type: z.ZodString;
166
+ agent_transcript_path: z.ZodString;
167
+ last_assistant_message: z.ZodString;
168
+ stop_hook_active: z.ZodOptional<z.ZodBoolean>;
169
+ }, "strip", z.ZodTypeAny, {
170
+ type: "subagent_end";
171
+ session_id: string;
172
+ transcript_path: string;
173
+ cwd: string;
174
+ hook_event_name: string;
175
+ wall_ts: string;
176
+ sequence: number;
177
+ agent_id: string;
178
+ agent_type: string;
179
+ agent_transcript_path: string;
180
+ last_assistant_message: string;
181
+ permission_mode?: string | undefined;
182
+ stop_hook_active?: boolean | undefined;
183
+ }, {
184
+ type: "subagent_end";
185
+ session_id: string;
186
+ transcript_path: string;
187
+ cwd: string;
188
+ hook_event_name: string;
189
+ wall_ts: string;
190
+ sequence: number;
191
+ agent_id: string;
192
+ agent_type: string;
193
+ agent_transcript_path: string;
194
+ last_assistant_message: string;
195
+ permission_mode?: string | undefined;
196
+ stop_hook_active?: boolean | undefined;
197
+ }>;
198
+ declare const SessionEndEvent: z.ZodObject<{
199
+ session_id: z.ZodString;
200
+ transcript_path: z.ZodString;
201
+ cwd: z.ZodString;
202
+ hook_event_name: z.ZodString;
203
+ permission_mode: z.ZodOptional<z.ZodString>;
204
+ } & {
205
+ wall_ts: z.ZodString;
206
+ sequence: z.ZodNumber;
207
+ } & {
208
+ type: z.ZodLiteral<"session_end">;
209
+ last_assistant_message: z.ZodOptional<z.ZodString>;
210
+ stop_hook_active: z.ZodOptional<z.ZodBoolean>;
211
+ }, "strip", z.ZodTypeAny, {
212
+ type: "session_end";
213
+ session_id: string;
214
+ transcript_path: string;
215
+ cwd: string;
216
+ hook_event_name: string;
217
+ wall_ts: string;
218
+ sequence: number;
219
+ permission_mode?: string | undefined;
220
+ last_assistant_message?: string | undefined;
221
+ stop_hook_active?: boolean | undefined;
222
+ }, {
223
+ type: "session_end";
224
+ session_id: string;
225
+ transcript_path: string;
226
+ cwd: string;
227
+ hook_event_name: string;
228
+ wall_ts: string;
229
+ sequence: number;
230
+ permission_mode?: string | undefined;
231
+ last_assistant_message?: string | undefined;
232
+ stop_hook_active?: boolean | undefined;
233
+ }>;
234
+ declare const RuntapeEvent: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
235
+ session_id: z.ZodString;
236
+ transcript_path: z.ZodString;
237
+ cwd: z.ZodString;
238
+ hook_event_name: z.ZodString;
239
+ permission_mode: z.ZodOptional<z.ZodString>;
240
+ } & {
241
+ wall_ts: z.ZodString;
242
+ sequence: z.ZodNumber;
243
+ } & {
244
+ type: z.ZodLiteral<"session_start">;
245
+ source: z.ZodString;
246
+ }, "strip", z.ZodTypeAny, {
247
+ type: "session_start";
248
+ session_id: string;
249
+ transcript_path: string;
250
+ cwd: string;
251
+ hook_event_name: string;
252
+ wall_ts: string;
253
+ sequence: number;
254
+ source: string;
255
+ permission_mode?: string | undefined;
256
+ }, {
257
+ type: "session_start";
258
+ session_id: string;
259
+ transcript_path: string;
260
+ cwd: string;
261
+ hook_event_name: string;
262
+ wall_ts: string;
263
+ sequence: number;
264
+ source: string;
265
+ permission_mode?: string | undefined;
266
+ }>, z.ZodObject<{
267
+ session_id: z.ZodString;
268
+ transcript_path: z.ZodString;
269
+ cwd: z.ZodString;
270
+ hook_event_name: z.ZodString;
271
+ permission_mode: z.ZodOptional<z.ZodString>;
272
+ } & {
273
+ wall_ts: z.ZodString;
274
+ sequence: z.ZodNumber;
275
+ } & {
276
+ type: z.ZodLiteral<"user_prompt">;
277
+ prompt: z.ZodString;
278
+ }, "strip", z.ZodTypeAny, {
279
+ type: "user_prompt";
280
+ session_id: string;
281
+ transcript_path: string;
282
+ cwd: string;
283
+ hook_event_name: string;
284
+ wall_ts: string;
285
+ sequence: number;
286
+ prompt: string;
287
+ permission_mode?: string | undefined;
288
+ }, {
289
+ type: "user_prompt";
290
+ session_id: string;
291
+ transcript_path: string;
292
+ cwd: string;
293
+ hook_event_name: string;
294
+ wall_ts: string;
295
+ sequence: number;
296
+ prompt: string;
297
+ permission_mode?: string | undefined;
298
+ }>, z.ZodObject<{
299
+ session_id: z.ZodString;
300
+ transcript_path: z.ZodString;
301
+ cwd: z.ZodString;
302
+ hook_event_name: z.ZodString;
303
+ permission_mode: z.ZodOptional<z.ZodString>;
304
+ } & {
305
+ wall_ts: z.ZodString;
306
+ sequence: z.ZodNumber;
307
+ } & {
308
+ type: z.ZodLiteral<"tool_attempt">;
309
+ tool_name: z.ZodString;
310
+ tool_input: z.ZodUnknown;
311
+ tool_use_id: z.ZodString;
312
+ }, "strip", z.ZodTypeAny, {
313
+ type: "tool_attempt";
314
+ session_id: string;
315
+ transcript_path: string;
316
+ cwd: string;
317
+ hook_event_name: string;
318
+ wall_ts: string;
319
+ sequence: number;
320
+ tool_name: string;
321
+ tool_use_id: string;
322
+ permission_mode?: string | undefined;
323
+ tool_input?: unknown;
324
+ }, {
325
+ type: "tool_attempt";
326
+ session_id: string;
327
+ transcript_path: string;
328
+ cwd: string;
329
+ hook_event_name: string;
330
+ wall_ts: string;
331
+ sequence: number;
332
+ tool_name: string;
333
+ tool_use_id: string;
334
+ permission_mode?: string | undefined;
335
+ tool_input?: unknown;
336
+ }>, z.ZodObject<{
337
+ session_id: z.ZodString;
338
+ transcript_path: z.ZodString;
339
+ cwd: z.ZodString;
340
+ hook_event_name: z.ZodString;
341
+ permission_mode: z.ZodOptional<z.ZodString>;
342
+ } & {
343
+ wall_ts: z.ZodString;
344
+ sequence: z.ZodNumber;
345
+ } & {
346
+ type: z.ZodLiteral<"tool_call">;
347
+ tool_name: z.ZodString;
348
+ tool_input: z.ZodUnknown;
349
+ tool_response: z.ZodUnknown;
350
+ tool_use_id: z.ZodString;
351
+ duration_ms: z.ZodNumber;
352
+ }, "strip", z.ZodTypeAny, {
353
+ type: "tool_call";
354
+ session_id: string;
355
+ transcript_path: string;
356
+ cwd: string;
357
+ hook_event_name: string;
358
+ wall_ts: string;
359
+ sequence: number;
360
+ tool_name: string;
361
+ tool_use_id: string;
362
+ duration_ms: number;
363
+ permission_mode?: string | undefined;
364
+ tool_input?: unknown;
365
+ tool_response?: unknown;
366
+ }, {
367
+ type: "tool_call";
368
+ session_id: string;
369
+ transcript_path: string;
370
+ cwd: string;
371
+ hook_event_name: string;
372
+ wall_ts: string;
373
+ sequence: number;
374
+ tool_name: string;
375
+ tool_use_id: string;
376
+ duration_ms: number;
377
+ permission_mode?: string | undefined;
378
+ tool_input?: unknown;
379
+ tool_response?: unknown;
380
+ }>, z.ZodObject<{
381
+ session_id: z.ZodString;
382
+ transcript_path: z.ZodString;
383
+ cwd: z.ZodString;
384
+ hook_event_name: z.ZodString;
385
+ permission_mode: z.ZodOptional<z.ZodString>;
386
+ } & {
387
+ wall_ts: z.ZodString;
388
+ sequence: z.ZodNumber;
389
+ } & {
390
+ type: z.ZodLiteral<"subagent_end">;
391
+ agent_id: z.ZodString;
392
+ agent_type: z.ZodString;
393
+ agent_transcript_path: z.ZodString;
394
+ last_assistant_message: z.ZodString;
395
+ stop_hook_active: z.ZodOptional<z.ZodBoolean>;
396
+ }, "strip", z.ZodTypeAny, {
397
+ type: "subagent_end";
398
+ session_id: string;
399
+ transcript_path: string;
400
+ cwd: string;
401
+ hook_event_name: string;
402
+ wall_ts: string;
403
+ sequence: number;
404
+ agent_id: string;
405
+ agent_type: string;
406
+ agent_transcript_path: string;
407
+ last_assistant_message: string;
408
+ permission_mode?: string | undefined;
409
+ stop_hook_active?: boolean | undefined;
410
+ }, {
411
+ type: "subagent_end";
412
+ session_id: string;
413
+ transcript_path: string;
414
+ cwd: string;
415
+ hook_event_name: string;
416
+ wall_ts: string;
417
+ sequence: number;
418
+ agent_id: string;
419
+ agent_type: string;
420
+ agent_transcript_path: string;
421
+ last_assistant_message: string;
422
+ permission_mode?: string | undefined;
423
+ stop_hook_active?: boolean | undefined;
424
+ }>, z.ZodObject<{
425
+ session_id: z.ZodString;
426
+ transcript_path: z.ZodString;
427
+ cwd: z.ZodString;
428
+ hook_event_name: z.ZodString;
429
+ permission_mode: z.ZodOptional<z.ZodString>;
430
+ } & {
431
+ wall_ts: z.ZodString;
432
+ sequence: z.ZodNumber;
433
+ } & {
434
+ type: z.ZodLiteral<"session_end">;
435
+ last_assistant_message: z.ZodOptional<z.ZodString>;
436
+ stop_hook_active: z.ZodOptional<z.ZodBoolean>;
437
+ }, "strip", z.ZodTypeAny, {
438
+ type: "session_end";
439
+ session_id: string;
440
+ transcript_path: string;
441
+ cwd: string;
442
+ hook_event_name: string;
443
+ wall_ts: string;
444
+ sequence: number;
445
+ permission_mode?: string | undefined;
446
+ last_assistant_message?: string | undefined;
447
+ stop_hook_active?: boolean | undefined;
448
+ }, {
449
+ type: "session_end";
450
+ session_id: string;
451
+ transcript_path: string;
452
+ cwd: string;
453
+ hook_event_name: string;
454
+ wall_ts: string;
455
+ sequence: number;
456
+ permission_mode?: string | undefined;
457
+ last_assistant_message?: string | undefined;
458
+ stop_hook_active?: boolean | undefined;
459
+ }>]>;
460
+ type RuntapeEvent = z.infer<typeof RuntapeEvent>;
461
+ declare const IngestionRequest: z.ZodObject<{
462
+ events: z.ZodArray<z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
463
+ session_id: z.ZodString;
464
+ transcript_path: z.ZodString;
465
+ cwd: z.ZodString;
466
+ hook_event_name: z.ZodString;
467
+ permission_mode: z.ZodOptional<z.ZodString>;
468
+ } & {
469
+ wall_ts: z.ZodString;
470
+ sequence: z.ZodNumber;
471
+ } & {
472
+ type: z.ZodLiteral<"session_start">;
473
+ source: z.ZodString;
474
+ }, "strip", z.ZodTypeAny, {
475
+ type: "session_start";
476
+ session_id: string;
477
+ transcript_path: string;
478
+ cwd: string;
479
+ hook_event_name: string;
480
+ wall_ts: string;
481
+ sequence: number;
482
+ source: string;
483
+ permission_mode?: string | undefined;
484
+ }, {
485
+ type: "session_start";
486
+ session_id: string;
487
+ transcript_path: string;
488
+ cwd: string;
489
+ hook_event_name: string;
490
+ wall_ts: string;
491
+ sequence: number;
492
+ source: string;
493
+ permission_mode?: string | undefined;
494
+ }>, z.ZodObject<{
495
+ session_id: z.ZodString;
496
+ transcript_path: z.ZodString;
497
+ cwd: z.ZodString;
498
+ hook_event_name: z.ZodString;
499
+ permission_mode: z.ZodOptional<z.ZodString>;
500
+ } & {
501
+ wall_ts: z.ZodString;
502
+ sequence: z.ZodNumber;
503
+ } & {
504
+ type: z.ZodLiteral<"user_prompt">;
505
+ prompt: z.ZodString;
506
+ }, "strip", z.ZodTypeAny, {
507
+ type: "user_prompt";
508
+ session_id: string;
509
+ transcript_path: string;
510
+ cwd: string;
511
+ hook_event_name: string;
512
+ wall_ts: string;
513
+ sequence: number;
514
+ prompt: string;
515
+ permission_mode?: string | undefined;
516
+ }, {
517
+ type: "user_prompt";
518
+ session_id: string;
519
+ transcript_path: string;
520
+ cwd: string;
521
+ hook_event_name: string;
522
+ wall_ts: string;
523
+ sequence: number;
524
+ prompt: string;
525
+ permission_mode?: string | undefined;
526
+ }>, z.ZodObject<{
527
+ session_id: z.ZodString;
528
+ transcript_path: z.ZodString;
529
+ cwd: z.ZodString;
530
+ hook_event_name: z.ZodString;
531
+ permission_mode: z.ZodOptional<z.ZodString>;
532
+ } & {
533
+ wall_ts: z.ZodString;
534
+ sequence: z.ZodNumber;
535
+ } & {
536
+ type: z.ZodLiteral<"tool_attempt">;
537
+ tool_name: z.ZodString;
538
+ tool_input: z.ZodUnknown;
539
+ tool_use_id: z.ZodString;
540
+ }, "strip", z.ZodTypeAny, {
541
+ type: "tool_attempt";
542
+ session_id: string;
543
+ transcript_path: string;
544
+ cwd: string;
545
+ hook_event_name: string;
546
+ wall_ts: string;
547
+ sequence: number;
548
+ tool_name: string;
549
+ tool_use_id: string;
550
+ permission_mode?: string | undefined;
551
+ tool_input?: unknown;
552
+ }, {
553
+ type: "tool_attempt";
554
+ session_id: string;
555
+ transcript_path: string;
556
+ cwd: string;
557
+ hook_event_name: string;
558
+ wall_ts: string;
559
+ sequence: number;
560
+ tool_name: string;
561
+ tool_use_id: string;
562
+ permission_mode?: string | undefined;
563
+ tool_input?: unknown;
564
+ }>, z.ZodObject<{
565
+ session_id: z.ZodString;
566
+ transcript_path: z.ZodString;
567
+ cwd: z.ZodString;
568
+ hook_event_name: z.ZodString;
569
+ permission_mode: z.ZodOptional<z.ZodString>;
570
+ } & {
571
+ wall_ts: z.ZodString;
572
+ sequence: z.ZodNumber;
573
+ } & {
574
+ type: z.ZodLiteral<"tool_call">;
575
+ tool_name: z.ZodString;
576
+ tool_input: z.ZodUnknown;
577
+ tool_response: z.ZodUnknown;
578
+ tool_use_id: z.ZodString;
579
+ duration_ms: z.ZodNumber;
580
+ }, "strip", z.ZodTypeAny, {
581
+ type: "tool_call";
582
+ session_id: string;
583
+ transcript_path: string;
584
+ cwd: string;
585
+ hook_event_name: string;
586
+ wall_ts: string;
587
+ sequence: number;
588
+ tool_name: string;
589
+ tool_use_id: string;
590
+ duration_ms: number;
591
+ permission_mode?: string | undefined;
592
+ tool_input?: unknown;
593
+ tool_response?: unknown;
594
+ }, {
595
+ type: "tool_call";
596
+ session_id: string;
597
+ transcript_path: string;
598
+ cwd: string;
599
+ hook_event_name: string;
600
+ wall_ts: string;
601
+ sequence: number;
602
+ tool_name: string;
603
+ tool_use_id: string;
604
+ duration_ms: number;
605
+ permission_mode?: string | undefined;
606
+ tool_input?: unknown;
607
+ tool_response?: unknown;
608
+ }>, z.ZodObject<{
609
+ session_id: z.ZodString;
610
+ transcript_path: z.ZodString;
611
+ cwd: z.ZodString;
612
+ hook_event_name: z.ZodString;
613
+ permission_mode: z.ZodOptional<z.ZodString>;
614
+ } & {
615
+ wall_ts: z.ZodString;
616
+ sequence: z.ZodNumber;
617
+ } & {
618
+ type: z.ZodLiteral<"subagent_end">;
619
+ agent_id: z.ZodString;
620
+ agent_type: z.ZodString;
621
+ agent_transcript_path: z.ZodString;
622
+ last_assistant_message: z.ZodString;
623
+ stop_hook_active: z.ZodOptional<z.ZodBoolean>;
624
+ }, "strip", z.ZodTypeAny, {
625
+ type: "subagent_end";
626
+ session_id: string;
627
+ transcript_path: string;
628
+ cwd: string;
629
+ hook_event_name: string;
630
+ wall_ts: string;
631
+ sequence: number;
632
+ agent_id: string;
633
+ agent_type: string;
634
+ agent_transcript_path: string;
635
+ last_assistant_message: string;
636
+ permission_mode?: string | undefined;
637
+ stop_hook_active?: boolean | undefined;
638
+ }, {
639
+ type: "subagent_end";
640
+ session_id: string;
641
+ transcript_path: string;
642
+ cwd: string;
643
+ hook_event_name: string;
644
+ wall_ts: string;
645
+ sequence: number;
646
+ agent_id: string;
647
+ agent_type: string;
648
+ agent_transcript_path: string;
649
+ last_assistant_message: string;
650
+ permission_mode?: string | undefined;
651
+ stop_hook_active?: boolean | undefined;
652
+ }>, z.ZodObject<{
653
+ session_id: z.ZodString;
654
+ transcript_path: z.ZodString;
655
+ cwd: z.ZodString;
656
+ hook_event_name: z.ZodString;
657
+ permission_mode: z.ZodOptional<z.ZodString>;
658
+ } & {
659
+ wall_ts: z.ZodString;
660
+ sequence: z.ZodNumber;
661
+ } & {
662
+ type: z.ZodLiteral<"session_end">;
663
+ last_assistant_message: z.ZodOptional<z.ZodString>;
664
+ stop_hook_active: z.ZodOptional<z.ZodBoolean>;
665
+ }, "strip", z.ZodTypeAny, {
666
+ type: "session_end";
667
+ session_id: string;
668
+ transcript_path: string;
669
+ cwd: string;
670
+ hook_event_name: string;
671
+ wall_ts: string;
672
+ sequence: number;
673
+ permission_mode?: string | undefined;
674
+ last_assistant_message?: string | undefined;
675
+ stop_hook_active?: boolean | undefined;
676
+ }, {
677
+ type: "session_end";
678
+ session_id: string;
679
+ transcript_path: string;
680
+ cwd: string;
681
+ hook_event_name: string;
682
+ wall_ts: string;
683
+ sequence: number;
684
+ permission_mode?: string | undefined;
685
+ last_assistant_message?: string | undefined;
686
+ stop_hook_active?: boolean | undefined;
687
+ }>]>, "many">;
688
+ }, "strip", z.ZodTypeAny, {
689
+ events: ({
690
+ type: "session_start";
691
+ session_id: string;
692
+ transcript_path: string;
693
+ cwd: string;
694
+ hook_event_name: string;
695
+ wall_ts: string;
696
+ sequence: number;
697
+ source: string;
698
+ permission_mode?: string | undefined;
699
+ } | {
700
+ type: "user_prompt";
701
+ session_id: string;
702
+ transcript_path: string;
703
+ cwd: string;
704
+ hook_event_name: string;
705
+ wall_ts: string;
706
+ sequence: number;
707
+ prompt: string;
708
+ permission_mode?: string | undefined;
709
+ } | {
710
+ type: "tool_attempt";
711
+ session_id: string;
712
+ transcript_path: string;
713
+ cwd: string;
714
+ hook_event_name: string;
715
+ wall_ts: string;
716
+ sequence: number;
717
+ tool_name: string;
718
+ tool_use_id: string;
719
+ permission_mode?: string | undefined;
720
+ tool_input?: unknown;
721
+ } | {
722
+ type: "tool_call";
723
+ session_id: string;
724
+ transcript_path: string;
725
+ cwd: string;
726
+ hook_event_name: string;
727
+ wall_ts: string;
728
+ sequence: number;
729
+ tool_name: string;
730
+ tool_use_id: string;
731
+ duration_ms: number;
732
+ permission_mode?: string | undefined;
733
+ tool_input?: unknown;
734
+ tool_response?: unknown;
735
+ } | {
736
+ type: "subagent_end";
737
+ session_id: string;
738
+ transcript_path: string;
739
+ cwd: string;
740
+ hook_event_name: string;
741
+ wall_ts: string;
742
+ sequence: number;
743
+ agent_id: string;
744
+ agent_type: string;
745
+ agent_transcript_path: string;
746
+ last_assistant_message: string;
747
+ permission_mode?: string | undefined;
748
+ stop_hook_active?: boolean | undefined;
749
+ } | {
750
+ type: "session_end";
751
+ session_id: string;
752
+ transcript_path: string;
753
+ cwd: string;
754
+ hook_event_name: string;
755
+ wall_ts: string;
756
+ sequence: number;
757
+ permission_mode?: string | undefined;
758
+ last_assistant_message?: string | undefined;
759
+ stop_hook_active?: boolean | undefined;
760
+ })[];
761
+ }, {
762
+ events: ({
763
+ type: "session_start";
764
+ session_id: string;
765
+ transcript_path: string;
766
+ cwd: string;
767
+ hook_event_name: string;
768
+ wall_ts: string;
769
+ sequence: number;
770
+ source: string;
771
+ permission_mode?: string | undefined;
772
+ } | {
773
+ type: "user_prompt";
774
+ session_id: string;
775
+ transcript_path: string;
776
+ cwd: string;
777
+ hook_event_name: string;
778
+ wall_ts: string;
779
+ sequence: number;
780
+ prompt: string;
781
+ permission_mode?: string | undefined;
782
+ } | {
783
+ type: "tool_attempt";
784
+ session_id: string;
785
+ transcript_path: string;
786
+ cwd: string;
787
+ hook_event_name: string;
788
+ wall_ts: string;
789
+ sequence: number;
790
+ tool_name: string;
791
+ tool_use_id: string;
792
+ permission_mode?: string | undefined;
793
+ tool_input?: unknown;
794
+ } | {
795
+ type: "tool_call";
796
+ session_id: string;
797
+ transcript_path: string;
798
+ cwd: string;
799
+ hook_event_name: string;
800
+ wall_ts: string;
801
+ sequence: number;
802
+ tool_name: string;
803
+ tool_use_id: string;
804
+ duration_ms: number;
805
+ permission_mode?: string | undefined;
806
+ tool_input?: unknown;
807
+ tool_response?: unknown;
808
+ } | {
809
+ type: "subagent_end";
810
+ session_id: string;
811
+ transcript_path: string;
812
+ cwd: string;
813
+ hook_event_name: string;
814
+ wall_ts: string;
815
+ sequence: number;
816
+ agent_id: string;
817
+ agent_type: string;
818
+ agent_transcript_path: string;
819
+ last_assistant_message: string;
820
+ permission_mode?: string | undefined;
821
+ stop_hook_active?: boolean | undefined;
822
+ } | {
823
+ type: "session_end";
824
+ session_id: string;
825
+ transcript_path: string;
826
+ cwd: string;
827
+ hook_event_name: string;
828
+ wall_ts: string;
829
+ sequence: number;
830
+ permission_mode?: string | undefined;
831
+ last_assistant_message?: string | undefined;
832
+ stop_hook_active?: boolean | undefined;
833
+ })[];
834
+ }>;
835
+ type IngestionRequest = z.infer<typeof IngestionRequest>;
836
+ declare const IngestionResponse: z.ZodObject<{
837
+ accepted: z.ZodNumber;
838
+ errors: z.ZodDefault<z.ZodArray<z.ZodObject<{
839
+ index: z.ZodNumber;
840
+ reason: z.ZodString;
841
+ }, "strip", z.ZodTypeAny, {
842
+ index: number;
843
+ reason: string;
844
+ }, {
845
+ index: number;
846
+ reason: string;
847
+ }>, "many">>;
848
+ }, "strip", z.ZodTypeAny, {
849
+ accepted: number;
850
+ errors: {
851
+ index: number;
852
+ reason: string;
853
+ }[];
854
+ }, {
855
+ accepted: number;
856
+ errors?: {
857
+ index: number;
858
+ reason: string;
859
+ }[] | undefined;
860
+ }>;
861
+ type IngestionResponse = z.infer<typeof IngestionResponse>;
862
+
863
+ export { IngestionRequest, IngestionResponse, RuntapeEvent, SessionEndEvent, SessionStartEvent, SubagentEndEvent, ToolAttemptEvent, ToolCallEvent, UserPromptEvent };