codebuff 1.0.220 → 1.0.222

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.
@@ -111,11 +111,11 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
111
111
  path: z.ZodString;
112
112
  content: z.ZodString;
113
113
  }, "strip", z.ZodTypeAny, {
114
- content: string;
115
114
  path: string;
116
- }, {
117
115
  content: string;
116
+ }, {
118
117
  path: string;
118
+ content: string;
119
119
  }>, "many">, "many">>;
120
120
  }, "strip", z.ZodTypeAny, {
121
121
  currentWorkingDirectory: string;
@@ -140,8 +140,8 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
140
140
  };
141
141
  userKnowledgeFiles?: Record<string, string> | undefined;
142
142
  fileVersions?: {
143
- content: string;
144
143
  path: string;
144
+ content: string;
145
145
  }[][] | undefined;
146
146
  }, {
147
147
  currentWorkingDirectory: string;
@@ -166,8 +166,8 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
166
166
  };
167
167
  userKnowledgeFiles?: Record<string, string> | undefined;
168
168
  fileVersions?: {
169
- content: string;
170
169
  path: string;
170
+ content: string;
171
171
  }[][] | undefined;
172
172
  }>;
173
173
  messageHistory: z.ZodArray<z.ZodObject<{
@@ -183,14 +183,14 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
183
183
  type: "ephemeral";
184
184
  }>>;
185
185
  }, "strip", z.ZodTypeAny, {
186
- text: string;
187
186
  type: "text";
187
+ text: string;
188
188
  cache_control?: {
189
189
  type: "ephemeral";
190
190
  } | undefined;
191
191
  }, {
192
- text: string;
193
192
  type: "text";
193
+ text: string;
194
194
  cache_control?: {
195
195
  type: "ephemeral";
196
196
  } | undefined;
@@ -207,16 +207,16 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
207
207
  type: "ephemeral";
208
208
  }>>;
