codebuff 1.0.260 → 1.0.262

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (45) hide show
  1. package/dist/client.d.ts +1 -1
  2. package/dist/client.js +2 -1
  3. package/dist/client.js.map +1 -1
  4. package/dist/code-map/tsconfig.tsbuildinfo +1 -1
  5. package/dist/common/actions.d.ts +55 -52
  6. package/dist/common/actions.js +1 -0
  7. package/dist/common/actions.js.map +1 -1
  8. package/dist/common/bigquery/client.d.ts +15 -0
  9. package/dist/common/bigquery/client.js +265 -0
  10. package/dist/common/bigquery/client.js.map +1 -0
  11. package/dist/common/bigquery/schema.d.ts +55 -0
  12. package/dist/common/bigquery/schema.js +24 -0
  13. package/dist/common/bigquery/schema.js.map +1 -0
  14. package/dist/common/constants/tools.d.ts +1 -0
  15. package/dist/common/constants/tools.js +1 -0
  16. package/dist/common/constants/tools.js.map +1 -1
  17. package/dist/common/types/agent-state.d.ts +6 -6
  18. package/dist/common/types/message.d.ts +6 -6
  19. package/dist/common/util/credentials.d.ts +2 -2
  20. package/dist/common/websockets/websocket-schema.d.ts +98 -88
  21. package/dist/dev-process-manager.js +1 -0
  22. package/dist/dev-process-manager.js.map +1 -1
  23. package/dist/index.js +10 -9
  24. package/dist/index.js.map +1 -1
  25. package/dist/project-files.d.ts +2 -1
  26. package/dist/project-files.js +7 -7
  27. package/dist/project-files.js.map +1 -1
  28. package/dist/startup-process-handler.js +1 -1
  29. package/dist/startup-process-handler.js.map +1 -1
  30. package/dist/tool-handlers.d.ts +2 -1
  31. package/dist/tool-handlers.js +6 -4
  32. package/dist/tool-handlers.js.map +1 -1
  33. package/dist/update-codebuff.js +3 -2
  34. package/dist/update-codebuff.js.map +1 -1
  35. package/dist/utils/__tests__/tool-renderers.test.js +2 -2
  36. package/dist/utils/__tests__/tool-renderers.test.js.map +1 -1
  37. package/dist/utils/git.d.ts +1 -0
  38. package/dist/utils/git.js +17 -0
  39. package/dist/utils/git.js.map +1 -1
  40. package/dist/utils/terminal.d.ts +2 -2
  41. package/dist/utils/terminal.js +48 -36
  42. package/dist/utils/terminal.js.map +1 -1
  43. package/dist/utils/tool-renderers.js +16 -1
  44. package/dist/utils/tool-renderers.js.map +1 -1
  45. package/package.json +2 -1
@@ -234,15 +234,15 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
234
234
  type: "ephemeral";
235
235
  }>>;
236
236
  }, "strip", z.ZodTypeAny, {
237
- type: "tool_result";
238
237
  content: string;
238
+ type: "tool_result";
239
239
  tool_use_id: string;
240
240
  cache_control?: {
241
241
  type: "ephemeral";
242
242
  } | undefined;
243
243
  }, {
244
- type: "tool_result";
245
244
  content: string;
245
+ type: "tool_result";
246
246
  tool_use_id: string;
247
247
  cache_control?: {
248
248
  type: "ephemeral";
@@ -306,8 +306,8 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
306
306
  type: "ephemeral";
307
307
  } | undefined;
308
308
  } | {
309
- type: "tool_result";
310
309
  content: string;
310
+ type: "tool_result";
311
311
  tool_use_id: string;
312
312
  cache_control?: {
313
313
  type: "ephemeral";
@@ -340,8 +340,8 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
340
340
  type: "ephemeral";
341
341
  } | undefined;
342
342
  } | {
343
- type: "tool_result";
344
343
  content: string;
344
+ type: "tool_result";
345
345
  tool_use_id: string;
346
346
  cache_control?: {
347
347
  type: "ephemeral";
@@ -405,8 +405,8 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
405
405
  type: "ephemeral";
406
406
  } | undefined;
407
407
  } | {
408
- type: "tool_result";
409
408
  content: string;
409
+ type: "tool_result";
410
410
  tool_use_id: string;
411
411
  cache_control?: {
412
412
  type: "ephemeral";
@@ -470,8 +470,8 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
470
470
  type: "ephemeral";
471
471
  } | undefined;
472
472
  } | {
473
- type: "tool_result";
474
473
  content: string;
474
+ type: "tool_result";
475
475
  tool_use_id: string;
476
476
  cache_control?: {
477
477
  type: "ephemeral";
@@ -505,6 +505,7 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
505
505
  result: string;
506
506
  }>, "many">;
507
507
  model: z.ZodOptional<z.ZodString>;
508
+ cwd: z.ZodOptional<z.ZodString>;
508
509
  }, "strip", z.ZodTypeAny, {
509
510
  type: "prompt";
510
511
  promptId: string;
@@ -555,8 +556,8 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
555
556
  type: "ephemeral";
556
557
  } | undefined;
