stitchkit 0.100.2 → 0.100.3

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 (225) hide show
  1. package/CHANGELOG.md +86 -0
  2. package/README.md +2 -1
  3. package/dist/entrypoints/agent-runtime/browser.js +119 -119
  4. package/dist/entrypoints/agent-runtime/coding-tools.js +15 -20
  5. package/dist/entrypoints/agent-runtime/harness.js +55 -63
  6. package/dist/entrypoints/agent-runtime/openrouter.js +6 -6
  7. package/dist/entrypoints/agent-runtime/sandbox.js +20 -25
  8. package/dist/entrypoints/agent-runtime/sqlite/bun.js +11 -13
  9. package/dist/entrypoints/agent-runtime/sqlite/node.js +11 -13
  10. package/dist/entrypoints/agent-runtime/testing.js +32 -34
  11. package/dist/entrypoints/agent-runtime.js +395 -402
  12. package/dist/entrypoints/application/diagnostic-journal.js +26 -27
  13. package/dist/entrypoints/application/directory-inbox.js +16 -17
  14. package/dist/entrypoints/application/grammy.js +13 -13
  15. package/dist/entrypoints/application/opentelemetry.js +13 -13
  16. package/dist/entrypoints/application/schemas.js +24 -24
  17. package/dist/entrypoints/application.js +208 -210
  18. package/dist/entrypoints/bin/upgrade-cli.js +2 -2
  19. package/dist/entrypoints/cli.js +81 -84
  20. package/dist/entrypoints/contract.js +54 -57
  21. package/dist/entrypoints/declaration.js +22 -22
  22. package/dist/entrypoints/files.js +18 -21
  23. package/dist/entrypoints/geo.js +7 -8
  24. package/dist/entrypoints/google.js +2 -2
  25. package/dist/entrypoints/index.js +150 -154
  26. package/dist/entrypoints/live.js +45 -47
  27. package/dist/entrypoints/node.js +68 -74
  28. package/dist/entrypoints/oauth.js +6 -6
  29. package/dist/entrypoints/observability.d.ts +1 -0
  30. package/dist/entrypoints/observability.d.ts.map +1 -1
  31. package/dist/entrypoints/observability.js +115 -87
  32. package/dist/entrypoints/primitives.js +35 -35
  33. package/dist/entrypoints/react/keyboard.d.ts +4 -0
  34. package/dist/entrypoints/react/keyboard.d.ts.map +1 -0
  35. package/dist/entrypoints/react/keyboard.js +397 -0
  36. package/dist/entrypoints/react.js +10 -10
  37. package/dist/entrypoints/release.js +7 -7
  38. package/dist/entrypoints/remote.js +15 -17
  39. package/dist/entrypoints/server.js +198 -200
  40. package/dist/entrypoints/telegram/html.d.ts +5 -0
  41. package/dist/entrypoints/telegram/html.d.ts.map +1 -0
  42. package/dist/entrypoints/telegram/html.js +26 -0
  43. package/dist/entrypoints/telegram/screens.d.ts +14 -0
  44. package/dist/entrypoints/telegram/screens.d.ts.map +1 -0
  45. package/dist/entrypoints/telegram/screens.js +2028 -0
  46. package/dist/entrypoints/telegram.d.ts +5 -1
  47. package/dist/entrypoints/telegram.d.ts.map +1 -1
  48. package/dist/entrypoints/telegram.js +548 -156
  49. package/dist/entrypoints/testing.js +75 -79
  50. package/dist/entrypoints/tools/connections.js +30 -32
  51. package/dist/entrypoints/tools/contract.js +18 -20
  52. package/dist/entrypoints/tools/invoker.js +12 -17
  53. package/dist/entrypoints/tools.js +223 -229
  54. package/dist/entrypoints/tracking/server.js +6 -6
  55. package/dist/entrypoints/tracking.js +40 -42
  56. package/dist/entrypoints/voice.js +3 -3
  57. package/dist/{index-eaysmdtq.js → index-0ndk4555.js} +56 -56
  58. package/dist/{index-2bxbyab0.js → index-1bx1xv1k.js} +1 -1
  59. package/dist/{index-p5r7qpdd.js → index-1eeqpadm.js} +4 -4
  60. package/dist/{index-hadmp193.js → index-3ct7hhq6.js} +210 -210
  61. package/dist/{index-e01r054k.js → index-45tdvqa3.js} +26 -26
  62. package/dist/{index-dce5wxcq.js → index-4s0fep5q.js} +8 -8
  63. package/dist/index-50ejfz75.js +9 -0
  64. package/dist/{index-m9zn6cpq.js → index-5107q189.js} +12 -12
  65. package/dist/{index-sbdmyz75.js → index-5cc6r990.js} +3 -3
  66. package/dist/index-6k1svmjh.js +141 -0
  67. package/dist/{index-c6bxbsnc.js → index-7kxw1awn.js} +2 -2
  68. package/dist/{index-0r0fbk7z.js → index-7z9ym7t8.js} +28 -28
  69. package/dist/{index-p7hgdyhb.js → index-814xpr6d.js} +2 -2
  70. package/dist/{index-gtj3zc53.js → index-8kzct1d6.js} +99 -99
  71. package/dist/{index-1zbbzgfh.js → index-9pw0a51a.js} +4 -4
  72. package/dist/{index-79z7m7dt.js → index-a9pd417t.js} +35 -35
  73. package/dist/{index-ham5sz8m.js → index-aaj97r4y.js} +45 -45
  74. package/dist/{index-s812ycat.js → index-aan6hqb9.js} +3 -3
  75. package/dist/{index-10x2hbx0.js → index-adhgd4pe.js} +44 -44
  76. package/dist/{index-2gxzjvyr.js → index-afjvjyck.js} +23 -23
  77. package/dist/{index-qmy6zq75.js → index-ahvsksw5.js} +16 -16
  78. package/dist/{index-hr4tzbwq.js → index-ap3gqe56.js} +3 -3
  79. package/dist/{index-znfs20ss.js → index-b2bz0kdm.js} +16 -16
  80. package/dist/{index-r066jx76.js → index-c6aagrbd.js} +148 -120
  81. package/dist/{index-k30h66yd.js → index-ck71tbcf.js} +9 -9
  82. package/dist/{index-eqqvgdb3.js → index-ct75c3at.js} +2 -2
  83. package/dist/{index-gw8bmyaj.js → index-djjhhgjk.js} +41 -41
  84. package/dist/{index-8qt2m66q.js → index-dvwj1f43.js} +43 -43
  85. package/dist/{index-fhwqwxe0.js → index-ej331hah.js} +1 -1
  86. package/dist/{index-9t3dffv2.js → index-ewbaywk5.js} +5 -5
  87. package/dist/{index-7p1f0vp2.js → index-fyphpknh.js} +25 -25
  88. package/dist/{index-83bdg97s.js → index-g149e9pk.js} +1 -1
  89. package/dist/{index-ngfhvfpd.js → index-g6a3na27.js} +4 -4
  90. package/dist/{index-qwhynv6x.js → index-h124epcf.js} +20 -20
  91. package/dist/{index-h6eeys1v.js → index-h97tqqp1.js} +9 -9
  92. package/dist/{index-zcgf3gqf.js → index-hby4qhax.js} +10 -10
  93. package/dist/{index-5jrd0yng.js → index-j8aw2c0e.js} +4 -4
  94. package/dist/{index-d8m8zpd8.js → index-jzczzcsb.js} +14 -14
  95. package/dist/index-kqnd6a85.js +26 -0
  96. package/dist/{index-35mh5bhj.js → index-kw1ws0cs.js} +12 -12
  97. package/dist/{index-yw4fzmdz.js → index-kzz6rq0w.js} +28 -17
  98. package/dist/{index-4gcnakhx.js → index-m38ej7e5.js} +2 -2
  99. package/dist/{index-ndddxtyx.js → index-m79yr938.js} +19 -19
  100. package/dist/{index-5p2m7we1.js → index-m9fndta6.js} +11 -11
  101. package/dist/index-mnkk1ffz.js +150 -0
  102. package/dist/index-n15jny5b.js +4 -0
  103. package/dist/{index-2vtcmrj9.js → index-n53mswt3.js} +20 -20
  104. package/dist/{index-bt14acb5.js → index-n5yqxd3d.js} +21 -21
  105. package/dist/{index-bm5rx7n6.js → index-n9tyz8z3.js} +12 -12
  106. package/dist/index-nmaqxdx7.js +463 -0
  107. package/dist/{index-mqv3b5rh.js → index-nx6eazt0.js} +30 -30
  108. package/dist/{index-3z73fh2c.js → index-q0th8q0z.js} +9 -9
  109. package/dist/{index-v260df89.js → index-qjeggp8w.js} +20 -20
  110. package/dist/{index-zfrhfn82.js → index-r1z0rd9c.js} +20 -20
  111. package/dist/{index-wqgjfstn.js → index-r5c4fedv.js} +3 -3
  112. package/dist/{index-cyktc4bp.js → index-r5hsgkz5.js} +118 -118
  113. package/dist/{index-0b1ess5e.js → index-r7a7r7ha.js} +1 -1
  114. package/dist/{index-1j8pm5t0.js → index-rfkh44ss.js} +15 -15
  115. package/dist/index-rz3z13e9.js +47 -0
  116. package/dist/{index-k6gpggb9.js → index-s80awwsw.js} +35 -35
  117. package/dist/{index-vqr7f7v8.js → index-ssmd41kh.js} +124 -124
  118. package/dist/{index-ensd0r74.js → index-v14qqmys.js} +41 -41
  119. package/dist/{index-paz6sgdp.js → index-v4a2fjtk.js} +36 -36
  120. package/dist/{index-d9pk3td4.js → index-w0eqdhyd.js} +14 -14
  121. package/dist/{index-5qn1kx34.js → index-w575evhq.js} +29 -29
  122. package/dist/{index-3gye9wzb.js → index-w5s3xftz.js} +26 -26
  123. package/dist/{index-tm88avnj.js → index-wykebpn9.js} +3 -3
  124. package/dist/{index-sh3s86na.js → index-xkhk5d6g.js} +17 -17
  125. package/dist/{index-6k1937bx.js → index-xqhede6x.js} +4 -4
  126. package/dist/{index-f4fx2tza.js → index-zs4ms3th.js} +181 -181
  127. package/dist/{index-k5hsfc3j.js → index-zsvzhjtk.js} +1 -1
  128. package/dist/observability/bounded-logger.d.ts +2 -0
  129. package/dist/observability/bounded-logger.d.ts.map +1 -1
  130. package/dist/observability/sanitize.d.ts +6 -0
  131. package/dist/observability/sanitize.d.ts.map +1 -1
  132. package/dist/observability/secret-values.d.ts +25 -0
  133. package/dist/observability/secret-values.d.ts.map +1 -0
  134. package/dist/react/keyboard/hooks.d.ts +71 -0
  135. package/dist/react/keyboard/hooks.d.ts.map +1 -0
  136. package/dist/react/keyboard/layers.d.ts +98 -0
  137. package/dist/react/keyboard/layers.d.ts.map +1 -0
  138. package/dist/react/keyboard/zone.d.ts +139 -0
  139. package/dist/react/keyboard/zone.d.ts.map +1 -0
  140. package/dist/telegram/crypto.d.ts +16 -0
  141. package/dist/telegram/crypto.d.ts.map +1 -0
  142. package/dist/telegram/html/check.d.ts +26 -0
  143. package/dist/telegram/html/check.d.ts.map +1 -0
  144. package/dist/telegram/html/nodes.d.ts +70 -0
  145. package/dist/telegram/html/nodes.d.ts.map +1 -0
  146. package/dist/telegram/html/parse.d.ts +35 -0
  147. package/dist/telegram/html/parse.d.ts.map +1 -0
  148. package/dist/telegram/html/render.d.ts +39 -0
  149. package/dist/telegram/html/render.d.ts.map +1 -0
  150. package/dist/telegram/init-data.d.ts.map +1 -1
  151. package/dist/telegram/operator-channel.d.ts +36 -3
  152. package/dist/telegram/operator-channel.d.ts.map +1 -1
  153. package/dist/telegram/screens/callback-codec.d.ts +34 -0
  154. package/dist/telegram/screens/callback-codec.d.ts.map +1 -0
  155. package/dist/telegram/screens/dispatch.d.ts +22 -0
  156. package/dist/telegram/screens/dispatch.d.ts.map +1 -0
  157. package/dist/telegram/screens/display.d.ts +70 -0
  158. package/dist/telegram/screens/display.d.ts.map +1 -0
  159. package/dist/telegram/screens/execute.d.ts +57 -0
  160. package/dist/telegram/screens/execute.d.ts.map +1 -0
  161. package/dist/telegram/screens/html.d.ts +36 -0
  162. package/dist/telegram/screens/html.d.ts.map +1 -0
  163. package/dist/telegram/screens/outcome.d.ts +74 -0
  164. package/dist/telegram/screens/outcome.d.ts.map +1 -0
  165. package/dist/telegram/screens/path.d.ts +29 -0
  166. package/dist/telegram/screens/path.d.ts.map +1 -0
  167. package/dist/telegram/screens/reconcile.d.ts +67 -0
  168. package/dist/telegram/screens/reconcile.d.ts.map +1 -0
  169. package/dist/telegram/screens/registry.d.ts +23 -0
  170. package/dist/telegram/screens/registry.d.ts.map +1 -0
  171. package/dist/telegram/screens/render.d.ts +70 -0
  172. package/dist/telegram/screens/render.d.ts.map +1 -0
  173. package/dist/telegram/screens/runtime.d.ts +133 -0
  174. package/dist/telegram/screens/runtime.d.ts.map +1 -0
  175. package/dist/telegram/screens/screen-types.d.ts +130 -0
  176. package/dist/telegram/screens/screen-types.d.ts.map +1 -0
  177. package/dist/telegram/screens/screen.d.ts +138 -0
  178. package/dist/telegram/screens/screen.d.ts.map +1 -0
  179. package/dist/telegram/screens/state.d.ts +115 -0
  180. package/dist/telegram/screens/state.d.ts.map +1 -0
  181. package/dist/telegram/screens/telegram-screens.d.ts +18 -0
  182. package/dist/telegram/screens/telegram-screens.d.ts.map +1 -0
  183. package/dist/telegram/screens/test-chat-telegram.d.ts +47 -0
  184. package/dist/telegram/screens/test-chat-telegram.d.ts.map +1 -0
  185. package/dist/telegram/screens/test-chat.d.ts +66 -0
  186. package/dist/telegram/screens/test-chat.d.ts.map +1 -0
  187. package/dist/telegram/screens/view.d.ts +89 -0
  188. package/dist/telegram/screens/view.d.ts.map +1 -0
  189. package/dist/telegram/send-failure.d.ts +19 -0
  190. package/dist/telegram/send-failure.d.ts.map +1 -1
  191. package/dist/telegram/update-intake.d.ts +78 -0
  192. package/dist/telegram/update-intake.d.ts.map +1 -0
  193. package/dist/telegram/update-store-sqlite.d.ts +26 -0
  194. package/dist/telegram/update-store-sqlite.d.ts.map +1 -0
  195. package/dist/telegram/update-store.d.ts +67 -0
  196. package/dist/telegram/update-store.d.ts.map +1 -0
  197. package/dist/telegram/webhook.d.ts +105 -0
  198. package/dist/telegram/webhook.d.ts.map +1 -0
  199. package/dist/tools/cli/args-fields.d.ts +8 -0
  200. package/dist/tools/cli/args-fields.d.ts.map +1 -1
  201. package/dist/tools/cli/args-route.d.ts.map +1 -1
  202. package/dist/tools/cli/args.d.ts.map +1 -1
  203. package/dist/tools/cli/help.d.ts.map +1 -1
  204. package/llms/cli.txt +8 -2
  205. package/llms/observability.txt +2 -1
  206. package/llms/react-keyboard.txt +193 -0
  207. package/llms/stitchkit.txt +7 -1
  208. package/llms/telegram-html.txt +35 -0
  209. package/llms/telegram-screens.txt +365 -0
  210. package/llms/telegram.txt +160 -4
  211. package/llms-full.txt +736 -8
  212. package/llms.txt +10 -5
  213. package/package.json +17 -2
  214. package/dist/index-2k4yrqkc.js +0 -9
  215. package/dist/index-crykmqkr.js +0 -26
  216. package/dist/index-y64k3s0h.js +0 -150
  217. package/dist/index-y91ry9h2.js +0 -4
  218. /package/dist/{index-hffjpmq9.js → index-9jfdm5tg.js} +0 -0
  219. /package/dist/{index-zjjyynm3.js → index-d4pa2bgs.js} +0 -0
  220. /package/dist/{index-rxfy4cq7.js → index-dwfv9a85.js} +0 -0
  221. /package/dist/{index-5jm36zv1.js → index-gfk7nrht.js} +0 -0
  222. /package/dist/{index-b9aefrqd.js → index-n1dqr7gf.js} +0 -0
  223. /package/dist/{index-q3pyb9n0.js → index-sykb5ag7.js} +0 -0
  224. /package/dist/{index-48ffdxgk.js → index-xhzq2qvj.js} +0 -0
  225. /package/dist/{index-kzfs85xp.js → index-zsarb5xp.js} +0 -0
