@tickernelz/paperclip-pro-adapter-utils 2026.1009.3 → 2026.1010.1

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 (47) hide show
  1. package/dist/types.d.ts +3 -0
  2. package/dist/types.d.ts.map +1 -1
  3. package/node_modules/@agentclientprotocol/sdk/dist/acp.d.ts +1 -1
  4. package/node_modules/@agentclientprotocol/sdk/dist/acp.js +1 -1
  5. package/node_modules/@agentclientprotocol/sdk/dist/acp.js.map +1 -1
  6. package/node_modules/@agentclientprotocol/sdk/dist/schema/guards.gen.d.ts +62 -0
  7. package/node_modules/@agentclientprotocol/sdk/dist/schema/guards.gen.js +94 -1
  8. package/node_modules/@agentclientprotocol/sdk/dist/schema/guards.gen.js.map +1 -1
  9. package/node_modules/@agentclientprotocol/sdk/dist/schema/index.d.ts +1 -1
  10. package/node_modules/@agentclientprotocol/sdk/dist/schema/index.js.map +1 -1
  11. package/node_modules/@agentclientprotocol/sdk/dist/schema/types.gen.d.ts +58 -75
  12. package/node_modules/@agentclientprotocol/sdk/dist/schema/zod.gen.d.ts +680 -1355
  13. package/node_modules/@agentclientprotocol/sdk/dist/schema/zod.gen.js +88 -80
  14. package/node_modules/@agentclientprotocol/sdk/dist/schema/zod.gen.js.map +1 -1
  15. package/node_modules/@agentclientprotocol/sdk/dist/schema-deserialize.d.ts +1 -0
  16. package/node_modules/@agentclientprotocol/sdk/dist/schema-deserialize.js +19 -0
  17. package/node_modules/@agentclientprotocol/sdk/dist/schema-deserialize.js.map +1 -1
  18. package/node_modules/@agentclientprotocol/sdk/dist/v2/acp.d.ts +2 -2
  19. package/node_modules/@agentclientprotocol/sdk/dist/v2/acp.js +1 -1
  20. package/node_modules/@agentclientprotocol/sdk/dist/v2/acp.js.map +1 -1
  21. package/node_modules/@agentclientprotocol/sdk/dist/v2/schema/guards.gen.d.ts +67 -0
  22. package/node_modules/@agentclientprotocol/sdk/dist/v2/schema/guards.gen.js +158 -15
  23. package/node_modules/@agentclientprotocol/sdk/dist/v2/schema/guards.gen.js.map +1 -1
  24. package/node_modules/@agentclientprotocol/sdk/dist/v2/schema/index.d.ts +1 -1
  25. package/node_modules/@agentclientprotocol/sdk/dist/v2/schema/types.gen.d.ts +66 -55
  26. package/node_modules/@agentclientprotocol/sdk/dist/v2/schema/zod.gen.d.ts +656 -870
  27. package/node_modules/@agentclientprotocol/sdk/dist/v2/schema/zod.gen.js +75 -69
  28. package/node_modules/@agentclientprotocol/sdk/dist/v2/schema/zod.gen.js.map +1 -1
  29. package/node_modules/@agentclientprotocol/sdk/package.json +1 -1
  30. package/node_modules/@agentclientprotocol/sdk/schema/schema.json +209 -67
  31. package/node_modules/@agentclientprotocol/sdk/schema/v2/schema.unstable.json +206 -89
  32. package/node_modules/bare-fs/binding.c +1 -1
  33. package/node_modules/bare-fs/package.json +1 -1
  34. package/node_modules/bare-fs/prebuilds/android-arm/bare-fs.bare +0 -0
  35. package/node_modules/bare-fs/prebuilds/android-arm64/bare-fs.bare +0 -0
  36. package/node_modules/bare-fs/prebuilds/android-ia32/bare-fs.bare +0 -0
  37. package/node_modules/bare-fs/prebuilds/android-x64/bare-fs.bare +0 -0
  38. package/node_modules/bare-fs/prebuilds/darwin-arm64/bare-fs.bare +0 -0
  39. package/node_modules/bare-fs/prebuilds/darwin-x64/bare-fs.bare +0 -0
  40. package/node_modules/bare-fs/prebuilds/ios-arm64/bare-fs.bare +0 -0
  41. package/node_modules/bare-fs/prebuilds/ios-arm64-simulator/bare-fs.bare +0 -0
  42. package/node_modules/bare-fs/prebuilds/ios-x64-simulator/bare-fs.bare +0 -0
  43. package/node_modules/bare-fs/prebuilds/linux-arm64/bare-fs.bare +0 -0
  44. package/node_modules/bare-fs/prebuilds/linux-x64/bare-fs.bare +0 -0
  45. package/node_modules/bare-fs/prebuilds/win32-arm64/bare-fs.bare +0 -0
  46. package/node_modules/bare-fs/prebuilds/win32-x64/bare-fs.bare +0 -0
  47. package/package.json +2 -2
