codebuff 1.0.288 → 1.0.289

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 (42) hide show
  1. package/dist/cli-handlers/checkpoint.d.ts +1 -1
  2. package/dist/cli.d.ts +2 -1
  3. package/dist/cli.js +2 -3
  4. package/dist/cli.js.map +1 -1
  5. package/dist/client.d.ts +1 -4
  6. package/dist/client.js +3 -4
  7. package/dist/client.js.map +1 -1
  8. package/dist/common/actions.d.ts +60 -60
  9. package/dist/common/types/agent-state.d.ts +8 -8
  10. package/dist/common/types/message.d.ts +6 -6
  11. package/dist/common/types/usage.d.ts +2 -2
  12. package/dist/common/util/credentials.d.ts +2 -2
  13. package/dist/common/websockets/websocket-schema.d.ts +112 -112
  14. package/dist/index.js +8 -2
  15. package/dist/slash-commands.d.ts +7 -0
  16. package/dist/slash-commands.js +21 -0
  17. package/dist/slash-commands.js.map +1 -0
  18. package/dist/utils/spinner.js +1 -1
  19. package/package.json +1 -1
  20. package/dist/common/__tests__/project-file-tree.test.d.ts +0 -1
  21. package/dist/common/__tests__/project-file-tree.test.js +0 -251
  22. package/dist/common/__tests__/project-file-tree.test.js.map +0 -1
  23. package/dist/common/json-config/__tests__/__snapshots__/stringify-schema.test.js.snap +0 -119
  24. package/dist/common/util/process-stream.d.ts +0 -7
  25. package/dist/common/util/process-stream.js +0 -162
  26. package/dist/common/util/process-stream.js.map +0 -1
  27. package/dist/readline.d.ts +0 -22
  28. package/dist/readline.js +0 -180
  29. package/dist/readline.js.map +0 -1
  30. package/dist/utils/__tests__/__snapshots__/background-process-manager.test.js.snap +0 -137
  31. package/dist/utils/__tests__/file-paths.test.d.ts +0 -1
  32. package/dist/utils/__tests__/file-paths.test.js +0 -37
  33. package/dist/utils/__tests__/file-paths.test.js.map +0 -1
  34. package/dist/utils/__tests__/path.test.d.ts +0 -1
  35. package/dist/utils/__tests__/path.test.js +0 -37
  36. package/dist/utils/__tests__/path.test.js.map +0 -1
  37. package/dist/utils/file-paths.d.ts +0 -9
  38. package/dist/utils/file-paths.js +0 -24
  39. package/dist/utils/file-paths.js.map +0 -1
  40. package/dist/utils/path.d.ts +0 -9
  41. package/dist/utils/path.js +0 -27
  42. package/dist/utils/path.js.map +0 -1
@@ -5,12 +5,12 @@ export declare const FileChangeSchema: z.ZodObject<{
5
5
  content: z.ZodString;
6
6
  }, "strip", z.ZodTypeAny, {
7
7
  content: string;
8
- type: "patch" | "file";
9
8
  path: string;
9
+ type: "patch" | "file";
10
10
  }, {
11
11
  content: string;
12
- type: "patch" | "file";
13
12
  path: string;
13
+ type: "patch" | "file";
14
14
  }>;
15
15
  export type FileChange = z.infer<typeof FileChangeSchema>;