557
558
  } | {
558
- type: "tool_result";
559
559
  content: string;
560
+ type: "tool_result";
560
561
  tool_use_id: string;
561
562
  cache_control?: {
562
563
  type: "ephemeral";
@@ -584,6 +585,7 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
584
585
  prompt?: string | undefined;
585
586
  authToken?: string | undefined;
586
587
  model?: string | undefined;
588
+ cwd?: string | undefined;
587
589
  }, {
588
590
  type: "prompt";
589
591
  promptId: string;
@@ -633,8 +635,8 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
633
635
  type: "ephemeral";
634
636
  } | undefined;
635
637
  } | {
636
- type: "tool_result";
637
638
  content: string;
639
+ type: "tool_result";
638
640
  tool_use_id: string;
639
641
  cache_control?: {
640
642
  type: "ephemeral";
@@ -663,6 +665,7 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
663
665
  authToken?: string | undefined;
664
666
  costMode?: "lite" | "normal" | "max" | "experimental" | undefined;
665
667
  model?: string | undefined;
668
+ cwd?: string | undefined;
666
669
  }>, z.ZodObject<{
667
670
  type: z.ZodLiteral<"read-files-response">;
668
671
  files: z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodNull]>>;
@@ -918,8 +921,8 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
918
921
  type: "ephemeral";
919
922
  } | undefined;