209
209
  }, "strip", z.ZodTypeAny, {
210
- name: string;
211
210
  type: "tool_use";
211
+ name: string;
212
212
  id: string;
213
213
  input: Record<string, any>;
214
214
  cache_control?: {
215
215
  type: "ephemeral";
216
216
  } | undefined;
217
217
  }, {
218
- name: string;
219
218
  type: "tool_use";
219
+ name: string;
220
220
  id: string;
221
221
  input: Record<string, any>;
222
222
  cache_control?: {
@@ -234,15 +234,15 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
234
234
  type: "ephemeral";
235
235
  }>>;
236
236
  }, "strip", z.ZodTypeAny, {
237
- content: string;
238
237
  type: "tool_result";
238
+ content: string;
239
239
  tool_use_id: string;
240
240
  cache_control?: {
241
241
  type: "ephemeral";
242
242
  } | undefined;
243
243
  }, {
244
- content: string;
245
244
  type: "tool_result";
245
+ content: string;
246
246
  tool_use_id: string;
247
247
  cache_control?: {
248
248
  type: "ephemeral";
@@ -254,13 +254,13 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
254
254
  media_type: z.ZodLiteral<"image/jpeg">;
255
255
  data: z.ZodString;
256
256
  }, "strip", z.ZodTypeAny, {
257
- data: string;
258
257
  type: "base64";
259
258
  media_type: "image/jpeg";
260
- }, {
261
259
  data: string;
260
+ }, {
262
261
  type: "base64";
263
262
  media_type: "image/jpeg";
263
+ data: string;
264
264
  }>;
265
265
  cache_control: z.ZodOptional<z.ZodObject<{
266
266
  type: z.ZodLiteral<"ephemeral">;
@@ -272,9 +272,9 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
272
272
  }, "strip", z.ZodTypeAny, {
273
273
  type: "image";
274
274
  source: {
275
- data: string;
276
275
  type: "base64";
277
276
  media_type: "image/jpeg";
277
+ data: string;
278
278
  };
279
279
  cache_control?: {
280
280
  type: "ephemeral";
@@ -282,9 +282,9 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
282
282
  }, {
283
283
  type: "image";
284
284
  source: {
285
- data: string;
286
285
  type: "base64";
287
286
  media_type: "image/jpeg";
287
+ data: string;
288
288
  };
289
289
  cache_control?: {
290
290
  type: "ephemeral";
@@ -292,22 +292,22 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
292
292
  }>]>, "many">]>;
293
293
  }, "strip", z.ZodTypeAny, {
294
294
  content: string | ({
295
- text: string;
296
295
  type: "text";
296
+ text: string;
297
297
  cache_control?: {
298
298
  type: "ephemeral";
299
299
  } | undefined;
300
300
  } | {
301
- name: string;
302
301
  type: "tool_use";
302
+ name: string;
303
303
  id: string;
304
304
  input: Record<string, any>;
305
305
  cache_control?: {
306
306
  type: "ephemeral";
307
307
  } | undefined;
308
308
  } | {
309
- content: string;
310
309
  type: "tool_result";
310
+ content: string;
311
311
  tool_use_id: string;
312
312
  cache_control?: {
313
313
  type: "ephemeral";
@@ -315,9 +315,9 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
315
315
  } | {
316
316
  type: "image";
317
317
  source: {
318
- data: string;
319
318
  type: "base64";
320
319
  media_type: "image/jpeg";
320
+ data: string;
321
321
  };
322
322
  cache_control?: {
323
323
  type: "ephemeral";
@@ -326,22 +326,22 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
326
326
  role: "user" | "assistant";
327
327
  }, {
328
328
  content: string | ({
329
- text: string;
330
329
  type: "text";
330
+ text: string;
331
331
  cache_control?: {
332
332
  type: "ephemeral";
333
333
  } | undefined;
334
334
  } | {
335
- name: string;
336
335
  type: "tool_use";
336
+ name: string;
337
337
  id: string;
338
338
  input: Record<string, any>;
339
339
  cache_control?: {
340
340
  type: "ephemeral";
341
341
  } | undefined;
342
342
  } | {
343
- content: string;
344
343
  type: "tool_result";
344
+ content: string;
345
345
  tool_use_id: string;
346
346
  cache_control?: {
347
347
  type: "ephemeral";
@@ -349,9 +349,9 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
349
349
  } | {
350
350
  type: "image";
351
351
  source: {
352
- data: string;
353
352
  type: "base64";
354
353
  media_type: "image/jpeg";
354
+ data: string;
355
355
  };
356
356
  cache_control?: {
357
357
  type: "ephemeral";
@@ -385,28 +385,28 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
385
385
  };
386
386
  userKnowledgeFiles?: Record<string, string> | undefined;
387
387
  fileVersions?: {
388
- content: string;
389
388
  path: string;
389
+ content: string;
390
390
  }[][] | undefined;
391
391
  };
392
392
  messageHistory: {
393
393
  content: string | ({
394
- text: string;
395
394
  type: "text";
395
+ text: string;
396
396
  cache_control?: {
397
397
  type: "ephemeral";
398
398
  } | undefined;
399
399
  } | {
400
- name: string;
401
400
  type: "tool_use";
401
+ name: string;
402
402
  id: string;
403
403
  input: Record<string, any>;
404
404
  cache_control?: {
405
405
  type: "ephemeral";
406
406
  } | undefined;
407
407
  } | {
408
- content: string;
409
408
  type: "tool_result";
409
+ content: string;
410
410
  tool_use_id: string;
411
411
  cache_control?: {
412
412
  type: "ephemeral";
@@ -414,9 +414,9 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
414
414
  } | {
415
415
  type: "image";
416
416
  source: {
417
- data: string;
418
417
  type: "base64";
419
418
  media_type: "image/jpeg";
419
+ data: string;
420
420
  };
421
421
  cache_control?: {
422
422
  type: "ephemeral";
@@ -450,28 +450,28 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
450
450
  };
451
451
  userKnowledgeFiles?: Record<string, string> | undefined;
452
452
  fileVersions?: {
453
- content: string;
454
453
  path: string;
454
+ content: string;
455
455
  }[][] | undefined;
456
456
  };
457
457
  messageHistory: {
458
458
  content: string | ({
459
- text: string;
460
459
  type: "text";
460
+ text: string;
461
461
  cache_control?: {
462
462
  type: "ephemeral";
463
463
  } | undefined;
464
464
  } | {
465
- name: string;
466
465
  type: "tool_use";
466
+ name: string;
467
467
  id: string;
468
468
  input: Record<string, any>;
469
469
  cache_control?: {
470
470
  type: "ephemeral";
471
471
  } | undefined;
472
472
  } | {
473
- content: string;
474
473
  type: "tool_result";
474
+ content: string;
475
475
  tool_use_id: string;
476
476
  cache_control?: {
477
477
  type: "ephemeral";
@@ -479,9 +479,9 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
479
479
  } | {
480
480
  type: "image";
481
481
  source: {
482
- data: string;
483
482
  type: "base64";
484
483
  media_type: "image/jpeg";
484
+ data: string;
485
485
  };
486
486
  cache_control?: {
487
487
  type: "ephemeral";
@@ -535,28 +535,28 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
535
535
  };
536
536
  userKnowledgeFiles?: Record<string, string> | undefined;
537
537
  fileVersions?: {
538
- content: string;
539
538
  path: string;
539
+ content: string;
540
540
  }[][] | undefined;
541
541
  };
542
542
  messageHistory: {
543
543
  content: string | ({
544
- text: string;
545
544
  type: "text";
545
+ text: string;
546
546
  cache_control?: {
547
547
  type: "ephemeral";
548
548
  } | undefined;
549
549
  } | {
550
- name: string;
551
550
  type: "tool_use";
551
+ name: string;
552
552
  id: string;
553
553
  input: Record<string, any>;
554
554
  cache_control?: {
555
555
  type: "ephemeral";
556
556
  } | undefined;
557
557
  } | {
558
- content: string;
559
558
  type: "tool_result";
559
+ content: string;
560
560
  tool_use_id: string;
561
561
  cache_control?: {
562
562
  type: "ephemeral";
@@ -564,9 +564,9 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
564
564
  } | {
565
565
  type: "image";
566
566
  source: {
567
- data: string;
568
567
  type: "base64";
569
568
  media_type: "image/jpeg";
569
+ data: string;
570
570
  };
571
571
  cache_control?: {
572
572
  type: "ephemeral";
@@ -613,28 +613,28 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
613
613
  };
614
614
  userKnowledgeFiles?: Record<string, string> | undefined;
615
615
  fileVersions?: {
616
- content: string;
617
616
  path: string;
617
+ content: string;
618
618
  }[][] | undefined;
619
619
  };
620
620
  messageHistory: {
621
621
  content: string | ({
622
- text: string;
623
622
  type: "text";
623
+ text: string;
624
624
  cache_control?: {
625
625
  type: "ephemeral";
626
626
  } | undefined;
627
627
  } | {
628
- name: string;
629
628
  type: "tool_use";
629
+ name: string;
630
630
  id: string;
631
631
  input: Record<string, any>;
632
632
  cache_control?: {
633
633
  type: "ephemeral";
634
634
  } | undefined;
635
635
  } | {
636
- content: string;
637
636
  type: "tool_result";
637
+ content: string;
638
638
  tool_use_id: string;
639
639
  cache_control?: {
640
640
  type: "ephemeral";
@@ -642,9 +642,9 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
642
642
  } | {
643
643
  type: "image";
644
644
  source: {
645
- data: string;
646
645
  type: "base64";
647
646
  media_type: "image/jpeg";
647
+ data: string;
648
648
  };
649
649
  cache_control?: {
650
650
  type: "ephemeral";
@@ -729,11 +729,11 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
729
729
  path: z.ZodString;
730
730
  content: z.ZodString;
731
731
  }, "strip", z.ZodTypeAny, {
732
- content: string;
733
732
  path: string;
734
- }, {
735
733
  content: string;
734
+ }, {
736
735
  path: string;
736
+ content: string;
737
737
  }>, "many">, "many">>;
738
738
  }, "strip", z.ZodTypeAny, {
739
739
  currentWorkingDirectory: string;
@@ -758,8 +758,8 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
758
758
  };
759
759
  userKnowledgeFiles?: Record<string, string> | undefined;
760
760
  fileVersions?: {
761
- content: string;
762
761
  path: string;
762
+ content: string;
763
763
  }[][] | undefined;
764
764
  }, {
765
765
  currentWorkingDirectory: string;
@@ -784,8 +784,8 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
784
784
  };
785
785
  userKnowledgeFiles?: Record<string, string> | undefined;
786
786
  fileVersions?: {
787
- content: string;
788
787
  path: string;
788
+ content: string;
789
789
  }[][] | undefined;
790
790
  }>;
791
791
  }, "strip", z.ZodTypeAny, {
@@ -814,8 +814,8 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
814
814
  };
815
815
  userKnowledgeFiles?: Record<string, string> | undefined;
816
816
  fileVersions?: {
817
- content: string;
818
817
  path: string;
818
+ content: string;
819
819
  }[][] | undefined;
820
820
  };
821
821
  authToken?: string | undefined;
@@ -845,8 +845,8 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
845
845
  };
846
846
  userKnowledgeFiles?: Record<string, string> | undefined;
847
847
  fileVersions?: {
848
- content: string;
849
848
  path: string;
849
+ content: string;
850
850
  }[][] | undefined;
851
851
  };
852
852
  authToken?: string | undefined;
@@ -867,6 +867,7 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
867
867
  authToken?: string | undefined;
868
868
  }>]>;
869
869
  }, "strip", z.ZodTypeAny, {
870
+ type: "action";
870
871
  data: {
871
872
  type: "prompt";
872
873
  promptId: string;
@@ -897,28 +898,28 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
897
898
  };
898
899
  userKnowledgeFiles?: Record<string, string> | undefined;
899
900
  fileVersions?: {
900
- content: string;
901
901
  path: string;
902
+ content: string;
902
903
  }[][] | undefined;
903
904
  };
904
905
  messageHistory: {
905
906
  content: string | ({
906
- text: string;
907
907
  type: "text";
908
+ text: string;
908
909
  cache_control?: {
909
910
  type: "ephemeral";
910
911
  } | undefined;
911
912
  } | {
912
- name: string;
913
913
  type: "tool_use";
914
+ name: string;
914
915
  id: string;
915
916
  input: Record<string, any>;
916
917
  cache_control?: {
917
918
  type: "ephemeral";
918
919
  } | undefined;
919
920
  } | {
920
- content: string;
921
921
  type: "tool_result";
922
+ content: string;
922
923
  tool_use_id: string;
923
924
  cache_control?: {
924
925
  type: "ephemeral";
@@ -926,9 +927,9 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
926
927
  } | {
927
928
  type: "image";
928
929
  source: {
929
- data: string;
930
930
  type: "base64";
931
931
  media_type: "image/jpeg";
932
+ data: string;
932
933
  };
933
934
  cache_control?: {
934
935
  type: "ephemeral";
@@ -976,8 +977,8 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
976
977
  };
977
978
  userKnowledgeFiles?: Record<string, string> | undefined;
978
979
  fileVersions?: {
979
- content: string;
980
980
  path: string;
981
+ content: string;
981
982
  }[][] | undefined;
982
983
  };
983
984
  authToken?: string | undefined;
@@ -987,9 +988,9 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
987
988
  stagedChanges: string;
988
989
  authToken?: string | undefined;
989
990
  };
990
- type: "action";
991
991
  txid: number;
992
992
  }, {
993
+ type: "action";
993
994
  data: {
994
995
  type: "prompt";
995
996
  promptId: string;
@@ -1019,28 +1020,28 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
1019
1020
  };
1020
1021
  userKnowledgeFiles?: Record<string, string> | undefined;
1021
1022
  fileVersions?: {
1022
- content: string;
1023
1023
  path: string;
1024
+ content: string;
1024
1025
  }[][] | undefined;
1025
1026
  };
1026
1027
  messageHistory: {
1027
1028
  content: string | ({
1028
- text: string;
1029
1029
  type: "text";
1030
+ text: string;
1030
1031
  cache_control?: {
1031
1032
  type: "ephemeral";
1032
1033
  } | undefined;
1033
1034
  } | {
1034
- name: string;
1035
1035
  type: "tool_use";
1036
+ name: string;
1036
1037
  id: string;
1037
1038
  input: Record<string, any>;
1038
1039
  cache_control?: {
1039
1040
  type: "ephemeral";
1040
1041
  } | undefined;
1041
1042
  } | {
1042
- content: string;
1043
1043
  type: "tool_result";
1044
+ content: string;
1044
1045
  tool_use_id: string;
1045
1046
  cache_control?: {
1046
1047
  type: "ephemeral";
@@ -1048,9 +1049,9 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
1048
1049
  } | {
1049
1050
  type: "image";
1050
1051
  source: {
1051
- data: string;
1052
1052
  type: "base64";
1053
1053
  media_type: "image/jpeg";
1054
+ data: string;
1054
1055
  };
1055
1056
  cache_control?: {
1056
1057
  type: "ephemeral";
@@ -1099,8 +1100,8 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
1099
1100
  };
1100
1101
  userKnowledgeFiles?: Record<string, string> | undefined;
1101
1102
  fileVersions?: {
1102
- content: string;
1103
1103
  path: string;
1104
+ content: string;
1104
1105
  }[][] | undefined;
1105
1106
  };
1106
1107
  authToken?: string | undefined;
@@ -1110,7 +1111,6 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
1110
1111
  stagedChanges: string;
1111
1112
  authToken?: string | undefined;
1112
1113
  };
1113
- type: "action";
1114
1114
  txid: number;
1115
1115
  }>;
1116
1116
  };
@@ -1221,11 +1221,11 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1221
1221
  path: z.ZodString;
1222
1222
  content: z.ZodString;
1223
1223
  }, "strip", z.ZodTypeAny, {
1224
- content: string;
1225
1224
  path: string;
1226
- }, {
1227
1225
  content: string;
1226
+ }, {
1228
1227
  path: string;
1228
+ content: string;
1229
1229
  }>, "many">, "many">>;
1230
1230
  }, "strip", z.ZodTypeAny, {
1231
1231
  currentWorkingDirectory: string;
@@ -1250,8 +1250,8 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1250
1250
  };
1251
1251
  userKnowledgeFiles?: Record<string, string> | undefined;
1252
1252
  fileVersions?: {
1253
- content: string;
1254
1253
  path: string;
1254
+ content: string;
1255
1255
  }[][] | undefined;
1256
1256
  }, {
1257
1257
  currentWorkingDirectory: string;
@@ -1276,8 +1276,8 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1276
1276
  };
1277
1277
  userKnowledgeFiles?: Record<string, string> | undefined;
1278
1278
  fileVersions?: {
1279
- content: string;
1280
1279
  path: string;
1280
+ content: string;
1281
1281
  }[][] | undefined;
1282
1282
  }>;
1283
1283
  messageHistory: z.ZodArray<z.ZodObject<{
@@ -1293,14 +1293,14 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1293
1293
  type: "ephemeral";
1294
1294
  }>>;
1295
1295
  }, "strip", z.ZodTypeAny, {
1296
- text: string;
1297
1296
  type: "text";
1297
+ text: string;
1298
1298
  cache_control?: {
1299
1299
  type: "ephemeral";
1300
1300
  } | undefined;
1301
1301
  }, {
1302
- text: string;
1303
1302
  type: "text";
1303
+ text: string;
1304
1304
  cache_control?: {
1305
1305
  type: "ephemeral";
1306
1306
  } | undefined;
@@ -1317,16 +1317,16 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1317
1317
  type: "ephemeral";
1318
1318
  }>>;
1319
1319
  }, "strip", z.ZodTypeAny, {
1320
- name: string;
1321
1320
  type: "tool_use";
1321
+ name: string;
1322
1322
  id: string;
1323
1323
  input: Record<string, any>;
1324
1324
  cache_control?: {
1325
1325
  type: "ephemeral";
1326
1326
  } | undefined;
1327
1327
  }, {
1328
- name: string;
1329
1328
  type: "tool_use";
1329
+ name: string;
1330
1330
  id: string;
1331
1331
  input: Record<string, any>;
1332
1332
  cache_control?: {
@@ -1344,15 +1344,15 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1344
1344
  type: "ephemeral";
1345
1345
  }>>;
1346
1346
  }, "strip", z.ZodTypeAny, {
1347
- content: string;
1348
1347
  type: "tool_result";
1348
+ content: string;
1349
1349
  tool_use_id: string;
1350
1350
  cache_control?: {
1351
1351
  type: "ephemeral";
1352
1352
  } | undefined;
1353
1353
  }, {
1354
- content: string;
1355
1354
  type: "tool_result";
1355
+ content: string;
1356
1356
  tool_use_id: string;
1357
1357
  cache_control?: {
1358
1358
  type: "ephemeral";
@@ -1364,13 +1364,13 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1364
1364
  media_type: z.ZodLiteral<"image/jpeg">;
1365
1365
  data: z.ZodString;
1366
1366
  }, "strip", z.ZodTypeAny, {
1367
- data: string;
1368
1367
  type: "base64";
1369
1368
  media_type: "image/jpeg";
1370
- }, {
1371
1369
  data: string;
1370
+ }, {
1372
1371
  type: "base64";
1373
1372
  media_type: "image/jpeg";
1373
+ data: string;
1374
1374
  }>;
1375
1375
  cache_control: z.ZodOptional<z.ZodObject<{
1376
1376
  type: z.ZodLiteral<"ephemeral">;
@@ -1382,9 +1382,9 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1382
1382
  }, "strip", z.ZodTypeAny, {
1383
1383
  type: "image";
1384
1384
  source: {
1385
- data: string;
1386
1385
  type: "base64";
1387
1386
  media_type: "image/jpeg";
1387
+ data: string;
1388
1388
  };
1389
1389
  cache_control?: {
1390
1390
  type: "ephemeral";
@@ -1392,9 +1392,9 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1392
1392
  }, {
1393
1393
  type: "image";
1394
1394
  source: {
1395
- data: string;
1396
1395
  type: "base64";
1397
1396
  media_type: "image/jpeg";
1397
+ data: string;
1398
1398
  };
1399
1399
  cache_control?: {
1400
1400
  type: "ephemeral";
@@ -1402,22 +1402,22 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1402
1402
  }>]>, "many">]>;
1403
1403
  }, "strip", z.ZodTypeAny, {
1404
1404
  content: string | ({
1405
- text: string;
1406
1405
  type: "text";
1406
+ text: string;
1407
1407
  cache_control?: {
1408
1408
  type: "ephemeral";
1409
1409
  } | undefined;
1410
1410
  } | {
1411
- name: string;
1412
1411
  type: "tool_use";
1412
+ name: string;
1413
1413
  id: string;
1414
1414
  input: Record<string, any>;
1415
1415
  cache_control?: {
1416
1416
  type: "ephemeral";
1417
1417
  } | undefined;
1418
1418
  } | {
1419
- content: string;
1420
1419
  type: "tool_result";
1420
+ content: string;
1421
1421
  tool_use_id: string;
1422
1422
  cache_control?: {
1423
1423
  type: "ephemeral";
@@ -1425,9 +1425,9 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1425
1425
  } | {
1426
1426
  type: "image";
1427
1427
  source: {
1428
- data: string;
1429
1428
  type: "base64";
1430
1429
  media_type: "image/jpeg";
1430
+ data: string;
1431
1431
  };
1432
1432
  cache_control?: {
1433
1433
  type: "ephemeral";
@@ -1436,22 +1436,22 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1436
1436
  role: "user" | "assistant";
1437
1437
  }, {
1438
1438
  content: string | ({
1439
- text: string;
1440
1439
  type: "text";
1440
+ text: string;
1441
1441
  cache_control?: {
1442
1442
  type: "ephemeral";
1443
1443
  } | undefined;
1444
1444
  } | {
1445
- name: string;
1446
1445
  type: "tool_use";
1446
+ name: string;
1447
1447
  id: string;
1448
1448
  input: Record<string, any>;
1449
1449
  cache_control?: {
1450
1450
  type: "ephemeral";
1451
1451
  } | undefined;
1452
1452
  } | {
1453
- content: string;
1454
1453
  type: "tool_result";
1454
+ content: string;
1455
1455
  tool_use_id: string;
1456
1456
  cache_control?: {
1457
1457
  type: "ephemeral";
@@ -1459,9 +1459,9 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1459
1459
  } | {
1460
1460
  type: "image";
1461
1461
  source: {
1462
- data: string;
1463
1462
  type: "base64";
1464
1463
  media_type: "image/jpeg";
1464
+ data: string;
1465
1465
  };
1466
1466
  cache_control?: {
1467
1467
  type: "ephemeral";
@@ -1495,28 +1495,28 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1495
1495
  };
1496
1496
  userKnowledgeFiles?: Record<string, string> | undefined;
1497
1497
  fileVersions?: {
1498
- content: string;
1499
1498
  path: string;
1499
+ content: string;
1500
1500
  }[][] | undefined;
1501
1501
  };
1502
1502
  messageHistory: {
1503
1503
  content: string | ({
1504
- text: string;
1505
1504
  type: "text";
1505
+ text: string;
1506
1506
  cache_control?: {
1507
1507
  type: "ephemeral";
1508
1508
  } | undefined;
1509
1509
  } | {
1510
- name: string;
1511
1510
  type: "tool_use";
1511
+ name: string;
1512
1512
  id: string;
1513
1513
  input: Record<string, any>;
1514
1514
  cache_control?: {
1515
1515
  type: "ephemeral";
1516
1516
  } | undefined;
1517
1517
  } | {
1518
- content: string;
1519
1518
  type: "tool_result";
1519
+ content: string;
1520
1520
  tool_use_id: string;
1521
1521
  cache_control?: {
1522
1522
  type: "ephemeral";
@@ -1524,9 +1524,9 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1524
1524
  } | {
1525
1525
  type: "image";
1526
1526
  source: {
1527
- data: string;
1528
1527
  type: "base64";
1529
1528
  media_type: "image/jpeg";
1529
+ data: string;
1530
1530
  };
1531
1531
  cache_control?: {
1532
1532
  type: "ephemeral";
@@ -1560,28 +1560,28 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1560
1560
  };
1561
1561
  userKnowledgeFiles?: Record<string, string> | undefined;
1562
1562
  fileVersions?: {
1563
- content: string;
1564
1563
  path: string;
1564
+ content: string;
1565
1565
  }[][] | undefined;
1566
1566
  };
1567
1567
  messageHistory: {
1568
1568
  content: string | ({
1569
- text: string;
1570
1569
  type: "text";
1570
+ text: string;
1571
1571
  cache_control?: {
1572
1572
  type: "ephemeral";
1573
1573
  } | undefined;
1574
1574
  } | {
1575
- name: string;
1576
1575
  type: "tool_use";
1576
+ name: string;
1577
1577
  id: string;
1578
1578
  input: Record<string, any>;
1579
1579
  cache_control?: {
1580
1580
  type: "ephemeral";
1581
1581
  } | undefined;
1582
1582
  } | {
1583
- content: string;
1584
1583
  type: "tool_result";
1584
+ content: string;
1585
1585
  tool_use_id: string;
1586
1586
  cache_control?: {
1587
1587
  type: "ephemeral";
@@ -1589,9 +1589,9 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1589
1589
  } | {
1590
1590
  type: "image";
1591
1591
  source: {
1592
- data: string;
1593
1592
  type: "base64";
1594
1593
  media_type: "image/jpeg";
1594
+ data: string;
1595
1595
  };
1596
1596
  cache_control?: {
1597
1597
  type: "ephemeral";
@@ -1645,28 +1645,28 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1645
1645
  };
1646
1646
  userKnowledgeFiles?: Record<string, string> | undefined;
1647
1647
  fileVersions?: {
1648
- content: string;
1649
1648
  path: string;
1649
+ content: string;
1650
1650
  }[][] | undefined;
1651
1651
  };
1652
1652
  messageHistory: {
1653
1653
  content: string | ({
1654
- text: string;
1655
1654
  type: "text";
1655
+ text: string;
1656
1656
  cache_control?: {
1657
1657
  type: "ephemeral";
1658
1658
  } | undefined;
1659
1659
  } | {
1660
- name: string;
1661
1660
  type: "tool_use";
1661
+ name: string;
1662
1662
  id: string;
1663
1663
  input: Record<string, any>;
1664
1664
  cache_control?: {
1665
1665
  type: "ephemeral";
1666
1666
  } | undefined;
1667
1667
  } | {
1668
- content: string;
1669
1668
  type: "tool_result";
1669
+ content: string;
1670
1670
  tool_use_id: string;
1671
1671
  cache_control?: {
1672
1672
  type: "ephemeral";
@@ -1674,9 +1674,9 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1674
1674
  } | {
1675
1675
  type: "image";
1676
1676
  source: {
1677
- data: string;
1678
1677
  type: "base64";
1679
1678
  media_type: "image/jpeg";
1679
+ data: string;
1680
1680
  };
1681
1681
  cache_control?: {
1682
1682
  type: "ephemeral";
@@ -1723,28 +1723,28 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1723
1723
  };
1724
1724
  userKnowledgeFiles?: Record<string, string> | undefined;
1725
1725
  fileVersions?: {
1726
- content: string;
1727
1726
  path: string;
1727
+ content: string;
1728
1728
  }[][] | undefined;
1729
1729
  };
1730
1730
  messageHistory: {
1731
1731
  content: string | ({
1732
- text: string;
1733
1732
  type: "text";
1733
+ text: string;
1734
1734
  cache_control?: {
1735
1735
  type: "ephemeral";
1736
1736
  } | undefined;
1737
1737
  } | {
1738
- name: string;
1739
1738
  type: "tool_use";
1739
+ name: string;
1740
1740
  id: string;
1741
1741
  input: Record<string, any>;
1742
1742
  cache_control?: {
1743
1743
  type: "ephemeral";
1744
1744
  } | undefined;
1745
1745
  } | {
1746
- content: string;
1747
1746
  type: "tool_result";
1747
+ content: string;
1748
1748
  tool_use_id: string;
1749
1749
  cache_control?: {
1750
1750
  type: "ephemeral";
@@ -1752,9 +1752,9 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1752
1752
  } | {
1753
1753
  type: "image";
1754
1754
  source: {
1755
- data: string;
1756
1755
  type: "base64";
1757
1756
  media_type: "image/jpeg";
1757
+ data: string;
1758
1758
  };
1759
1759
  cache_control?: {
1760
1760
  type: "ephemeral";
@@ -1839,11 +1839,11 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1839
1839
  path: z.ZodString;
1840
1840
  content: z.ZodString;
1841
1841
  }, "strip", z.ZodTypeAny, {
1842
- content: string;
1843
1842
  path: string;
1844
- }, {
1845
1843
  content: string;
1844
+ }, {
1846
1845
  path: string;
1846
+ content: string;
1847
1847
  }>, "many">, "many">>;
1848
1848
  }, "strip", z.ZodTypeAny, {
1849
1849
  currentWorkingDirectory: string;
@@ -1868,8 +1868,8 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1868
1868
  };
1869
1869
  userKnowledgeFiles?: Record<string, string> | undefined;
1870
1870
  fileVersions?: {
1871
- content: string;
1872
1871
  path: string;
1872
+ content: string;
1873
1873
  }[][] | undefined;
1874
1874
  }, {
1875
1875
  currentWorkingDirectory: string;
@@ -1894,8 +1894,8 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1894
1894
  };
1895
1895
  userKnowledgeFiles?: Record<string, string> | undefined;
1896
1896
  fileVersions?: {
1897
- content: string;
1898
1897
  path: string;
1898
+ content: string;
1899
1899
  }[][] | undefined;
1900
1900
  }>;
1901
1901
  }, "strip", z.ZodTypeAny, {
@@ -1924,8 +1924,8 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1924
1924
  };
1925
1925
  userKnowledgeFiles?: Record<string, string> | undefined;
1926
1926
  fileVersions?: {
1927
- content: string;
1928
1927
  path: string;
1928
+ content: string;
1929
1929
  }[][] | undefined;
1930
1930
  };
1931
1931
  authToken?: string | undefined;
@@ -1955,8 +1955,8 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1955
1955
  };
1956
1956
  userKnowledgeFiles?: Record<string, string> | undefined;
1957
1957
  fileVersions?: {
1958
- content: string;
1959
1958
  path: string;
1959
+ content: string;
1960
1960
  }[][] | undefined;
1961
1961
  };
1962
1962
  authToken?: string | undefined;
@@ -1977,6 +1977,7 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1977
1977
  authToken?: string | undefined;
1978
1978
  }>]>;
1979
1979
  }, "strip", z.ZodTypeAny, {
1980
+ type: "action";
1980
1981
  data: {
1981
1982
  type: "prompt";
1982
1983
  promptId: string;
@@ -2007,28 +2008,28 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
2007
2008
  };
2008
2009
  userKnowledgeFiles?: Record<string, string> | undefined;
2009
2010
  fileVersions?: {
2010
- content: string;
2011
2011
  path: string;
2012
+ content: string;
2012
2013
  }[][] | undefined;
2013
2014
  };
2014
2015
  messageHistory: {
2015
2016
  content: string | ({
2016
- text: string;
2017
2017
  type: "text";
2018
+ text: string;
2018
2019
  cache_control?: {
2019
2020
  type: "ephemeral";
2020
2021
  } | undefined;
2021
2022
  } | {
2022
- name: string;
2023
2023
  type: "tool_use";
2024
+ name: string;
2024
2025
  id: string;
2025
2026
  input: Record<string, any>;
2026
2027
  cache_control?: {
2027
2028
  type: "ephemeral";
2028
2029
  } | undefined;
2029
2030
  } | {
2030
- content: string;
2031
2031
  type: "tool_result";
2032
+ content: string;
2032
2033
  tool_use_id: string;
2033
2034
  cache_control?: {
2034
2035
  type: "ephemeral";
@@ -2036,9 +2037,9 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
2036
2037
  } | {
2037
2038
  type: "image";
2038
2039
  source: {
2039
- data: string;
2040
2040
  type: "base64";
2041
2041
  media_type: "image/jpeg";
2042
+ data: string;
2042
2043
  };
2043
2044
  cache_control?: {
2044
2045
  type: "ephemeral";
@@ -2086,8 +2087,8 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
2086
2087
  };
2087
2088
  userKnowledgeFiles?: Record<string, string> | undefined;
2088
2089
  fileVersions?: {
2089
- content: string;
2090
2090
  path: string;
2091
+ content: string;
2091
2092
  }[][] | undefined;
2092
2093
  };
2093
2094
  authToken?: string | undefined;
@@ -2097,9 +2098,9 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
2097
2098
  stagedChanges: string;
2098
2099
  authToken?: string | undefined;
2099
2100
  };
2100
- type: "action";
2101
2101
  txid: number;
2102
2102
  }, {
2103
+ type: "action";
2103
2104
  data: {
2104
2105
  type: "prompt";
2105
2106
  promptId: string;
@@ -2129,28 +2130,28 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
2129
2130
  };
2130
2131
  userKnowledgeFiles?: Record<string, string> | undefined;
2131
2132
  fileVersions?: {
2132
- content: string;
2133
2133
  path: string;
2134
+ content: string;
2134
2135
  }[][] | undefined;
2135
2136
  };
2136
2137
  messageHistory: {
2137
2138
  content: string | ({
2138
- text: string;
2139
2139
  type: "text";
2140
+ text: string;
2140
2141
  cache_control?: {
2141
2142
  type: "ephemeral";
2142
2143
  } | undefined;
2143
2144
  } | {
2144
- name: string;
2145
2145
  type: "tool_use";
2146
+ name: string;
2146
2147
  id: string;
2147
2148
  input: Record<string, any>;
2148
2149
  cache_control?: {
2149
2150
  type: "ephemeral";
2150
2151
  } | undefined;
2151
2152
  } | {
2152
- content: string;
2153
2153
  type: "tool_result";
2154
+ content: string;
2154
2155
  tool_use_id: string;
2155
2156
  cache_control?: {
2156
2157
  type: "ephemeral";
@@ -2158,9 +2159,9 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
2158
2159
  } | {
2159
2160
  type: "image";
2160
2161
  source: {
2161
- data: string;
2162
2162
  type: "base64";
2163
2163
  media_type: "image/jpeg";
2164
+ data: string;
2164
2165
  };
2165
2166
  cache_control?: {
2166
2167
  type: "ephemeral";
@@ -2209,8 +2210,8 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
2209
2210
  };
2210
2211
  userKnowledgeFiles?: Record<string, string> | undefined;
2211
2212
  fileVersions?: {
2212
- content: string;
2213
2213
  path: string;
2214
+ content: string;
2214
2215
  }[][] | undefined;
2215
2216
  };
2216
2217
  authToken?: string | undefined;
@@ -2220,7 +2221,6 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
2220
2221
  stagedChanges: string;
2221
2222
  authToken?: string | undefined;
2222
2223
  };
2223
- type: "action";
2224
2224
  txid: number;
2225
2225
  }>]>;
2226
2226
  export type ClientMessageType = keyof typeof CLIENT_MESSAGE_SCHEMAS;
@@ -2265,36 +2265,36 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2265
2265
  path: z.ZodString;
2266
2266
  content: z.ZodString;
2267
2267
  }, "strip", z.ZodTypeAny, {
2268
- content: string;
2269
2268
  type: "patch" | "file";
2270
2269
  path: string;
2271
- }, {
2272
2270
  content: string;
2271
+ }, {
2273
2272
  type: "patch" | "file";
2274
2273
  path: string;
2274
+ content: string;
2275
2275
  }>, "many">;
2276
2276
  changesAlreadyApplied: z.ZodArray<z.ZodObject<{
2277
2277
  type: z.ZodEnum<["patch", "file"]>;
2278
2278
  path: z.ZodString;
2279
2279
  content: z.ZodString;
2280
2280
  }, "strip", z.ZodTypeAny, {
2281
- content: string;
2282
2281
  type: "patch" | "file";
2283
2282
  path: string;
2284
- }, {
2285
2283
  content: string;
2284
+ }, {
2286
2285
  type: "patch" | "file";
2287
2286
  path: string;
2287
+ content: string;
2288
2288
  }>, "many">;
2289
2289
  addedFileVersions: z.ZodArray<z.ZodObject<{
2290
2290
  path: z.ZodString;
2291
2291
  content: z.ZodString;
2292
2292
  }, "strip", z.ZodTypeAny, {
2293
- content: string;
2294
2293
  path: string;
2295
- }, {
2296
2294
  content: string;
2295
+ }, {
2297
2296
  path: string;
2297
+ content: string;
2298
2298
  }>, "many">;
2299
2299
  resetFileVersions: z.ZodBoolean;
2300
2300
  }, {
@@ -2309,18 +2309,18 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2309
2309
  userInputId: string;
2310
2310
  response: string;
2311
2311
  changes: {
2312
- content: string;
2313
2312
  type: "patch" | "file";
2314
2313
  path: string;
2314
+ content: string;
2315
2315
  }[];
2316
2316
  changesAlreadyApplied: {
2317
- content: string;
2318
2317
  type: "patch" | "file";
2319
2318
  path: string;
2319
+ content: string;
2320
2320
  }[];
2321
2321
  addedFileVersions: {
2322
- content: string;
2323
2322
  path: string;
2323
+ content: string;
2324
2324
  }[];
2325
2325
  resetFileVersions: boolean;
2326
2326
  usage?: number | undefined;
@@ -2334,18 +2334,18 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2334
2334
  userInputId: string;
2335
2335
  response: string;
2336
2336
  changes: {
2337
- content: string;
2338
2337
  type: "patch" | "file";
2339
2338
  path: string;
2339
+ content: string;
2340
2340
  }[];
2341
2341
  changesAlreadyApplied: {
2342
- content: string;
2343
2342
  type: "patch" | "file";
2344
2343
  path: string;
2344
+ content: string;
2345
2345
  }[];
2346
2346
  addedFileVersions: {
2347
- content: string;
2348
2347
  path: string;
2348
+ content: string;
2349
2349
  }[];
2350
2350
  resetFileVersions: boolean;
2351
2351
  usage?: number | undefined;
@@ -2409,11 +2409,11 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2409
2409
  path: z.ZodString;
2410
2410
  content: z.ZodString;
2411
2411
  }, "strip", z.ZodTypeAny, {
2412
- content: string;
2413
2412
  path: string;
2414
- }, {
2415
2413
  content: string;
2414
+ }, {
2416
2415
  path: string;
2416
+ content: string;
2417
2417
  }>, "many">, "many">>;
2418
2418
  }, "strip", z.ZodTypeAny, {
2419
2419
  currentWorkingDirectory: string;
@@ -2438,8 +2438,8 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2438
2438
  };
2439
2439
  userKnowledgeFiles?: Record<string, string> | undefined;
2440
2440
  fileVersions?: {
2441
- content: string;
2442
2441
  path: string;
2442
+ content: string;
2443
2443
  }[][] | undefined;
2444
2444
  }, {
2445
2445
  currentWorkingDirectory: string;
@@ -2464,8 +2464,8 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2464
2464
  };
2465
2465
  userKnowledgeFiles?: Record<string, string> | undefined;
2466
2466
  fileVersions?: {
2467
- content: string;
2468
2467
  path: string;
2468
+ content: string;
2469
2469
  }[][] | undefined;
2470
2470
  }>;
2471
2471
  messageHistory: z.ZodArray<z.ZodObject<{
@@ -2481,14 +2481,14 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2481
2481
  type: "ephemeral";
2482
2482
  }>>;
2483
2483
  }, "strip", z.ZodTypeAny, {
2484
- text: string;
2485
2484
  type: "text";
2485
+ text: string;
2486
2486
  cache_control?: {
2487
2487
  type: "ephemeral";
2488
2488
  } | undefined;
2489
2489
  }, {
2490
- text: string;
2491
2490
  type: "text";
2491
+ text: string;
2492
2492
  cache_control?: {
2493
2493
  type: "ephemeral";
2494
2494
  } | undefined;
@@ -2505,16 +2505,16 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2505
2505
  type: "ephemeral";
2506
2506
  }>>;
2507
2507
  }, "strip", z.ZodTypeAny, {
2508
- name: string;
2509
2508
  type: "tool_use";
2509
+ name: string;
2510
2510
  id: string;
2511
2511
  input: Record<string, any>;
2512
2512
  cache_control?: {
2513
2513
  type: "ephemeral";
2514
2514
  } | undefined;
2515
2515
  }, {
2516
- name: string;
2517
2516
  type: "tool_use";
2517
+ name: string;
2518
2518
  id: string;
2519
2519
  input: Record<string, any>;
2520
2520
  cache_control?: {
@@ -2532,15 +2532,15 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2532
2532
  type: "ephemeral";
2533
2533
  }>>;
2534
2534
  }, "strip", z.ZodTypeAny, {
2535
- content: string;
2536
2535
  type: "tool_result";
2536
+ content: string;
2537
2537
  tool_use_id: string;
2538
2538
  cache_control?: {
2539
2539
  type: "ephemeral";
2540
2540
  } | undefined;
2541
2541
  }, {
2542
- content: string;
2543
2542
  type: "tool_result";
2543
+ content: string;
2544
2544
  tool_use_id: string;
2545
2545
  cache_control?: {
2546
2546
  type: "ephemeral";
@@ -2552,13 +2552,13 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2552
2552
  media_type: z.ZodLiteral<"image/jpeg">;
2553
2553
  data: z.ZodString;
2554
2554
  }, "strip", z.ZodTypeAny, {
2555
- data: string;
2556
2555
  type: "base64";
2557
2556
  media_type: "image/jpeg";
2558
- }, {
2559
2557
  data: string;
2558
+ }, {
2560
2559
  type: "base64";
2561
2560
  media_type: "image/jpeg";
2561
+ data: string;
2562
2562
  }>;
2563
2563
  cache_control: z.ZodOptional<z.ZodObject<{
2564
2564
  type: z.ZodLiteral<"ephemeral">;
@@ -2570,9 +2570,9 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2570
2570
  }, "strip", z.ZodTypeAny, {
2571
2571
  type: "image";
2572
2572
  source: {
2573
- data: string;
2574
2573
  type: "base64";
2575
2574
  media_type: "image/jpeg";
2575
+ data: string;
2576
2576
  };
2577
2577
  cache_control?: {
2578
2578
  type: "ephemeral";
@@ -2580,9 +2580,9 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2580
2580
  }, {
2581
2581
  type: "image";
2582
2582
  source: {
2583
- data: string;
2584
2583
  type: "base64";
2585
2584
  media_type: "image/jpeg";
2585
+ data: string;
2586
2586
  };
2587
2587
  cache_control?: {
2588
2588
  type: "ephemeral";
@@ -2590,22 +2590,22 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2590
2590
  }>]>, "many">]>;
2591
2591
  }, "strip", z.ZodTypeAny, {
2592
2592
  content: string | ({
2593
- text: string;
2594
2593
  type: "text";
2594
+ text: string;
2595
2595
  cache_control?: {
2596
2596
  type: "ephemeral";
2597
2597
  } | undefined;
2598
2598
  } | {
2599
- name: string;
2600
2599
  type: "tool_use";
2600
+ name: string;
2601
2601
  id: string;
2602
2602
  input: Record<string, any>;
2603
2603
  cache_control?: {
2604
2604
  type: "ephemeral";
2605
2605
  } | undefined;
2606
2606
  } | {
2607
- content: string;
2608
2607
  type: "tool_result";
2608
+ content: string;
2609
2609
  tool_use_id: string;
2610
2610
  cache_control?: {
2611
2611
  type: "ephemeral";
@@ -2613,9 +2613,9 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2613
2613
  } | {
2614
2614
  type: "image";
2615
2615
  source: {
2616
- data: string;
2617
2616
  type: "base64";
2618
2617
  media_type: "image/jpeg";
2618
+ data: string;
2619
2619
  };
2620
2620
  cache_control?: {
2621
2621
  type: "ephemeral";
@@ -2624,22 +2624,22 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2624
2624
  role: "user" | "assistant";
2625
2625
  }, {
2626
2626
  content: string | ({
2627
- text: string;
2628
2627
  type: "text";
2628
+ text: string;
2629
2629
  cache_control?: {
2630
2630
  type: "ephemeral";
2631
2631
  } | undefined;
2632
2632
  } | {
2633
- name: string;
2634
2633
  type: "tool_use";
2634
+ name: string;
2635
2635
  id: string;
2636
2636
  input: Record<string, any>;
2637
2637
  cache_control?: {
2638
2638
  type: "ephemeral";
2639
2639
  } | undefined;
2640
2640
  } | {
2641
- content: string;
2642
2641
  type: "tool_result";
2642
+ content: string;
2643
2643
  tool_use_id: string;
2644
2644
  cache_control?: {
2645
2645
  type: "ephemeral";
@@ -2647,9 +2647,9 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2647
2647
  } | {
2648
2648
  type: "image";
2649
2649
  source: {
2650
- data: string;
2651
2650
  type: "base64";
2652
2651
  media_type: "image/jpeg";
2652
+ data: string;
2653
2653
  };
2654
2654
  cache_control?: {
2655
2655
  type: "ephemeral";
@@ -2683,28 +2683,28 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2683
2683
  };
2684
2684
  userKnowledgeFiles?: Record<string, string> | undefined;
2685
2685
  fileVersions?: {
2686
- content: string;
2687
2686
  path: string;
2687
+ content: string;
2688
2688
  }[][] | undefined;
2689
2689
  };
2690
2690
  messageHistory: {
2691
2691
  content: string | ({
2692
- text: string;
2693
2692
  type: "text";
2693
+ text: string;
2694
2694
  cache_control?: {
2695
2695
  type: "ephemeral";
2696
2696
  } | undefined;
2697
2697
  } | {
2698
- name: string;
2699
2698
  type: "tool_use";
2699
+ name: string;
2700
2700
  id: string;
2701
2701
  input: Record<string, any>;
2702
2702
  cache_control?: {
2703
2703
  type: "ephemeral";
2704
2704
  } | undefined;
2705
2705
  } | {
2706
- content: string;
2707
2706
  type: "tool_result";
2707
+ content: string;
2708
2708
  tool_use_id: string;
2709
2709
  cache_control?: {
2710
2710
  type: "ephemeral";
@@ -2712,9 +2712,9 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2712
2712
  } | {
2713
2713
  type: "image";
2714
2714
  source: {
2715
- data: string;
2716
2715
  type: "base64";
2717
2716
  media_type: "image/jpeg";
2717
+ data: string;
2718
2718
  };
2719
2719
  cache_control?: {
2720
2720
  type: "ephemeral";
@@ -2748,28 +2748,28 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2748
2748
  };
2749
2749
  userKnowledgeFiles?: Record<string, string> | undefined;
2750
2750
  fileVersions?: {
2751
- content: string;
2752
2751
  path: string;
2752
+ content: string;
2753
2753
  }[][] | undefined;
2754
2754
  };
2755
2755
  messageHistory: {
2756
2756
  content: string | ({
2757
- text: string;
2758
2757
  type: "text";
2758
+ text: string;
2759
2759
  cache_control?: {
2760
2760
  type: "ephemeral";
2761
2761
  } | undefined;
2762
2762
  } | {
2763
- name: string;
2764
2763
  type: "tool_use";
2764
+ name: string;
2765
2765
  id: string;
2766
2766
  input: Record<string, any>;
2767
2767
  cache_control?: {
2768
2768
  type: "ephemeral";
2769
2769
  } | undefined;
2770
2770
  } | {
2771
- content: string;
2772
2771
  type: "tool_result";
2772
+ content: string;
2773
2773
  tool_use_id: string;
2774
2774
  cache_control?: {
2775
2775
  type: "ephemeral";
@@ -2777,9 +2777,9 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2777
2777
  } | {
2778
2778
  type: "image";
2779
2779
  source: {
2780
- data: string;
2781
2780
  type: "base64";
2782
2781
  media_type: "image/jpeg";
2782
+ data: string;
2783
2783
  };
2784
2784
  cache_control?: {
2785
2785
  type: "ephemeral";
@@ -2843,28 +2843,28 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2843
2843
  };
2844
2844
  userKnowledgeFiles?: Record<string, string> | undefined;
2845
2845
  fileVersions?: {
2846
- content: string;
2847
2846
  path: string;
2847
+ content: string;
2848
2848
  }[][] | undefined;
2849
2849
  };
2850
2850
  messageHistory: {
2851
2851
  content: string | ({
2852
- text: string;
2853
2852
  type: "text";
2853
+ text: string;
2854
2854
  cache_control?: {
2855
2855
  type: "ephemeral";
2856
2856
  } | undefined;
2857
2857
  } | {
2858
- name: string;
2859
2858
  type: "tool_use";
2859
+ name: string;
2860
2860
  id: string;
2861
2861
  input: Record<string, any>;
2862
2862
  cache_control?: {
2863
2863
  type: "ephemeral";
2864
2864
  } | undefined;
2865
2865
  } | {
2866
- content: string;
2867
2866
  type: "tool_result";
2867
+ content: string;
2868
2868
  tool_use_id: string;
2869
2869
  cache_control?: {
2870
2870
  type: "ephemeral";
@@ -2872,9 +2872,9 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2872
2872
  } | {
2873
2873
  type: "image";
2874
2874
  source: {
2875
- data: string;
2876
2875
  type: "base64";
2877
2876
  media_type: "image/jpeg";
2877
+ data: string;
2878
2878
  };
2879
2879
  cache_control?: {
2880
2880
  type: "ephemeral";
@@ -2922,28 +2922,28 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2922
2922
  };
2923
2923
  userKnowledgeFiles?: Record<string, string> | undefined;
2924
2924
  fileVersions?: {
2925
- content: string;
2926
2925
  path: string;
2926
+ content: string;
2927
2927
  }[][] | undefined;
2928
2928
  };
2929
2929
  messageHistory: {
2930
2930
  content: string | ({
2931
- text: string;
2932
2931
  type: "text";
2932
+ text: string;
2933
2933
  cache_control?: {
2934
2934
  type: "ephemeral";
2935
2935
  } | undefined;
2936
2936
  } | {
2937
- name: string;
2938
2937
  type: "tool_use";
2938
+ name: string;
2939
2939
  id: string;
2940
2940
  input: Record<string, any>;
2941
2941
  cache_control?: {
2942
2942
  type: "ephemeral";
2943
2943
  } | undefined;
2944
2944
  } | {
2945
- content: string;
2946
2945
  type: "tool_result";
2946
+ content: string;
2947
2947
  tool_use_id: string;
2948
2948
  cache_control?: {
2949
2949
  type: "ephemeral";
@@ -2951,9 +2951,9 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2951
2951
  } | {
2952
2952
  type: "image";
2953
2953
  source: {
2954
- data: string;
2955
2954
  type: "base64";
2956
2955
  media_type: "image/jpeg";
2956
+ data: string;
2957
2957
  };
2958
2958
  cache_control?: {
2959
2959
  type: "ephemeral";
@@ -3007,84 +3007,84 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
3007
3007
  path: z.ZodString;
3008
3008
  content: z.ZodString;
3009
3009
  }, "strip", z.ZodTypeAny, {
3010
- content: string;
3011
3010
  type: "patch" | "file";
3012
3011
  path: string;
3013
- }, {
3014
3012
  content: string;
3013
+ }, {
3015
3014
  type: "patch" | "file";
3016
3015
  path: string;
3016
+ content: string;
3017
3017
  }>, "many">;
3018
3018
  changesAlreadyApplied: z.ZodArray<z.ZodObject<{
3019
3019
  type: z.ZodEnum<["patch", "file"]>;
3020
3020
  path: z.ZodString;
3021
3021
  content: z.ZodString;
3022
3022
  }, "strip", z.ZodTypeAny, {
3023
- content: string;
3024
3023
  type: "patch" | "file";
3025
3024
  path: string;
3026
- }, {
3027
3025
  content: string;
3026
+ }, {
3028
3027
  type: "patch" | "file";
3029
3028
  path: string;
3029
+ content: string;
3030
3030
  }>, "many">;
3031
3031
  addedFileVersions: z.ZodArray<z.ZodObject<{
3032
3032
  path: z.ZodString;
3033
3033
  content: z.ZodString;
3034
3034
  }, "strip", z.ZodTypeAny, {
3035
- content: string;
3036
3035
  path: string;
3037
- }, {
3038
3036
  content: string;
3037
+ }, {
3039
3038
  path: string;
3039
+ content: string;
3040
3040
  }>, "many">;
3041
3041
  resetFileVersions: z.ZodBoolean;
3042
3042
  }, "strip", z.ZodTypeAny, {
3043
+ type: "tool-call";
3043
3044
  data: {
3044
3045
  name: string;
3045
3046
  id: string;
3046
3047
  input: Record<string, any>;
3047
3048
  };
3048
- type: "tool-call";
3049
3049
  userInputId: string;
3050
3050
  response: string;
3051
3051
  changes: {
3052
- content: string;
3053
3052
  type: "patch" | "file";
3054
3053
  path: string;
3054
+ content: string;
3055
3055
  }[];
3056
3056
  changesAlreadyApplied: {
3057
- content: string;
3058
3057
  type: "patch" | "file";
3059
3058
  path: string;
3059
+ content: string;
3060
3060
  }[];
3061
3061
  addedFileVersions: {
3062
- content: string;
3063
3062
  path: string;
3063
+ content: string;
3064
3064
  }[];
3065
3065
  resetFileVersions: boolean;
3066
3066
  }, {
3067
+ type: "tool-call";
3067
3068
  data: {
3068
3069
  name: string;
3069
3070
  id: string;
3070
3071
  input: Record<string, any>;
3071
3072
  };
3072
- type: "tool-call";
3073
3073
  userInputId: string;
3074
3074
  response: string;
3075
3075
  changes: {
3076
- content: string;
3077
3076
  type: "patch" | "file";
3078
3077
  path: string;
3078
+ content: string;
3079
3079
  }[];
3080
3080
  changesAlreadyApplied: {
3081
- content: string;
3082
3081
  type: "patch" | "file";
3083
3082
  path: string;
3083
+ content: string;
3084
3084
  }[];
3085
3085
  addedFileVersions: {
3086
- content: string;
3087
3086
  path: string;
3087
+ content: string;
3088
3088
  }[];
3089
3089
  resetFileVersions: boolean;
3090
3090
  }>, z.ZodObject<{
@@ -3181,13 +3181,13 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
3181
3181
  }, "strip", z.ZodTypeAny, {
3182
3182
  type: "action-error";
3183
3183
  message: string;
3184
- error?: string | undefined;
3185
3184
  remainingBalance?: number | undefined;
3185
+ error?: string | undefined;
3186
3186
  }, {
3187
3187
  type: "action-error";
3188
3188
  message: string;
3189
- error?: string | undefined;
3190
3189
  remainingBalance?: number | undefined;
3190
+ error?: string | undefined;
3191
3191
  }>, z.ZodObject<{
3192
3192
  type: z.ZodLiteral<"commit-message-response">;
3193
3193
  commitMessage: z.ZodString;
@@ -3199,6 +3199,7 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
3199
3199
  commitMessage: string;
3200
3200
  }>]>;
3201
3201
  }, "strip", z.ZodTypeAny, {
3202
+ type: "action";
3202
3203
  data: {
3203
3204
  type: "usage-response";
3204
3205
  usage: number;
@@ -3220,18 +3221,18 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
3220
3221
  userInputId: string;
3221
3222
  response: string;
3222
3223
  changes: {
3223
- content: string;
3224
3224
  type: "patch" | "file";
3225
3225
  path: string;
3226
+ content: string;
3226
3227
  }[];
3227
3228
  changesAlreadyApplied: {
3228
- content: string;
3229
3229
  type: "patch" | "file";
3230
3230
  path: string;
3231
+ content: string;
3231
3232
  }[];
3232
3233
  addedFileVersions: {
3233
- content: string;
3234
3234
  path: string;
3235
+ content: string;
3235
3236
  }[];
3236
3237
  resetFileVersions: boolean;
3237
3238
  usage?: number | undefined;
@@ -3272,28 +3273,28 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
3272
3273
  };
3273
3274
  userKnowledgeFiles?: Record<string, string> | undefined;
3274
3275
  fileVersions?: {
3275
- content: string;
3276
3276
  path: string;
3277
+ content: string;
3277
3278
  }[][] | undefined;
3278
3279
  };
3279
3280
  messageHistory: {
3280
3281
  content: string | ({
3281
- text: string;
3282
3282
  type: "text";
3283
+ text: string;
3283
3284
  cache_control?: {
3284
3285
  type: "ephemeral";
3285
3286
  } | undefined;
3286
3287
  } | {
3287
- name: string;
3288
3288
  type: "tool_use";
3289
+ name: string;
3289
3290
  id: string;
3290
3291
  input: Record<string, any>;
3291
3292
  cache_control?: {
3292
3293
  type: "ephemeral";
3293
3294
  } | undefined;
3294
3295
  } | {
3295
- content: string;
3296
3296
  type: "tool_result";
3297
+ content: string;
3297
3298
  tool_use_id: string;
3298
3299
  cache_control?: {
3299
3300
  type: "ephemeral";
@@ -3301,9 +3302,9 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
3301
3302
  } | {
3302
3303
  type: "image";
3303
3304
  source: {
3304
- data: string;
3305
3305
  type: "base64";
3306
3306
  media_type: "image/jpeg";
3307
+ data: string;
3307
3308
  };
3308
3309
  cache_control?: {
3309
3310
  type: "ephemeral";
@@ -3332,27 +3333,27 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
3332
3333
  requestId: string;
3333
3334
  filePaths: string[];
3334
3335
  } | {
3336
+ type: "tool-call";
3335
3337
  data: {
3336
3338
  name: string;
3337
3339
  id: string;
3338
3340
  input: Record<string, any>;
3339
3341
  };
3340
- type: "tool-call";
3341
3342
  userInputId: string;
3342
3343
  response: string;
3343
3344
  changes: {
3344
- content: string;
3345
3345
  type: "patch" | "file";
3346
3346
  path: string;
3347
+ content: string;
3347
3348
  }[];
3348
3349
  changesAlreadyApplied: {
3349
- content: string;
3350
3350
  type: "patch" | "file";
3351
3351
  path: string;
3352
+ content: string;
3352
3353
  }[];
3353
3354
  addedFileVersions: {
3354
- content: string;
3355
3355
  path: string;
3356
+ content: string;
3356
3357
  }[];
3357
3358
  resetFileVersions: boolean;
3358
3359
  } | {
@@ -3366,14 +3367,14 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
3366
3367
  } | {
3367
3368
  type: "action-error";
3368
3369
  message: string;
3369
- error?: string | undefined;
3370
3370
  remainingBalance?: number | undefined;
3371
+ error?: string | undefined;
3371
3372
  } | {
3372
3373
  type: "commit-message-response";
3373
3374
  commitMessage: string;
3374
3375
  };
3375
- type: "action";
3376
3376
  }, {
3377
+ type: "action";
3377
3378
  data: {
3378
3379
  type: "usage-response";
3379
3380
  usage: number;
@@ -3395,18 +3396,18 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
3395
3396
  userInputId: string;
3396
3397
  response: string;
3397
3398
  changes: {
3398
- content: string;
3399
3399
  type: "patch" | "file";
3400
3400
  path: string;
3401
+ content: string;
3401
3402
  }[];
3402
3403
  changesAlreadyApplied: {
3403
- content: string;
3404
3404
  type: "patch" | "file";
3405
3405
  path: string;
3406
+ content: string;
3406
3407
  }[];
3407
3408
  addedFileVersions: {
3408
- content: string;
3409
3409
  path: string;
3410
+ content: string;
3410
3411
  }[];
3411
3412
  resetFileVersions: boolean;
3412
3413
  usage?: number | undefined;
@@ -3447,28 +3448,28 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
3447
3448
  };
3448
3449
  userKnowledgeFiles?: Record<string, string> | undefined;
3449
3450
  fileVersions?: {
3450
- content: string;
3451
3451
  path: string;
3452
+ content: string;
3452
3453
  }[][] | undefined;
3453
3454
  };
3454
3455
  messageHistory: {
3455
3456
  content: string | ({
3456
- text: string;
3457
3457
  type: "text";
3458
+ text: string;
3458
3459
  cache_control?: {
3459
3460
  type: "ephemeral";
3460
3461
  } | undefined;
3461
3462
  } | {
3462
- name: string;
3463
3463
  type: "tool_use";
3464
+ name: string;
3464
3465
  id: string;
3465
3466
  input: Record<string, any>;
3466
3467
  cache_control?: {
3467
3468
  type: "ephemeral";
3468
3469
  } | undefined;
3469
3470
  } | {
3470
- content: string;
3471
3471
  type: "tool_result";
3472
+ content: string;
3472
3473
  tool_use_id: string;
3473
3474
  cache_control?: {
3474
3475
  type: "ephemeral";
@@ -3476,9 +3477,9 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
3476
3477
  } | {
3477
3478
  type: "image";
3478
3479
  source: {
3479
- data: string;
3480
3480
  type: "base64";
3481
3481
  media_type: "image/jpeg";
3482
+ data: string;
3482
3483
  };
3483
3484
  cache_control?: {
3484
3485
  type: "ephemeral";
@@ -3507,27 +3508,27 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
3507
3508
  requestId: string;
3508
3509
  filePaths: string[];
3509
3510
  } | {
3511
+ type: "tool-call";
3510
3512
  data: {
3511
3513
  name: string;
3512
3514
  id: string;
3513
3515
  input: Record<string, any>;
3514
3516
  };
3515
- type: "tool-call";
3516
3517
  userInputId: string;
3517
3518
  response: string;
3518
3519
  changes: {
3519
- content: string;
3520
3520
  type: "patch" | "file";
3521
3521
  path: string;
3522
+ content: string;
3522
3523
  }[];
3523
3524
  changesAlreadyApplied: {
3524
- content: string;
3525
3525
  type: "patch" | "file";
3526
3526
  path: string;
3527
+ content: string;
3527
3528
  }[];
3528
3529
  addedFileVersions: {
3529
- content: string;
3530
3530
  path: string;
3531
+ content: string;
3531
3532
  }[];
3532
3533
  resetFileVersions: boolean;
3533
3534
  } | {
@@ -3541,13 +3542,12 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
3541
3542
  } | {
3542
3543
  type: "action-error";
3543
3544
  message: string;
3544
- error?: string | undefined;
3545
3545
  remainingBalance?: number | undefined;
3546
+ error?: string | undefined;
3546
3547
  } | {
3547
3548
  type: "commit-message-response";
3548
3549
  commitMessage: string;
3549
3550
  };
3550
- type: "action";
3551
3551
  }>;
3552
3552
  };
3553
3553
  export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
@@ -3588,36 +3588,36 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
3588
3588
  path: z.ZodString;
3589
3589
  content: z.ZodString;
3590
3590
  }, "strip", z.ZodTypeAny, {
3591
- content: string;
3592
3591
  type: "patch" | "file";
3593
3592
  path: string;
3594
- }, {
3595
3593
  content: string;
3594
+ }, {
3596
3595
  type: "patch" | "file";
3597
3596
  path: string;
3597
+ content: string;
3598
3598
  }>, "many">;
3599
3599
  changesAlreadyApplied: z.ZodArray<z.ZodObject<{
3600
3600
  type: z.ZodEnum<["patch", "file"]>;
3601
3601
  path: z.ZodString;
3602
3602
  content: z.ZodString;
3603
3603
  }, "strip", z.ZodTypeAny, {
3604
- content: string;
3605
3604
  type: "patch" | "file";
3606
3605
  path: string;
3607
- }, {
3608
3606
  content: string;
3607
+ }, {
3609
3608
  type: "patch" | "file";
3610
3609
  path: string;
3610
+ content: string;
3611
3611
  }>, "many">;
3612
3612
  addedFileVersions: z.ZodArray<z.ZodObject<{
3613
3613
  path: z.ZodString;
3614
3614
  content: z.ZodString;
3615
3615
  }, "strip", z.ZodTypeAny, {
3616
- content: string;
3617
3616
  path: string;
3618
- }, {
3619
3617
  content: string;
3618
+ }, {
3620
3619
  path: string;
3620
+ content: string;
3621
3621
  }>, "many">;
3622
3622
  resetFileVersions: z.ZodBoolean;
3623
3623
  }, {
@@ -3632,18 +3632,18 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
3632
3632
  userInputId: string;
3633
3633
  response: string;
3634
3634
  changes: {
3635
- content: string;
3636
3635
  type: "patch" | "file";
3637
3636
  path: string;
3637
+ content: string;
3638
3638
  }[];
3639
3639
  changesAlreadyApplied: {
3640
- content: string;
3641
3640
  type: "patch" | "file";
3642
3641
  path: string;
3642
+ content: string;
3643
3643
  }[];
3644
3644
  addedFileVersions: {
3645
- content: string;
3646
3645
  path: string;
3646
+ content: string;
3647
3647
  }[];
3648
3648
  resetFileVersions: boolean;
3649
3649
  usage?: number | undefined;
@@ -3657,18 +3657,18 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
3657
3657
  userInputId: string;
3658
3658
  response: string;
3659
3659
  changes: {
3660
- content: string;
3661
3660
  type: "patch" | "file";
3662
3661
  path: string;
3662
+ content: string;
3663
3663
  }[];
3664
3664
  changesAlreadyApplied: {
3665
- content: string;
3666
3665
  type: "patch" | "file";
3667
3666
  path: string;
3667
+ content: string;
3668
3668
  }[];
3669
3669
  addedFileVersions: {
3670
- content: string;
3671
3670
  path: string;
3671
+ content: string;
3672
3672
  }[];
3673
3673
  resetFileVersions: boolean;
3674
3674
  usage?: number | undefined;
@@ -3732,11 +3732,11 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
3732
3732
  path: z.ZodString;
3733
3733
  content: z.ZodString;
3734
3734
  }, "strip", z.ZodTypeAny, {
3735
- content: string;
3736
3735
  path: string;
3737
- }, {
3738
3736
  content: string;
3737
+ }, {
3739
3738
  path: string;
3739
+ content: string;
3740
3740
  }>, "many">, "many">>;
3741
3741
  }, "strip", z.ZodTypeAny, {
3742
3742
  currentWorkingDirectory: string;
@@ -3761,8 +3761,8 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
3761
3761
  };
3762
3762
  userKnowledgeFiles?: Record<string, string> | undefined;
3763
3763
  fileVersions?: {
3764
- content: string;
3765
3764
  path: string;
3765
+ content: string;
3766
3766
  }[][] | undefined;
3767
3767
  }, {
3768
3768
  currentWorkingDirectory: string;
@@ -3787,8 +3787,8 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
3787
3787
  };
3788
3788
  userKnowledgeFiles?: Record<string, string> | undefined;
3789
3789
  fileVersions?: {
3790
- content: string;
3791
3790
  path: string;
3791
+ content: string;
3792
3792
  }[][] | undefined;
3793
3793
  }>;
3794
3794
  messageHistory: z.ZodArray<z.ZodObject<{
@@ -3804,14 +3804,14 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
3804
3804
  type: "ephemeral";
3805
3805
  }>>;
3806
3806
  }, "strip", z.ZodTypeAny, {
3807
- text: string;
3808
3807
  type: "text";
3808
+ text: string;
3809
3809
  cache_control?: {
3810
3810
  type: "ephemeral";
3811
3811
  } | undefined;
3812
3812
  }, {
3813
- text: string;
3814
3813
  type: "text";
3814
+ text: string;
3815
3815
  cache_control?: {
3816
3816
  type: "ephemeral";
3817
3817
  } | undefined;
@@ -3828,16 +3828,16 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
3828
3828
  type: "ephemeral";
3829
3829
  }>>;
3830
3830
  }, "strip", z.ZodTypeAny, {
3831
- name: string;
3832
3831
  type: "tool_use";
3832
+ name: string;
3833
3833
  id: string;
3834
3834
  input: Record<string, any>;
3835
3835
  cache_control?: {
3836
3836
  type: "ephemeral";
3837
3837
  } | undefined;
3838
3838
  }, {
3839
- name: string;
3840
3839
  type: "tool_use";
3840
+ name: string;
3841
3841
  id: string;
3842
3842
  input: Record<string, any>;
3843
3843
  cache_control?: {
@@ -3855,15 +3855,15 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
3855
3855
  type: "ephemeral";
3856
3856
  }>>;
3857
3857
  }, "strip", z.ZodTypeAny, {
3858
- content: string;
3859
3858
  type: "tool_result";
3859
+ content: string;
3860
3860
  tool_use_id: string;
3861
3861
  cache_control?: {
3862
3862
  type: "ephemeral";
3863
3863
  } | undefined;
3864
3864
  }, {
3865
- content: string;
3866
3865
  type: "tool_result";
3866
+ content: string;
3867
3867
  tool_use_id: string;
3868
3868
  cache_control?: {
3869
3869
  type: "ephemeral";
@@ -3875,13 +3875,13 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
3875
3875
  media_type: z.ZodLiteral<"image/jpeg">;
3876
3876
  data: z.ZodString;
3877
3877
  }, "strip", z.ZodTypeAny, {
3878
- data: string;
3879
3878
  type: "base64";
3880
3879
  media_type: "image/jpeg";
3881
- }, {
3882
3880
  data: string;
3881
+ }, {
3883
3882
  type: "base64";
3884
3883
  media_type: "image/jpeg";
3884
+ data: string;
3885
3885
  }>;
3886
3886
  cache_control: z.ZodOptional<z.ZodObject<{
3887
3887
  type: z.ZodLiteral<"ephemeral">;
@@ -3893,9 +3893,9 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
3893
3893
  }, "strip", z.ZodTypeAny, {
3894
3894
  type: "image";
3895
3895
  source: {
3896
- data: string;
3897
3896
  type: "base64";
3898
3897
  media_type: "image/jpeg";
3898
+ data: string;
3899
3899
  };
3900
3900
  cache_control?: {
3901
3901
  type: "ephemeral";
@@ -3903,9 +3903,9 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
3903
3903
  }, {
3904
3904
  type: "image";
3905
3905
  source: {
3906
- data: string;
3907
3906
  type: "base64";
3908
3907
  media_type: "image/jpeg";
3908
+ data: string;
3909
3909
  };
3910
3910
  cache_control?: {
3911
3911
  type: "ephemeral";
@@ -3913,22 +3913,22 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
3913
3913
  }>]>, "many">]>;
3914
3914
  }, "strip", z.ZodTypeAny, {
3915
3915
  content: string | ({
3916
- text: string;
3917
3916
  type: "text";
3917
+ text: string;
3918
3918
  cache_control?: {
3919
3919
  type: "ephemeral";
3920
3920
  } | undefined;
3921
3921
  } | {
3922
- name: string;
3923
3922
  type: "tool_use";
3923
+ name: string;
3924
3924
  id: string;
3925
3925
  input: Record<string, any>;
3926
3926
  cache_control?: {
3927
3927
  type: "ephemeral";
3928
3928
  } | undefined;
3929
3929
  } | {
3930
- content: string;
3931
3930
  type: "tool_result";
3931
+ content: string;
3932
3932
  tool_use_id: string;
3933
3933
  cache_control?: {
3934
3934
  type: "ephemeral";
@@ -3936,9 +3936,9 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
3936
3936
  } | {
3937
3937
  type: "image";
3938
3938
  source: {
3939
- data: string;
3940
3939
  type: "base64";
3941
3940
  media_type: "image/jpeg";
3941
+ data: string;
3942
3942
  };
3943
3943
  cache_control?: {
3944
3944
  type: "ephemeral";
@@ -3947,22 +3947,22 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
3947
3947
  role: "user" | "assistant";
3948
3948
  }, {
3949
3949
  content: string | ({
3950
- text: string;
3951
3950
  type: "text";
3951
+ text: string;
3952
3952
  cache_control?: {
3953
3953
  type: "ephemeral";
3954
3954
  } | undefined;
3955
3955
  } | {
3956
- name: string;
3957
3956
  type: "tool_use";
3957
+ name: string;
3958
3958
  id: string;
3959
3959
  input: Record<string, any>;
3960
3960
  cache_control?: {
3961
3961
  type: "ephemeral";
3962
3962
  } | undefined;
3963
3963
  } | {
3964
- content: string;
3965
3964
  type: "tool_result";
3965
+ content: string;
3966
3966
  tool_use_id: string;
3967
3967
  cache_control?: {
3968
3968
  type: "ephemeral";
@@ -3970,9 +3970,9 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
3970
3970
  } | {
3971
3971
  type: "image";
3972
3972
  source: {
3973
- data: string;
3974
3973
  type: "base64";
3975
3974
  media_type: "image/jpeg";
3975
+ data: string;
3976
3976
  };
3977
3977
  cache_control?: {
3978
3978
  type: "ephemeral";
@@ -4006,28 +4006,28 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4006
4006
  };
4007
4007
  userKnowledgeFiles?: Record<string, string> | undefined;
4008
4008
  fileVersions?: {
4009
- content: string;
4010
4009
  path: string;
4010
+ content: string;
4011
4011
  }[][] | undefined;
4012
4012
  };
4013
4013
  messageHistory: {
4014
4014
  content: string | ({
4015
- text: string;
4016
4015
  type: "text";
4016
+ text: string;
4017
4017
  cache_control?: {
4018
4018
  type: "ephemeral";
4019
4019
  } | undefined;
4020
4020
  } | {
4021
- name: string;
4022
4021
  type: "tool_use";
4022
+ name: string;
4023
4023
  id: string;
4024
4024
  input: Record<string, any>;
4025
4025
  cache_control?: {
4026
4026
  type: "ephemeral";
4027
4027
  } | undefined;
4028
4028
  } | {
4029
- content: string;
4030
4029
  type: "tool_result";
4030
+ content: string;
4031
4031
  tool_use_id: string;
4032
4032
  cache_control?: {
4033
4033
  type: "ephemeral";
@@ -4035,9 +4035,9 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4035
4035
  } | {
4036
4036
  type: "image";
4037
4037
  source: {
4038
- data: string;
4039
4038
  type: "base64";
4040
4039
  media_type: "image/jpeg";
4040
+ data: string;
4041
4041
  };
4042
4042
  cache_control?: {
4043
4043
  type: "ephemeral";
@@ -4071,28 +4071,28 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4071
4071
  };
4072
4072
  userKnowledgeFiles?: Record<string, string> | undefined;
4073
4073
  fileVersions?: {
4074
- content: string;
4075
4074
  path: string;
4075
+ content: string;
4076
4076
  }[][] | undefined;
4077
4077
  };
4078
4078
  messageHistory: {
4079
4079
  content: string | ({
4080
- text: string;
4081
4080
  type: "text";
4081
+ text: string;
4082
4082
  cache_control?: {
4083
4083
  type: "ephemeral";
4084
4084
  } | undefined;
4085
4085
  } | {
4086
- name: string;
4087
4086
  type: "tool_use";
4087
+ name: string;
4088
4088
  id: string;
4089
4089
  input: Record<string, any>;
4090
4090
  cache_control?: {
4091
4091
  type: "ephemeral";
4092
4092
  } | undefined;
4093
4093
  } | {
4094
- content: string;
4095
4094
  type: "tool_result";
4095
+ content: string;
4096
4096
  tool_use_id: string;
4097
4097
  cache_control?: {
4098
4098
  type: "ephemeral";
@@ -4100,9 +4100,9 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4100
4100
  } | {
4101
4101
  type: "image";
4102
4102
  source: {
4103
- data: string;
4104
4103
  type: "base64";
4105
4104
  media_type: "image/jpeg";
4105
+ data: string;
4106
4106
  };
4107
4107
  cache_control?: {
4108
4108
  type: "ephemeral";
@@ -4166,28 +4166,28 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4166
4166
  };
4167
4167
  userKnowledgeFiles?: Record<string, string> | undefined;
4168
4168
  fileVersions?: {
4169
- content: string;
4170
4169
  path: string;
4170
+ content: string;
4171
4171
  }[][] | undefined;
4172
4172
  };
4173
4173
  messageHistory: {
4174
4174
  content: string | ({
4175
- text: string;
4176
4175
  type: "text";
4176
+ text: string;
4177
4177
  cache_control?: {
4178
4178
  type: "ephemeral";
4179
4179
  } | undefined;
4180
4180
  } | {
4181
- name: string;
4182
4181
  type: "tool_use";
4182
+ name: string;
4183
4183
  id: string;
4184
4184
  input: Record<string, any>;
4185
4185
  cache_control?: {
4186
4186
  type: "ephemeral";
4187
4187
  } | undefined;
4188
4188
  } | {
4189
- content: string;
4190
4189
  type: "tool_result";
4190
+ content: string;
4191
4191
  tool_use_id: string;
4192
4192
  cache_control?: {
4193
4193
  type: "ephemeral";
@@ -4195,9 +4195,9 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4195
4195
  } | {
4196
4196
  type: "image";
4197
4197
  source: {
4198
- data: string;
4199
4198
  type: "base64";
4200
4199
  media_type: "image/jpeg";
4200
+ data: string;
4201
4201
  };
4202
4202
  cache_control?: {
4203
4203
  type: "ephemeral";
@@ -4245,28 +4245,28 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4245
4245
  };
4246
4246
  userKnowledgeFiles?: Record<string, string> | undefined;
4247
4247
  fileVersions?: {
4248
- content: string;
4249
4248
  path: string;
4249
+ content: string;
4250
4250
  }[][] | undefined;
4251
4251
  };
4252
4252
  messageHistory: {
4253
4253
  content: string | ({
4254
- text: string;
4255
4254
  type: "text";
4255
+ text: string;
4256
4256
  cache_control?: {
4257
4257
  type: "ephemeral";
4258
4258
  } | undefined;
4259
4259
  } | {
4260
- name: string;
4261
4260
  type: "tool_use";
4261
+ name: string;
4262
4262
  id: string;
4263
4263
  input: Record<string, any>;
4264
4264
  cache_control?: {
4265
4265
  type: "ephemeral";
4266
4266
  } | undefined;
4267
4267
  } | {
4268
- content: string;
4269
4268
  type: "tool_result";
4269
+ content: string;
4270
4270
  tool_use_id: string;
4271
4271
  cache_control?: {
4272
4272
  type: "ephemeral";
@@ -4274,9 +4274,9 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4274
4274
  } | {
4275
4275
  type: "image";
4276
4276
  source: {
4277
- data: string;
4278
4277
  type: "base64";
4279
4278
  media_type: "image/jpeg";
4279
+ data: string;
4280
4280
  };
4281
4281
  cache_control?: {
4282
4282
  type: "ephemeral";
@@ -4330,84 +4330,84 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4330
4330
  path: z.ZodString;
4331
4331
  content: z.ZodString;
4332
4332
  }, "strip", z.ZodTypeAny, {
4333
- content: string;
4334
4333
  type: "patch" | "file";
4335
4334
  path: string;
4336
- }, {
4337
4335
  content: string;
4336
+ }, {
4338
4337
  type: "patch" | "file";
4339
4338
  path: string;
4339
+ content: string;
4340
4340
  }>, "many">;
4341
4341
  changesAlreadyApplied: z.ZodArray<z.ZodObject<{
4342
4342
  type: z.ZodEnum<["patch", "file"]>;
4343
4343
  path: z.ZodString;
4344
4344
  content: z.ZodString;
4345
4345
  }, "strip", z.ZodTypeAny, {
4346
- content: string;
4347
4346
  type: "patch" | "file";
4348
4347
  path: string;
4349
- }, {
4350
4348
  content: string;
4349
+ }, {
4351
4350
  type: "patch" | "file";
4352
4351
  path: string;
4352
+ content: string;
4353
4353
  }>, "many">;
4354
4354
  addedFileVersions: z.ZodArray<z.ZodObject<{
4355
4355
  path: z.ZodString;
4356
4356
  content: z.ZodString;
4357
4357
  }, "strip", z.ZodTypeAny, {
4358
- content: string;
4359
4358
  path: string;
4360
- }, {
4361
4359
  content: string;
4360
+ }, {
4362
4361
  path: string;
4362
+ content: string;
4363
4363
  }>, "many">;
4364
4364
  resetFileVersions: z.ZodBoolean;
4365
4365
  }, "strip", z.ZodTypeAny, {
4366
+ type: "tool-call";
4366
4367
  data: {
4367
4368
  name: string;
4368
4369
  id: string;
4369
4370
  input: Record<string, any>;
4370
4371
  };
4371
- type: "tool-call";
4372
4372
  userInputId: string;
4373
4373
  response: string;
4374
4374
  changes: {
4375
- content: string;
4376
4375
  type: "patch" | "file";
4377
4376
  path: string;
4377
+ content: string;
4378
4378
  }[];
4379
4379
  changesAlreadyApplied: {
4380
- content: string;
4381
4380
  type: "patch" | "file";
4382
4381
  path: string;
4382
+ content: string;
4383
4383
  }[];
4384
4384
  addedFileVersions: {
4385
- content: string;
4386
4385
  path: string;
4386
+ content: string;
4387
4387
  }[];
4388
4388
  resetFileVersions: boolean;
4389
4389
  }, {
4390
+ type: "tool-call";
4390
4391
  data: {
4391
4392
  name: string;
4392
4393
  id: string;
4393
4394
  input: Record<string, any>;
4394
4395
  };
4395
- type: "tool-call";
4396
4396
  userInputId: string;
4397
4397
  response: string;
4398
4398
  changes: {
4399
- content: string;
4400
4399
  type: "patch" | "file";
4401
4400
  path: string;
4401
+ content: string;
4402
4402
  }[];
4403
4403
  changesAlreadyApplied: {
4404
- content: string;
4405
4404
  type: "patch" | "file";
4406
4405
  path: string;
4406
+ content: string;
4407
4407
  }[];
4408
4408
  addedFileVersions: {
4409
- content: string;
4410
4409
  path: string;
4410
+ content: string;
4411
4411
  }[];
4412
4412
  resetFileVersions: boolean;
4413
4413
  }>, z.ZodObject<{
@@ -4504,13 +4504,13 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4504
4504
  }, "strip", z.ZodTypeAny, {
4505
4505
  type: "action-error";
4506
4506
  message: string;
4507
- error?: string | undefined;
4508
4507
  remainingBalance?: number | undefined;
4508
+ error?: string | undefined;
4509
4509
  }, {
4510
4510
  type: "action-error";
4511
4511
  message: string;
4512
- error?: string | undefined;
4513
4512
  remainingBalance?: number | undefined;
4513
+ error?: string | undefined;
4514
4514
  }>, z.ZodObject<{
4515
4515
  type: z.ZodLiteral<"commit-message-response">;
4516
4516
  commitMessage: z.ZodString;
@@ -4522,6 +4522,7 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4522
4522
  commitMessage: string;
4523
4523
  }>]>;
4524
4524
  }, "strip", z.ZodTypeAny, {
4525
+ type: "action";
4525
4526
  data: {
4526
4527
  type: "usage-response";
4527
4528
  usage: number;
@@ -4543,18 +4544,18 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4543
4544
  userInputId: string;
4544
4545
  response: string;
4545
4546
  changes: {
4546
- content: string;
4547
4547
  type: "patch" | "file";
4548
4548
  path: string;
4549
+ content: string;
4549
4550
  }[];
4550
4551
  changesAlreadyApplied: {
4551
- content: string;
4552
4552
  type: "patch" | "file";
4553
4553
  path: string;
4554
+ content: string;
4554
4555
  }[];
4555
4556
  addedFileVersions: {
4556
- content: string;
4557
4557
  path: string;
4558
+ content: string;
4558
4559
  }[];
4559
4560
  resetFileVersions: boolean;
4560
4561
  usage?: number | undefined;
@@ -4595,28 +4596,28 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4595
4596
  };
4596
4597
  userKnowledgeFiles?: Record<string, string> | undefined;
4597
4598
  fileVersions?: {
4598
- content: string;
4599
4599
  path: string;
4600
+ content: string;
4600
4601
  }[][] | undefined;
4601
4602
  };
4602
4603
  messageHistory: {
4603
4604
  content: string | ({
4604
- text: string;
4605
4605
  type: "text";
4606
+ text: string;
4606
4607
  cache_control?: {
4607
4608
  type: "ephemeral";
4608
4609
  } | undefined;
4609
4610
  } | {
4610
- name: string;
4611
4611
  type: "tool_use";
4612
+ name: string;
4612
4613
  id: string;
4613
4614
  input: Record<string, any>;
4614
4615
  cache_control?: {
4615
4616
  type: "ephemeral";
4616
4617
  } | undefined;
4617
4618
  } | {
4618
- content: string;
4619
4619
  type: "tool_result";
4620
+ content: string;
4620
4621
  tool_use_id: string;
4621
4622
  cache_control?: {
4622
4623
  type: "ephemeral";
@@ -4624,9 +4625,9 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4624
4625
  } | {
4625
4626
  type: "image";
4626
4627
  source: {
4627
- data: string;
4628
4628
  type: "base64";
4629
4629
  media_type: "image/jpeg";
4630
+ data: string;
4630
4631
  };
4631
4632
  cache_control?: {
4632
4633
  type: "ephemeral";
@@ -4655,27 +4656,27 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4655
4656
  requestId: string;
4656
4657
  filePaths: string[];
4657
4658
  } | {
4659
+ type: "tool-call";
4658
4660
  data: {
4659
4661
  name: string;
4660
4662
  id: string;
4661
4663
  input: Record<string, any>;
4662
4664
  };
4663
- type: "tool-call";
4664
4665
  userInputId: string;
4665
4666
  response: string;
4666
4667
  changes: {
4667
- content: string;
4668
4668
  type: "patch" | "file";
4669
4669
  path: string;
4670
+ content: string;
4670
4671
  }[];
4671
4672
  changesAlreadyApplied: {
4672
- content: string;
4673
4673
  type: "patch" | "file";
4674
4674
  path: string;
4675
+ content: string;
4675
4676
  }[];
4676
4677
  addedFileVersions: {
4677
- content: string;
4678
4678
  path: string;
4679
+ content: string;
4679
4680
  }[];
4680
4681
  resetFileVersions: boolean;
4681
4682
  } | {
@@ -4689,14 +4690,14 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4689
4690
  } | {
4690
4691
  type: "action-error";
4691
4692
  message: string;
4692
- error?: string | undefined;
4693
4693
  remainingBalance?: number | undefined;
4694
+ error?: string | undefined;
4694
4695
  } | {
4695
4696
  type: "commit-message-response";
4696
4697
  commitMessage: string;
4697
4698
  };
4698
- type: "action";
4699
4699
  }, {
4700
+ type: "action";
4700
4701
  data: {
4701
4702
  type: "usage-response";
4702
4703
  usage: number;
@@ -4718,18 +4719,18 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4718
4719
  userInputId: string;
4719
4720
  response: string;
4720
4721
  changes: {
4721
- content: string;
4722
4722
  type: "patch" | "file";
4723
4723
  path: string;
4724
+ content: string;
4724
4725
  }[];
4725
4726
  changesAlreadyApplied: {
4726
- content: string;
4727
4727
  type: "patch" | "file";
4728
4728
  path: string;
4729
+ content: string;
4729
4730
  }[];
4730
4731
  addedFileVersions: {
4731
- content: string;
4732
4732
  path: string;
4733
+ content: string;
4733
4734
  }[];
4734
4735
  resetFileVersions: boolean;
4735
4736
  usage?: number | undefined;
@@ -4770,28 +4771,28 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4770
4771
  };
4771
4772
  userKnowledgeFiles?: Record<string, string> | undefined;
4772
4773
  fileVersions?: {
4773
- content: string;
4774
4774
  path: string;
4775
+ content: string;
4775
4776
  }[][] | undefined;
4776
4777
  };
4777
4778
  messageHistory: {
4778
4779
  content: string | ({
4779
- text: string;
4780
4780
  type: "text";
4781
+ text: string;
4781
4782
  cache_control?: {
4782
4783
  type: "ephemeral";
4783
4784
  } | undefined;
4784
4785
  } | {
4785
- name: string;
4786
4786
  type: "tool_use";
4787
+ name: string;
4787
4788
  id: string;
4788
4789
  input: Record<string, any>;
4789
4790
  cache_control?: {
4790
4791
  type: "ephemeral";
4791
4792
  } | undefined;
4792
4793
  } | {
4793
- content: string;
4794
4794
  type: "tool_result";
4795
+ content: string;
4795
4796
  tool_use_id: string;
4796
4797
  cache_control?: {
4797
4798
  type: "ephemeral";
@@ -4799,9 +4800,9 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4799
4800
  } | {
4800
4801
  type: "image";
4801
4802
  source: {
4802
- data: string;
4803
4803
  type: "base64";
4804
4804
  media_type: "image/jpeg";
4805
+ data: string;
4805
4806
  };
4806
4807
  cache_control?: {
4807
4808
  type: "ephemeral";
@@ -4830,27 +4831,27 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4830
4831
  requestId: string;
4831
4832
  filePaths: string[];
4832
4833
  } | {
4834
+ type: "tool-call";
4833
4835
  data: {
4834
4836
  name: string;
4835
4837
  id: string;
4836
4838
  input: Record<string, any>;
4837
4839
  };
4838
- type: "tool-call";
4839
4840
  userInputId: string;
4840
4841
  response: string;
4841
4842
  changes: {
4842
- content: string;
4843
4843
  type: "patch" | "file";
4844
4844
  path: string;
4845
+ content: string;
4845
4846
  }[];
4846
4847
  changesAlreadyApplied: {
4847
- content: string;
4848
4848
  type: "patch" | "file";
4849
4849
  path: string;
4850
+ content: string;
4850
4851
  }[];
4851
4852
  addedFileVersions: {
4852
- content: string;
4853
4853
  path: string;
4854
+ content: string;
4854
4855
  }[];
4855
4856
  resetFileVersions: boolean;
4856
4857
  } | {
@@ -4864,13 +4865,12 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4864
4865
  } | {
4865
4866
  type: "action-error";
4866
4867
  message: string;
4867
- error?: string | undefined;
4868
4868
  remainingBalance?: number | undefined;
4869
+ error?: string | undefined;
4869
4870
  } | {
4870
4871
  type: "commit-message-response";
4871
4872
  commitMessage: string;
4872
4873
  };
4873
- type: "action";
4874
4874
  }>]>;
4875
4875
  export type ServerMessageType = keyof typeof SERVER_MESSAGE_SCHEMAS;
4876
4876
  export type ServerMessage<T extends ServerMessageType = ServerMessageType> = z.infer<(typeof SERVER_MESSAGE_SCHEMAS)[T]>;