16
16
  export declare const CHANGES: z.ZodArray<z.ZodObject<{
@@ -19,12 +19,12 @@ export declare const CHANGES: z.ZodArray<z.ZodObject<{
19
19
  content: z.ZodString;
20
20
  }, "strip", z.ZodTypeAny, {
21
21
  content: string;
22
- type: "patch" | "file";
23
22
  path: string;
23
+ type: "patch" | "file";
24
24
  }, {
25
25
  content: string;
26
- type: "patch" | "file";
27
26
  path: string;
27
+ type: "patch" | "file";
28
28
  }>, "many">;
29
29
  export type FileChanges = z.infer<typeof CHANGES>;
30
30
  export declare const ToolCallSchema: z.ZodObject<{
@@ -246,13 +246,13 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
246
246
  media_type: z.ZodLiteral<"image/jpeg">;
247
247
  data: z.ZodString;
248
248
  }, "strip", z.ZodTypeAny, {
249
+ data: string;
249
250
  type: "base64";
250
251
  media_type: "image/jpeg";
251
- data: string;
252
252
  }, {
253
+ data: string;
253
254
  type: "base64";
254
255
  media_type: "image/jpeg";
255
- data: string;
256
256
  }>;
257
257
  cache_control: z.ZodOptional<z.ZodObject<{
258
258
  type: z.ZodLiteral<"ephemeral">;
@@ -264,9 +264,9 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
264
264
  }, "strip", z.ZodTypeAny, {
265
265
  type: "image";
266
266
  source: {
267
+ data: string;
267
268
  type: "base64";
268
269
  media_type: "image/jpeg";
269
- data: string;
270
270
  };
271
271
  cache_control?: {
272
272
  type: "ephemeral";
@@ -274,9 +274,9 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
274
274
  }, {
275
275
  type: "image";
276
276
  source: {
277
+ data: string;
277
278
  type: "base64";
278
279
  media_type: "image/jpeg";
279
- data: string;
280
280
  };
281
281
  cache_control?: {
282
282
  type: "ephemeral";
@@ -307,9 +307,9 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
307
307
  } | {
308
308
  type: "image";
309
309
  source: {
310
+ data: string;
310
311
  type: "base64";
311
312
  media_type: "image/jpeg";
312
- data: string;
313
313
  };
314
314
  cache_control?: {
315
315
  type: "ephemeral";
@@ -341,9 +341,9 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
341
341
  } | {
342
342
  type: "image";
343
343
  source: {
344
+ data: string;
344
345
  type: "base64";
345
346
  media_type: "image/jpeg";
346
- data: string;
347
347
  };
348
348
  cache_control?: {
349
349
  type: "ephemeral";
@@ -407,9 +407,9 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
407
407
  } | {
408
408
  type: "image";
409
409
  source: {
410
+ data: string;
410
411
  type: "base64";
411
412
  media_type: "image/jpeg";
412
- data: string;
413
413
  };
414
414
  cache_control?: {
415
415
  type: "ephemeral";
@@ -473,9 +473,9 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
473
473
  } | {
474
474
  type: "image";
475
475
  source: {
476
+ data: string;
476
477
  type: "base64";
477
478
  media_type: "image/jpeg";
478
- data: string;
479
479
  };
480
480
  cache_control?: {
481
481
  type: "ephemeral";
@@ -560,9 +560,9 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
560
560
  } | {
561
561
  type: "image";
562
562
  source: {
563
+ data: string;
563
564
  type: "base64";
564
565
  media_type: "image/jpeg";
565
- data: string;
566
566
  };
567
567
  cache_control?: {
568
568
  type: "ephemeral";
@@ -640,9 +640,9 @@ export declare const CLIENT_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
640
640
  } | {
641
641
  type: "image";
642
642
  source: {
643
+ data: string;
643
644
  type: "base64";
644
645
  media_type: "image/jpeg";
645
- data: string;
646
646
  };
647
647
  cache_control?: {
648
648
  type: "ephemeral";
@@ -929,12 +929,12 @@ export declare const ResponseCompleteSchema: z.ZodObject<z.objectUtil.extendShap
929
929
  content: z.ZodString;
930
930
  }, "strip", z.ZodTypeAny, {
931
931
  content: string;
932
- type: "patch" | "file";
933
932
  path: string;
933
+ type: "patch" | "file";
934
934
  }, {
935
935
  content: string;
936
- type: "patch" | "file";
937
936
  path: string;
937
+ type: "patch" | "file";
938
938
  }>, "many">;
939
939
  changesAlreadyApplied: z.ZodArray<z.ZodObject<{
940
940
  type: z.ZodEnum<["patch", "file"]>;
@@ -942,12 +942,12 @@ export declare const ResponseCompleteSchema: z.ZodObject<z.objectUtil.extendShap
942
942
  content: z.ZodString;
943
943
  }, "strip", z.ZodTypeAny, {
944
944
  content: string;
945
- type: "patch" | "file";
946
945
  path: string;
946
+ type: "patch" | "file";
947
947
  }, {
948
948
  content: string;
949
- type: "patch" | "file";
950
949
  path: string;
950
+ type: "patch" | "file";
951
951
  }>, "many">;
952
952
  addedFileVersions: z.ZodArray<z.ZodObject<{
953
953
  path: z.ZodString;
@@ -972,13 +972,13 @@ export declare const ResponseCompleteSchema: z.ZodObject<z.objectUtil.extendShap
972
972
  response: string;
973
973
  changes: {
974
974
  content: string;
975
- type: "patch" | "file";
976
975
  path: string;
976
+ type: "patch" | "file";
977
977
  }[];
978
978
  changesAlreadyApplied: {
979
979
  content: string;
980
- type: "patch" | "file";
981
980
  path: string;
981
+ type: "patch" | "file";
982
982
  }[];
983
983
  addedFileVersions: {
984
984
  content: string;
@@ -996,13 +996,13 @@ export declare const ResponseCompleteSchema: z.ZodObject<z.objectUtil.extendShap
996
996
  response: string;
997
997
  changes: {
998
998
  content: string;
999
- type: "patch" | "file";
1000
999
  path: string;
1000
+ type: "patch" | "file";
1001
1001
  }[];
1002
1002
  changesAlreadyApplied: {
1003
1003
  content: string;
1004
- type: "patch" | "file";
1005
1004
  path: string;
1005
+ type: "patch" | "file";
1006
1006
  }[];
1007
1007
  addedFileVersions: {
1008
1008
  content: string;
@@ -1230,13 +1230,13 @@ export declare const PromptResponseSchema: z.ZodObject<{
1230
1230
  media_type: z.ZodLiteral<"image/jpeg">;
1231
1231
  data: z.ZodString;
1232
1232
  }, "strip", z.ZodTypeAny, {
1233
+ data: string;
1233
1234
  type: "base64";
1234
1235
  media_type: "image/jpeg";
1235
- data: string;
1236
1236
  }, {
1237
+ data: string;
1237
1238
  type: "base64";
1238
1239
  media_type: "image/jpeg";
1239
- data: string;
1240
1240
  }>;
1241
1241
  cache_control: z.ZodOptional<z.ZodObject<{
1242
1242
  type: z.ZodLiteral<"ephemeral">;
@@ -1248,9 +1248,9 @@ export declare const PromptResponseSchema: z.ZodObject<{
1248
1248
  }, "strip", z.ZodTypeAny, {
1249
1249
  type: "image";
1250
1250
  source: {
1251
+ data: string;
1251
1252
  type: "base64";
1252
1253
  media_type: "image/jpeg";
1253
- data: string;
1254
1254
  };
1255
1255
  cache_control?: {
1256
1256
  type: "ephemeral";
@@ -1258,9 +1258,9 @@ export declare const PromptResponseSchema: z.ZodObject<{
1258
1258
  }, {
1259
1259
  type: "image";
1260
1260
  source: {
1261
+ data: string;
1261
1262
  type: "base64";
1262
1263
  media_type: "image/jpeg";
1263
- data: string;
1264
1264
  };
1265
1265
  cache_control?: {
1266
1266
  type: "ephemeral";
@@ -1291,9 +1291,9 @@ export declare const PromptResponseSchema: z.ZodObject<{
1291
1291
  } | {
1292
1292
  type: "image";
1293
1293
  source: {
1294
+ data: string;
1294
1295
  type: "base64";
1295
1296
  media_type: "image/jpeg";
1296
- data: string;
1297
1297
  };
1298
1298
  cache_control?: {
1299
1299
  type: "ephemeral";
@@ -1325,9 +1325,9 @@ export declare const PromptResponseSchema: z.ZodObject<{
1325
1325
  } | {
1326
1326
  type: "image";
1327
1327
  source: {
1328
+ data: string;
1328
1329
  type: "base64";
1329
1330
  media_type: "image/jpeg";
1330
- data: string;
1331
1331
  };
1332
1332
  cache_control?: {
1333
1333
  type: "ephemeral";
@@ -1391,9 +1391,9 @@ export declare const PromptResponseSchema: z.ZodObject<{
1391
1391
  } | {
1392
1392
  type: "image";
1393
1393
  source: {
1394
+ data: string;
1394
1395
  type: "base64";
1395
1396
  media_type: "image/jpeg";
1396
- data: string;
1397
1397
  };
1398
1398
  cache_control?: {
1399
1399
  type: "ephemeral";
@@ -1457,9 +1457,9 @@ export declare const PromptResponseSchema: z.ZodObject<{
1457
1457
  } | {
1458
1458
  type: "image";
1459
1459
  source: {
1460
+ data: string;
1460
1461
  type: "base64";
1461
1462
  media_type: "image/jpeg";
1462
- data: string;
1463
1463
  };
1464
1464
  cache_control?: {
1465
1465
  type: "ephemeral";
@@ -1553,9 +1553,9 @@ export declare const PromptResponseSchema: z.ZodObject<{
1553
1553
  } | {
1554
1554
  type: "image";
1555
1555
  source: {
1556
+ data: string;
1556
1557
  type: "base64";
1557
1558
  media_type: "image/jpeg";
1558
- data: string;
1559
1559
  };
1560
1560
  cache_control?: {
1561
1561
  type: "ephemeral";
@@ -1633,9 +1633,9 @@ export declare const PromptResponseSchema: z.ZodObject<{
1633
1633
  } | {
1634
1634
  type: "image";
1635
1635
  source: {
1636
+ data: string;
1636
1637
  type: "base64";
1637
1638
  media_type: "image/jpeg";
1638
- data: string;
1639
1639
  };
1640
1640
  cache_control?: {
1641
1641
  type: "ephemeral";
@@ -1679,12 +1679,12 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
1679
1679
  content: z.ZodString;
1680
1680
  }, "strip", z.ZodTypeAny, {
1681
1681
  content: string;
1682
- type: "patch" | "file";
1683
1682
  path: string;
1683
+ type: "patch" | "file";
1684
1684
  }, {
1685
1685
  content: string;
1686
- type: "patch" | "file";
1687
1686
  path: string;
1687
+ type: "patch" | "file";
1688
1688
  }>, "many">;
1689
1689
  changesAlreadyApplied: z.ZodArray<z.ZodObject<{
1690
1690
  type: z.ZodEnum<["patch", "file"]>;
@@ -1692,12 +1692,12 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
1692
1692
  content: z.ZodString;
1693
1693
  }, "strip", z.ZodTypeAny, {
1694
1694
  content: string;
1695
- type: "patch" | "file";
1696
1695
  path: string;
1696
+ type: "patch" | "file";
1697
1697
  }, {
1698
1698
  content: string;
1699
- type: "patch" | "file";
1700
1699
  path: string;
1700
+ type: "patch" | "file";
1701
1701
  }>, "many">;
1702
1702
  addedFileVersions: z.ZodArray<z.ZodObject<{
1703
1703
  path: z.ZodString;
@@ -1722,13 +1722,13 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
1722
1722
  response: string;
1723
1723
  changes: {
1724
1724
  content: string;
1725
- type: "patch" | "file";
1726
1725
  path: string;
1726
+ type: "patch" | "file";
1727
1727
  }[];
1728
1728
  changesAlreadyApplied: {
1729
1729
  content: string;
1730
- type: "patch" | "file";
1731
1730
  path: string;
1731
+ type: "patch" | "file";
1732
1732
  }[];
1733
1733
  addedFileVersions: {
1734
1734
  content: string;
@@ -1746,13 +1746,13 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
1746
1746
  response: string;
1747
1747
  changes: {
1748
1748
  content: string;
1749
- type: "patch" | "file";
1750
1749
  path: string;
1750
+ type: "patch" | "file";
1751
1751
  }[];
1752
1752
  changesAlreadyApplied: {
1753
1753
  content: string;
1754
- type: "patch" | "file";
1755
1754
  path: string;
1755
+ type: "patch" | "file";
1756
1756
  }[];
1757
1757
  addedFileVersions: {
1758
1758
  content: string;
@@ -1965,13 +1965,13 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
1965
1965
  media_type: z.ZodLiteral<"image/jpeg">;
1966
1966
  data: z.ZodString;
1967
1967
  }, "strip", z.ZodTypeAny, {
1968
+ data: string;
1968
1969
  type: "base64";
1969
1970
  media_type: "image/jpeg";
1970
- data: string;
1971
1971
  }, {
1972
+ data: string;
1972
1973
  type: "base64";
1973
1974
  media_type: "image/jpeg";
1974
- data: string;
1975
1975
  }>;
1976
1976
  cache_control: z.ZodOptional<z.ZodObject<{
1977
1977
  type: z.ZodLiteral<"ephemeral">;
@@ -1983,9 +1983,9 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
1983
1983
  }, "strip", z.ZodTypeAny, {
1984
1984
  type: "image";
1985
1985
  source: {
1986
+ data: string;
1986
1987
  type: "base64";
1987
1988
  media_type: "image/jpeg";
1988
- data: string;
1989
1989
  };
1990
1990
  cache_control?: {
1991
1991
  type: "ephemeral";
@@ -1993,9 +1993,9 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
1993
1993
  }, {
1994
1994
  type: "image";
1995
1995
  source: {
1996
+ data: string;
1996
1997
  type: "base64";
1997
1998
  media_type: "image/jpeg";
1998
- data: string;
1999
1999
  };
2000
2000
  cache_control?: {
2001
2001
  type: "ephemeral";
@@ -2026,9 +2026,9 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
2026
2026
  } | {
2027
2027
  type: "image";
2028
2028
  source: {
2029
+ data: string;
2029
2030
  type: "base64";
2030
2031
  media_type: "image/jpeg";
2031
- data: string;
2032
2032
  };
2033
2033
  cache_control?: {
2034
2034
  type: "ephemeral";
@@ -2060,9 +2060,9 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
2060
2060
  } | {
2061
2061
  type: "image";
2062
2062
  source: {
2063
+ data: string;
2063
2064
  type: "base64";
2064
2065
  media_type: "image/jpeg";
2065
- data: string;
2066
2066
  };
2067
2067
  cache_control?: {
2068
2068
  type: "ephemeral";
@@ -2126,9 +2126,9 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
2126
2126
  } | {
2127
2127
  type: "image";
2128
2128
  source: {
2129
+ data: string;
2129
2130
  type: "base64";
2130
2131
  media_type: "image/jpeg";
2131
- data: string;
2132
2132
  };
2133
2133
  cache_control?: {
2134
2134
  type: "ephemeral";
@@ -2192,9 +2192,9 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
2192
2192
  } | {
2193
2193
  type: "image";
2194
2194
  source: {
2195
+ data: string;
2195
2196
  type: "base64";
2196
2197
  media_type: "image/jpeg";
2197
- data: string;
2198
2198
  };
2199
2199
  cache_control?: {
2200
2200
  type: "ephemeral";
@@ -2288,9 +2288,9 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
2288
2288
  } | {
2289
2289
  type: "image";
2290
2290
  source: {
2291
+ data: string;
2291
2292
  type: "base64";
2292
2293
  media_type: "image/jpeg";
2293
- data: string;
2294
2294
  };
2295
2295
  cache_control?: {
2296
2296
  type: "ephemeral";
@@ -2368,9 +2368,9 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
2368
2368
  } | {
2369
2369
  type: "image";
2370
2370
  source: {
2371
+ data: string;
2371
2372
  type: "base64";
2372
2373
  media_type: "image/jpeg";
2373
- data: string;
2374
2374
  };
2375
2375
  cache_control?: {
2376
2376
  type: "ephemeral";
@@ -2425,12 +2425,12 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
2425
2425
  content: z.ZodString;
2426
2426
  }, "strip", z.ZodTypeAny, {
2427
2427
  content: string;
2428
- type: "patch" | "file";
2429
2428
  path: string;
2429
+ type: "patch" | "file";
2430
2430
  }, {
2431
2431
  content: string;
2432
- type: "patch" | "file";
2433
2432
  path: string;
2433
+ type: "patch" | "file";
2434
2434
  }>, "many">;
2435
2435
  changesAlreadyApplied: z.ZodArray<z.ZodObject<{
2436
2436
  type: z.ZodEnum<["patch", "file"]>;
@@ -2438,12 +2438,12 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
2438
2438
  content: z.ZodString;
2439
2439
  }, "strip", z.ZodTypeAny, {
2440
2440
  content: string;
2441
- type: "patch" | "file";
2442
2441
  path: string;
2442
+ type: "patch" | "file";
2443
2443
  }, {
2444
2444
  content: string;
2445
- type: "patch" | "file";
2446
2445
  path: string;
2446
+ type: "patch" | "file";
2447
2447
  }>, "many">;
2448
2448
  addedFileVersions: z.ZodArray<z.ZodObject<{
2449
2449
  path: z.ZodString;
@@ -2457,23 +2457,23 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
2457
2457
  }>, "many">;
2458
2458
  resetFileVersions: z.ZodBoolean;
2459
2459
  }, "strip", z.ZodTypeAny, {
2460
- type: "tool-call";
2461
2460
  data: {
2462
2461
  name: string;
2463
2462
  id: string;
2464
2463
  input: Record<string, any>;
2465
2464
  };
2465
+ type: "tool-call";
2466
2466
  userInputId: string;
2467
2467
  response: string;
2468
2468
  changes: {
2469
2469
  content: string;
2470
- type: "patch" | "file";
2471
2470
  path: string;
2471
+ type: "patch" | "file";
2472
2472
  }[];
2473
2473
  changesAlreadyApplied: {
2474
2474
  content: string;
2475
- type: "patch" | "file";
2476
2475
  path: string;
2476
+ type: "patch" | "file";
2477
2477
  }[];
2478
2478
  addedFileVersions: {
2479
2479
  content: string;
@@ -2481,23 +2481,23 @@ export declare const SERVER_ACTION_SCHEMA: z.ZodDiscriminatedUnion<"type", [z.Zo
2481
2481
  }[];
2482
2482
  resetFileVersions: boolean;
2483
2483
  }, {
2484
- type: "tool-call";
2485
2484
  data: {
2486
2485
  name: string;
2487
2486
  id: string;
2488
2487
  input: Record<string, any>;
2489
2488
  };
2489
+ type: "tool-call";
2490
2490
  userInputId: string;
2491
2491
  response: string;
2492
2492
  changes: {
2493
2493
  content: string;
2494
- type: "patch" | "file";
2495
2494
  path: string;
2495
+ type: "patch" | "file";
2496
2496
  }[];
2497
2497
  changesAlreadyApplied: {
2498
2498
  content: string;
2499
- type: "patch" | "file";
2500
2499
  path: string;
2500
+ type: "patch" | "file";
2501
2501
  }[];
2502
2502
  addedFileVersions: {
2503
2503
  content: string;
@@ -6,12 +6,12 @@ export declare const ToolCallSchema: z.ZodObject<{
6
6
  id: z.ZodString;
7
7
  }, "strip", z.ZodTypeAny, {
8
8
  name: string;
9
- parameters: Record<string, string>;
10
9
  id: string;
10
+ parameters: Record<string, string>;
11
11
  }, {
12
12
  name: string;
13
- parameters: Record<string, string>;
14
13
  id: string;
14
+ parameters: Record<string, string>;
15
15
  }>;
16
16
  export type ToolCall = z.infer<typeof ToolCallSchema>;
17
17
  export declare const ToolResultSchema: z.ZodObject<{
@@ -206,15 +206,15 @@ export declare const AgentStateSchema: z.ZodObject<{
206
206
  type: "ephemeral";
207
207
  }>>;
208
208
  }, "strip", z.ZodTypeAny, {
209
- content: string;
210
209
  type: "tool_result";
210
+ content: string;
211
211
  tool_use_id: string;
212
212
  cache_control?: {
213
213
  type: "ephemeral";
214
214
  } | undefined;
215
215
  }, {
216
- content: string;
217
216
  type: "tool_result";
217
+ content: string;
218
218
  tool_use_id: string;
219
219
  cache_control?: {
220
220
  type: "ephemeral";
@@ -278,8 +278,8 @@ export declare const AgentStateSchema: z.ZodObject<{
278
278
  type: "ephemeral";
279
279
  } | undefined;
280
280
  } | {
281
- content: string;
282
281
  type: "tool_result";
282
+ content: string;
283
283
  tool_use_id: string;
284
284
  cache_control?: {
285
285
  type: "ephemeral";
@@ -312,8 +312,8 @@ export declare const AgentStateSchema: z.ZodObject<{
312
312
  type: "ephemeral";
313
313
  } | undefined;
314
314
  } | {
315
- content: string;
316
315
  type: "tool_result";
316
+ content: string;
317
317
  tool_use_id: string;
318
318
  cache_control?: {
319
319
  type: "ephemeral";
@@ -378,8 +378,8 @@ export declare const AgentStateSchema: z.ZodObject<{
378
378
  type: "ephemeral";
379
379
  } | undefined;
380
380
  } | {
381
- content: string;
382
381
  type: "tool_result";
382
+ content: string;
383
383
  tool_use_id: string;
384
384
  cache_control?: {
385
385
  type: "ephemeral";
@@ -444,8 +444,8 @@ export declare const AgentStateSchema: z.ZodObject<{
444
444
  type: "ephemeral";
445
445
  } | undefined;
446
446
  } | {
447
- content: string;
448
447
  type: "tool_result";
448
+ content: string;
449
449
  tool_use_id: string;
450
450
  cache_control?: {
451
451
  type: "ephemeral";
@@ -61,15 +61,15 @@ declare const MessageContentObjectSchema: z.ZodUnion<[z.ZodObject<{
61
61
  type: "ephemeral";
62
62
  }>>;
63
63
  }, "strip", z.ZodTypeAny, {
64
- content: string;
65
64
  type: "tool_result";
65
+ content: string;
66
66
  tool_use_id: string;
67
67
  cache_control?: {
68
68
  type: "ephemeral";
69
69
  } | undefined;
70
70
  }, {
71
- content: string;
72
71
  type: "tool_result";
72
+ content: string;
73
73
  tool_use_id: string;
74
74
  cache_control?: {
75
75
  type: "ephemeral";
@@ -181,15 +181,15 @@ export declare const MessageSchema: z.ZodObject<{
181
181
  type: "ephemeral";
182
182
  }>>;
183
183
  }, "strip", z.ZodTypeAny, {
184
- content: string;
185
184
  type: "tool_result";
185
+ content: string;
186
186
  tool_use_id: string;
187
187
  cache_control?: {
188
188
  type: "ephemeral";
189
189
  } | undefined;
190
190
  }, {
191
- content: string;
192
191
  type: "tool_result";
192
+ content: string;
193
193
  tool_use_id: string;
194
194
  cache_control?: {
195
195
  type: "ephemeral";
@@ -253,8 +253,8 @@ export declare const MessageSchema: z.ZodObject<{
253
253
  type: "ephemeral";
254
254
  } | undefined;
255
255
  } | {
256
- content: string;
257
256
  type: "tool_result";
257
+ content: string;
258
258
  tool_use_id: string;
259
259
  cache_control?: {
260
260
  type: "ephemeral";
@@ -287,8 +287,8 @@ export declare const MessageSchema: z.ZodObject<{
287
287
  type: "ephemeral";
288
288
  } | undefined;
289
289
  } | {
290
- content: string;
291
290
  type: "tool_result";
291
+ content: string;
292
292
  tool_use_id: string;
293
293
  cache_control?: {
294
294
  type: "ephemeral";
@@ -19,22 +19,22 @@ export declare const usageDataSchema: z.ZodObject<{
19
19
  }>;
20
20
  nextQuotaReset: z.ZodNullable<z.ZodDate>;
21
21
  }, "strip", z.ZodTypeAny, {
22
- usageThisCycle: number;
23
22
  balance: {
24
23
  totalRemaining: number;
25
24
  totalDebt: number;
26
25
  netBalance: number;
27
26
  breakdown: Partial<Record<"free" | "referral" | "purchase" | "admin", number>>;
28
27
  };
28
+ usageThisCycle: number;
29
29
  nextQuotaReset: Date | null;
30
30
  }, {
31
- usageThisCycle: number;
32
31
  balance: {
33
32
  totalRemaining: number;
34
33
  totalDebt: number;
35
34
  netBalance: number;
36
35
  breakdown: Partial<Record<"free" | "referral" | "purchase" | "admin", number>>;
37
36
  };
37
+ usageThisCycle: number;
38
38
  nextQuotaReset: Date | null;
39
39
  }>;
40
40
  export type UsageData = z.infer<typeof usageDataSchema>;