920
923
  } | {
921
- type: "tool_result";
922
924
  content: string;
925
+ type: "tool_result";
923
926
  tool_use_id: string;
924
927
  cache_control?: {
925
928
  type: "ephemeral";
@@ -947,6 +950,7 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
947
950
  prompt?: string | undefined;
948
951
  authToken?: string | undefined;
949
952
  model?: string | undefined;
953
+ cwd?: string | undefined;
950
954
  } | {
951
955
  type: "read-files-response";
952
956
  files: Record<string, string | null>;
@@ -1040,8 +1044,8 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
1040
1044
  type: "ephemeral";
1041
1045
  } | undefined;
1042
1046
  } | {
1043
- type: "tool_result";
1044
1047
  content: string;
1048
+ type: "tool_result";
1045
1049
  tool_use_id: string;
1046
1050
  cache_control?: {
1047
1051
  type: "ephemeral";
@@ -1070,6 +1074,7 @@ export declare const CLIENT_MESSAGE_SCHEMAS: {
1070
1074
  authToken?: string | undefined;
1071
1075
  costMode?: "lite" | "normal" | "max" | "experimental" | undefined;
1072
1076
  model?: string | undefined;
1077
+ cwd?: string | undefined;
1073
1078
  } | {
1074
1079
  type: "read-files-response";
1075
1080
  files: Record<string, string | null>;
@@ -1344,15 +1349,15 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1344
1349
  type: "ephemeral";
1345
1350
  }>>;
1346
1351
  }, "strip", z.ZodTypeAny, {
1347
- type: "tool_result";
1348
1352
  content: string;
1353
+ type: "tool_result";
1349
1354
  tool_use_id: string;
1350
1355
  cache_control?: {
1351
1356
  type: "ephemeral";
1352
1357
  } | undefined;
1353
1358
  }, {
1354
- type: "tool_result";
1355
1359
  content: string;
1360
+ type: "tool_result";
1356
1361
  tool_use_id: string;
1357
1362
  cache_control?: {
1358
1363
  type: "ephemeral";
@@ -1416,8 +1421,8 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1416
1421
  type: "ephemeral";
1417
1422
  } | undefined;
1418
1423
  } | {
1419
- type: "tool_result";
1420
1424
  content: string;
1425
+ type: "tool_result";
1421
1426
  tool_use_id: string;
1422
1427
  cache_control?: {
1423
1428
  type: "ephemeral";
@@ -1450,8 +1455,8 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1450
1455
  type: "ephemeral";
1451
1456
  } | undefined;
1452
1457
  } | {
1453
- type: "tool_result";
1454
1458
  content: string;
1459
+ type: "tool_result";
1455
1460
  tool_use_id: string;
1456
1461
  cache_control?: {
1457
1462
  type: "ephemeral";
@@ -1515,8 +1520,8 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1515
1520
  type: "ephemeral";
1516
1521
  } | undefined;
1517
1522
  } | {
1518
- type: "tool_result";
1519
1523
  content: string;
1524
+ type: "tool_result";
1520
1525
  tool_use_id: string;
1521
1526
  cache_control?: {
1522
1527
  type: "ephemeral";
@@ -1580,8 +1585,8 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1580
1585
  type: "ephemeral";
1581
1586
  } | undefined;
1582
1587
  } | {
1583
- type: "tool_result";
1584
1588
  content: string;
1589
+ type: "tool_result";
1585
1590
  tool_use_id: string;
1586
1591
  cache_control?: {
1587
1592
  type: "ephemeral";
@@ -1615,6 +1620,7 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1615
1620
  result: string;
1616
1621
  }>, "many">;
1617
1622
  model: z.ZodOptional<z.ZodString>;
1623
+ cwd: z.ZodOptional<z.ZodString>;
1618
1624
  }, "strip", z.ZodTypeAny, {
1619
1625
  type: "prompt";
1620
1626
  promptId: string;
@@ -1665,8 +1671,8 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1665
1671
  type: "ephemeral";
1666
1672
  } | undefined;
1667
1673
  } | {
1668
- type: "tool_result";
1669
1674
  content: string;
1675
+ type: "tool_result";
1670
1676
  tool_use_id: string;
1671
1677
  cache_control?: {
1672
1678
  type: "ephemeral";
@@ -1694,6 +1700,7 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1694
1700
  prompt?: string | undefined;
1695
1701
  authToken?: string | undefined;
1696
1702
  model?: string | undefined;
1703
+ cwd?: string | undefined;
1697
1704
  }, {
1698
1705
  type: "prompt";
1699
1706
  promptId: string;
@@ -1743,8 +1750,8 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1743
1750
  type: "ephemeral";
1744
1751
  } | undefined;
1745
1752
  } | {
1746
- type: "tool_result";
1747
1753
  content: string;
1754
+ type: "tool_result";
1748
1755
  tool_use_id: string;
1749
1756
  cache_control?: {
1750
1757
  type: "ephemeral";
@@ -1773,6 +1780,7 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
1773
1780
  authToken?: string | undefined;
1774
1781
  costMode?: "lite" | "normal" | "max" | "experimental" | undefined;
1775
1782
  model?: string | undefined;
1783
+ cwd?: string | undefined;
1776
1784
  }>, z.ZodObject<{
1777
1785
  type: z.ZodLiteral<"read-files-response">;
1778
1786
  files: z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodNull]>>;
@@ -2028,8 +2036,8 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
2028
2036
  type: "ephemeral";
2029
2037
  } | undefined;