@@ -1,21 +1,21 @@
1
1
  import {
2
2
  isRecord
3
- } from "./index-hffjpmq9.js";
3
+ } from "./index-9jfdm5tg.js";
4
4
 
5
5
  // src/application/diagnostic-journal-contract.ts
6
6
  import { z } from "zod";
7
7
  var PositiveSafeIntegerSchema = z.number().int().positive().safe();
8
8
  var FileModeSchema = z.number().int().min(0).max(511);
9
- var DiagnosticJournalLimitsSchema = z.object({
9
+ var DiagnosticJournalLimitsSchema2 = z.object({
10
10
  maxEventBytes: PositiveSafeIntegerSchema,
11
11
  maxPendingItems: PositiveSafeIntegerSchema,
12
12
  maxPendingBytes: PositiveSafeIntegerSchema,
13
13
  maxFileBytes: PositiveSafeIntegerSchema,
14
14
  maxFiles: PositiveSafeIntegerSchema
15
15
  }).strict().readonly();
16
- var DiagnosticJournalLockPolicySchema = z.enum(["refuse", "reclaim-stale"]);
17
- var DiagnosticJournalStateSchema = z.enum(["open", "draining", "closed", "failed"]);
18
- var DiagnosticJournalRefusalReasonSchema = z.enum([
16
+ var DiagnosticJournalLockPolicySchema2 = z.enum(["refuse", "reclaim-stale"]);
17
+ var DiagnosticJournalStateSchema2 = z.enum(["open", "draining", "closed", "failed"]);
18
+ var DiagnosticJournalRefusalReasonSchema2 = z.enum([
19
19
  "closed",
20
20
  "failed",
21
21
  "invalid",
@@ -31,13 +31,13 @@ var DiagnosticJournalRefusalCountersSchema = z.object({
31
31
  "item-capacity": z.number().int().nonnegative(),
32
32
  "byte-capacity": z.number().int().nonnegative()
33
33
  }).strict().readonly();
34
- var DiagnosticJournalFailurePhaseSchema = z.enum(["write", "rotation", "close"]);
35
- var DiagnosticJournalStatusSchema = z.object({
36
- state: DiagnosticJournalStateSchema,
34
+ var DiagnosticJournalFailurePhaseSchema2 = z.enum(["write", "rotation", "close"]);
35
+ var DiagnosticJournalStatusSchema2 = z.object({
36
+ state: DiagnosticJournalStateSchema2,
37
37
  epoch: z.uuid(),
38
- limits: DiagnosticJournalLimitsSchema,
38
+ limits: DiagnosticJournalLimitsSchema2,
39
39
  lock: z.object({
40
- policy: DiagnosticJournalLockPolicySchema,
40
+ policy: DiagnosticJournalLockPolicySchema2,
41
41
  reclaimedStale: z.boolean()
42
42
  }).strict().readonly(),
43
43
  received: z.number().int().nonnegative(),
@@ -58,11 +58,11 @@ var DiagnosticJournalStatusSchema = z.object({
58
58
  lastWrittenSequence: z.number().int().positive().optional(),
59
59
  lastSettledSequence: z.number().int().positive().optional(),
60
60
  lastFailure: z.object({
61
- phase: DiagnosticJournalFailurePhaseSchema,
61
+ phase: DiagnosticJournalFailurePhaseSchema2,
62
62
  sequence: z.number().int().positive().optional()
63
63
  }).strict().readonly().optional()
64
64
  }).strict().readonly();
65
- var DiagnosticJournalSubmitResultSchema = z.discriminatedUnion("outcome", [
65
+ var DiagnosticJournalSubmitResultSchema2 = z.discriminatedUnion("outcome", [
66
66
  z.object({
67
67
  outcome: z.literal("accepted"),
68
68
  epoch: z.uuid(),
@@ -70,21 +70,21 @@ var DiagnosticJournalSubmitResultSchema = z.discriminatedUnion("outcome", [
70
70
  }).strict().readonly(),
71
71
  z.object({
72
72
  outcome: z.literal("refused"),
73
- reason: DiagnosticJournalRefusalReasonSchema
73
+ reason: DiagnosticJournalRefusalReasonSchema2
74
74
  }).strict().readonly()
75
75
  ]);
76
- var DiagnosticJournalWaitResultSchema = z.object({
76
+ var DiagnosticJournalWaitResultSchema2 = z.object({
77
77
  outcome: z.enum(["settled", "timed-out", "cancelled"]),
78
- state: DiagnosticJournalStateSchema,
78
+ state: DiagnosticJournalStateSchema2,
79
79
  throughSequence: z.number().int().nonnegative(),
80
80
  settledSequence: z.number().int().nonnegative()
81
81
  }).strict().readonly();
82
- var DiagnosticJournalCloseResultSchema = z.object({
82
+ var DiagnosticJournalCloseResultSchema2 = z.object({
83
83
  outcome: z.enum(["closed", "timed-out", "cancelled"]),
84
- state: DiagnosticJournalStateSchema,
84
+ state: DiagnosticJournalStateSchema2,
85
85
  pendingItems: z.number().int().nonnegative()
86
86
  }).strict().readonly();
87
- var DiagnosticJournalFrameSchema = z.object({
87
+ var DiagnosticJournalFrameSchema2 = z.object({
88
88
  schemaVersion: z.literal(1),
89
89
  epoch: z.uuid(),
90
90
  sequence: z.number().int().positive(),
@@ -93,11 +93,11 @@ var DiagnosticJournalFrameSchema = z.object({
93
93
  function parseDiagnosticJournalMode(mode) {
94
94
  return FileModeSchema.parse(mode ?? 384);
95
95
  }
96
- function readDiagnosticJournalLockDiagnosis(error) {
96
+ function readDiagnosticJournalLockDiagnosis2(error) {
97
97
  if (!isRecord(error))
98
98
  return;
99
99
  const diagnosis = error.journalLock;
100
100
  return isRecord(diagnosis) ? diagnosis : undefined;
101
101
  }
102
102
 
103
- export { DiagnosticJournalLimitsSchema, DiagnosticJournalLockPolicySchema, DiagnosticJournalStateSchema, DiagnosticJournalRefusalReasonSchema, DiagnosticJournalFailurePhaseSchema, DiagnosticJournalStatusSchema, DiagnosticJournalSubmitResultSchema, DiagnosticJournalWaitResultSchema, DiagnosticJournalCloseResultSchema, DiagnosticJournalFrameSchema, parseDiagnosticJournalMode, readDiagnosticJournalLockDiagnosis };
103
+ export { DiagnosticJournalLimitsSchema2, DiagnosticJournalLockPolicySchema2, DiagnosticJournalStateSchema2, DiagnosticJournalRefusalReasonSchema2, DiagnosticJournalFailurePhaseSchema2, DiagnosticJournalStatusSchema2, DiagnosticJournalSubmitResultSchema2, DiagnosticJournalWaitResultSchema2, DiagnosticJournalCloseResultSchema2, DiagnosticJournalFrameSchema2, parseDiagnosticJournalMode, readDiagnosticJournalLockDiagnosis2 };
@@ -1,7 +1,7 @@
1
1
  // src/observability/status.ts
2
2
  import { z } from "zod";
3
3
  var NonNegativeIntegerSchema = z.number().int().nonnegative();
4
- var ObservabilitySinkStatusSchema = z.object({
4
+ var ObservabilitySinkStatusSchema2 = z.object({
5
5
  capacity: NonNegativeIntegerSchema,
6
6
  received: NonNegativeIntegerSchema,
7
7
  accepted: NonNegativeIntegerSchema,
@@ -15,12 +15,12 @@ var ObservabilitySinkStatusSchema = z.object({
15
15
  closed: z.boolean()
16
16
  }).readonly();
17
17
  var ObservabilityStatusObjectSchema = z.object({
18
- request: ObservabilitySinkStatusSchema.optional(),
19
- tools: ObservabilitySinkStatusSchema.optional(),
20
- total: ObservabilitySinkStatusSchema
18
+ request: ObservabilitySinkStatusSchema2.optional(),
19
+ tools: ObservabilitySinkStatusSchema2.optional(),
20
+ total: ObservabilitySinkStatusSchema2
21
21
  });
22
- var ObservabilityStatusSchema = ObservabilityStatusObjectSchema.readonly();
23
- var ObservabilityDrainReportSchema = ObservabilityStatusObjectSchema.extend({
22
+ var ObservabilityStatusSchema2 = ObservabilityStatusObjectSchema.readonly();
23
+ var ObservabilityDrainReportSchema2 = ObservabilityStatusObjectSchema.extend({
24
24
  durationMs: z.number().nonnegative(),
25
25
  drained: z.boolean()
26
26
  }).readonly();
@@ -53,7 +53,7 @@ function aggregateObservabilityStatus(surfaces, closed) {
53
53
  for (const key of SUMMED_STATUS_KEYS)
54
54
  totals[key] += surface[key];
55
55
  }
56
- return ObservabilitySinkStatusSchema.parse({ ...totals, closed });
56
+ return ObservabilitySinkStatusSchema2.parse({ ...totals, closed });
57
57
  }
58
58
 
59
59
  // src/observability/bounded-sink.ts
@@ -192,7 +192,7 @@ function createBoundedSinkManager(config) {
192
192
  }
193
193
  };
194
194
  function getStatus() {
195
- return ObservabilitySinkStatusSchema.parse({
195
+ return ObservabilitySinkStatusSchema2.parse({
196
196
  capacity: maxPending,
197
197
  received,
198
198
  accepted,
@@ -208,4 +208,4 @@ function createBoundedSinkManager(config) {
208
208
  }
209
209
  }
210
210
 
211
- export { ObservabilitySinkStatusSchema, ObservabilityStatusSchema, ObservabilityDrainReportSchema, aggregateObservabilityStatus, assertDrainBound, withinBound, createBoundedSinkManager };
211
+ export { ObservabilitySinkStatusSchema2, ObservabilityStatusSchema2, ObservabilityDrainReportSchema2, aggregateObservabilityStatus, assertDrainBound, withinBound, createBoundedSinkManager };
@@ -10,10 +10,10 @@ function randomHex(bytes) {
10
10
 
11
11
  // src/observability/trace.ts
12
12
  var TRACEPARENT_RE = /^([0-9a-f]{2})-([0-9a-f]{32})-([0-9a-f]{16})-([0-9a-f]{2})(.*)$/i;
13
- function createTraceContext() {
13
+ function createTraceContext2() {
14
14
  return { traceId: randomHex(16), spanId: randomHex(8) };
15
15
  }
16
- function parseTraceparent(header) {
16
+ function parseTraceparent2(header) {
17
17
  if (!header)
18
18
  return null;
19
19
  const match = TRACEPARENT_RE.exec(header.trim());
@@ -33,13 +33,13 @@ function parseTraceparent(header) {
33
33
  return null;
34
34
  return { traceId, spanId: randomHex(8), parentSpanId, traceFlags };
35
35
  }
36
- function formatTraceparent(ctx) {
36
+ function formatTraceparent2(ctx) {
37
37
  return `00-${ctx.traceId}-${ctx.spanId}-${ctx.traceFlags ?? "01"}`;
38
38
  }
39
- function resolveTraceContext(req) {
40
- return parseTraceparent(req.headers.get("traceparent")) ?? createTraceContext();
39
+ function resolveTraceContext2(req) {
40
+ return parseTraceparent2(req.headers.get("traceparent")) ?? createTraceContext2();
41
41
  }
42
- function childSpan(parent) {
42
+ function childSpan2(parent) {
43
43
  return {
44
44
  traceId: parent.traceId,
45
45
  spanId: randomHex(8),
@@ -67,10 +67,10 @@ function boundedPropagationValue(value, maxBytes, maxMembers) {
67
67
  }
68
68
  return trimmed;
69
69
  }
70
- function resolvePropagationContext(metadata, fallback) {
70
+ function resolvePropagationContext2(metadata, fallback) {
71
71
  const traceparent = metadata?.traceparent;
72
- const parsed = typeof traceparent === "string" ? parseTraceparent(traceparent) : null;
73
- const trace = traceparent === undefined ? fallback ?? createTraceContext() : parsed ?? createTraceContext();
72
+ const parsed = typeof traceparent === "string" ? parseTraceparent2(traceparent) : null;
73
+ const trace = traceparent === undefined ? fallback ?? createTraceContext2() : parsed ?? createTraceContext2();
74
74
  const tracestate = parsed ? boundedPropagationValue(metadata?.tracestate, 512, 32) : undefined;
75
75
  const baggage = boundedPropagationValue(metadata?.baggage, 8192, 180);
76
76
  return {
@@ -80,4 +80,4 @@ function resolvePropagationContext(metadata, fallback) {
80
80
  };
81
81
  }
82
82
 
83
- export { randomHex, createTraceContext, parseTraceparent, formatTraceparent, resolveTraceContext, childSpan, resolvePropagationContext };
83
+ export { randomHex, createTraceContext2, parseTraceparent2, formatTraceparent2, resolveTraceContext2, childSpan2, resolvePropagationContext2 };
@@ -2,12 +2,12 @@
2
2
  import { z } from "zod";
3
3
  var timestamp = z.string().datetime({ offset: true });
4
4
  var key = z.string().min(1).max(255);
5
- var DirectoryInboxRejectionReasonSchema = z.enum([
5
+ var DirectoryInboxRejectionReasonSchema2 = z.enum([
6
6
  "invalid",
7
7
  "too-large",
8
8
  "attempt-limit"
9
9
  ]);
10
- var DirectoryInboxStateSchema = z.object({
10
+ var DirectoryInboxStateSchema2 = z.object({
11
11
  schemaVersion: z.literal(1),
12
12
  claims: z.array(z.object({
13
13
  key,
@@ -19,7 +19,7 @@ var DirectoryInboxStateSchema = z.object({
19
19
  receipts: z.array(z.object({ key, completedAt: timestamp }).strict()),
20
20
  rejected: z.array(z.object({
21
21
  key,
22
- reason: DirectoryInboxRejectionReasonSchema,
22
+ reason: DirectoryInboxRejectionReasonSchema2,
23
23
  detail: z.string().max(1000),
24
24
  rejectedAt: timestamp
25
25
  }).strict())
@@ -111,4 +111,4 @@ function forgetMissing(state, present, now) {
111
111
  };
112
112
  }
113
113
 
114
- export { DirectoryInboxRejectionReasonSchema, DirectoryInboxStateSchema, emptyDirectoryInboxState, withRejection, claimEntry, completeEntry, releaseEntry, forgetMissing };
114
+ export { DirectoryInboxRejectionReasonSchema2, DirectoryInboxStateSchema2, emptyDirectoryInboxState, withRejection, claimEntry, completeEntry, releaseEntry, forgetMissing };
@@ -1,15 +1,15 @@
1
1
  import {
2
2
  projectRuntimeTool
3
- } from "./index-0r0fbk7z.js";
3
+ } from "./index-7z9ym7t8.js";
4
4
 
5
5
  // src/tools/runtime-tool.ts
6
- function defineRuntimeTool(definition) {
6
+ function defineRuntimeTool2(definition) {
7
7
  if (definition.transports?.length === 0) {
8
8
  throw new Error(`Runtime tool "${definition.name}" must expose at least one transport`);
9
9
  }
10
10
  return definition;
11
11
  }
12
- function createRuntimeToolFactory(config) {
12
+ function createRuntimeToolFactory2(config) {
13
13
  function parseContext(context) {
14
14
  const parsed = config.context.parse(context);
15
15
  return {
@@ -22,18 +22,18 @@ function createRuntimeToolFactory(config) {
22
22
  }
23
23
  function define(definition) {
24
24
  if (definition.output !== undefined) {
25
- const { action: action2, method: method2, meta: meta2, handler: handler2, ...tool2 } = definition;
26
- const identity2 = {
25
+ const { action, method, meta, handler, ...tool } = definition;
26
+ const identity = {
27
27
  serviceName: config.serviceName,
28
- action: action2,
29
- method: method2,
28
+ action,
29
+ method,
30
30
  ...config.scope !== undefined && { scope: config.scope },
31
- ...(meta2 ?? config.meta) !== undefined && { meta: meta2 ?? config.meta }
31
+ ...(meta ?? config.meta) !== undefined && { meta: meta ?? config.meta }
32
32
  };
33
- return defineRuntimeTool({
34
- ...tool2,
35
- identity: identity2,
36
- handler: (context) => handler2(parseContext(context))
33
+ return defineRuntimeTool2({
34
+ ...tool,
35
+ identity,
36
+ handler: (context) => handler(parseContext(context))
37
37
  });
38
38
  }
39
39
  const { action, method, meta, handler, ...tool } = definition;
@@ -44,7 +44,7 @@ function createRuntimeToolFactory(config) {
44
44
  ...config.scope !== undefined && { scope: config.scope },
45
45
  ...(meta ?? config.meta) !== undefined && { meta: meta ?? config.meta }
46
46
  };
47
- return defineRuntimeTool({
47
+ return defineRuntimeTool2({
48
48
  ...tool,
49
49
  identity,
50
50
  handler: (context) => handler(parseContext(context))
@@ -97,4 +97,4 @@ function executableAgentRuntimeTools(tools) {
97
97
  return tools;
98
98
  }
99
99
 
100
- export { defineRuntimeTool, createRuntimeToolFactory, runtimeToolMountable, executableAgentRuntimeTools };
100
+ export { defineRuntimeTool2, createRuntimeToolFactory2, runtimeToolMountable, executableAgentRuntimeTools };
@@ -0,0 +1,26 @@
1
+ import {
2
+ AgentRecordIdSchema2,
3
+ AgentRecordVersionSchema2,
4
+ AgentMessageSchema2
5
+ } from "./index-8kzct1d6.js";
6
+
7
+ // src/agent-runtime/conversations.ts
8
+ import { z } from "zod";
9
+ var AgentConversationSummarySchema2 = z.object({
10
+ conversationId: AgentRecordIdSchema2,
11
+ version: AgentRecordVersionSchema2,
12
+ updatedAt: z.iso.datetime({ offset: true }),
13
+ preview: z.string(),
14
+ activeRuns: z.int().nonnegative()
15
+ }).strict();
16
+ var AgentConversationPageSchema2 = z.object({
17
+ items: z.array(AgentConversationSummarySchema2),
18
+ nextCursor: z.string().min(1).optional()
19
+ }).strict();
20
+ var AgentConversationMessagePageSchema2 = z.object({
21
+ items: z.array(AgentMessageSchema2),
22
+ compacted: z.array(z.string().min(1)),
23
+ nextCursor: z.string().min(1).optional()
24
+ }).strict();
25
+
26
+ export { AgentConversationSummarySchema2, AgentConversationPageSchema2, AgentConversationMessagePageSchema2 };
@@ -1,23 +1,23 @@
1
1
  import {
2
2
  isUnsafeKey
3
- } from "./index-kzfs85xp.js";
3
+ } from "./index-zsarb5xp.js";
4
4
  import {
5
5
  isRecord
6
- } from "./index-hffjpmq9.js";
6
+ } from "./index-9jfdm5tg.js";
7
7
 
8
8
  // src/internal/request.ts
9
- function generateTraceId() {
9
+ function generateTraceId2() {
10
10
  return `${Date.now().toString(36)}-${crypto.randomUUID().slice(0, 8)}`;
11
11
  }
12
- function resolveTraceId(req) {
12
+ function resolveTraceId2(req) {
13
13
  const header = req.headers.get("x-request-id") ?? req.headers.get("x-trace-id");
14
14
  const trimmed = header?.trim();
15
15
  if (trimmed && trimmed.length <= 128 && /^[\w.-]+$/.test(trimmed)) {
16
16
  return trimmed;
17
17
  }
18
- return generateTraceId();
18
+ return generateTraceId2();
19
19
  }
20
- function resolveSocketIp(req, server) {
20
+ function resolveSocketIp2(req, server) {
21
21
  if (typeof server === "object" && server !== null && "requestIP" in server && typeof server.requestIP === "function") {
22
22
  const addr = server.requestIP(req);
23
23
  if (isRecord(addr) && typeof addr.address === "string" && addr.address) {
@@ -28,7 +28,7 @@ function resolveSocketIp(req, server) {
28
28
  return req.ip;
29
29
  return;
30
30
  }
31
- function extractIp(req, options = {}) {
31
+ function extractIp2(req, options = {}) {
32
32
  if (options.trustProxy) {
33
33
  const forwarded = req.headers.get("x-forwarded-for");
34
34
  if (forwarded)
@@ -39,9 +39,9 @@ function extractIp(req, options = {}) {
39
39
  }
40
40
  return (options.socketIp ?? "").replace(/^::ffff:/, "");
41
41
  }
42
- function getClientInfo(req, options = {}) {
42
+ function getClientInfo2(req, options = {}) {
43
43
  return {
44
- ipAddress: extractIp(req, options) || undefined,
44
+ ipAddress: extractIp2(req, options) || undefined,
45
45
  userAgent: req.headers.get("user-agent") ?? undefined
46
46
  };
47
47
  }
@@ -145,7 +145,7 @@ function hasPrefix(bytes, prefix, bits) {
145
145
  }
146
146
  return true;
147
147
  }
148
- function isPublicIp(value) {
148
+ function isPublicIp2(value) {
149
149
  const address = value.trim();
150
150
  if (!address)
151
151
  return false;
@@ -163,7 +163,7 @@ function isPublicIp(value) {
163
163
  if (!bytes)
164
164
  return false;
165
165
  if (hasPrefix(bytes, [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 255, 255], 96)) {
166
- return isPublicIp(Array.from(bytes.slice(12)).join("."));
166
+ return isPublicIp2(Array.from(bytes.slice(12)).join("."));
167
167
  }
168
168
  if (!hasPrefix(bytes, [32], 3))
169
169
  return false;
@@ -174,4 +174,4 @@ function isPublicIp(value) {
174
174
  return true;
175
175
  }
176
176
 
177
- export { generateTraceId, resolveTraceId, resolveSocketIp, extractIp, getClientInfo, parseQueryParams, isPublicIp };
177
+ export { generateTraceId2, resolveTraceId2, resolveSocketIp2, extractIp2, getClientInfo2, parseQueryParams, isPublicIp2 };
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  isUnsafeKey
3
- } from "./index-kzfs85xp.js";
3
+ } from "./index-zsarb5xp.js";
4
4
  import {
5
5
  isRecord
6
- } from "./index-hffjpmq9.js";
6
+ } from "./index-9jfdm5tg.js";
7
7
 
8
8
  // src/observability/sanitize.ts
9
9
  var SENSITIVE_WORDS = new Set([
@@ -53,7 +53,23 @@ var DEFAULT_MAX_BYTES = 16000;
53
53
  var DEFAULT_MAX_DEPTH = 20;
54
54
  var DEFAULT_MAX_NODES = 20000;
55
55
  var MASK = "[redacted]";
56
- function redact(value, options = {}) {
56
+ function secretMasker(options) {
57
+ const values = [...options.sensitiveValues ?? []].filter((value) => value !== "").sort((left, right) => right.length - left.length);
58
+ const patterns = options.sensitiveUrlPatterns ?? [];
59
+ return (input) => {
60
+ let output = input;
61
+ for (const value of values)
62
+ output = output.replaceAll(value, MASK);
63
+ for (const pattern of patterns) {
64
+ try {
65
+ const global = new RegExp(pattern.source, `${pattern.flags.replace(/[gy]/g, "")}g`);
66
+ output = output.replace(global, MASK);
67
+ } catch {}
68
+ }
69
+ return output;
70
+ };
71
+ }
72
+ function redact2(value, options = {}) {
57
73
  const custom = options.sensitiveKeys;
58
74
  const isSensitive = custom === undefined ? isSensitiveKeyDefault : (key) => {
59
75
  custom.lastIndex = 0;
@@ -85,15 +101,10 @@ function redact(value, options = {}) {
85
101
  const byKey = key === undefined ? undefined : options.maxStringLengthByKey?.[key];
86
102
  return byKey ?? maxStringLength;
87
103
  };
104
+ const mask = secretMasker(options);
88
105
  const safeString = (input, key) => {
89
106
  const bound = stringBoundFor(key);
90
- let output = input;
91
- for (const pattern of options.sensitiveUrlPatterns ?? []) {
92
- try {
93
- const global = new RegExp(pattern.source, `${pattern.flags.replace(/[gy]/g, "")}g`);
94
- output = output.replace(global, MASK);
95
- } catch {}
96
- }
107
+ const output = mask(input);
97
108
  if (output.length <= bound)
98
109
  return output;
99
110
  return `${output.slice(0, Math.max(0, bound))}…[truncated]`;
@@ -128,12 +139,12 @@ function redact(value, options = {}) {
128
139
  return "[circular]";
129
140
  ancestors.add(input);
130
141
  const entries = [...input.entries()];
131
- const result = entries.slice(0, maxCollectionLength).map(([key, value2]) => {
142
+ const result = entries.slice(0, maxCollectionLength).map(([key, value]) => {
132
143
  const segment = typeof key === "string" ? key : String(key);
133
144
  const childPath = [...path, segment];
134
145
  return [
135
146
  walk(key, depth + 1, [...path, "[key]"]),
136
- typeof key === "string" && isSensitive(key) || isSensitivePath(childPath) ? MASK : walk(value2, depth + 1, childPath)
147
+ typeof key === "string" && isSensitive(key) || isSensitivePath(childPath) ? MASK : walk(value, depth + 1, childPath)
137
148
  ];
138
149
  });
139
150
  if (entries.length > maxCollectionLength)
@@ -222,7 +233,7 @@ function redact(value, options = {}) {
222
233
  };
223
234
  return walk(value, 0);
224
235
  }
225
- function truncatePreview(value, maxBytes = DEFAULT_MAX_BYTES) {
236
+ function truncatePreview2(value, maxBytes = DEFAULT_MAX_BYTES) {
226
237
  const json = JSON.stringify(value);
227
238
  const bytes = new TextEncoder().encode(json);
228
239
  if (bytes.byteLength <= maxBytes)
@@ -237,16 +248,16 @@ function truncatePreview(value, maxBytes = DEFAULT_MAX_BYTES) {
237
248
  preview: `${preview}…`
238
249
  };
239
250
  }
240
- function sanitizePayload(value, options = {}) {
251
+ function sanitizePayload2(value, options = {}) {
241
252
  if (value === undefined || value === null)
242
253
  return null;
243
254
  try {
244
- return truncatePreview(redact(value, options), options.maxBytes ?? DEFAULT_MAX_BYTES);
255
+ return truncatePreview2(redact2(value, options), options.maxBytes ?? DEFAULT_MAX_BYTES);
245
256
  } catch {
246
257
  return "[unserializable]";
247
258
  }
248
259
  }
249
- function measureSize(value) {
260
+ function measureSize2(value) {
250
261
  if (value === undefined || value === null) {
251
262
  return { resultSize: null, responseBytes: 0 };
252
263
  }
@@ -265,4 +276,4 @@ function measureSize(value) {
265
276
  return { resultSize: null, responseBytes };
266
277
  }
267
278
 
268
- export { redact, truncatePreview, sanitizePayload, measureSize };
279
+ export { redact2, truncatePreview2, sanitizePayload2, measureSize2 };
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  isUnsafeKey
3
- } from "./index-kzfs85xp.js";
3
+ } from "./index-zsarb5xp.js";
4
4
 
5
5
  // src/internal/route-pattern.ts
6
6
  import { z } from "zod";
@@ -79,4 +79,4 @@ function parseTrailingWildcard(path) {
79
79
  return wildcard ? { name: wildcard.name, segmentIndex: wildcard.segmentIndex } : null;
80
80
  }
81
81
 
82
- export { joinRoutePath, resolveRouteParamsSchema, parseTrailingWildcard };
82
+ export { joinRoutePath, parseRoutePattern, resolveRouteParamsSchema, parseTrailingWildcard };
@@ -1,24 +1,24 @@
1
1
  import {
2
- RealtimeRequestInvalidAcknowledgementError,
3
- RealtimeRequestRejectedError
4
- } from "./index-dce5wxcq.js";
2
+ AppError2
3
+ } from "./index-n53mswt3.js";
5
4
  import {
6
- zodIssues
7
- } from "./index-p5r7qpdd.js";
5
+ RealtimeRequestInvalidAcknowledgementError2,
6
+ RealtimeRequestRejectedError2
7
+ } from "./index-4s0fep5q.js";
8
8
  import {
9
- AppError
10
- } from "./index-2vtcmrj9.js";
9
+ zodIssues2
10
+ } from "./index-1eeqpadm.js";
11
11
 
12
12
  // src/realtime/rejected-frame.ts
13
- var REALTIME_REJECTION_KEY = "@stitchkit/realtime-rejected";
13
+ var REALTIME_REJECTION_KEY2 = "@stitchkit/realtime-rejected";
14
14
  var MAX_REJECTION_ISSUES = 20;
15
15
  function realtimeRejectionEnvelope(report) {
16
- return { [REALTIME_REJECTION_KEY]: report };
16
+ return { [REALTIME_REJECTION_KEY2]: report };
17
17
  }
18
- function asRealtimeRejection(value) {
18
+ function asRealtimeRejection2(value) {
19
19
  if (typeof value !== "object" || value === null)
20
20
  return null;
21
- const report = Reflect.get(value, REALTIME_REJECTION_KEY);
21
+ const report = Reflect.get(value, REALTIME_REJECTION_KEY2);
22
22
  if (typeof report !== "object" || report === null)
23
23
  return null;
24
24
  const event = Reflect.get(report, "event");
@@ -58,9 +58,9 @@ function parseIssues(value) {
58
58
  // src/realtime/rejection.ts
59
59
  import { z } from "zod";
60
60
  function realtimeContractViolation(options) {
61
- const issues = options.cause instanceof z.ZodError ? zodIssues(options.cause) : undefined;
61
+ const issues = options.cause instanceof z.ZodError ? zodIssues2(options.cause) : undefined;
62
62
  const reason = options.reason.replaceAll("-", " ");
63
- const error = new AppError("REALTIME_CONTRACT_VIOLATION", `Realtime event "${options.event}" (${options.direction}, ${options.phase}): ${reason}`, 500, {
63
+ const error = new AppError2("REALTIME_CONTRACT_VIOLATION", `Realtime event "${options.event}" (${options.direction}, ${options.phase}): ${reason}`, 500, {
64
64
  event: options.event,
65
65
  direction: options.direction,
66
66
  phase: options.phase,
@@ -152,7 +152,7 @@ function parseRealtimeRequestArguments(registry, event, direction, args) {
152
152
  return parsed.data;
153
153
  }
154
154
  function parseRealtimeRequestAcknowledgement(schema, event, direction, value, hook, logger) {
155
- const refusal = asRealtimeRejection(value);
155
+ const refusal = asRealtimeRejection2(value);
156
156
  if (refusal) {
157
157
  reportRejected(realtimeContractViolation({
158
158
  event,
@@ -161,7 +161,7 @@ function parseRealtimeRequestAcknowledgement(schema, event, direction, value, ho
161
161
  reason: "rejected-by-peer",
162
162
  fault: "local"
163
163
  }), hook, logger);
164
- throw new RealtimeRequestRejectedError(event, refusal.reason, refusal.message, refusal.issues);
164
+ throw new RealtimeRequestRejectedError2(event, refusal.reason, refusal.message, refusal.issues);
165
165
  }
166
166
  const parsed = schema.safeParse(value);
167
167
  if (parsed.success)
@@ -175,7 +175,7 @@ function parseRealtimeRequestAcknowledgement(schema, event, direction, value, ho
175
175
  cause: parsed.error
176
176
  });
177
177
  reportRejected(rejected, hook, logger);
178
- throw new RealtimeRequestInvalidAcknowledgementError(event, rejected.error);
178
+ throw new RealtimeRequestInvalidAcknowledgementError2(event, rejected.error);
179
179
  }
180
180
  function createValidatedRealtimeSocket({
181
181
  target,
@@ -208,7 +208,7 @@ function createValidatedRealtimeSocket({
208
208
  event,
209
209
  reason: "invalid-arguments",
210
210
  message: rejected.error.message,
211
- issues: zodIssues(parsed.error).slice(0, MAX_REJECTION_ISSUES)
211
+ issues: zodIssues2(parsed.error).slice(0, MAX_REJECTION_ISSUES)
212
212
  }, logger);
213
213
  return;
214
214
  }
@@ -279,7 +279,7 @@ function createValidatedRealtimeSocket({
279
279
  const wireArgs = [...parsed.data];
280
280
  if (definition.ack && acknowledgement) {
281
281
  wireArgs.push((value) => {
282
- const refusal = asRealtimeRejection(value);
282
+ const refusal = asRealtimeRejection2(value);
283
283
  if (refusal) {
284
284
  reportRejected(realtimeContractViolation({
285
285
  event,
@@ -321,4 +321,4 @@ function isModuleNotFound(error) {
321
321
  return code === "ERR_MODULE_NOT_FOUND" || code === "MODULE_NOT_FOUND" || message.includes("Cannot find module") || message.includes("Cannot find package");
322
322
  }
323
323
 
324
- export { REALTIME_REJECTION_KEY, asRealtimeRejection, parseRealtimeRequestArguments, parseRealtimeRequestAcknowledgement, createValidatedRealtimeSocket, isModuleNotFound };
324
+ export { REALTIME_REJECTION_KEY2, asRealtimeRejection2, parseRealtimeRequestArguments, parseRealtimeRequestAcknowledgement, createValidatedRealtimeSocket, isModuleNotFound };
@@ -1,23 +1,23 @@
1
1
  import {
2
- collectTools,
3
- createToolRunner
4
- } from "./index-bm5rx7n6.js";
2
+ AppError2
3
+ } from "./index-n53mswt3.js";
5
4
  import {
6
5
  toolErrorFromResult
7
- } from "./index-8qt2m66q.js";
6
+ } from "./index-dvwj1f43.js";
8
7
  import {
9
8
  assertUniqueToolName
10
- } from "./index-0r0fbk7z.js";
9
+ } from "./index-7z9ym7t8.js";
11
10
  import {
12
- AppError
13
- } from "./index-2vtcmrj9.js";
11
+ collectTools2,
12
+ createToolRunner
13
+ } from "./index-n9tyz8z3.js";
14
14
 
15
15
  // src/tools/invoker.ts
16
- function createToolInvoker(services, config) {
16
+ function createToolInvoker2(services, config) {
17
17
  const serviceList = Array.isArray(services) ? services : [services];
18
18
  const tools = new Map;
19
19
  for (const service of serviceList) {
20
- for (const tool of collectTools(service, config.transport, {
20
+ for (const tool of collectTools2(service, config.transport, {
21
21
  extend: config.extend,
22
22
  flattenUnionInput: config.flattenUnionInput
23
23
  })) {
@@ -30,7 +30,7 @@ function createToolInvoker(services, config) {
30
30
  const tool = tools.get(name);
31
31
  if (tool)
32
32
  return tool;
33
- throw new AppError("NOT_FOUND", `Unknown tool: ${name}`, 404, {
33
+ throw new AppError2("NOT_FOUND", `Unknown tool: ${name}`, 404, {
34
34
  available: names
35
35
  });
36
36
  };
@@ -61,4 +61,4 @@ function createToolInvoker(services, config) {
61
61
  });
62
62
  }
63
63
 
64
- export { createToolInvoker };
64
+ export { createToolInvoker2 };