@@ -1,5 +1,5 @@
1
1
  // This file is auto-generated by @hey-api/openapi-ts
2
- import { defaultOnError, excludeKnownTags, preserveCustomPayload, requiredDefaultOnError, vecSkipError, } from "../schema-deserialize.js";
2
+ import { defaultOnError, defaultOnErrorOptionalStringTag, excludeKnownTags, preserveCustomPayload, requiredDefaultOnError, vecSkipError, } from "../schema-deserialize.js";
3
3
  import * as z from "zod/v4";
4
4
  /**
5
5
  * JSON RPC Request Id
@@ -41,20 +41,20 @@ export const zWriteTextFileRequest = z.object({
41
41
  export const zReadTextFileRequest = z.object({
42
42
  sessionId: zSessionId,
43
43
  path: z.string(),
44
- line: defaultOnError(z
44
+ line: z
45
45
  .int()
46
46
  .gte(0)
47
47
  .max(4294967295, {
48
48
  error: "Invalid value: Expected uint32 to be <= 4294967295",
49
49
  })
50
- .nullish(), () => undefined),
51
- limit: defaultOnError(z
50
+ .nullish(),
51
+ limit: z
52
52
  .int()
53
53
  .gte(0)
54
54
  .max(4294967295, {
55
55
  error: "Invalid value: Expected uint32 to be <= 4294967295",
56
56
  })
57
- .nullish(), () => undefined),
57
+ .nullish(),
58
58
  _meta: defaultOnError(z.record(z.string(), z.unknown()).nullish(), () => undefined),
59
59
  });
60
60
  /**
@@ -357,10 +357,10 @@ export const zEnvVariable = z.object({
357
357
  export const zCreateTerminalRequest = z.object({
358
358
  sessionId: zSessionId,
359
359
  command: z.string(),
360
- args: defaultOnError(vecSkipError(z.string()).optional(), () => []),
361
- env: defaultOnError(vecSkipError(zEnvVariable).optional(), () => []),
362
- cwd: defaultOnError(z.string().nullish(), () => undefined),
363
- outputByteLimit: defaultOnError(z.number().nullish(), () => undefined),
360
+ args: z.array(z.string()).optional(),
361
+ env: z.array(zEnvVariable).optional(),
362
+ cwd: z.string().nullish(),
363
+ outputByteLimit: z.number().nullish(),
364
364
  _meta: defaultOnError(z.record(z.string(), z.unknown()).nullish(), () => undefined),
365
365
  });
366
366
  /**
@@ -1037,8 +1037,8 @@ export const zAuthMethodTerminal = z.object({
1037
1037
  id: zAuthMethodId,
1038
1038
  name: z.string(),
1039
1039
  description: defaultOnError(z.string().nullish(), () => undefined),
1040
- args: defaultOnError(vecSkipError(z.string()).optional(), () => []),
1041
- env: defaultOnError(z.record(z.string(), z.string()).optional(), () => undefined),
1040
+ args: z.array(z.string()).optional(),
1041
+ env: z.record(z.string(), z.string()).optional(),
1042
1042
  _meta: defaultOnError(z.record(z.string(), z.unknown()).nullish(), () => undefined),
1043
1043
  });
1044
1044
  /**
@@ -1905,13 +1905,7 @@ export const zUsageUpdate = z.object({
1905
1905
  _meta: defaultOnError(z.record(z.string(), z.unknown()).nullish(), () => undefined),
1906
1906
  });
1907
1907
  /**
1908
- * **UNSTABLE**
1909
- *
1910
- * This capability is not part of the spec yet, and may be removed or changed at any point.
1911
- *
1912
1908
  * Severity hint for a session notice.
1913
- *
1914
- * @experimental
1915
1909
  */
