@getcliqio/cliq-sdk 0.0.0-stage → 1.15.32

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 (338) hide show
  1. package/README.md +28 -2
  2. package/dist/agent_api.d.ts +39 -0
  3. package/dist/agent_api.d.ts.map +1 -0
  4. package/dist/agent_api.js +105 -0
  5. package/dist/agent_api.js.map +1 -0
  6. package/dist/agent_manifest.d.ts +162 -0
  7. package/dist/agent_manifest.d.ts.map +1 -0
  8. package/dist/agent_manifest.js +242 -0
  9. package/dist/agent_manifest.js.map +1 -0
  10. package/dist/agent_payloads.d.ts +103 -0
  11. package/dist/agent_payloads.d.ts.map +1 -0
  12. package/dist/agent_payloads.js +56 -0
  13. package/dist/agent_payloads.js.map +1 -0
  14. package/dist/agents/base_agent.d.ts +113 -0
  15. package/dist/agents/base_agent.d.ts.map +1 -0
  16. package/dist/agents/base_agent.js +413 -0
  17. package/dist/agents/base_agent.js.map +1 -0
  18. package/dist/agents/cli_agent.d.ts +98 -0
  19. package/dist/agents/cli_agent.d.ts.map +1 -0
  20. package/dist/agents/cli_agent.js +303 -0
  21. package/dist/agents/cli_agent.js.map +1 -0
  22. package/dist/agents/cli_rehydrate.d.ts +29 -0
  23. package/dist/agents/cli_rehydrate.d.ts.map +1 -0
  24. package/dist/agents/cli_rehydrate.js +32 -0
  25. package/dist/agents/cli_rehydrate.js.map +1 -0
  26. package/dist/agents/connector_agent.d.ts +20 -0
  27. package/dist/agents/connector_agent.d.ts.map +1 -0
  28. package/dist/agents/connector_agent.js +110 -0
  29. package/dist/agents/connector_agent.js.map +1 -0
  30. package/dist/agents/event_artifacts.d.ts +33 -0
  31. package/dist/agents/event_artifacts.d.ts.map +1 -0
  32. package/dist/agents/event_artifacts.js +73 -0
  33. package/dist/agents/event_artifacts.js.map +1 -0
  34. package/dist/agents/gate_agent.d.ts +40 -0
  35. package/dist/agents/gate_agent.d.ts.map +1 -0
  36. package/dist/agents/gate_agent.js +121 -0
  37. package/dist/agents/gate_agent.js.map +1 -0
  38. package/dist/agents/index.d.ts +32 -0
  39. package/dist/agents/index.d.ts.map +1 -0
  40. package/dist/agents/index.js +26 -0
  41. package/dist/agents/index.js.map +1 -0
  42. package/dist/agents/llm_agent.d.ts +109 -0
  43. package/dist/agents/llm_agent.d.ts.map +1 -0
  44. package/dist/agents/llm_agent.js +285 -0
  45. package/dist/agents/llm_agent.js.map +1 -0
  46. package/dist/agents/llm_contract.d.ts +7 -0
  47. package/dist/agents/llm_contract.d.ts.map +1 -0
  48. package/dist/agents/llm_contract.js +7 -0
  49. package/dist/agents/llm_contract.js.map +1 -0
  50. package/dist/agents/standard_agent.d.ts +15 -0
  51. package/dist/agents/standard_agent.d.ts.map +1 -0
  52. package/dist/agents/standard_agent.js +34 -0
  53. package/dist/agents/standard_agent.js.map +1 -0
  54. package/dist/agents/turn_result.d.ts +67 -0
  55. package/dist/agents/turn_result.d.ts.map +1 -0
  56. package/dist/agents/turn_result.js +81 -0
  57. package/dist/agents/turn_result.js.map +1 -0
  58. package/dist/agents/types.d.ts +314 -0
  59. package/dist/agents/types.d.ts.map +1 -0
  60. package/dist/agents/types.js +20 -0
  61. package/dist/agents/types.js.map +1 -0
  62. package/dist/builtin_teams/hello_hug.d.ts +9 -0
  63. package/dist/builtin_teams/hello_hug.d.ts.map +1 -0
  64. package/dist/builtin_teams/hello_hug.js +68 -0
  65. package/dist/builtin_teams/hello_hug.js.map +1 -0
  66. package/dist/builtin_teams/hello_world.d.ts +8 -0
  67. package/dist/builtin_teams/hello_world.d.ts.map +1 -0
  68. package/dist/builtin_teams/hello_world.js +65 -0
  69. package/dist/builtin_teams/hello_world.js.map +1 -0
  70. package/dist/builtin_teams/hug_example.d.ts +10 -0
  71. package/dist/builtin_teams/hug_example.d.ts.map +1 -0
  72. package/dist/builtin_teams/hug_example.js +94 -0
  73. package/dist/builtin_teams/hug_example.js.map +1 -0
  74. package/dist/builtin_teams/index.d.ts +12 -0
  75. package/dist/builtin_teams/index.d.ts.map +1 -0
  76. package/dist/builtin_teams/index.js +18 -0
  77. package/dist/builtin_teams/index.js.map +1 -0
  78. package/dist/builtin_teams/types.d.ts +29 -0
  79. package/dist/builtin_teams/types.d.ts.map +1 -0
  80. package/dist/builtin_teams/types.js +3 -0
  81. package/dist/builtin_teams/types.js.map +1 -0
  82. package/dist/core_api_client.d.ts +48 -0
  83. package/dist/core_api_client.d.ts.map +1 -0
  84. package/dist/core_api_client.js +132 -0
  85. package/dist/core_api_client.js.map +1 -0
  86. package/dist/daemon_wire.d.ts +122 -0
  87. package/dist/daemon_wire.d.ts.map +1 -0
  88. package/dist/daemon_wire.js +105 -0
  89. package/dist/daemon_wire.js.map +1 -0
  90. package/dist/events/catalog.d.ts +40 -0
  91. package/dist/events/catalog.d.ts.map +1 -0
  92. package/dist/events/catalog.js +76 -0
  93. package/dist/events/catalog.js.map +1 -0
  94. package/dist/http_daemon_client.d.ts +136 -0
  95. package/dist/http_daemon_client.d.ts.map +1 -0
  96. package/dist/http_daemon_client.js +192 -0
  97. package/dist/http_daemon_client.js.map +1 -0
  98. package/dist/hug/ask.d.ts +160 -0
  99. package/dist/hug/ask.d.ts.map +1 -0
  100. package/dist/hug/ask.js +318 -0
  101. package/dist/hug/ask.js.map +1 -0
  102. package/dist/hug/attach.d.ts +60 -0
  103. package/dist/hug/attach.d.ts.map +1 -0
  104. package/dist/hug/attach.js +103 -0
  105. package/dist/hug/attach.js.map +1 -0
  106. package/dist/hug/bridge/index.d.ts +16 -0
  107. package/dist/hug/bridge/index.d.ts.map +1 -0
  108. package/dist/hug/bridge/index.js +13 -0
  109. package/dist/hug/bridge/index.js.map +1 -0
  110. package/dist/hug/bridge/messages.d.ts +559 -0
  111. package/dist/hug/bridge/messages.d.ts.map +1 -0
  112. package/dist/hug/bridge/messages.js +165 -0
  113. package/dist/hug/bridge/messages.js.map +1 -0
  114. package/dist/hug/client.d.ts +70 -0
  115. package/dist/hug/client.d.ts.map +1 -0
  116. package/dist/hug/client.js +144 -0
  117. package/dist/hug/client.js.map +1 -0
  118. package/dist/hug/context.d.ts +54 -0
  119. package/dist/hug/context.d.ts.map +1 -0
  120. package/dist/hug/context.js +27 -0
  121. package/dist/hug/context.js.map +1 -0
  122. package/dist/hug/define.d.ts +116 -0
  123. package/dist/hug/define.d.ts.map +1 -0
  124. package/dist/hug/define.js +119 -0
  125. package/dist/hug/define.js.map +1 -0
  126. package/dist/hug/definitions/approval.d.ts +216 -0
  127. package/dist/hug/definitions/approval.d.ts.map +1 -0
  128. package/dist/hug/definitions/approval.js +50 -0
  129. package/dist/hug/definitions/approval.js.map +1 -0
  130. package/dist/hug/definitions/common.d.ts +122 -0
  131. package/dist/hug/definitions/common.d.ts.map +1 -0
  132. package/dist/hug/definitions/common.js +70 -0
  133. package/dist/hug/definitions/common.js.map +1 -0
  134. package/dist/hug/definitions/form.d.ts +197 -0
  135. package/dist/hug/definitions/form.d.ts.map +1 -0
  136. package/dist/hug/definitions/form.js +29 -0
  137. package/dist/hug/definitions/form.js.map +1 -0
  138. package/dist/hug/definitions/index.d.ts +10 -0
  139. package/dist/hug/definitions/index.d.ts.map +1 -0
  140. package/dist/hug/definitions/index.js +8 -0
  141. package/dist/hug/definitions/index.js.map +1 -0
  142. package/dist/hug/errors.d.ts +30 -0
  143. package/dist/hug/errors.d.ts.map +1 -0
  144. package/dist/hug/errors.js +46 -0
  145. package/dist/hug/errors.js.map +1 -0
  146. package/dist/hug/file_checks.d.ts +41 -0
  147. package/dist/hug/file_checks.d.ts.map +1 -0
  148. package/dist/hug/file_checks.js +105 -0
  149. package/dist/hug/file_checks.js.map +1 -0
  150. package/dist/hug/files.d.ts +137 -0
  151. package/dist/hug/files.d.ts.map +1 -0
  152. package/dist/hug/files.js +283 -0
  153. package/dist/hug/files.js.map +1 -0
  154. package/dist/hug/hug_bundle.d.ts +70 -0
  155. package/dist/hug/hug_bundle.d.ts.map +1 -0
  156. package/dist/hug/hug_bundle.js +299 -0
  157. package/dist/hug/hug_bundle.js.map +1 -0
  158. package/dist/hug/hug_catalog.d.ts +38 -0
  159. package/dist/hug/hug_catalog.d.ts.map +1 -0
  160. package/dist/hug/hug_catalog.js +67 -0
  161. package/dist/hug/hug_catalog.js.map +1 -0
  162. package/dist/hug/hug_definitions.d.ts +32 -0
  163. package/dist/hug/hug_definitions.d.ts.map +1 -0
  164. package/dist/hug/hug_definitions.js +74 -0
  165. package/dist/hug/hug_definitions.js.map +1 -0
  166. package/dist/hug/index.d.ts +37 -0
  167. package/dist/hug/index.d.ts.map +1 -0
  168. package/dist/hug/index.js +23 -0
  169. package/dist/hug/index.js.map +1 -0
  170. package/dist/hug/llm.d.ts +106 -0
  171. package/dist/hug/llm.d.ts.map +1 -0
  172. package/dist/hug/llm.js +250 -0
  173. package/dist/hug/llm.js.map +1 -0
  174. package/dist/hug/policies.d.ts +65 -0
  175. package/dist/hug/policies.d.ts.map +1 -0
  176. package/dist/hug/policies.js +80 -0
  177. package/dist/hug/policies.js.map +1 -0
  178. package/dist/hug/problems.d.ts +35 -0
  179. package/dist/hug/problems.d.ts.map +1 -0
  180. package/dist/hug/problems.js +53 -0
  181. package/dist/hug/problems.js.map +1 -0
  182. package/dist/hug/requested_inputs.d.ts +190 -0
  183. package/dist/hug/requested_inputs.d.ts.map +1 -0
  184. package/dist/hug/requested_inputs.js +220 -0
  185. package/dist/hug/requested_inputs.js.map +1 -0
  186. package/dist/hug/schema_for_inputs.d.ts +20 -0
  187. package/dist/hug/schema_for_inputs.d.ts.map +1 -0
  188. package/dist/hug/schema_for_inputs.js +95 -0
  189. package/dist/hug/schema_for_inputs.js.map +1 -0
  190. package/dist/hug/session.d.ts +113 -0
  191. package/dist/hug/session.d.ts.map +1 -0
  192. package/dist/hug/session.js +210 -0
  193. package/dist/hug/session.js.map +1 -0
  194. package/dist/hug/types.d.ts +141 -0
  195. package/dist/hug/types.d.ts.map +1 -0
  196. package/dist/hug/types.js +80 -0
  197. package/dist/hug/types.js.map +1 -0
  198. package/dist/index.d.ts +72 -0
  199. package/dist/index.d.ts.map +1 -0
  200. package/dist/index.js +54 -0
  201. package/dist/index.js.map +1 -0
  202. package/dist/logging.d.ts +172 -0
  203. package/dist/logging.d.ts.map +1 -0
  204. package/dist/logging.js +306 -0
  205. package/dist/logging.js.map +1 -0
  206. package/dist/mcp.d.ts +119 -0
  207. package/dist/mcp.d.ts.map +1 -0
  208. package/dist/mcp.js +259 -0
  209. package/dist/mcp.js.map +1 -0
  210. package/dist/mcp_client.d.ts +145 -0
  211. package/dist/mcp_client.d.ts.map +1 -0
  212. package/dist/mcp_client.js +374 -0
  213. package/dist/mcp_client.js.map +1 -0
  214. package/dist/paths.d.ts +20 -0
  215. package/dist/paths.d.ts.map +1 -0
  216. package/dist/paths.js +20 -0
  217. package/dist/paths.js.map +1 -0
  218. package/dist/protocol/factory.d.ts +32 -0
  219. package/dist/protocol/factory.d.ts.map +1 -0
  220. package/dist/protocol/factory.js +31 -0
  221. package/dist/protocol/factory.js.map +1 -0
  222. package/dist/protocol/framing.d.ts +35 -0
  223. package/dist/protocol/framing.d.ts.map +1 -0
  224. package/dist/protocol/framing.js +73 -0
  225. package/dist/protocol/framing.js.map +1 -0
  226. package/dist/protocol/index.d.ts +13 -0
  227. package/dist/protocol/index.d.ts.map +1 -0
  228. package/dist/protocol/index.js +13 -0
  229. package/dist/protocol/index.js.map +1 -0
  230. package/dist/protocol/types/agent.d.ts +42 -0
  231. package/dist/protocol/types/agent.d.ts.map +1 -0
  232. package/dist/protocol/types/agent.js +9 -0
  233. package/dist/protocol/types/agent.js.map +1 -0
  234. package/dist/protocol/types/cliq_core.d.ts +79 -0
  235. package/dist/protocol/types/cliq_core.d.ts.map +1 -0
  236. package/dist/protocol/types/cliq_core.js +17 -0
  237. package/dist/protocol/types/cliq_core.js.map +1 -0
  238. package/dist/protocol/types/foundations.d.ts +41 -0
  239. package/dist/protocol/types/foundations.d.ts.map +1 -0
  240. package/dist/protocol/types/foundations.js +10 -0
  241. package/dist/protocol/types/foundations.js.map +1 -0
  242. package/dist/protocol/types/index.d.ts +32 -0
  243. package/dist/protocol/types/index.d.ts.map +1 -0
  244. package/dist/protocol/types/index.js +27 -0
  245. package/dist/protocol/types/index.js.map +1 -0
  246. package/dist/protocol/types/messages.d.ts +827 -0
  247. package/dist/protocol/types/messages.d.ts.map +1 -0
  248. package/dist/protocol/types/messages.js +117 -0
  249. package/dist/protocol/types/messages.js.map +1 -0
  250. package/dist/protocol/types/pipeline.d.ts +122 -0
  251. package/dist/protocol/types/pipeline.d.ts.map +1 -0
  252. package/dist/protocol/types/pipeline.js +16 -0
  253. package/dist/protocol/types/pipeline.js.map +1 -0
  254. package/dist/protocol/types/schemas.d.ts +814 -0
  255. package/dist/protocol/types/schemas.d.ts.map +1 -0
  256. package/dist/protocol/types/schemas.js +772 -0
  257. package/dist/protocol/types/schemas.js.map +1 -0
  258. package/dist/protocol/types/team.d.ts +42 -0
  259. package/dist/protocol/types/team.d.ts.map +1 -0
  260. package/dist/protocol/types/team.js +15 -0
  261. package/dist/protocol/types/team.js.map +1 -0
  262. package/dist/protocol/types/workspace.d.ts +46 -0
  263. package/dist/protocol/types/workspace.d.ts.map +1 -0
  264. package/dist/protocol/types/workspace.js +9 -0
  265. package/dist/protocol/types/workspace.js.map +1 -0
  266. package/dist/settings_keys.d.ts +12 -0
  267. package/dist/settings_keys.d.ts.map +1 -0
  268. package/dist/settings_keys.js +35 -0
  269. package/dist/settings_keys.js.map +1 -0
  270. package/dist/tcp/client.d.ts +15 -0
  271. package/dist/tcp/client.d.ts.map +1 -0
  272. package/dist/tcp/client.js +28 -0
  273. package/dist/tcp/client.js.map +1 -0
  274. package/dist/tcp/connection.d.ts +79 -0
  275. package/dist/tcp/connection.d.ts.map +1 -0
  276. package/dist/tcp/connection.js +153 -0
  277. package/dist/tcp/connection.js.map +1 -0
  278. package/dist/tcp/index.d.ts +10 -0
  279. package/dist/tcp/index.d.ts.map +1 -0
  280. package/dist/tcp/index.js +7 -0
  281. package/dist/tcp/index.js.map +1 -0
  282. package/dist/tcp/server.d.ts +31 -0
  283. package/dist/tcp/server.d.ts.map +1 -0
  284. package/dist/tcp/server.js +54 -0
  285. package/dist/tcp/server.js.map +1 -0
  286. package/dist/team/bundle.d.ts +88 -0
  287. package/dist/team/bundle.d.ts.map +1 -0
  288. package/dist/team/bundle.js +214 -0
  289. package/dist/team/bundle.js.map +1 -0
  290. package/dist/team/identity.d.ts +31 -0
  291. package/dist/team/identity.d.ts.map +1 -0
  292. package/dist/team/identity.js +83 -0
  293. package/dist/team/identity.js.map +1 -0
  294. package/dist/team/index.d.ts +13 -0
  295. package/dist/team/index.d.ts.map +1 -0
  296. package/dist/team/index.js +8 -0
  297. package/dist/team/index.js.map +1 -0
  298. package/dist/team/lint_bundle.d.ts +16 -0
  299. package/dist/team/lint_bundle.d.ts.map +1 -0
  300. package/dist/team/lint_bundle.js +35 -0
  301. package/dist/team/lint_bundle.js.map +1 -0
  302. package/dist/team/ref.d.ts +48 -0
  303. package/dist/team/ref.d.ts.map +1 -0
  304. package/dist/team/ref.js +70 -0
  305. package/dist/team/ref.js.map +1 -0
  306. package/dist/team/roles.d.ts +22 -0
  307. package/dist/team/roles.d.ts.map +1 -0
  308. package/dist/team/roles.js +33 -0
  309. package/dist/team/roles.js.map +1 -0
  310. package/dist/team/tree.d.ts +101 -0
  311. package/dist/team/tree.d.ts.map +1 -0
  312. package/dist/team/tree.js +125 -0
  313. package/dist/team/tree.js.map +1 -0
  314. package/dist/team_lint.d.ts +57 -0
  315. package/dist/team_lint.d.ts.map +1 -0
  316. package/dist/team_lint.js +277 -0
  317. package/dist/team_lint.js.map +1 -0
  318. package/dist/telemetry/stream_json_usage.d.ts +39 -0
  319. package/dist/telemetry/stream_json_usage.d.ts.map +1 -0
  320. package/dist/telemetry/stream_json_usage.js +139 -0
  321. package/dist/telemetry/stream_json_usage.js.map +1 -0
  322. package/dist/telemetry/usage.d.ts +288 -0
  323. package/dist/telemetry/usage.d.ts.map +1 -0
  324. package/dist/telemetry/usage.js +421 -0
  325. package/dist/telemetry/usage.js.map +1 -0
  326. package/dist/utils/duration.d.ts +11 -0
  327. package/dist/utils/duration.d.ts.map +1 -0
  328. package/dist/utils/duration.js +22 -0
  329. package/dist/utils/duration.js.map +1 -0
  330. package/dist/utils/redact.d.ts +26 -0
  331. package/dist/utils/redact.d.ts.map +1 -0
  332. package/dist/utils/redact.js +52 -0
  333. package/dist/utils/redact.js.map +1 -0
  334. package/dist/utils/url.d.ts +6 -0
  335. package/dist/utils/url.d.ts.map +1 -0
  336. package/dist/utils/url.js +11 -0
  337. package/dist/utils/url.js.map +1 -0
  338. package/package.json +72 -5
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/protocol/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,cAAc,kBAAkB,CAAC;AAGjC,OAAO,EAAE,WAAW,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC"}
@@ -0,0 +1,13 @@
1
+ /**
2
+ * Public barrel for the protocol module.
3
+ *
4
+ * Re-exports:
5
+ * - All schemas / types / atoms / envelope helpers from `./types/`.
6
+ * The schemas double as types (`Message` is both `z.discriminatedUnion`
7
+ * and the inferred TS type).
8
+ * - `MessageFactory` stays internal to the agent TCP transport (`tcp/`).
9
+ * - `NdjsonCodec`, `NdjsonDecoder` — wire framing.
10
+ */
11
+ export * from './types/index.js';
12
+ export { NdjsonCodec, NdjsonDecoder } from './framing.js';
13
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/protocol/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,cAAc,kBAAkB,CAAC;AAGjC,OAAO,EAAE,WAAW,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC"}
@@ -0,0 +1,42 @@
1
+ /**
2
+ * Agents — package management AND the agent runtime protocol
3
+ * (`invoke`, `hello`).
4
+ *
5
+ * Operations on an installed agent carry `agent: Ref`.
6
+ * `agent_register` resolves a local agent and pushes to Hub.
7
+ */
8
+ import type { z } from 'zod';
9
+ import type { schemas } from './schemas.js';
10
+ import type { Message } from './messages.js';
11
+ /** `agent_register` — resolve local agent and push manifest to Hub. */
12
+ export type AgentRegister = z.infer<typeof schemas.AgentRegister>;
13
+ /** `agent_get_by_id` — resolve a single agent by name from the local path. */
14
+ export type AgentGetById = z.infer<typeof schemas.AgentGetById>;
15
+ /** `agent_unregister` — remove an agent from the Hub registry. */
16
+ export type AgentUnregister = z.infer<typeof schemas.AgentUnregister>;
17
+ /**
18
+ * A command IS the entity (not a reference to one), so its identity
19
+ * fields live directly on the schema as `id` and `name`.
20
+ */
21
+ export type Command = z.infer<typeof schemas.Command>;
22
+ /** How the orchestrator treats a phase: `STANDARD`, `GATE` or `NOTIFY`. */
23
+ export type PhaseType = z.infer<typeof schemas.PhaseType>;
24
+ /** The orchestrator dispatches a phase to an agent with this payload. */
25
+ export type Invoke = z.infer<typeof schemas.Invoke>;
26
+ /**
27
+ * First message an agent sends after connecting. Agent ref is
28
+ * required; phase ref is optional (the agent may not yet know which
29
+ * phase it's about to run at connection setup).
30
+ */
31
+ export type Hello = z.infer<typeof schemas.Hello>;
32
+ /** `agent_list` payload: list local agents, optionally checking Hub registration. */
33
+ export type AgentList = z.infer<typeof schemas.AgentList>;
34
+ /** Envelope of an `invoke` message. */
35
+ export type InvokeMessage = Extract<Message, {
36
+ type: 'invoke';
37
+ }>;
38
+ /** Envelope of a `hello` message. */
39
+ export type HelloMessage = Extract<Message, {
40
+ type: 'hello';
41
+ }>;
42
+ //# sourceMappingURL=agent.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"agent.d.ts","sourceRoot":"","sources":["../../../src/protocol/types/agent.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,KAAK,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAC7B,OAAO,KAAK,EAAE,OAAO,EAAE,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`).
4
+ *
5
+ * Operations on an installed agent carry `agent: Ref`.
6
+ * `agent_register` resolves a local agent and pushes to Hub.
7
+ */
8
+ export {};
9
+ //# sourceMappingURL=agent.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"agent.js","sourceRoot":"","sources":["../../../src/protocol/types/agent.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG"}
@@ -0,0 +1,79 @@
1
+ /**
2
+ * CliqCore — daemon-side concerns that aren't tied to a single
3
+ * domain entity. Sub-sections:
4
+ *
5
+ * Instance pipeline instance lifecycle (list / info / kill).
6
+ * Settings settings get / set (workspace-scoped at the wire,
7
+ * daemon-served at runtime).
8
+ * Daemon daemon_status.
9
+ * Hub & tokens hub login / logout, token create / list / revoke.
10
+ * Cross-cutting log lines, channel notifications, heartbeats.
11
+ * Responses generic reply envelopes (ok / error / progress / complete).
12
+ *
13
+ * `InstanceScope` is the one shared shape that lives here — used by
14
+ * `instance_info` and `instance_kill`.
15
+ */
16
+ import type { z } from 'zod';
17
+ import type { schemas } from './schemas.js';
18
+ import type { Message } from './messages.js';
19
+ /** `{ instance_id }` — used by `instance_info` and `instance_kill`. */
20
+ /** Payload shape `{ instance_id }` for operations on one workspace instance. */
21
+ export type InstanceScope = z.infer<typeof schemas.InstanceScope>;
22
+ /** `settings_get` payload: read one setting `key` (workspace-level when `workspace_dir` is set, else global). */
23
+ export type SettingsGet = z.infer<typeof schemas.SettingsGet>;
24
+ /** `settings_list` payload: list settings, optionally only keys under `prefix`. */
25
+ export type SettingsList = z.infer<typeof schemas.SettingsList>;
26
+ /** `settings_set` payload: set `key` to `value` (`null` clears it; `value` must be present). */
27
+ export type SettingsSet = z.infer<typeof schemas.SettingsSet>;
28
+ /** `hub_login` payload: provider-specific credentials the daemon exchanges for a Hub session. */
29
+ export type HubLogin = z.infer<typeof schemas.HubLogin>;
30
+ /** `token_create` payload: mint a user token, or a realm token for daemon enrollment. */
31
+ export type TokenCreate = z.infer<typeof schemas.TokenCreate>;
32
+ /** `token_revoke` payload: revoke the token with `token_id`. */
33
+ export type TokenRevoke = z.infer<typeof schemas.TokenRevoke>;
34
+ /** `rotate_dispatch` payload: rotate the dispatch key pair for a realm. */
35
+ export type RotateDispatch = z.infer<typeof schemas.RotateDispatch>;
36
+ /** Log severity on the wire: `DEBUG`, `INFO`, `WARN` or `ERROR`. */
37
+ export type LogLevel = z.infer<typeof schemas.LogLevel>;
38
+ /**
39
+ * Structured log line. Phase and agent refs are optional — system-
40
+ * level lines (daemon startup, connection lifecycle) carry neither.
41
+ */
42
+ export type Log = z.infer<typeof schemas.Log>;
43
+ /** `notification` payload: a message for a channel (subject plus a body that may be empty). */
44
+ export type Notification = z.infer<typeof schemas.Notification>;
45
+ /** `ok` reply payload, with optional result `data`. */
46
+ export type Ok = z.infer<typeof schemas.Ok>;
47
+ /** `error` reply payload: a code, a message and optional structured `details`. */
48
+ export type Err = z.infer<typeof schemas.Err>;
49
+ /** `progress` payload: a status message and optional 0–100 percent. */
50
+ export type Progress = z.infer<typeof schemas.Progress>;
51
+ /** Envelope of a `log` message. */
52
+ export type LogMessage = Extract<Message, {
53
+ type: 'log';
54
+ }>;
55
+ /** Envelope of a `notification` message. */
56
+ export type NotificationMessage = Extract<Message, {
57
+ type: 'notification';
58
+ }>;
59
+ /** Envelope of a `heartbeat` message. */
60
+ export type HeartbeatMessage = Extract<Message, {
61
+ type: 'heartbeat';
62
+ }>;
63
+ /** Envelope of an `ok` reply. */
64
+ export type OkMessage = Extract<Message, {
65
+ type: 'ok';
66
+ }>;
67
+ /** Envelope of an `error` reply. */
68
+ export type ErrorMessage = Extract<Message, {
69
+ type: 'error';
70
+ }>;
71
+ /** Envelope of a `progress` message. */
72
+ export type ProgressMessage = Extract<Message, {
73
+ type: 'progress';
74
+ }>;
75
+ /** Envelope of a `complete` message. */
76
+ export type CompleteMessage = Extract<Message, {
77
+ type: 'complete';
78
+ }>;
79
+ //# sourceMappingURL=cliq_core.d.ts.map
@@ -0,0 +1 @@
1
+ {"version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E,CAAC,CAAC;AACzE,wCAAwC;AACxC,MAAM,MAAM,eAAe,GAAO,OAAO,CAAC,OAAO,EAAE;IAAE,IAAI,EAAE,UAAU,CAAA;CAAE,CAAC,CAAC"}
@@ -0,0 +1,17 @@
1
+ /**
2
+ * CliqCore — daemon-side concerns that aren't tied to a single
3
+ * domain entity. Sub-sections:
4
+ *
5
+ * Instance pipeline instance lifecycle (list / info / kill).
6
+ * Settings settings get / set (workspace-scoped at the wire,
7
+ * daemon-served at runtime).
8
+ * Daemon daemon_status.
9
+ * Hub & tokens hub login / logout, token create / list / revoke.
10
+ * Cross-cutting log lines, channel notifications, heartbeats.
11
+ * Responses generic reply envelopes (ok / error / progress / complete).
12
+ *
13
+ * `InstanceScope` is the one shared shape that lives here — used by
14
+ * `instance_info` and `instance_kill`.
15
+ */
16
+ export {};
17
+ //# sourceMappingURL=cliq_core.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cliq_core.js","sourceRoot":"","sources":["../../../src/protocol/types/cliq_core.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG"}
@@ -0,0 +1,41 @@
1
+ /**
2
+ * Foundations — the building-block TYPES every domain depends on.
3
+ *
4
+ * Every type here is `z.infer<typeof schemas.X>` — the schema lives
5
+ * in `schemas.ts`; this file owns the public type names. No
6
+ * runtime schema is exported from this file; the only value
7
+ * exported is `PROTOCOL_VERSION`.
8
+ */
9
+ import type { z } from 'zod';
10
+ import type { schemas } from './schemas.js';
11
+ export { PROTOCOL_VERSION } from './schemas.js';
12
+ /**
13
+ * UUID atom used by every id field. The schema is private to
14
+ * `schemas.ts`; this is just the inferred string type.
15
+ */
16
+ export type EntityId = string;
17
+ /**
18
+ * Lookup ref — `{ id?, name? }`, at least one required. The entity
19
+ * type (team, agent, phase, channel) is encoded by the parent key
20
+ * in the payload.
21
+ */
22
+ export type Ref = z.infer<typeof schemas.Ref>;
23
+ /**
24
+ * Creation spec — `{ id?, name }`. Name required (the user just
25
+ * typed it), id optional (idempotency / automation).
26
+ */
27
+ export type Spec = z.infer<typeof schemas.Spec>;
28
+ /** Zero-field payload type. */
29
+ export type Empty = z.infer<typeof schemas.Empty>;
30
+ /** Fields common to every message envelope. */
31
+ export type Envelope = z.infer<typeof schemas.Envelope>;
32
+ /**
33
+ * Generic typed envelope — `Envelope` plus a literal `type` and the
34
+ * typed `payload` for that variant. Used by the factory and framing
35
+ * layers that don't care about the specific message.
36
+ */
37
+ export type MessageEnvelope<T extends string = string, P = unknown> = Envelope & {
38
+ readonly type: T;
39
+ readonly payload: P;
40
+ };
41
+ //# sourceMappingURL=foundations.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"foundations.d.ts","sourceRoot":"","sources":["../../../src/protocol/types/foundations.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,KAAK,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAC7B,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AAE5C,OAAO,EAAE,gBAAgB,EAAE,MAAM,cAAc,CAAC;AAOhD;;;GAGG;AACH,MAAM,MAAM,QAAQ,GAAG,MAAM,CAAC;AAE9B;;;;GAIG;AACH,MAAM,MAAM,GAAG,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,OAAO,CAAC,GAAG,CAAC,CAAC;AAE9C;;;GAGG;AACH,MAAM,MAAM,IAAI,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,OAAO,CAAC,IAAI,CAAC,CAAC;AAOhD,+BAA+B;AAC/B,MAAM,MAAM,KAAK,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,OAAO,CAAC,KAAK,CAAC,CAAC;AAElD,+CAA+C;AAC/C,MAAM,MAAM,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,OAAO,CAAC,QAAQ,CAAC,CAAC;AAExD;;;;GAIG;AACH,MAAM,MAAM,eAAe,CAAC,CAAC,SAAS,MAAM,GAAG,MAAM,EAAE,CAAC,GAAG,OAAO,IAC9D,QAAQ,GAAG;IACP,QAAQ,CAAC,IAAI,EAAE,CAAC,CAAC;IACjB,QAAQ,CAAC,OAAO,EAAE,CAAC,CAAC;CACvB,CAAC"}
@@ -0,0 +1,10 @@
1
+ /**
2
+ * Foundations — the building-block TYPES every domain depends on.
3
+ *
4
+ * Every type here is `z.infer<typeof schemas.X>` — the schema lives
5
+ * in `schemas.ts`; this file owns the public type names. No
6
+ * runtime schema is exported from this file; the only value
7
+ * exported is `PROTOCOL_VERSION`.
8
+ */
9
+ export { PROTOCOL_VERSION } from './schemas.js';
10
+ //# sourceMappingURL=foundations.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"foundations.js","sourceRoot":"","sources":["../../../src/protocol/types/foundations.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAKH,OAAO,EAAE,gBAAgB,EAAE,MAAM,cAAc,CAAC"}
@@ -0,0 +1,32 @@
1
+ /**
2
+ * Public barrel for protocol types.
3
+ *
4
+ * Type-heavy, value-light:
5
+ *
6
+ * - Every payload and envelope type (`Init`, `Invoke`, `InvokeMessage`,
7
+ * `Log`, ...) is re-exported as a TypeScript type. The schemas
8
+ * that back those types live in the private `schemas` registry
9
+ * (`schemas.ts`) and are not part of the public API.
10
+ *
11
+ * - Five runtime entry points are exported as values:
12
+ *
13
+ * Message discriminated union schema over every envelope
14
+ * Payloads per-type payload schema registry
15
+ * MessageType z.enum / inferred type of valid `type` strings
16
+ * MESSAGE_TYPES tuple of valid type strings, for iteration
17
+ * PROTOCOL_VERSION wire protocol version
18
+ *
19
+ * There is exactly ONE canonical way to validate a payload at runtime
20
+ * (`Payloads[t].safeParse`) and ONE way to validate a full envelope
21
+ * (`Message.safeParse`). Direct `Invoke.safeParse(x)` style calls are
22
+ * not part of the public API — `Invoke` is a type, never a value.
23
+ */
24
+ export type * from './foundations.js';
25
+ export type * from './workspace.js';
26
+ export type * from './team.js';
27
+ export type * from './agent.js';
28
+ export type * from './pipeline.js';
29
+ export type * from './cliq_core.js';
30
+ export { PROTOCOL_VERSION } from './foundations.js';
31
+ export { Message, MessageType, MESSAGE_TYPES, Payloads, } from './messages.js';
32
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/protocol/types/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AAGH,mBAAmB,kBAAkB,CAAC;AAGtC,mBAAmB,gBAAgB,CAAC;AACpC,mBAAmB,WAAW,CAAC;AAC/B,mBAAmB,YAAY,CAAC;AAChC,mBAAmB,eAAe,CAAC;AACnC,mBAAmB,gBAAgB,CAAC;AAGpC,OAAO,EAAE,gBAAgB,EAAE,MAAM,kBAAkB,CAAC;AACpD,OAAO,EACH,OAAO,EACP,WAAW,EACX,aAAa,EACb,QAAQ,GACX,MAAM,eAAe,CAAC"}
@@ -0,0 +1,27 @@
1
+ /**
2
+ * Public barrel for protocol types.
3
+ *
4
+ * Type-heavy, value-light:
5
+ *
6
+ * - Every payload and envelope type (`Init`, `Invoke`, `InvokeMessage`,
7
+ * `Log`, ...) is re-exported as a TypeScript type. The schemas
8
+ * that back those types live in the private `schemas` registry
9
+ * (`schemas.ts`) and are not part of the public API.
10
+ *
11
+ * - Five runtime entry points are exported as values:
12
+ *
13
+ * Message discriminated union schema over every envelope
14
+ * Payloads per-type payload schema registry
15
+ * MessageType z.enum / inferred type of valid `type` strings
16
+ * MESSAGE_TYPES tuple of valid type strings, for iteration
17
+ * PROTOCOL_VERSION wire protocol version
18
+ *
19
+ * There is exactly ONE canonical way to validate a payload at runtime
20
+ * (`Payloads[t].safeParse`) and ONE way to validate a full envelope
21
+ * (`Message.safeParse`). Direct `Invoke.safeParse(x)` style calls are
22
+ * not part of the public API — `Invoke` is a type, never a value.
23
+ */
24
+ // Runtime values.
25
+ export { PROTOCOL_VERSION } from './foundations.js';
26
+ export { Message, MessageType, MESSAGE_TYPES, Payloads, } from './messages.js';
27
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/protocol/types/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AAYH,kBAAkB;AAClB,OAAO,EAAE,gBAAgB,EAAE,MAAM,kBAAkB,CAAC;AACpD,OAAO,EACH,OAAO,EACP,WAAW,EACX,aAAa,EACb,QAAQ,GACX,MAAM,eAAe,CAAC"}