2030
2038
  } | {
2031
- type: "tool_result";
2032
2039
  content: string;
2040
+ type: "tool_result";
2033
2041
  tool_use_id: string;
2034
2042
  cache_control?: {
2035
2043
  type: "ephemeral";
@@ -2057,6 +2065,7 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
2057
2065
  prompt?: string | undefined;
2058
2066
  authToken?: string | undefined;
2059
2067
  model?: string | undefined;
2068
+ cwd?: string | undefined;
2060
2069
  } | {
2061
2070
  type: "read-files-response";
2062
2071
  files: Record<string, string | null>;
@@ -2150,8 +2159,8 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
2150
2159
  type: "ephemeral";
2151
2160
  } | undefined;
2152
2161
  } | {
2153
- type: "tool_result";
2154
2162
  content: string;
2163
+ type: "tool_result";
2155
2164
  tool_use_id: string;
2156
2165
  cache_control?: {
2157
2166
  type: "ephemeral";
@@ -2180,6 +2189,7 @@ export declare const CLIENT_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
2180
2189
  authToken?: string | undefined;
2181
2190
  costMode?: "lite" | "normal" | "max" | "experimental" | undefined;
2182
2191
  model?: string | undefined;
2192
+ cwd?: string | undefined;
2183
2193
  } | {
2184
2194
  type: "read-files-response";
2185
2195
  files: Record<string, string | null>;
@@ -2266,12 +2276,12 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2266
2276
  content: z.ZodString;
2267
2277
  }, "strip", z.ZodTypeAny, {
2268
2278
  path: string;
2269
- type: "file" | "patch";
2270
2279
  content: string;
2280
+ type: "file" | "patch";
2271
2281
  }, {
2272
2282
  path: string;
2273
- type: "file" | "patch";
2274
2283
  content: string;
2284
+ type: "file" | "patch";
2275
2285
  }>, "many">;
2276
2286
  changesAlreadyApplied: z.ZodArray<z.ZodObject<{
2277
2287
  type: z.ZodEnum<["patch", "file"]>;
@@ -2279,12 +2289,12 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2279
2289
  content: z.ZodString;
2280
2290
  }, "strip", z.ZodTypeAny, {
2281
2291
  path: string;
2282
- type: "file" | "patch";
2283
2292
  content: string;
2293
+ type: "file" | "patch";
2284
2294
  }, {
2285
2295
  path: string;
2286
- type: "file" | "patch";
2287
2296
  content: string;
2297
+ type: "file" | "patch";
2288
2298
  }>, "many">;
2289
2299
  addedFileVersions: z.ZodArray<z.ZodObject<{
2290
2300
  path: z.ZodString;
@@ -2309,13 +2319,13 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2309
2319
  response: string;
2310
2320
  changes: {
2311
2321
  path: string;
2312
- type: "file" | "patch";
2313
2322
  content: string;
2323
+ type: "file" | "patch";
2314
2324
  }[];
2315
2325
  changesAlreadyApplied: {
2316
2326
  path: string;
2317
- type: "file" | "patch";
2318
2327
  content: string;
2328
+ type: "file" | "patch";
2319
2329
  }[];
2320
2330
  addedFileVersions: {
2321
2331
  path: string;
@@ -2333,13 +2343,13 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2333
2343
  response: string;
2334
2344
  changes: {
2335
2345
  path: string;
2336
- type: "file" | "patch";
2337
2346
  content: string;
2347
+ type: "file" | "patch";
2338
2348
  }[];
2339
2349
  changesAlreadyApplied: {
2340
2350
  path: string;
2341
- type: "file" | "patch";
2342
2351
  content: string;
2352
+ type: "file" | "patch";
2343
2353
  }[];
2344
2354
  addedFileVersions: {
2345
2355
  path: string;
@@ -2529,15 +2539,15 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2529
2539
  type: "ephemeral";
2530
2540
  }>>;
2531
2541
  }, "strip", z.ZodTypeAny, {
2532
- type: "tool_result";
2533
2542
  content: string;
2543
+ type: "tool_result";
2534
2544
  tool_use_id: string;
2535
2545
  cache_control?: {
2536
2546
  type: "ephemeral";
2537
2547
  } | undefined;
2538
2548
  }, {
2539
- type: "tool_result";
2540
2549
  content: string;
2550
+ type: "tool_result";
2541
2551
  tool_use_id: string;
2542
2552
  cache_control?: {
2543
2553
  type: "ephemeral";
@@ -2601,8 +2611,8 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2601
2611
  type: "ephemeral";
2602
2612
  } | undefined;
2603
2613
  } | {
2604
- type: "tool_result";
2605
2614
  content: string;
2615
+ type: "tool_result";
2606
2616
  tool_use_id: string;
2607
2617
  cache_control?: {
2608
2618
  type: "ephemeral";
@@ -2635,8 +2645,8 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2635
2645
  type: "ephemeral";
2636
2646
  } | undefined;
2637
2647
  } | {
2638
- type: "tool_result";
2639
2648
  content: string;
2649
+ type: "tool_result";
2640
2650
  tool_use_id: string;
2641
2651
  cache_control?: {
2642
2652
  type: "ephemeral";
@@ -2700,8 +2710,8 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2700
2710
  type: "ephemeral";
2701
2711
  } | undefined;
2702
2712
  } | {
2703
- type: "tool_result";
2704
2713
  content: string;
2714
+ type: "tool_result";
2705
2715
  tool_use_id: string;
2706
2716
  cache_control?: {
2707
2717
  type: "ephemeral";
@@ -2765,8 +2775,8 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2765
2775
  type: "ephemeral";
2766
2776
  } | undefined;
2767
2777
  } | {
2768
- type: "tool_result";
2769
2778
  content: string;
2779
+ type: "tool_result";
2770
2780
  tool_use_id: string;
2771
2781
  cache_control?: {
2772
2782
  type: "ephemeral";
@@ -2860,8 +2870,8 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2860
2870
  type: "ephemeral";
2861
2871
  } | undefined;
2862
2872
  } | {
2863
- type: "tool_result";
2864
2873
  content: string;
2874
+ type: "tool_result";
2865
2875
  tool_use_id: string;
2866
2876
  cache_control?: {
2867
2877
  type: "ephemeral";
@@ -2939,8 +2949,8 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
2939
2949
  type: "ephemeral";
2940
2950
  } | undefined;
2941
2951
  } | {
2942
- type: "tool_result";
2943
2952
  content: string;
2953
+ type: "tool_result";
2944
2954
  tool_use_id: string;
2945
2955
  cache_control?: {
2946
2956
  type: "ephemeral";
@@ -3005,12 +3015,12 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
3005
3015
  content: z.ZodString;
3006
3016
  }, "strip", z.ZodTypeAny, {
3007
3017
  path: string;
3008
- type: "file" | "patch";
3009
3018
  content: string;
3019
+ type: "file" | "patch";
3010
3020
  }, {
3011
3021
  path: string;
3012
- type: "file" | "patch";
3013
3022
  content: string;
3023
+ type: "file" | "patch";
3014
3024
  }>, "many">;
3015
3025
  changesAlreadyApplied: z.ZodArray<z.ZodObject<{
3016
3026
  type: z.ZodEnum<["patch", "file"]>;
@@ -3018,12 +3028,12 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
3018
3028
  content: z.ZodString;
3019
3029
  }, "strip", z.ZodTypeAny, {
3020
3030
  path: string;
3021
- type: "file" | "patch";
3022
3031
  content: string;
3032
+ type: "file" | "patch";
3023
3033
  }, {
3024
3034
  path: string;
3025
- type: "file" | "patch";
3026
3035
  content: string;
3036
+ type: "file" | "patch";
3027
3037
  }>, "many">;
3028
3038
  addedFileVersions: z.ZodArray<z.ZodObject<{
3029
3039
  path: z.ZodString;
@@ -3047,13 +3057,13 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
3047
3057
  response: string;
3048
3058
  changes: {
3049
3059
  path: string;
3050
- type: "file" | "patch";
3051
3060
  content: string;
3061
+ type: "file" | "patch";
3052
3062
  }[];
3053
3063
  changesAlreadyApplied: {
3054
3064
  path: string;
3055
- type: "file" | "patch";
3056
3065
  content: string;
3066
+ type: "file" | "patch";
3057
3067
  }[];
3058
3068
  addedFileVersions: {
3059
3069
  path: string;
@@ -3071,13 +3081,13 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
3071
3081
  response: string;
3072
3082
  changes: {
3073
3083
  path: string;
3074
- type: "file" | "patch";
3075
3084
  content: string;
3085
+ type: "file" | "patch";
3076
3086
  }[];
3077
3087
  changesAlreadyApplied: {
3078
3088
  path: string;
3079
- type: "file" | "patch";
3080
3089
  content: string;
3090
+ type: "file" | "patch";
3081
3091
  }[];
3082
3092
  addedFileVersions: {
3083
3093
  path: string;
@@ -3217,13 +3227,13 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
3217
3227
  response: string;
3218
3228
  changes: {
3219
3229
  path: string;
3220
- type: "file" | "patch";
3221
3230
  content: string;
3231
+ type: "file" | "patch";
3222
3232
  }[];
3223
3233
  changesAlreadyApplied: {
3224
3234
  path: string;
3225
- type: "file" | "patch";
3226
3235
  content: string;
3236
+ type: "file" | "patch";
3227
3237
  }[];
3228
3238
  addedFileVersions: {
3229
3239
  path: string;
@@ -3287,8 +3297,8 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
3287
3297
  type: "ephemeral";
3288
3298
  } | undefined;
3289
3299
  } | {
3290
- type: "tool_result";
3291
3300
  content: string;
3301
+ type: "tool_result";
3292
3302
  tool_use_id: string;
3293
3303
  cache_control?: {
3294
3304
  type: "ephemeral";
@@ -3337,13 +3347,13 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
3337
3347
  response: string;
3338
3348
  changes: {
3339
3349
  path: string;
3340
- type: "file" | "patch";
3341
3350
  content: string;
3351
+ type: "file" | "patch";
3342
3352
  }[];
3343
3353
  changesAlreadyApplied: {
3344
3354
  path: string;
3345
- type: "file" | "patch";
3346
3355
  content: string;
3356
+ type: "file" | "patch";
3347
3357
  }[];
3348
3358
  addedFileVersions: {
3349
3359
  path: string;
@@ -3391,13 +3401,13 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
3391
3401
  response: string;
3392
3402
  changes: {
3393
3403
  path: string;
3394
- type: "file" | "patch";
3395
3404
  content: string;
3405
+ type: "file" | "patch";
3396
3406
  }[];
3397
3407
  changesAlreadyApplied: {
3398
3408
  path: string;
3399
- type: "file" | "patch";
3400
3409
  content: string;
3410
+ type: "file" | "patch";
3401
3411
  }[];
3402
3412
  addedFileVersions: {
3403
3413
  path: string;
@@ -3461,8 +3471,8 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
3461
3471
  type: "ephemeral";
3462
3472
  } | undefined;
3463
3473
  } | {
3464
- type: "tool_result";
3465
3474
  content: string;
3475
+ type: "tool_result";
3466
3476
  tool_use_id: string;
3467
3477
  cache_control?: {
3468
3478
  type: "ephemeral";
@@ -3511,13 +3521,13 @@ export declare const SERVER_MESSAGE_SCHEMAS: {
3511
3521
  response: string;
3512
3522
  changes: {
3513
3523
  path: string;
3514
- type: "file" | "patch";
3515
3524
  content: string;
3525
+ type: "file" | "patch";
3516
3526
  }[];
3517
3527
  changesAlreadyApplied: {
3518
3528
  path: string;
3519
- type: "file" | "patch";
3520
3529
  content: string;
3530
+ type: "file" | "patch";
3521
3531
  }[];
3522
3532
  addedFileVersions: {
3523
3533
  path: string;
@@ -3584,12 +3594,12 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
3584
3594
  content: z.ZodString;
3585
3595
  }, "strip", z.ZodTypeAny, {
3586
3596
  path: string;
3587
- type: "file" | "patch";
3588
3597
  content: string;
3598
+ type: "file" | "patch";
3589
3599
  }, {
3590
3600
  path: string;
3591
- type: "file" | "patch";
3592
3601
  content: string;
3602
+ type: "file" | "patch";
3593
3603
  }>, "many">;
3594
3604
  changesAlreadyApplied: z.ZodArray<z.ZodObject<{
3595
3605
  type: z.ZodEnum<["patch", "file"]>;
@@ -3597,12 +3607,12 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
3597
3607
  content: z.ZodString;
3598
3608
  }, "strip", z.ZodTypeAny, {
3599
3609
  path: string;
3600
- type: "file" | "patch";
3601
3610
  content: string;
3611
+ type: "file" | "patch";
3602
3612
  }, {
3603
3613
  path: string;
3604
- type: "file" | "patch";
3605
3614
  content: string;
3615
+ type: "file" | "patch";
3606
3616
  }>, "many">;
3607
3617
  addedFileVersions: z.ZodArray<z.ZodObject<{
3608
3618
  path: z.ZodString;
@@ -3627,13 +3637,13 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
3627
3637
  response: string;
3628
3638
  changes: {
3629
3639
  path: string;
3630
- type: "file" | "patch";
3631
3640
  content: string;
3641
+ type: "file" | "patch";
3632
3642
  }[];
3633
3643
  changesAlreadyApplied: {
3634
3644
  path: string;
3635
- type: "file" | "patch";
3636
3645
  content: string;
3646
+ type: "file" | "patch";
3637
3647
  }[];
3638
3648
  addedFileVersions: {
3639
3649
  path: string;
@@ -3651,13 +3661,13 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
3651
3661
  response: string;
3652
3662
  changes: {
3653
3663
  path: string;
3654
- type: "file" | "patch";
3655
3664
  content: string;
3665
+ type: "file" | "patch";
3656
3666
  }[];
3657
3667
  changesAlreadyApplied: {
3658
3668
  path: string;
3659
- type: "file" | "patch";
3660
3669
  content: string;
3670
+ type: "file" | "patch";
3661
3671
  }[];
3662
3672
  addedFileVersions: {
3663
3673
  path: string;
@@ -3847,15 +3857,15 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
3847
3857
  type: "ephemeral";
3848
3858
  }>>;
3849
3859
  }, "strip", z.ZodTypeAny, {
3850
- type: "tool_result";
3851
3860
  content: string;
3861
+ type: "tool_result";
3852
3862
  tool_use_id: string;
3853
3863
  cache_control?: {
3854
3864
  type: "ephemeral";
3855
3865
  } | undefined;
3856
3866
  }, {
3857
- type: "tool_result";
3858
3867
  content: string;
3868
+ type: "tool_result";
3859
3869
  tool_use_id: string;
3860
3870
  cache_control?: {
3861
3871
  type: "ephemeral";
@@ -3919,8 +3929,8 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
3919
3929
  type: "ephemeral";
3920
3930
  } | undefined;
3921
3931
  } | {
3922
- type: "tool_result";
3923
3932
  content: string;
3933
+ type: "tool_result";
3924
3934
  tool_use_id: string;
3925
3935
  cache_control?: {
3926
3936
  type: "ephemeral";
@@ -3953,8 +3963,8 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
3953
3963
  type: "ephemeral";
3954
3964
  } | undefined;
3955
3965
  } | {
3956
- type: "tool_result";
3957
3966
  content: string;
3967
+ type: "tool_result";
3958
3968
  tool_use_id: string;
3959
3969
  cache_control?: {
3960
3970
  type: "ephemeral";
@@ -4018,8 +4028,8 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4018
4028
  type: "ephemeral";
4019
4029
  } | undefined;
4020
4030
  } | {
4021
- type: "tool_result";
4022
4031
  content: string;
4032
+ type: "tool_result";
4023
4033
  tool_use_id: string;
4024
4034
  cache_control?: {
4025
4035
  type: "ephemeral";
@@ -4083,8 +4093,8 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4083
4093
  type: "ephemeral";
4084
4094
  } | undefined;
4085
4095
  } | {
4086
- type: "tool_result";
4087
4096
  content: string;
4097
+ type: "tool_result";
4088
4098
  tool_use_id: string;
4089
4099
  cache_control?: {
4090
4100
  type: "ephemeral";
@@ -4178,8 +4188,8 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4178
4188
  type: "ephemeral";
4179
4189
  } | undefined;
4180
4190
  } | {
4181
- type: "tool_result";
4182
4191
  content: string;
4192
+ type: "tool_result";
4183
4193
  tool_use_id: string;
4184
4194
  cache_control?: {
4185
4195
  type: "ephemeral";
@@ -4257,8 +4267,8 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4257
4267
  type: "ephemeral";
4258
4268
  } | undefined;
4259
4269
  } | {
4260
- type: "tool_result";
4261
4270
  content: string;
4271
+ type: "tool_result";
4262
4272
  tool_use_id: string;
4263
4273
  cache_control?: {
4264
4274
  type: "ephemeral";
@@ -4323,12 +4333,12 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4323
4333
  content: z.ZodString;
4324
4334
  }, "strip", z.ZodTypeAny, {
4325
4335
  path: string;
4326
- type: "file" | "patch";
4327
4336
  content: string;
4337
+ type: "file" | "patch";
4328
4338
  }, {
4329
4339
  path: string;
4330
- type: "file" | "patch";
4331
4340
  content: string;
4341
+ type: "file" | "patch";
4332
4342
  }>, "many">;
4333
4343
  changesAlreadyApplied: z.ZodArray<z.ZodObject<{
4334
4344
  type: z.ZodEnum<["patch", "file"]>;
@@ -4336,12 +4346,12 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4336
4346
  content: z.ZodString;
4337
4347
  }, "strip", z.ZodTypeAny, {
4338
4348
  path: string;
4339
- type: "file" | "patch";
4340
4349
  content: string;
4350
+ type: "file" | "patch";
4341
4351
  }, {
4342
4352
  path: string;
4343
- type: "file" | "patch";
4344
4353
  content: string;
4354
+ type: "file" | "patch";
4345
4355
  }>, "many">;
4346
4356
  addedFileVersions: z.ZodArray<z.ZodObject<{
4347
4357
  path: z.ZodString;
@@ -4365,13 +4375,13 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4365
4375
  response: string;
4366
4376
  changes: {
4367
4377
  path: string;
4368
- type: "file" | "patch";
4369
4378
  content: string;
4379
+ type: "file" | "patch";
4370
4380
  }[];
4371
4381
  changesAlreadyApplied: {
4372
4382
  path: string;
4373
- type: "file" | "patch";
4374
4383
  content: string;
4384
+ type: "file" | "patch";
4375
4385
  }[];
4376
4386
  addedFileVersions: {
4377
4387
  path: string;
@@ -4389,13 +4399,13 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4389
4399
  response: string;
4390
4400
  changes: {
4391
4401
  path: string;
4392
- type: "file" | "patch";
4393
4402
  content: string;
4403
+ type: "file" | "patch";
4394
4404
  }[];
4395
4405
  changesAlreadyApplied: {
4396
4406
  path: string;
4397
- type: "file" | "patch";
4398
4407
  content: string;
4408
+ type: "file" | "patch";
4399
4409
  }[];
4400
4410
  addedFileVersions: {
4401
4411
  path: string;
@@ -4535,13 +4545,13 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4535
4545
  response: string;
4536
4546
  changes: {
4537
4547
  path: string;
4538
- type: "file" | "patch";
4539
4548
  content: string;
4549
+ type: "file" | "patch";
4540
4550
  }[];
4541
4551
  changesAlreadyApplied: {
4542
4552
  path: string;
4543
- type: "file" | "patch";
4544
4553
  content: string;
4554
+ type: "file" | "patch";
4545
4555
  }[];
4546
4556
  addedFileVersions: {
4547
4557
  path: string;
@@ -4605,8 +4615,8 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4605
4615
  type: "ephemeral";
4606
4616
  } | undefined;
4607
4617
  } | {
4608
- type: "tool_result";
4609
4618
  content: string;
4619
+ type: "tool_result";
4610
4620
  tool_use_id: string;
4611
4621
  cache_control?: {
4612
4622
  type: "ephemeral";
@@ -4655,13 +4665,13 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4655
4665
  response: string;
4656
4666
  changes: {
4657
4667
  path: string;
4658
- type: "file" | "patch";
4659
4668
  content: string;
4669
+ type: "file" | "patch";
4660
4670
  }[];
4661
4671
  changesAlreadyApplied: {
4662
4672
  path: string;
4663
- type: "file" | "patch";
4664
4673
  content: string;
4674
+ type: "file" | "patch";
4665
4675
  }[];
4666
4676
  addedFileVersions: {
4667
4677
  path: string;
@@ -4709,13 +4719,13 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4709
4719
  response: string;
4710
4720
  changes: {
4711
4721
  path: string;
4712
- type: "file" | "patch";
4713
4722
  content: string;
4723
+ type: "file" | "patch";
4714
4724
  }[];
4715
4725
  changesAlreadyApplied: {
4716
4726
  path: string;
4717
- type: "file" | "patch";
4718
4727
  content: string;
4728
+ type: "file" | "patch";
4719
4729
  }[];
4720
4730
  addedFileVersions: {
4721
4731
  path: string;
@@ -4779,8 +4789,8 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4779
4789
  type: "ephemeral";
4780
4790
  } | undefined;
4781
4791
  } | {
4782
- type: "tool_result";
4783
4792
  content: string;
4793
+ type: "tool_result";
4784
4794
  tool_use_id: string;
4785
4795
  cache_control?: {
4786
4796
  type: "ephemeral";
@@ -4829,13 +4839,13 @@ export declare const SERVER_MESSAGE_SCHEMA: z.ZodUnion<[z.ZodObject<{
4829
4839
  response: string;
4830
4840
  changes: {
4831
4841
  path: string;
4832
- type: "file" | "patch";
4833
4842
  content: string;
4843
+ type: "file" | "patch";
4834
4844
  }[];
4835
4845
  changesAlreadyApplied: {
4836
4846
  path: string;
4837
- type: "file" | "patch";
4838
4847
  content: string;
4848
+ type: "file" | "patch";
4839
4849
  }[];
4840
4850
  addedFileVersions: {
4841
4851
  path: string;