1916
1910
  export const zNoticeSeverity = z.union([
1917
1911
  z.literal("info"),
@@ -1920,11 +1914,7 @@ export const zNoticeSeverity = z.union([
1920
1914
  z.string(),
1921
1915
  ]);
1922
1916
  /**
1923
- * **UNSTABLE**
1924
- *
1925
- * This capability is not part of the spec yet, and may be removed or changed at any point.
1926
- *
1927
- * Fire-and-forget advisory information for the user.
1917
+ * Fire-and-forget information for the user.
1928
1918
  *
1929
1919
  * Notices are live events rather than session history. Agents must not rely on
1930
1920
  * a notice being received, displayed, or seen by the user.
@@ -1933,8 +1923,6 @@ export const zNoticeSeverity = z.union([
1933
1923
  * message when the information should still be surfaced to the user.
1934
1924
  *
1935
1925
  * See RFD: [Session Notices](https://agentclientprotocol.com/rfds/session-notices)
1936
- *
1937
- * @experimental
1938
1926
  */
1939
1927
  export const zNotice = z.object({
1940
1928
  severity: zNoticeSeverity,
@@ -1943,23 +1931,11 @@ export const zNotice = z.object({
1943
1931
  _meta: defaultOnError(z.record(z.string(), z.unknown()).nullish(), () => undefined),
1944
1932
  });
1945
1933
  /**
1946
- * **UNSTABLE**
1947
- *
1948
- * This capability is not part of the spec yet, and may be removed or changed at any point.
1949
- *
1950
1934
  * Unique identifier for a context compaction within a session.
1951
- *
1952
- * @experimental
1953
1935
  */
1954
1936
  export const zCompactionId = z.string();
1955
1937
  /**
1956
- * **UNSTABLE**
1957
- *
1958
- * This capability is not part of the spec yet, and may be removed or changed at any point.
1959
- *
1960
1938
  * Lifecycle state of a context compaction.
1961
- *
1962
- * @experimental
1963
1939
  */
1964
1940
  export const zCompactionStatus = z.union([
1965
1941
  z.literal("in_progress"),
@@ -1969,21 +1945,14 @@ export const zCompactionStatus = z.union([
1969
1945
  z.string(),
1970
1946
  ]);
1971
1947
  /**
1972
- * **UNSTABLE**
1973
- *
1974
- * This capability is not part of the spec yet, and may be removed or changed at any point.
1975
- *
1976
- * A context compaction upsert. The first update fixes the compaction's
1948
+ * A context compaction upsert. The first notification fixes the compaction's
1977
1949
  * timeline position. Later updates with the same ID patch that entity in place.
1978
1950
  * Agents MUST only send this update when the Client advertised
1979
1951
  * [`ClientSessionCapabilities::compaction`].
1980
1952
  *
1981
1953
  * `summary`, `error`, and `_meta` have patch semantics: omission leaves the
1982
1954
  * stored value unchanged, `null` clears it, and a concrete value replaces it.
1983
- * `summary: []` also clears the retained summary. A non-empty summary is only
1984
- * valid with `completed`; `error` is only valid with `failed`.
1985
- *
1986
- * @experimental
1955
+ * `summary: []` also clears the summary.
1987
1956
  */
1988
1957
  export const zCompactionUpdate = z.object({
1989
1958
  compactionId: zCompactionId,
@@ -1993,16 +1962,10 @@ export const zCompactionUpdate = z.object({
1993
1962
  _meta: defaultOnError(z.record(z.string(), z.unknown()).nullish(), () => undefined),
1994
1963
  });
1995
1964
  /**
1996
- * **UNSTABLE**
1997
- *
1998
- * This capability is not part of the spec yet, and may be removed or changed at any point.
1999
- *
2000
- * A content block appended to the retained summary of an in-progress
2001
- * compaction. Agents send chunks only after an `in_progress` update and before
2002
- * the terminal update for the same ID. Agents MUST only send this update when
2003
- * the Client advertised [`ClientSessionCapabilities::compaction`].
2004
- *
2005
- * @experimental
1965
+ * A content block appended to a compaction's summary. A first-seen ID creates
1966
+ * an in-progress compaction. Chunks append in receive order.
1967
+ * Agents MUST only send this update when the Client advertised
1968
+ * [`ClientSessionCapabilities::compaction`].
2006
1969
  */
2007
1970
  export const zCompactionSummaryChunk = z.object({
2008
1971
  compactionId: zCompactionId,
@@ -2045,14 +2008,71 @@ export const zSubagentSessionCapabilities = z.object({
2045
2008
  export const zRunningStateUpdate = z.object({
2046
2009
  _meta: defaultOnError(z.record(z.string(), z.unknown()).nullish(), () => undefined),
2047
2010
  });
2011
+ /**
2012
+ * **UNSTABLE**
2013
+ *
2014
+ * This capability is not part of the spec yet, and may be removed or changed at any point.
2015
+ *
2016
+ * Details of a failure that ended a child's foreground work.
2017
+ *
2018
+ * @experimental
2019
+ */
2020
+ export const zErrorStopReason = z.object({
2021
+ error: defaultOnError(zError.nullish(), () => undefined),
2022
+ });
2048
2023
  /**
2049
2024
  * The child is ready to process another prompt.
2025
+ *
2026
+ * An omitted, `null`, or malformed `stopReason` means not reported.
2027
+ *
2028
+ * Custom variants (unknown `stopReason` values) keep their extra
2029
+ * properties exactly as received; unlike known variants, those keys
2030
+ * bypass lenient-field salvage and arrive unvalidated.
2050
2031
  */
2051
- export const zIdleStateUpdate = z.object({
2052
- stopReason: defaultOnError(zStopReason.nullish(), () => undefined),
2032
+ export const zIdleStateUpdate = defaultOnErrorOptionalStringTag(preserveCustomPayload(z.intersection(z.union([
2033
+ z.object({
2034
+ stopReason: z.literal("end_turn"),
2035
+ }),
2036
+ z.object({
2037
+ stopReason: z.literal("max_tokens"),
2038
+ }),
2039
+ z.object({
2040
+ stopReason: z.literal("max_turn_requests"),
2041
+ }),
2042
+ z.object({
2043
+ stopReason: z.literal("refusal"),
2044
+ }),
2045
+ z.object({
2046
+ stopReason: z.literal("cancelled"),
2047
+ }),
2048
+ zErrorStopReason.and(z.object({
2049
+ stopReason: z.literal("error"),
2050
+ })),
2051
+ excludeKnownTags(z.object({
2052
+ stopReason: z.string(),
2053
+ }), "stopReason", [
2054
+ "cancelled",
2055
+ "end_turn",
2056
+ "error",
2057
+ "max_tokens",
2058
+ "max_turn_requests",
2059
+ "refusal",
2060
+ ]),
2061
+ z.object({
2062
+ stopReason: z.null().optional(),
2063
+ }),
2064
+ ]), z.object({
2053
2065
  usage: defaultOnError(zUsage.nullish(), () => undefined),
2054
2066
  _meta: defaultOnError(z.record(z.string(), z.unknown()).nullish(), () => undefined),
2055
- });
2067
+ stopReason: defaultOnError(z.string().nullish(), () => undefined),
2068
+ })), "stopReason", [
2069
+ "cancelled",
2070
+ "end_turn",
2071
+ "error",
2072
+ "max_tokens",
2073
+ "max_turn_requests",
2074
+ "refusal",
2075
+ ]), "stopReason");
2056
2076
  /**
2057
2077
  * Foreground work is blocked on user action.
2058
2078
  */
@@ -2297,13 +2317,7 @@ export const zFileSystemCapabilities = z.object({
2297
2317
  _meta: defaultOnError(z.record(z.string(), z.unknown()).nullish(), () => undefined),
2298
2318
  });
2299
2319
  /**
2300
- * **UNSTABLE**
2301
- *
2302
- * This capability is not part of the spec yet, and may be removed or changed at any point.
2303
- *
2304
2320
  * Client support for ID-addressed context compaction updates.
2305
- *
2306
- * @experimental
2307
2321
  */
2308
2322
  export const zCompactionCapabilities = z.record(z.string(), z.unknown());
2309
2323
  /**
@@ -2322,13 +2336,7 @@ export const zSessionConfigOptionsCapabilities = z.object({
2322
2336
  _meta: defaultOnError(z.record(z.string(), z.unknown()).nullish(), () => undefined),
2323
2337
  });
2324
2338
  /**
2325
- * **UNSTABLE**
2326
- *
2327
- * This capability is not part of the spec yet, and may be removed or changed at any point.
2328
- *
2329
- * Client support for presenting live advisory notices to the user.
2330
- *
2331
- * @experimental
2339
+ * Client support for presenting live notices to the user.
2332
2340
  */
2333
2341
  export const zNoticeCapabilities = z.record(z.string(), z.unknown());
2334
2342
  /**
@@ -2614,8 +2622,8 @@ export const zMcpServer = z.union([
2614
2622
  */
2615
2623
  export const zNewSessionRequest = z.object({
2616
2624
  cwd: z.string(),
2617
- additionalDirectories: defaultOnError(vecSkipError(z.string()).optional(), () => []),
2618
- mcpServers: requiredDefaultOnError(vecSkipError(zMcpServer), () => []),
2625
+ additionalDirectories: z.array(z.string()).optional(),
2626
+ mcpServers: z.array(zMcpServer),
2619
2627
  _meta: defaultOnError(z.record(z.string(), z.unknown()).nullish(), () => undefined),
2620
2628
  });
2621
2629
  /**
@@ -2626,9 +2634,9 @@ export const zNewSessionRequest = z.object({
2626
2634
  * See protocol docs: [Loading Sessions](https://agentclientprotocol.com/protocol/session-setup#loading-sessions)
2627
2635
  */
2628
2636
  export const zLoadSessionRequest = z.object({
2629
- mcpServers: requiredDefaultOnError(vecSkipError(zMcpServer), () => []),
2637
+ mcpServers: z.array(zMcpServer),
2630
2638
  cwd: z.string(),
2631
- additionalDirectories: defaultOnError(vecSkipError(z.string()).optional(), () => []),
2639
+ additionalDirectories: z.array(z.string()).optional(),
2632
2640
  sessionId: zSessionId,
2633
2641
  _meta: defaultOnError(z.record(z.string(), z.unknown()).nullish(), () => undefined),
2634
2642
  });
@@ -2668,8 +2676,8 @@ export const zDeleteSessionRequest = z.object({
2668
2676
  export const zForkSessionRequest = z.object({
2669
2677
  sessionId: zSessionId,
2670
2678
  cwd: z.string(),
2671
- additionalDirectories: defaultOnError(vecSkipError(z.string()).optional(), () => []),
2672
- mcpServers: defaultOnError(vecSkipError(zMcpServer).optional(), () => []),
2679
+ additionalDirectories: z.array(z.string()).optional(),
2680
+ mcpServers: z.array(zMcpServer).optional(),
2673
2681
  _meta: defaultOnError(z.record(z.string(), z.unknown()).nullish(), () => undefined),
2674
2682
  });
2675
2683
  /**
@@ -2683,8 +2691,8 @@ export const zForkSessionRequest = z.object({
2683
2691
  export const zResumeSessionRequest = z.object({
2684
2692
  sessionId: zSessionId,
2685
2693
  cwd: z.string(),
2686
- additionalDirectories: defaultOnError(vecSkipError(z.string()).optional(), () => []),
2687
- mcpServers: defaultOnError(vecSkipError(zMcpServer).optional(), () => []),
2694
+ additionalDirectories: z.array(z.string()).optional(),
2695
+ mcpServers: z.array(zMcpServer).optional(),
2688
2696
  _meta: defaultOnError(z.record(z.string(), z.unknown()).nullish(), () => undefined),
2689
2697
  });
2690
2698
  /**
@@ -3155,7 +3163,7 @@ export const zDidChangeDocumentNotification = z.object({
3155
3163
  sessionId: zSessionId,
3156
3164
  uri: z.string(),
3157
3165
  version: z.number(),
3158
- contentChanges: requiredDefaultOnError(vecSkipError(zTextDocumentContentChangeEvent), () => []),
3166
+ contentChanges: z.array(zTextDocumentContentChangeEvent),
3159
3167
  _meta: defaultOnError(z.record(z.string(), z.unknown()).nullish(), () => undefined),
3160
3168
  });
3161
3169
  /**