@rallycry/conveyor-agent 11.0.31 → 11.0.33

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.
@@ -320,6 +320,7 @@ var AgentConnection = class _AgentConnection {
320
320
  // PTY relay (S5 terminal). Single-slot callbacks, set per PtySession run.
321
321
  ptyInputCallback = null;
322
322
  ptyResizeCallback = null;
323
+ ptyModelEffortCallback = null;
323
324
  /** Epoch ms of the last relayed keystroke, or null before any input. The
324
325
  * question-grace expiry reads it to defer un-parking while a human is
325
326
  * actively typing into the Connected-TUI (they may be mid-answer). */
@@ -522,6 +523,12 @@ var AgentConnection = class _AgentConnection {
522
523
  if (data.sessionId && data.sessionId !== this.config.sessionId) return;
523
524
  this.ptyResizeCallback?.(data.cols, data.rows);
524
525
  });
526
+ this.socket.on("pty:model-effort", (data) => {
527
+ if (data.sessionId && data.sessionId !== this.config.sessionId) return;
528
+ if (data.model) process.env.CONVEYOR_MODEL_OVERRIDE = data.model;
529
+ if (data.effort) process.env.CONVEYOR_EFFORT_OVERRIDE = data.effort;
530
+ this.ptyModelEffortCallback?.(data);
531
+ });
525
532
  this.socket.on("connect", () => {
526
533
  process.stderr.write("[conveyor-agent] Socket connected\n");
527
534
  this.scheduleSocketRecycle();
@@ -1018,6 +1025,13 @@ var AgentConnection = class _AgentConnection {
1018
1025
  if (this.ptyInputCallback === handler) this.ptyInputCallback = null;
1019
1026
  };
1020
1027
  }
1028
+ /** Subscribe to composer model/effort switches. Returns an unsubscribe fn. */
1029
+ onPtyModelEffort(handler) {
1030
+ this.ptyModelEffortCallback = handler;
1031
+ return () => {
1032
+ if (this.ptyModelEffortCallback === handler) this.ptyModelEffortCallback = null;
1033
+ };
1034
+ }
1021
1035
  /** Subscribe to relayed (reconciled) terminal resizes. Returns an unsubscribe fn. */
1022
1036
  onPtyResize(handler) {
1023
1037
  this.ptyResizeCallback = handler;
@@ -1792,8 +1806,8 @@ async function runQueryGrafanaLogs(port, params, now = Date.now) {
1792
1806
  // ../shared/dist/index.js
1793
1807
  import { z as z3 } from "zod";
1794
1808
  import { z as z22 } from "zod";
1795
- import { z as z32 } from "zod";
1796
1809
  import { z as z4 } from "zod";
1810
+ import { z as z32 } from "zod";
1797
1811
  import { z as z5 } from "zod";
1798
1812
  import { z as z6 } from "zod";
1799
1813
  import { z as z7 } from "zod";
@@ -1802,6 +1816,7 @@ import { z as z9 } from "zod";
1802
1816
  import { z as z10 } from "zod";
1803
1817
  import { z as z11 } from "zod";
1804
1818
  import { z as z12 } from "zod";
1819
+ import { z as z13 } from "zod";
1805
1820
  var EXTERNAL_AGENT_MESSAGE_SOURCE = "external_agent";
1806
1821
  var TUI_KINDS = ["claude-code", "opencode", "codex"];
1807
1822
  var ACHIEVEMENT_RARITIES = [
@@ -2076,29 +2091,120 @@ var AgentEventSchema = z22.union([
2076
2091
  KnownAgentEventSchema,
2077
2092
  z22.object({ type: z22.string().min(1) }).catchall(z22.unknown())
2078
2093
  ]);
2079
- var cardDescription = z32.string().max(CARD_DESCRIPTION_MAX, CARD_DESCRIPTION_LIMIT_MESSAGE).optional();
2080
- var AgentHeartbeatSchema = z32.object({
2081
- sessionId: z32.string().optional(),
2082
- timestamp: z32.string(),
2083
- status: z32.enum(["active", "idle", "building"]),
2084
- currentAction: z32.string().optional(),
2094
+ var PtyChatAtSchema = z32.string().max(40).optional();
2095
+ var PtyChatTurnUsageSchema = z32.object({
2096
+ input: z32.number().int().nonnegative(),
2097
+ output: z32.number().int().nonnegative(),
2098
+ cacheRead: z32.number().int().nonnegative(),
2099
+ cacheWrite: z32.number().int().nonnegative()
2100
+ });
2101
+ var PtyChatTurnFileSchema = z32.object({
2102
+ path: z32.string().max(500),
2103
+ added: z32.number().int(),
2104
+ removed: z32.number().int()
2105
+ });
2106
+ var PTY_CHAT_TURN_FILES_MAX = 50;
2107
+ var PtyChatEventPayloadSchema = z32.discriminatedUnion("kind", [
2108
+ z32.object({
2109
+ kind: z32.literal("init"),
2110
+ at: PtyChatAtSchema,
2111
+ model: z32.string().max(200),
2112
+ claudeSessionId: z32.string().max(100).optional()
2113
+ }),
2114
+ z32.object({
2115
+ kind: z32.literal("user_text"),
2116
+ at: PtyChatAtSchema,
2117
+ text: z32.string().max(16384),
2118
+ // Set by the SERVER (never the agent) when this prompt was injected by
2119
+ // Conveyor rather than typed by a human — the routed message's `source`
2120
+ // (`ci_success`, `review_trigger`, `automated_feedback`, …). The agent
2121
+ // pastes automated messages into the TUI exactly like human prompts, so the
2122
+ // CLI records both as plain transcript `user` records; without this the
2123
+ // builder chat renders "All CI checks passed on your PR." as the human's
2124
+ // own bubble. Absent ⇒ a genuine human prompt. Exception: the AGENT sets
2125
+ // `model_switch` on the notice it emits after a live model/effort switch.
2126
+ source: z32.string().max(60).optional()
2127
+ }),
2128
+ z32.object({
2129
+ kind: z32.literal("assistant_text"),
2130
+ at: PtyChatAtSchema,
2131
+ text: z32.string().max(16384),
2132
+ model: z32.string().max(200).optional()
2133
+ }),
2134
+ z32.object({
2135
+ kind: z32.literal("tool_use"),
2136
+ at: PtyChatAtSchema,
2137
+ name: z32.string().max(200),
2138
+ // Compact preview: JSON.stringify(input) truncated agent-side. The cap
2139
+ // matches the text events because AskUserQuestion payloads ride this field
2140
+ // and the web lifts them into an interactive card — a tight cap forced
2141
+ // option descriptions down to 80 chars, making them unreadable. Every
2142
+ // other tool keeps a far smaller agent-side budget (`TOOL_INPUT_MAX` in
2143
+ // `chat-record-mapper.ts`), so the ring does not grow for normal calls.
2144
+ input: z32.string().max(16384),
2145
+ // Transcript tool_use block id — lets the client pair the tool_result.
2146
+ id: z32.string().max(100).optional()
2147
+ }),
2148
+ z32.object({
2149
+ kind: z32.literal("tool_result"),
2150
+ at: PtyChatAtSchema,
2151
+ // tool_use block id this result answers (absent on malformed records).
2152
+ toolUseId: z32.string().max(100).optional(),
2153
+ // Compact output preview, truncated agent-side.
2154
+ output: z32.string().max(2e3),
2155
+ isError: z32.boolean().optional()
2156
+ }),
2157
+ z32.object({
2158
+ kind: z32.literal("turn_end"),
2159
+ at: PtyChatAtSchema,
2160
+ // Wall-clock turn length as the CLI measured it ("Worked for 23s").
2161
+ durationMs: z32.number().int().nonnegative().optional(),
2162
+ // Last model that answered in this turn.
2163
+ model: z32.string().max(200).optional(),
2164
+ // Token usage summed over the turn's API responses.
2165
+ usage: PtyChatTurnUsageSchema.optional(),
2166
+ // Files the turn edited, with line counts. Absent when nothing was edited.
2167
+ files: z32.array(PtyChatTurnFileSchema).max(PTY_CHAT_TURN_FILES_MAX).optional()
2168
+ })
2169
+ ]);
2170
+ var PtyChatEventRequestSchema = z32.object({
2171
+ sessionId: z32.string(),
2172
+ event: PtyChatEventPayloadSchema
2173
+ });
2174
+ var PtyChatAttachRequestSchema = z32.object({
2175
+ sessionId: z32.string()
2176
+ });
2177
+ var PTY_EFFORT_LEVELS = ["low", "medium", "high", "xhigh", "max"];
2178
+ var SetPtyModelEffortRequestSchema = z32.object({
2179
+ sessionId: z32.string(),
2180
+ model: z32.string().min(1).max(200).optional(),
2181
+ effort: z32.enum(PTY_EFFORT_LEVELS).optional()
2182
+ }).refine((p) => p.model !== void 0 || p.effort !== void 0, {
2183
+ message: "model or effort is required"
2184
+ });
2185
+ var cardDescription = z4.string().max(CARD_DESCRIPTION_MAX, CARD_DESCRIPTION_LIMIT_MESSAGE).optional();
2186
+ var AgentHeartbeatSchema = z4.object({
2187
+ sessionId: z4.string().optional(),
2188
+ timestamp: z4.string(),
2189
+ status: z4.enum(["active", "idle", "building"]),
2190
+ currentAction: z4.string().optional(),
2085
2191
  /** Sender-observed main event-loop lag (ms) — see AgentHeartbeat.loopLagMs. */
2086
- loopLagMs: z32.number().nonnegative().optional()
2192
+ loopLagMs: z4.number().nonnegative().optional()
2087
2193
  });
2088
- var CreatePRInputSchema = z32.object({
2089
- title: z32.string().min(1),
2090
- body: z32.string(),
2091
- head: z32.string().optional(),
2092
- base: z32.string().optional()
2194
+ var CreatePRInputSchema = z4.object({
2195
+ title: z4.string().min(1),
2196
+ body: z4.string(),
2197
+ head: z4.string().optional(),
2198
+ base: z4.string().optional()
2093
2199
  });
2094
- var PostToChatInputSchema = z32.object({
2095
- message: z32.string().min(1),
2096
- type: z32.enum(["message", "question", "update"]).optional().default("message"),
2097
- milestone: z32.enum(["plan_ready", "implementation_complete", "blocked"]).optional()
2200
+ var PostToChatInputSchema = z4.object({
2201
+ message: z4.string().min(1),
2202
+ type: z4.enum(["message", "question", "update"]).optional().default("message"),
2203
+ milestone: z4.enum(["plan_ready", "implementation_complete", "blocked"]).optional()
2098
2204
  });
2099
- var GetTaskContextRequestSchema = z32.object({
2100
- sessionId: z32.string(),
2101
- includeHistory: z32.boolean().optional().default(false),
2205
+ var GetTaskContextRequestSchema = z4.object({
2206
+ sessionId: z4.string(),
2207
+ includeHistory: z4.boolean().optional().default(false),
2102
2208
  /**
2103
2209
  * Read the plan-revised marker WITHOUT consuming it. Bookkeeping fetches
2104
2210
  * (the session-identity check, the branch refresh) pass true so they cannot
@@ -2106,283 +2212,283 @@ var GetTaskContextRequestSchema = z32.object({
2106
2212
  * Defaults to false — consuming — so a pod running an older agent build still
2107
2213
  * clears the marker instead of showing the notice on every boot forever.
2108
2214
  */
2109
- peekPlanRevision: z32.boolean().optional().default(false)
2215
+ peekPlanRevision: z4.boolean().optional().default(false)
2110
2216
  });
2111
- var GetChatMessagesRequestSchema = z32.object({
2112
- sessionId: z32.string(),
2113
- limit: z32.number().int().positive().optional().default(50),
2114
- offset: z32.number().int().nonnegative().optional().default(0),
2217
+ var GetChatMessagesRequestSchema = z4.object({
2218
+ sessionId: z4.string(),
2219
+ limit: z4.number().int().positive().optional().default(50),
2220
+ offset: z4.number().int().nonnegative().optional().default(0),
2115
2221
  /** Task id or slug to read chat from. Omit for the session's own task. Only
2116
2222
  * the session's own task or one of its children resolves — anything else is
2117
2223
  * an error, never a silent fallback to the caller's own chat. */
2118
- taskId: z32.string().optional()
2224
+ taskId: z4.string().optional()
2119
2225
  });
2120
- var GetTaskFilesRequestSchema = z32.object({
2121
- sessionId: z32.string(),
2122
- taskId: z32.string().optional()
2226
+ var GetTaskFilesRequestSchema = z4.object({
2227
+ sessionId: z4.string(),
2228
+ taskId: z4.string().optional()
2123
2229
  });
2124
- var GetTaskFileRequestSchema = z32.object({
2125
- sessionId: z32.string(),
2126
- fileId: z32.string(),
2127
- taskId: z32.string().optional()
2230
+ var GetTaskFileRequestSchema = z4.object({
2231
+ sessionId: z4.string(),
2232
+ fileId: z4.string(),
2233
+ taskId: z4.string().optional()
2128
2234
  });
2129
- var DeleteTaskFileRequestSchema = z32.object({
2130
- sessionId: z32.string(),
2131
- fileId: z32.string()
2235
+ var DeleteTaskFileRequestSchema = z4.object({
2236
+ sessionId: z4.string(),
2237
+ fileId: z4.string()
2132
2238
  });
2133
- var GetTaskRequestSchema = z32.object({
2134
- sessionId: z32.string(),
2135
- taskSlugOrId: z32.string()
2239
+ var GetTaskRequestSchema = z4.object({
2240
+ sessionId: z4.string(),
2241
+ taskSlugOrId: z4.string()
2136
2242
  });
2137
- var GetCliHistoryRequestSchema = z32.object({
2138
- sessionId: z32.string(),
2139
- limit: z32.number().int().positive().optional().default(100),
2140
- source: z32.enum(["agent", "application"]).optional(),
2243
+ var GetCliHistoryRequestSchema = z4.object({
2244
+ sessionId: z4.string(),
2245
+ limit: z4.number().int().positive().optional().default(100),
2246
+ source: z4.enum(["agent", "application"]).optional(),
2141
2247
  /** Task id or slug to read logs from. Omit for the session's own task. Only
2142
2248
  * the session's own task or one of its children resolves — anything else is
2143
2249
  * an error, never a silent fallback to the caller's own logs. */
2144
- taskId: z32.string().optional()
2250
+ taskId: z4.string().optional()
2145
2251
  });
2146
- var ListSubtasksRequestSchema = z32.object({
2147
- sessionId: z32.string(),
2252
+ var ListSubtasksRequestSchema = z4.object({
2253
+ sessionId: z4.string(),
2148
2254
  /** "compact" returns the slim orchestration view (ListSubtasksCompactResponse:
2149
2255
  * per-child status, agent, story points, PR state, dependencies); "full" (default — wire-compat with older
2150
2256
  * agents) returns the verbose SubtaskSummaryDTO[] including description/plan. */
2151
- view: z32.enum(["compact", "full"]).optional()
2257
+ view: z4.enum(["compact", "full"]).optional()
2152
2258
  });
2153
- var GetDependenciesRequestSchema = z32.object({
2154
- sessionId: z32.string()
2259
+ var GetDependenciesRequestSchema = z4.object({
2260
+ sessionId: z4.string()
2155
2261
  });
2156
- var GetSuggestionsRequestSchema = z32.object({
2157
- sessionId: z32.string(),
2158
- status: z32.string().optional(),
2159
- limit: z32.number().int().min(1).max(100).optional()
2262
+ var GetSuggestionsRequestSchema = z4.object({
2263
+ sessionId: z4.string(),
2264
+ status: z4.string().optional(),
2265
+ limit: z4.number().int().min(1).max(100).optional()
2160
2266
  });
2161
- var ListManualTestsRequestSchema = z32.object({
2162
- sessionId: z32.string()
2267
+ var ListManualTestsRequestSchema = z4.object({
2268
+ sessionId: z4.string()
2163
2269
  });
2164
- var QueryManualTestsRequestSchema = z32.object({
2165
- sessionId: z32.string(),
2166
- cardStatuses: z32.array(z32.string()).optional(),
2167
- testStatuses: z32.array(z32.enum(["open", "approved", "rejected"])).optional()
2270
+ var QueryManualTestsRequestSchema = z4.object({
2271
+ sessionId: z4.string(),
2272
+ cardStatuses: z4.array(z4.string()).optional(),
2273
+ testStatuses: z4.array(z4.enum(["open", "approved", "rejected"])).optional()
2168
2274
  });
2169
- var CreatePullRequestRequestSchema = CreatePRInputSchema.extend({ sessionId: z32.string() });
2170
- var RequestFileUploadRequestSchema = z32.object({
2171
- sessionId: z32.string(),
2172
- fileName: z32.string().min(1).max(255),
2173
- mimeType: z32.string().min(1).max(128),
2174
- fileSize: z32.number().int().positive().max(MAX_FILE_SIZE_BYTES)
2275
+ var CreatePullRequestRequestSchema = CreatePRInputSchema.extend({ sessionId: z4.string() });
2276
+ var RequestFileUploadRequestSchema = z4.object({
2277
+ sessionId: z4.string(),
2278
+ fileName: z4.string().min(1).max(255),
2279
+ mimeType: z4.string().min(1).max(128),
2280
+ fileSize: z4.number().int().positive().max(MAX_FILE_SIZE_BYTES)
2175
2281
  });
2176
- var ConfirmFileUploadRequestSchema = z32.object({
2177
- sessionId: z32.string(),
2178
- fileId: z32.string(),
2179
- title: z32.string().max(500).optional(),
2282
+ var ConfirmFileUploadRequestSchema = z4.object({
2283
+ sessionId: z4.string(),
2284
+ fileId: z4.string(),
2285
+ title: z4.string().max(500).optional(),
2180
2286
  /** Glossary tag names (or ids) this file is an example of. */
2181
- tags: z32.array(z32.string().min(1).max(MAX_FILE_TAG_LENGTH)).max(MAX_FILE_TAGS).optional()
2287
+ tags: z4.array(z4.string().min(1).max(MAX_FILE_TAG_LENGTH)).max(MAX_FILE_TAGS).optional()
2182
2288
  });
2183
- var UpdateTaskStatusRequestSchema = z32.object({
2184
- sessionId: z32.string(),
2185
- status: z32.string(),
2186
- force: z32.boolean().optional().default(false)
2289
+ var UpdateTaskStatusRequestSchema = z4.object({
2290
+ sessionId: z4.string(),
2291
+ status: z4.string(),
2292
+ force: z4.boolean().optional().default(false)
2187
2293
  });
2188
- var StoreSessionIdRequestSchema = z32.object({
2189
- sessionId: z32.string(),
2190
- sdkSessionId: z32.string()
2294
+ var StoreSessionIdRequestSchema = z4.object({
2295
+ sessionId: z4.string(),
2296
+ sdkSessionId: z4.string()
2191
2297
  });
2192
- var SetManualTestsRequestSchema = z32.object({
2193
- sessionId: z32.string(),
2298
+ var SetManualTestsRequestSchema = z4.object({
2299
+ sessionId: z4.string(),
2194
2300
  items: ManualTestItemsSchema
2195
2301
  });
2196
- var EditManualTestRequestSchema = z32.object({
2197
- sessionId: z32.string(),
2198
- title: z32.string().min(1),
2199
- newTitle: z32.string().min(1)
2302
+ var EditManualTestRequestSchema = z4.object({
2303
+ sessionId: z4.string(),
2304
+ title: z4.string().min(1),
2305
+ newTitle: z4.string().min(1)
2200
2306
  });
2201
- var RemoveManualTestRequestSchema = z32.object({
2202
- sessionId: z32.string(),
2203
- title: z32.string().min(1)
2307
+ var RemoveManualTestRequestSchema = z4.object({
2308
+ sessionId: z4.string(),
2309
+ title: z4.string().min(1)
2204
2310
  });
2205
- var ApproveManualTestRequestSchema = z32.object({
2206
- sessionId: z32.string(),
2207
- title: z32.string().min(1)
2311
+ var ApproveManualTestRequestSchema = z4.object({
2312
+ sessionId: z4.string(),
2313
+ title: z4.string().min(1)
2208
2314
  });
2209
- var RejectManualTestRequestSchema = z32.object({
2210
- sessionId: z32.string(),
2211
- title: z32.string().min(1),
2212
- reason: z32.string().min(1).max(2e3)
2315
+ var RejectManualTestRequestSchema = z4.object({
2316
+ sessionId: z4.string(),
2317
+ title: z4.string().min(1),
2318
+ reason: z4.string().min(1).max(2e3)
2213
2319
  });
2214
- var SessionStartRequestSchema = z32.object({
2215
- sessionId: z32.string(),
2216
- agentVersion: z32.string(),
2217
- capabilities: z32.array(z32.string())
2320
+ var SessionStartRequestSchema = z4.object({
2321
+ sessionId: z4.string(),
2322
+ agentVersion: z4.string(),
2323
+ capabilities: z4.array(z4.string())
2218
2324
  });
2219
- var SessionStopRequestSchema = z32.object({
2220
- sessionId: z32.string(),
2221
- reason: z32.string().optional()
2325
+ var SessionStopRequestSchema = z4.object({
2326
+ sessionId: z4.string(),
2327
+ reason: z4.string().optional()
2222
2328
  });
2223
- var EndReviewSessionRequestSchema = z32.object({
2224
- sessionId: z32.string(),
2225
- reason: z32.enum(["approved", "changes_requested", "finished"]).optional()
2329
+ var EndReviewSessionRequestSchema = z4.object({
2330
+ sessionId: z4.string(),
2331
+ reason: z4.enum(["approved", "changes_requested", "finished"]).optional()
2226
2332
  });
2227
- var ConnectAgentRequestSchema = z32.object({
2228
- sessionId: z32.string()
2333
+ var ConnectAgentRequestSchema = z4.object({
2334
+ sessionId: z4.string()
2229
2335
  });
2230
- var ReportAgentStatusRequestSchema = z32.object({
2231
- sessionId: z32.string(),
2232
- status: z32.string(),
2336
+ var ReportAgentStatusRequestSchema = z4.object({
2337
+ sessionId: z4.string(),
2338
+ status: z4.string(),
2233
2339
  /** Why the agent reports this status (e.g. "user_question" while an AskUserQuestion questionnaire is pending in the TUI). */
2234
- reason: z32.string().optional(),
2340
+ reason: z4.string().optional(),
2235
2341
  /**
2236
2342
  * The pending question text, sent only alongside `reason: "user_question"`
2237
2343
  * so the server can surface it in the user-question notification body (and
2238
2344
  * thus the Attention feed) instead of a generic string. Optional: older
2239
2345
  * agents omit it and the server falls back to the generic wording.
2240
2346
  */
2241
- questionText: z32.string().optional()
2347
+ questionText: z4.string().optional()
2242
2348
  });
2243
- var NotifyAgentVersionRequestSchema = z32.object({
2244
- sessionId: z32.string(),
2245
- agentVersion: z32.string()
2349
+ var NotifyAgentVersionRequestSchema = z4.object({
2350
+ sessionId: z4.string(),
2351
+ agentVersion: z4.string()
2246
2352
  });
2247
- var DiscoveredPortSchema = z32.object({
2248
- port: z32.number().int().min(1).max(65535),
2249
- label: z32.string().min(1).max(64).optional(),
2250
- protocol: z32.enum(["http", "tcp"]).optional(),
2251
- detectedAt: z32.string()
2353
+ var DiscoveredPortSchema = z4.object({
2354
+ port: z4.number().int().min(1).max(65535),
2355
+ label: z4.string().min(1).max(64).optional(),
2356
+ protocol: z4.enum(["http", "tcp"]).optional(),
2357
+ detectedAt: z4.string()
2252
2358
  });
2253
- var ReportDiscoveredPortsRequestSchema = z32.object({
2254
- sessionId: z32.string(),
2255
- ports: z32.array(DiscoveredPortSchema).max(64)
2359
+ var ReportDiscoveredPortsRequestSchema = z4.object({
2360
+ sessionId: z4.string(),
2361
+ ports: z4.array(DiscoveredPortSchema).max(64)
2256
2362
  });
2257
- var ReportBootMilestoneRequestSchema = z32.object({
2258
- sessionId: z32.string(),
2259
- key: z32.string().max(64)
2363
+ var ReportBootMilestoneRequestSchema = z4.object({
2364
+ sessionId: z4.string(),
2365
+ key: z4.string().max(64)
2260
2366
  });
2261
- var CreateSubtaskRequestSchema = z32.object({
2262
- sessionId: z32.string(),
2263
- title: z32.string().min(1),
2367
+ var CreateSubtaskRequestSchema = z4.object({
2368
+ sessionId: z4.string(),
2369
+ title: z4.string().min(1),
2264
2370
  description: cardDescription,
2265
- plan: z32.string().optional(),
2266
- storyPointValue: z32.number().int().positive().optional(),
2267
- ordinal: z32.number().int().nonnegative().optional(),
2268
- followParentStatus: z32.boolean().optional(),
2371
+ plan: z4.string().optional(),
2372
+ storyPointValue: z4.number().int().positive().optional(),
2373
+ ordinal: z4.number().int().nonnegative().optional(),
2374
+ followParentStatus: z4.boolean().optional(),
2269
2375
  /** Sibling subtask ids or slugs this subtask blocks on (explicit dependency
2270
2376
  * metadata — preferred over encoding order in plan text / ordinal). */
2271
- dependsOn: z32.array(z32.string().min(1)).max(32).optional(),
2377
+ dependsOn: z4.array(z4.string().min(1)).max(32).optional(),
2272
2378
  /** Glossary tag names to assign to the child. Unmatched names come back in
2273
2379
  * the response rather than failing the create. */
2274
- tags: z32.array(z32.string().min(1)).max(10).optional()
2380
+ tags: z4.array(z4.string().min(1)).max(10).optional()
2275
2381
  });
2276
- var UpdateSubtaskRequestSchema = z32.object({
2277
- sessionId: z32.string(),
2278
- subtaskId: z32.string(),
2279
- title: z32.string().min(1).optional(),
2382
+ var UpdateSubtaskRequestSchema = z4.object({
2383
+ sessionId: z4.string(),
2384
+ subtaskId: z4.string(),
2385
+ title: z4.string().min(1).optional(),
2280
2386
  description: cardDescription,
2281
- plan: z32.string().optional(),
2387
+ plan: z4.string().optional(),
2282
2388
  /** Orchestration statuses only ("Planning" | "Open") — the pack parent's
2283
2389
  * sanctioned promotion path. Execution statuses stay with the build
2284
2390
  * pipeline / force_update_task_status. Enforced server-side. */
2285
- status: z32.string().optional(),
2391
+ status: z4.string().optional(),
2286
2392
  /** Assign a project agent to the child — accepts the agent's id or exact
2287
2393
  * name; resolved against the parent task's project server-side. */
2288
- agentIdOrName: z32.string().min(1).optional(),
2289
- storyPointValue: z32.number().int().positive().optional(),
2290
- followParentStatus: z32.boolean().optional(),
2394
+ agentIdOrName: z4.string().min(1).optional(),
2395
+ storyPointValue: z4.number().int().positive().optional(),
2396
+ followParentStatus: z4.boolean().optional(),
2291
2397
  /** Replace this subtask's dependency edges with these sibling ids/slugs.
2292
2398
  * Empty array clears all. Omit to leave dependencies unchanged. */
2293
- dependsOn: z32.array(z32.string().min(1)).max(32).optional()
2399
+ dependsOn: z4.array(z4.string().min(1)).max(32).optional()
2294
2400
  });
2295
- var DeleteSubtaskRequestSchema = z32.object({
2296
- sessionId: z32.string(),
2297
- subtaskId: z32.string()
2401
+ var DeleteSubtaskRequestSchema = z4.object({
2402
+ sessionId: z4.string(),
2403
+ subtaskId: z4.string()
2298
2404
  });
2299
- var SetSubtaskParentRequestSchema = z32.object({
2300
- sessionId: z32.string(),
2301
- taskId: z32.string().min(1),
2302
- detach: z32.boolean().optional(),
2303
- ordinal: z32.number().int().nonnegative().optional(),
2304
- followParentStatus: z32.boolean().optional()
2405
+ var SetSubtaskParentRequestSchema = z4.object({
2406
+ sessionId: z4.string(),
2407
+ taskId: z4.string().min(1),
2408
+ detach: z4.boolean().optional(),
2409
+ ordinal: z4.number().int().nonnegative().optional(),
2410
+ followParentStatus: z4.boolean().optional()
2305
2411
  });
2306
- var GetTaskPropertiesRequestSchema = z32.object({
2307
- sessionId: z32.string()
2412
+ var GetTaskPropertiesRequestSchema = z4.object({
2413
+ sessionId: z4.string()
2308
2414
  });
2309
- var UpdateTaskFieldsRequestSchema = z32.object({
2310
- sessionId: z32.string(),
2311
- plan: z32.string().optional(),
2415
+ var UpdateTaskFieldsRequestSchema = z4.object({
2416
+ sessionId: z4.string(),
2417
+ plan: z4.string().optional(),
2312
2418
  description: cardDescription
2313
2419
  });
2314
- var UpdateTaskPropertiesRequestSchema = z32.object({
2315
- sessionId: z32.string(),
2316
- title: z32.string().optional(),
2317
- storyPointValue: z32.number().int().positive().optional(),
2318
- tagIds: z32.array(z32.string()).optional(),
2319
- tagNames: z32.array(z32.string()).optional(),
2320
- githubPRUrl: z32.string().url().optional(),
2321
- githubBranch: z32.string().optional(),
2420
+ var UpdateTaskPropertiesRequestSchema = z4.object({
2421
+ sessionId: z4.string(),
2422
+ title: z4.string().optional(),
2423
+ storyPointValue: z4.number().int().positive().optional(),
2424
+ tagIds: z4.array(z4.string()).optional(),
2425
+ tagNames: z4.array(z4.string()).optional(),
2426
+ githubPRUrl: z4.string().url().optional(),
2427
+ githubBranch: z4.string().optional(),
2322
2428
  // Canonical risk level, or null to clear — same semantics as the headless
2323
2429
  // update_task boundary (resolved to the project's Risk row in the handler).
2324
2430
  risk: riskLevelSchema.nullable().optional()
2325
2431
  });
2326
- var ListIconsRequestSchema = z32.object({
2327
- sessionId: z32.string()
2432
+ var ListIconsRequestSchema = z4.object({
2433
+ sessionId: z4.string()
2328
2434
  });
2329
- var GenerateTaskIconRequestSchema = z32.object({
2330
- sessionId: z32.string(),
2331
- prompt: z32.string().min(1),
2332
- aspectRatio: z32.string().optional()
2435
+ var GenerateTaskIconRequestSchema = z4.object({
2436
+ sessionId: z4.string(),
2437
+ prompt: z4.string().min(1),
2438
+ aspectRatio: z4.string().optional()
2333
2439
  });
2334
- var SearchFaIconsRequestSchema = z32.object({
2335
- sessionId: z32.string(),
2336
- query: z32.string().min(1),
2337
- first: z32.number().int().positive().optional()
2440
+ var SearchFaIconsRequestSchema = z4.object({
2441
+ sessionId: z4.string(),
2442
+ query: z4.string().min(1),
2443
+ first: z4.number().int().positive().optional()
2338
2444
  });
2339
- var PickFaIconRequestSchema = z32.object({
2340
- sessionId: z32.string(),
2341
- fontAwesomeId: z32.string().min(1),
2342
- fontAwesomeStyle: z32.string().optional()
2445
+ var PickFaIconRequestSchema = z4.object({
2446
+ sessionId: z4.string(),
2447
+ fontAwesomeId: z4.string().min(1),
2448
+ fontAwesomeStyle: z4.string().optional()
2343
2449
  });
2344
- var CreateFollowUpTaskRequestSchema = z32.object({
2345
- sessionId: z32.string(),
2346
- title: z32.string().min(1),
2450
+ var CreateFollowUpTaskRequestSchema = z4.object({
2451
+ sessionId: z4.string(),
2452
+ title: z4.string().min(1),
2347
2453
  description: cardDescription,
2348
- plan: z32.string().optional(),
2349
- storyPointValue: z32.number().int().positive().optional()
2454
+ plan: z4.string().optional(),
2455
+ storyPointValue: z4.number().int().positive().optional()
2350
2456
  });
2351
- var AddDependencyRequestSchema = z32.object({
2352
- sessionId: z32.string(),
2353
- dependsOnSlugOrId: z32.string()
2457
+ var AddDependencyRequestSchema = z4.object({
2458
+ sessionId: z4.string(),
2459
+ dependsOnSlugOrId: z4.string()
2354
2460
  });
2355
- var RemoveDependencyRequestSchema = z32.object({
2356
- sessionId: z32.string(),
2357
- dependsOnSlugOrId: z32.string()
2461
+ var RemoveDependencyRequestSchema = z4.object({
2462
+ sessionId: z4.string(),
2463
+ dependsOnSlugOrId: z4.string()
2358
2464
  });
2359
- var CreateSuggestionRequestSchema = z32.object({
2360
- sessionId: z32.string(),
2361
- title: z32.string().min(1),
2465
+ var CreateSuggestionRequestSchema = z4.object({
2466
+ sessionId: z4.string(),
2467
+ title: z4.string().min(1),
2362
2468
  description: cardDescription,
2363
- tagNames: z32.array(z32.string()).optional()
2469
+ tagNames: z4.array(z4.string()).optional()
2364
2470
  });
2365
- var VoteSuggestionRequestSchema = z32.object({
2366
- sessionId: z32.string(),
2367
- suggestionId: z32.string(),
2368
- value: z32.union([z32.literal(1), z32.literal(-1)])
2471
+ var VoteSuggestionRequestSchema = z4.object({
2472
+ sessionId: z4.string(),
2473
+ suggestionId: z4.string(),
2474
+ value: z4.union([z4.literal(1), z4.literal(-1)])
2369
2475
  });
2370
- var TriggerIdentificationRequestSchema = z32.object({
2371
- sessionId: z32.string()
2476
+ var TriggerIdentificationRequestSchema = z4.object({
2477
+ sessionId: z4.string()
2372
2478
  });
2373
- var HandoffToImplementerRequestSchema = z32.object({
2374
- sessionId: z32.string(),
2479
+ var HandoffToImplementerRequestSchema = z4.object({
2480
+ sessionId: z4.string(),
2375
2481
  // Optional difficulty sizing — sets the task's story points before resolving
2376
2482
  // the matched implementer agent. Omit to hand off using the task's current
2377
2483
  // story points (or the project's default task agent when unsized).
2378
- storyPoints: z32.number().int().positive().optional(),
2484
+ storyPoints: z4.number().int().positive().optional(),
2379
2485
  // Optional kickoff note posted to the task chat alongside the handoff notice.
2380
- message: z32.string().optional()
2486
+ message: z4.string().optional()
2381
2487
  });
2382
- var SubmitCodeReviewResultRequestSchema = z32.object({
2383
- sessionId: z32.string(),
2384
- approved: z32.boolean(),
2385
- content: z32.string(),
2488
+ var SubmitCodeReviewResultRequestSchema = z4.object({
2489
+ sessionId: z4.string(),
2490
+ approved: z4.boolean(),
2491
+ content: z4.string(),
2386
2492
  // Canonical risk level the reviewer assigned to this change. Required on every
2387
2493
  // verdict — the reviewer must judge it. Applied authoritatively server-side
2388
2494
  // (may raise OR lower an already-set value; the reviewer has that authority).
@@ -2390,244 +2496,195 @@ var SubmitCodeReviewResultRequestSchema = z32.object({
2390
2496
  // The commit SHA the reviewer actually reviewed. When present, the verdict is
2391
2497
  // rejected unless the task is still at this SHA (guards against a late
2392
2498
  // old-SHA verdict overwriting a newer review cycle).
2393
- reviewedSha: z32.string().optional()
2499
+ reviewedSha: z4.string().optional()
2394
2500
  });
2395
- var CycleCodingAgentKeyRequestSchema = z32.object({
2396
- sessionId: z32.string(),
2397
- rateLimitType: z32.string(),
2398
- resetsAt: z32.string().optional()
2501
+ var CycleCodingAgentKeyRequestSchema = z4.object({
2502
+ sessionId: z4.string(),
2503
+ rateLimitType: z4.string(),
2504
+ resetsAt: z4.string().optional()
2399
2505
  });
2400
- var PostChildChatMessageRequestSchema = z32.object({
2401
- sessionId: z32.string(),
2402
- childTaskId: z32.string(),
2403
- message: z32.string().min(1)
2506
+ var PostChildChatMessageRequestSchema = z4.object({
2507
+ sessionId: z4.string(),
2508
+ childTaskId: z4.string(),
2509
+ message: z4.string().min(1)
2404
2510
  });
2405
- var UpdateChildStatusRequestSchema = z32.object({
2406
- sessionId: z32.string(),
2407
- childTaskId: z32.string(),
2408
- status: z32.string()
2511
+ var UpdateChildStatusRequestSchema = z4.object({
2512
+ sessionId: z4.string(),
2513
+ childTaskId: z4.string(),
2514
+ status: z4.string()
2409
2515
  });
2410
- var GetAgentStatusRequestSchema = z32.object({
2411
- taskId: z32.string()
2516
+ var GetAgentStatusRequestSchema = z4.object({
2517
+ taskId: z4.string()
2412
2518
  });
2413
- var GetUiCliHistoryRequestSchema = z32.object({
2414
- taskId: z32.string()
2519
+ var GetUiCliHistoryRequestSchema = z4.object({
2520
+ taskId: z4.string()
2415
2521
  });
2416
- var GetActivePtySessionRequestSchema = z32.object({
2417
- taskId: z32.string()
2522
+ var GetActivePtySessionRequestSchema = z4.object({
2523
+ taskId: z4.string()
2418
2524
  });
2419
- var ListActivePtySessionsRequestSchema = z32.object({
2420
- taskId: z32.string()
2525
+ var ListActivePtySessionsRequestSchema = z4.object({
2526
+ taskId: z4.string()
2421
2527
  });
2422
- var SendSoftStopRequestSchema = z32.object({
2423
- taskId: z32.string()
2528
+ var SendSoftStopRequestSchema = z4.object({
2529
+ taskId: z4.string()
2424
2530
  });
2425
- var StopTaskSessionRequestSchema = z32.object({
2426
- taskId: z32.string(),
2427
- sessionId: z32.string()
2531
+ var StopTaskSessionRequestSchema = z4.object({
2532
+ taskId: z4.string(),
2533
+ sessionId: z4.string()
2428
2534
  });
2429
- var FlushTaskQueueRequestSchema = z32.object({
2430
- taskId: z32.string(),
2431
- softStop: z32.boolean().optional()
2535
+ var FlushTaskQueueRequestSchema = z4.object({
2536
+ taskId: z4.string(),
2537
+ softStop: z4.boolean().optional()
2432
2538
  });
2433
- var CancelTaskQueuedMessageRequestSchema = z32.object({
2434
- taskId: z32.string(),
2435
- messageId: z32.string()
2539
+ var CancelTaskQueuedMessageRequestSchema = z4.object({
2540
+ taskId: z4.string(),
2541
+ messageId: z4.string()
2436
2542
  });
2437
- var FlushSingleQueuedMessageRequestSchema = z32.object({
2438
- taskId: z32.string(),
2439
- messageId: z32.string(),
2440
- softStop: z32.boolean().optional()
2543
+ var FlushSingleQueuedMessageRequestSchema = z4.object({
2544
+ taskId: z4.string(),
2545
+ messageId: z4.string(),
2546
+ softStop: z4.boolean().optional()
2441
2547
  });
2442
- var AnswerAgentQuestionRequestSchema = z32.object({
2443
- taskId: z32.string(),
2444
- requestId: z32.string(),
2445
- answers: z32.record(z32.string(), z32.string())
2548
+ var AnswerAgentQuestionRequestSchema = z4.object({
2549
+ taskId: z4.string(),
2550
+ requestId: z4.string(),
2551
+ answers: z4.record(z4.string(), z4.string())
2446
2552
  });
2447
- var ClearAgentTodosRequestSchema = z32.object({
2448
- taskId: z32.string()
2553
+ var ClearAgentTodosRequestSchema = z4.object({
2554
+ taskId: z4.string()
2449
2555
  });
2450
- var AgentQuestionOptionSchema = z32.object({
2451
- label: z32.string(),
2452
- description: z32.string(),
2453
- preview: z32.string().optional()
2556
+ var AgentQuestionOptionSchema = z4.object({
2557
+ label: z4.string(),
2558
+ description: z4.string(),
2559
+ preview: z4.string().optional()
2454
2560
  });
2455
- var AgentQuestionSchema = z32.object({
2456
- question: z32.string(),
2457
- header: z32.string(),
2458
- options: z32.array(AgentQuestionOptionSchema),
2459
- multiSelect: z32.boolean().optional()
2561
+ var AgentQuestionSchema = z4.object({
2562
+ question: z4.string(),
2563
+ header: z4.string(),
2564
+ options: z4.array(AgentQuestionOptionSchema),
2565
+ multiSelect: z4.boolean().optional()
2460
2566
  });
2461
- var AskUserQuestionRequestSchema = z32.object({
2462
- sessionId: z32.string(),
2463
- question: z32.string().min(1),
2464
- requestId: z32.string().min(1),
2465
- questions: z32.array(AgentQuestionSchema).min(1)
2567
+ var AskUserQuestionRequestSchema = z4.object({
2568
+ sessionId: z4.string(),
2569
+ question: z4.string().min(1),
2570
+ requestId: z4.string().min(1),
2571
+ questions: z4.array(AgentQuestionSchema).min(1)
2466
2572
  });
2467
- var PostAgentMessageRequestSchema = z32.object({
2468
- sessionId: z32.string().min(1),
2469
- content: z32.string(),
2470
- milestone: z32.enum(["plan_ready", "implementation_complete", "blocked"]).optional()
2573
+ var PostAgentMessageRequestSchema = z4.object({
2574
+ sessionId: z4.string().min(1),
2575
+ content: z4.string(),
2576
+ milestone: z4.enum(["plan_ready", "implementation_complete", "blocked"]).optional()
2471
2577
  });
2472
- var EmitAgentEventRequestSchema = z32.object({
2473
- sessionId: z32.string(),
2474
- events: z32.array(AgentEventSchema).max(500)
2578
+ var EmitAgentEventRequestSchema = z4.object({
2579
+ sessionId: z4.string(),
2580
+ events: z4.array(AgentEventSchema).max(500)
2475
2581
  });
2476
- var RefreshGithubTokenRequestSchema = z32.object({
2477
- sessionId: z32.string(),
2478
- forceFresh: z32.boolean().optional()
2582
+ var RefreshGithubTokenRequestSchema = z4.object({
2583
+ sessionId: z4.string(),
2584
+ forceFresh: z4.boolean().optional()
2479
2585
  });
2480
- var ReportCredentialFailureRequestSchema = z32.object({
2481
- sessionId: z32.string(),
2482
- error: z32.string().max(2e3).optional(),
2483
- tokenShape: z32.string().max(500).optional(),
2484
- healed: z32.boolean().optional()
2586
+ var ReportCredentialFailureRequestSchema = z4.object({
2587
+ sessionId: z4.string(),
2588
+ error: z4.string().max(2e3).optional(),
2589
+ tokenShape: z4.string().max(500).optional(),
2590
+ healed: z4.boolean().optional()
2485
2591
  });
2486
- var ReportReviewSpawnFailureRequestSchema = z32.object({
2487
- sessionId: z32.string(),
2488
- reviewSessionId: z32.string(),
2489
- error: z32.string().max(2e3).optional()
2592
+ var ReportReviewSpawnFailureRequestSchema = z4.object({
2593
+ sessionId: z4.string(),
2594
+ reviewSessionId: z4.string(),
2595
+ error: z4.string().max(2e3).optional()
2490
2596
  });
2491
2597
  var ReportBuilderSpawnFailureRequestSchema = ReportReviewSpawnFailureRequestSchema.omit({
2492
2598
  reviewSessionId: true
2493
- }).extend({ buildSessionId: z32.string() });
2494
- var SpawnTaskSessionRequestSchema = z32.object({
2495
- taskId: z32.string(),
2496
- kind: z32.enum(["tui", "shell"])
2599
+ }).extend({ buildSessionId: z4.string() });
2600
+ var SpawnTaskSessionRequestSchema = z4.object({
2601
+ taskId: z4.string(),
2602
+ kind: z4.enum(["tui", "shell"])
2497
2603
  });
2498
- var StartCodeReviewRequestSchema = z32.object({
2499
- taskId: z32.string(),
2500
- force: z32.boolean().optional()
2604
+ var StartCodeReviewRequestSchema = z4.object({
2605
+ taskId: z4.string(),
2606
+ force: z4.boolean().optional()
2501
2607
  });
2502
- var StopCodeReviewRequestSchema = z32.object({
2503
- taskId: z32.string()
2608
+ var StopCodeReviewRequestSchema = z4.object({
2609
+ taskId: z4.string()
2504
2610
  });
2505
- var ReportSessionSpawnFailureRequestSchema = z32.object({
2506
- sessionId: z32.string(),
2507
- spawnedSessionId: z32.string(),
2508
- error: z32.string().max(2e3).optional()
2611
+ var ReportSessionSpawnFailureRequestSchema = z4.object({
2612
+ sessionId: z4.string(),
2613
+ spawnedSessionId: z4.string(),
2614
+ error: z4.string().max(2e3).optional()
2509
2615
  });
2510
- var RefreshGithubTokenResponseSchema = z32.object({
2511
- token: z32.string()
2616
+ var RefreshGithubTokenResponseSchema = z4.object({
2617
+ token: z4.string()
2512
2618
  });
2513
2619
  var PTY_FRAME_MAX_CHARS = 256 * 1024;
2514
2620
  var PTY_MAX_DIMENSION = 1e3;
2515
- var PtyOutputRequestSchema = z32.object({
2516
- sessionId: z32.string(),
2517
- data: z32.string().max(PTY_FRAME_MAX_CHARS),
2518
- cols: z32.number().int().positive().max(PTY_MAX_DIMENSION).optional(),
2519
- rows: z32.number().int().positive().max(PTY_MAX_DIMENSION).optional()
2621
+ var PtyOutputRequestSchema = z4.object({
2622
+ sessionId: z4.string(),
2623
+ data: z4.string().max(PTY_FRAME_MAX_CHARS),
2624
+ cols: z4.number().int().positive().max(PTY_MAX_DIMENSION).optional(),
2625
+ rows: z4.number().int().positive().max(PTY_MAX_DIMENSION).optional()
2520
2626
  });
2521
- var PtyEndedRequestSchema = z32.object({
2522
- sessionId: z32.string()
2627
+ var PtyEndedRequestSchema = z4.object({
2628
+ sessionId: z4.string()
2523
2629
  });
2524
- var PtyInputRequestSchema = z32.object({
2525
- sessionId: z32.string(),
2526
- data: z32.string().max(PTY_FRAME_MAX_CHARS)
2630
+ var PtyInputRequestSchema = z4.object({
2631
+ sessionId: z4.string(),
2632
+ data: z4.string().max(PTY_FRAME_MAX_CHARS)
2527
2633
  });
2528
- var PtyResizeRequestSchema = z32.object({
2529
- sessionId: z32.string(),
2530
- cols: z32.number().int().positive().max(PTY_MAX_DIMENSION),
2531
- rows: z32.number().int().positive().max(PTY_MAX_DIMENSION)
2634
+ var PtyResizeRequestSchema = z4.object({
2635
+ sessionId: z4.string(),
2636
+ cols: z4.number().int().positive().max(PTY_MAX_DIMENSION),
2637
+ rows: z4.number().int().positive().max(PTY_MAX_DIMENSION)
2532
2638
  });
2533
- var PtyAttachRequestSchema = z32.object({
2534
- sessionId: z32.string()
2639
+ var PtyAttachRequestSchema = z4.object({
2640
+ sessionId: z4.string()
2535
2641
  });
2536
- var ReportPtyStreamRequestSchema = z32.object({
2537
- sessionId: z32.string(),
2538
- port: z32.number().int().positive().max(65535).nullable()
2642
+ var ReportPtyStreamRequestSchema = z4.object({
2643
+ sessionId: z4.string(),
2644
+ port: z4.number().int().positive().max(65535).nullable()
2539
2645
  });
2540
- var ReportPtyInputRequestSchema = z32.object({
2541
- sessionId: z32.string()
2646
+ var ReportPtyInputRequestSchema = z4.object({
2647
+ sessionId: z4.string()
2542
2648
  });
2543
- var GetPtyStreamEndpointRequestSchema = z32.object({
2544
- sessionId: z32.string()
2649
+ var GetPtyStreamEndpointRequestSchema = z4.object({
2650
+ sessionId: z4.string()
2545
2651
  });
2546
- var PtyChatEventPayloadSchema = z32.discriminatedUnion("kind", [
2547
- z32.object({
2548
- kind: z32.literal("init"),
2549
- model: z32.string().max(200),
2550
- claudeSessionId: z32.string().max(100).optional()
2551
- }),
2552
- z32.object({
2553
- kind: z32.literal("user_text"),
2554
- text: z32.string().max(16384),
2555
- // Set by the SERVER (never the agent) when this prompt was injected by
2556
- // Conveyor rather than typed by a human — the routed message's `source`
2557
- // (`ci_success`, `review_trigger`, `automated_feedback`, …). The agent
2558
- // pastes automated messages into the TUI exactly like human prompts, so the
2559
- // CLI records both as plain transcript `user` records; without this the
2560
- // builder chat renders "All CI checks passed on your PR." as the human's
2561
- // own bubble. Absent ⇒ a genuine human prompt.
2562
- source: z32.string().max(60).optional()
2563
- }),
2564
- z32.object({ kind: z32.literal("assistant_text"), text: z32.string().max(16384) }),
2565
- z32.object({
2566
- kind: z32.literal("tool_use"),
2567
- name: z32.string().max(200),
2568
- // Compact preview: JSON.stringify(input) truncated agent-side. The cap
2569
- // matches the text events because AskUserQuestion payloads ride this field
2570
- // and the web lifts them into an interactive card — a tight cap forced
2571
- // option descriptions down to 80 chars, making them unreadable. Every
2572
- // other tool keeps a far smaller agent-side budget (`TOOL_INPUT_MAX` in
2573
- // `chat-record-mapper.ts`), so the ring does not grow for normal calls.
2574
- input: z32.string().max(16384),
2575
- // Transcript tool_use block id — lets the client pair the tool_result.
2576
- id: z32.string().max(100).optional()
2577
- }),
2578
- z32.object({
2579
- kind: z32.literal("tool_result"),
2580
- // tool_use block id this result answers (absent on malformed records).
2581
- toolUseId: z32.string().max(100).optional(),
2582
- // Compact output preview, truncated agent-side.
2583
- output: z32.string().max(2e3),
2584
- isError: z32.boolean().optional()
2585
- }),
2586
- z32.object({ kind: z32.literal("turn_end") })
2587
- ]);
2588
- var PtyChatEventRequestSchema = z32.object({
2589
- sessionId: z32.string(),
2590
- event: PtyChatEventPayloadSchema
2591
- });
2592
- var PtyChatAttachRequestSchema = z32.object({
2593
- sessionId: z32.string()
2594
- });
2595
- var CreatePRResponseSchema = z32.object({
2596
- prNumber: z32.number().int().positive(),
2597
- prUrl: z32.string().url(),
2652
+ var CreatePRResponseSchema = z4.object({
2653
+ prNumber: z4.number().int().positive(),
2654
+ prUrl: z4.string().url(),
2598
2655
  /** Advisory glossary-upkeep note derived from the PR's changed files matched
2599
2656
  * against tag contextPaths — rendered into the tool result, never stored. */
2600
- glossaryNote: z32.string().optional()
2657
+ glossaryNote: z4.string().optional()
2601
2658
  });
2602
- var PostToChatResponseSchema = z32.object({
2603
- messageId: z32.string()
2659
+ var PostToChatResponseSchema = z4.object({
2660
+ messageId: z4.string()
2604
2661
  });
2605
- var UpdateTaskStatusResponseSchema = z32.object({
2606
- taskId: z32.string(),
2607
- status: z32.string()
2662
+ var UpdateTaskStatusResponseSchema = z4.object({
2663
+ taskId: z4.string(),
2664
+ status: z4.string()
2608
2665
  });
2609
- var StoreSessionIdResponseSchema = z32.object({
2610
- success: z32.boolean()
2666
+ var StoreSessionIdResponseSchema = z4.object({
2667
+ success: z4.boolean()
2611
2668
  });
2612
- var HeartbeatResponseSchema = z32.object({
2613
- acknowledged: z32.boolean()
2669
+ var HeartbeatResponseSchema = z4.object({
2670
+ acknowledged: z4.boolean()
2614
2671
  });
2615
- var SessionStartResponseSchema = z32.object({
2616
- sessionId: z32.string(),
2617
- startedAt: z32.string()
2672
+ var SessionStartResponseSchema = z4.object({
2673
+ sessionId: z4.string(),
2674
+ startedAt: z4.string()
2618
2675
  });
2619
- var SessionStopResponseSchema = z32.object({
2620
- sessionId: z32.string(),
2621
- stoppedAt: z32.string()
2676
+ var SessionStopResponseSchema = z4.object({
2677
+ sessionId: z4.string(),
2678
+ stoppedAt: z4.string()
2622
2679
  });
2623
- var DeleteSubtaskResponseSchema = z32.object({
2624
- deleted: z32.boolean()
2680
+ var DeleteSubtaskResponseSchema = z4.object({
2681
+ deleted: z4.boolean()
2625
2682
  });
2626
- var ParkOnCheckResultRequestSchema = z4.object({
2627
- sessionId: z4.string(),
2628
- sha: z4.string().regex(/^[0-9a-f]{7,40}$/i).optional(),
2629
- prNumber: z4.number().int().positive().optional(),
2630
- timeoutMinutes: z4.number().int().min(1).max(MAX_CI_WAIT_TIMEOUT_MINUTES).optional()
2683
+ var ParkOnCheckResultRequestSchema = z5.object({
2684
+ sessionId: z5.string(),
2685
+ sha: z5.string().regex(/^[0-9a-f]{7,40}$/i).optional(),
2686
+ prNumber: z5.number().int().positive().optional(),
2687
+ timeoutMinutes: z5.number().int().min(1).max(MAX_CI_WAIT_TIMEOUT_MINUTES).optional()
2631
2688
  });
2632
2689
  var GIT_BRANCH_NAME_MAX = 255;
2633
2690
  var GIT_BRANCH_NAME_MESSAGE = "Invalid git branch name \u2014 use only letters, numbers, '.', '_', '/' and '-', starting with a letter or number, with no '..', '@{' or '//', and no trailing '/', '-', '.' or '.lock'";
@@ -2641,97 +2698,97 @@ function isValidGitBranchName(name) {
2641
2698
  if (name.endsWith(".") || name.endsWith(".lock")) return false;
2642
2699
  return true;
2643
2700
  }
2644
- var cardDescription2 = z5.string().max(CARD_DESCRIPTION_MAX, CARD_DESCRIPTION_LIMIT_MESSAGE).optional();
2645
- var ListAccessibleProjectsRequestSchema = z5.object({
2646
- pageSize: z5.number().int().positive().max(100).optional().default(100)
2701
+ var cardDescription2 = z6.string().max(CARD_DESCRIPTION_MAX, CARD_DESCRIPTION_LIMIT_MESSAGE).optional();
2702
+ var ListAccessibleProjectsRequestSchema = z6.object({
2703
+ pageSize: z6.number().int().positive().max(100).optional().default(100)
2647
2704
  });
2648
- var ListProjectTasksRequestSchema = z5.object({
2649
- projectId: z5.string(),
2650
- status: z5.string().optional(),
2705
+ var ListProjectTasksRequestSchema = z6.object({
2706
+ projectId: z6.string(),
2707
+ status: z6.string().optional(),
2651
2708
  // Card types to include. Omitted/empty → defaults to ["task"] in the handler
2652
2709
  // (mirrors searchProjectTasks) so listing doesn't surface incidents/suggestions
2653
2710
  // unless asked. Enum validation lives at the MCP tool layer.
2654
- typeFilters: z5.array(z5.string()).optional(),
2655
- assigneeId: z5.string().optional(),
2656
- unassigned: z5.boolean().optional(),
2711
+ typeFilters: z6.array(z6.string()).optional(),
2712
+ assigneeId: z6.string().optional(),
2713
+ unassigned: z6.boolean().optional(),
2657
2714
  // Scope to a sub-project board when provided. Unlike the board layer's `?? null`
2658
2715
  // semantics, agents default to seeing the whole project when omitted.
2659
- subProjectId: z5.string().nullable().optional(),
2716
+ subProjectId: z6.string().nullable().optional(),
2660
2717
  // Plain equality on the on-hold flag: true = only parked cards, false =
2661
2718
  // exclude them, omitted = both. Deliberately NOT the board's
2662
2719
  // includeOnHold/surfaceActiveWork bucketing — an agent sweeping a backlog
2663
2720
  // needs the raw column, not a column projection.
2664
- onHold: z5.boolean().optional(),
2665
- limit: z5.number().int().positive().optional().default(50)
2721
+ onHold: z6.boolean().optional(),
2722
+ limit: z6.number().int().positive().optional().default(50)
2666
2723
  }).refine((p) => !(p.unassigned && p.assigneeId), {
2667
2724
  message: "Pass either assigneeId or unassigned, not both"
2668
2725
  });
2669
- var GetProjectTaskRequestSchema = z5.object({
2670
- projectId: z5.string(),
2671
- taskId: z5.string()
2726
+ var GetProjectTaskRequestSchema = z6.object({
2727
+ projectId: z6.string(),
2728
+ taskId: z6.string()
2672
2729
  });
2673
- var SearchProjectTasksRequestSchema = z5.object({
2674
- projectId: z5.string(),
2730
+ var SearchProjectTasksRequestSchema = z6.object({
2731
+ projectId: z6.string(),
2675
2732
  // Tag names, matched case-insensitively against the project glossary.
2676
- tagNames: z5.array(z5.string()).optional(),
2733
+ tagNames: z6.array(z6.string()).optional(),
2677
2734
  // How to combine tagNames: "any" (default) = carries at least one,
2678
2735
  // "all" = carries every one.
2679
- tagMatch: z5.enum(["any", "all"]).optional(),
2736
+ tagMatch: z6.enum(["any", "all"]).optional(),
2680
2737
  // Expand each named tag to its descendants in the tag DAG before matching,
2681
2738
  // so a parent tag sweeps its whole area. Default false.
2682
- includeChildTags: z5.boolean().optional(),
2683
- searchQuery: z5.string().optional(),
2684
- statusFilters: z5.array(z5.string()).optional(),
2739
+ includeChildTags: z6.boolean().optional(),
2740
+ searchQuery: z6.string().optional(),
2741
+ statusFilters: z6.array(z6.string()).optional(),
2685
2742
  // Card types to include. Omitted/empty → defaults to ["task"] in the handler so
2686
2743
  // search doesn't surface incidents/suggestions unless asked. Enum validation lives
2687
2744
  // at the MCP tool layer (mirrors statusFilters).
2688
- typeFilters: z5.array(z5.string()).optional(),
2689
- assigneeId: z5.string().optional(),
2690
- unassigned: z5.boolean().optional(),
2745
+ typeFilters: z6.array(z6.string()).optional(),
2746
+ assigneeId: z6.string().optional(),
2747
+ unassigned: z6.boolean().optional(),
2691
2748
  // Scope to a sub-project board when provided. Unlike the board layer's `?? null`
2692
2749
  // semantics, agents default to seeing the whole project when omitted.
2693
- subProjectId: z5.string().nullable().optional(),
2694
- limit: z5.number().int().positive().optional().default(20)
2750
+ subProjectId: z6.string().nullable().optional(),
2751
+ limit: z6.number().int().positive().optional().default(20)
2695
2752
  }).refine((p) => !(p.unassigned && p.assigneeId), {
2696
2753
  message: "Pass either assigneeId or unassigned, not both"
2697
2754
  });
2698
- var ListProjectTagsRequestSchema = z5.object({
2699
- projectId: z5.string(),
2755
+ var ListProjectTagsRequestSchema = z6.object({
2756
+ projectId: z6.string(),
2700
2757
  /** "summary" (default) omits inline context links; "full" includes them. */
2701
- detail: z5.enum(["summary", "full"]).optional()
2758
+ detail: z6.enum(["summary", "full"]).optional()
2702
2759
  });
2703
- var GetProjectTagRequestSchema = z5.object({
2704
- projectId: z5.string(),
2760
+ var GetProjectTagRequestSchema = z6.object({
2761
+ projectId: z6.string(),
2705
2762
  /** Tag id or exact (case-insensitive) tag name. */
2706
- tag: z5.string().min(1).max(100)
2763
+ tag: z6.string().min(1).max(100)
2707
2764
  });
2708
- var ListProjectTagAttachmentsRequestSchema = z5.object({
2709
- projectId: z5.string(),
2765
+ var ListProjectTagAttachmentsRequestSchema = z6.object({
2766
+ projectId: z6.string(),
2710
2767
  /** Tag id or exact (case-insensitive) tag name. */
2711
- tag: z5.string().min(1).max(100),
2712
- limit: z5.number().int().min(1).max(60).optional(),
2713
- offset: z5.number().int().min(0).optional()
2768
+ tag: z6.string().min(1).max(100),
2769
+ limit: z6.number().int().min(1).max(60).optional(),
2770
+ offset: z6.number().int().min(0).optional()
2714
2771
  });
2715
- var SetProjectFileTagsRequestSchema = z5.object({
2716
- projectId: z5.string(),
2717
- taskId: z5.string(),
2718
- fileId: z5.string(),
2719
- tags: z5.array(z5.string().min(1).max(MAX_FILE_TAG_LENGTH)).max(MAX_FILE_TAGS),
2720
- requestingUserId: z5.string().optional()
2772
+ var SetProjectFileTagsRequestSchema = z6.object({
2773
+ projectId: z6.string(),
2774
+ taskId: z6.string(),
2775
+ fileId: z6.string(),
2776
+ tags: z6.array(z6.string().min(1).max(MAX_FILE_TAG_LENGTH)).max(MAX_FILE_TAGS),
2777
+ requestingUserId: z6.string().optional()
2721
2778
  });
2722
- var GetProjectSummaryRequestSchema = z5.object({
2723
- projectId: z5.string()
2779
+ var GetProjectSummaryRequestSchema = z6.object({
2780
+ projectId: z6.string()
2724
2781
  });
2725
- var GetProjectOnboardingStatusRequestSchema = z5.object({
2726
- projectId: z5.string()
2782
+ var GetProjectOnboardingStatusRequestSchema = z6.object({
2783
+ projectId: z6.string()
2727
2784
  });
2728
- var GetProjectOnboardingStepRequestSchema = z5.object({
2729
- projectId: z5.string()
2785
+ var GetProjectOnboardingStepRequestSchema = z6.object({
2786
+ projectId: z6.string()
2730
2787
  });
2731
- var GetProjectConnectUrlsRequestSchema = z5.object({
2732
- projectId: z5.string()
2788
+ var GetProjectConnectUrlsRequestSchema = z6.object({
2789
+ projectId: z6.string()
2733
2790
  });
2734
- var conveyorCapabilitySchema = z5.enum([
2791
+ var conveyorCapabilitySchema = z6.enum([
2735
2792
  "read",
2736
2793
  "create",
2737
2794
  "update",
@@ -2739,475 +2796,475 @@ var conveyorCapabilitySchema = z5.enum([
2739
2796
  "files",
2740
2797
  "build"
2741
2798
  ]);
2742
- var GetConnectionContextRequestSchema = z5.object({
2743
- projectId: z5.string(),
2799
+ var GetConnectionContextRequestSchema = z6.object({
2800
+ projectId: z6.string(),
2744
2801
  // Optional board scope (CONVEYOR_SUBPROJECT_ID). Validated to belong to the
2745
2802
  // project in the handler; an invalid/foreign id is reported, not silently
2746
2803
  // dropped, so a mis-scoped connection is never presented as board-specific.
2747
- subProjectId: z5.string().nullable().optional()
2804
+ subProjectId: z6.string().nullable().optional()
2748
2805
  });
2749
- var VerifyConnectionRequestSchema = z5.object({
2750
- projectId: z5.string(),
2751
- subProjectId: z5.string().nullable().optional(),
2752
- intendedActions: z5.array(conveyorCapabilitySchema).optional()
2806
+ var VerifyConnectionRequestSchema = z6.object({
2807
+ projectId: z6.string(),
2808
+ subProjectId: z6.string().nullable().optional(),
2809
+ intendedActions: z6.array(conveyorCapabilitySchema).optional()
2753
2810
  });
2754
- var ListAccessibleSubprojectsRequestSchema = z5.object({
2755
- projectId: z5.string()
2811
+ var ListAccessibleSubprojectsRequestSchema = z6.object({
2812
+ projectId: z6.string()
2756
2813
  });
2757
- var CreateProjectTaskRequestSchema = z5.object({
2758
- projectId: z5.string(),
2759
- title: z5.string().min(1),
2814
+ var CreateProjectTaskRequestSchema = z6.object({
2815
+ projectId: z6.string(),
2816
+ title: z6.string().min(1),
2760
2817
  description: cardDescription2,
2761
- plan: z5.string().optional(),
2762
- status: z5.string().optional(),
2818
+ plan: z6.string().optional(),
2819
+ status: z6.string().optional(),
2763
2820
  // Assign to a sub-project board. Validated to belong to `projectId` in the handler.
2764
- subProjectId: z5.string().nullable().optional(),
2765
- requestingUserId: z5.string().optional()
2821
+ subProjectId: z6.string().nullable().optional(),
2822
+ requestingUserId: z6.string().optional()
2766
2823
  });
2767
- var SetProjectTaskParentRequestSchema = z5.object({
2768
- projectId: z5.string(),
2824
+ var SetProjectTaskParentRequestSchema = z6.object({
2825
+ projectId: z6.string(),
2769
2826
  /** Card to move — id or slug. */
2770
- taskId: z5.string().min(1),
2827
+ taskId: z6.string().min(1),
2771
2828
  /** New parent (id or slug), or null to detach. */
2772
- parentTaskId: z5.string().min(1).nullable(),
2773
- ordinal: z5.number().int().nonnegative().optional(),
2774
- followParentStatus: z5.boolean().optional(),
2775
- requestingUserId: z5.string().optional()
2829
+ parentTaskId: z6.string().min(1).nullable(),
2830
+ ordinal: z6.number().int().nonnegative().optional(),
2831
+ followParentStatus: z6.boolean().optional(),
2832
+ requestingUserId: z6.string().optional()
2776
2833
  }).strict();
2777
- var UpdateProjectTaskRequestSchema = z5.object({
2778
- projectId: z5.string(),
2779
- taskId: z5.string(),
2780
- title: z5.string().optional(),
2834
+ var UpdateProjectTaskRequestSchema = z6.object({
2835
+ projectId: z6.string(),
2836
+ taskId: z6.string(),
2837
+ title: z6.string().optional(),
2781
2838
  description: cardDescription2,
2782
- plan: z5.string().optional(),
2839
+ plan: z6.string().optional(),
2783
2840
  // Enum validation lives at the MCP tool layer (mirrors createProjectTask);
2784
2841
  // the handler routes through the shared updateStatus core (InProgress
2785
2842
  // dependency check + cleanup/board/Slack side effects), not the stricter
2786
2843
  // card-type-validating path the Socket.IO updateTaskStatus mutation uses.
2787
- status: z5.string().optional(),
2844
+ status: z6.string().optional(),
2788
2845
  // Canonical risk level, or null to clear. Resolved to the project's
2789
2846
  // configured Risk row (by rank) in the handler.
2790
2847
  risk: riskLevelSchema.nullable().optional(),
2791
2848
  // Story-point value, or null to clear. Resolved to the project's configured
2792
2849
  // StoryPoint row in the handler, which rejects an unconfigured value.
2793
- storyPointValue: z5.number().int().positive().nullable().optional(),
2794
- assignedUserId: z5.string().nullish(),
2850
+ storyPointValue: z6.number().int().positive().nullable().optional(),
2851
+ assignedUserId: z6.string().nullish(),
2795
2852
  // Move to a different sub-project board, or null to move to the parent board.
2796
2853
  // Validated to belong to `projectId` in the handler.
2797
- subProjectId: z5.string().nullable().optional(),
2854
+ subProjectId: z6.string().nullable().optional(),
2798
2855
  // Record the task's ACTUAL working branch (e.g. a locally-driven pack's
2799
2856
  // branch, so identification never mints a competing name and pack-child
2800
2857
  // merge handling matches reality), or null to detach. Guarded in the
2801
2858
  // handler: the ref must exist on origin and no live workspace may be bound
2802
2859
  // to a different branch.
2803
- githubBranch: z5.string().min(1).max(GIT_BRANCH_NAME_MAX).refine(isValidGitBranchName, { message: GIT_BRANCH_NAME_MESSAGE }).nullable().optional(),
2860
+ githubBranch: z6.string().min(1).max(GIT_BRANCH_NAME_MAX).refine(isValidGitBranchName, { message: GIT_BRANCH_NAME_MESSAGE }).nullable().optional(),
2804
2861
  // Park the card on hold (true) or return it to the active board (false).
2805
2862
  // The handler mirrors the web path's two side effects: a board re-bucket
2806
2863
  // event, and demotion to Open when an active-work card is parked.
2807
- onHold: z5.boolean().optional(),
2808
- requestingUserId: z5.string().optional()
2864
+ onHold: z6.boolean().optional(),
2865
+ requestingUserId: z6.string().optional()
2809
2866
  }).strict().refine(
2810
2867
  (v) => v.title !== void 0 || v.description !== void 0 || v.plan !== void 0 || v.status !== void 0 || v.risk !== void 0 || v.storyPointValue !== void 0 || v.assignedUserId !== void 0 || v.subProjectId !== void 0 || v.githubBranch !== void 0 || v.onHold !== void 0,
2811
2868
  {
2812
2869
  message: "update_task requires at least one field to change (title, description, plan, status, risk, storyPointValue, assignedUserId, subProjectId, githubBranch, or onHold)"
2813
2870
  }
2814
2871
  );
2815
- var TransitionProjectTaskStatusRequestSchema = z5.object({
2816
- projectId: z5.string(),
2817
- taskId: z5.string(),
2818
- toStatus: z5.string(),
2819
- expectedFromStatus: z5.string().optional(),
2872
+ var TransitionProjectTaskStatusRequestSchema = z6.object({
2873
+ projectId: z6.string(),
2874
+ taskId: z6.string(),
2875
+ toStatus: z6.string(),
2876
+ expectedFromStatus: z6.string().optional(),
2820
2877
  // Optional raise-only risk to attempt alongside the transition
2821
2878
  // (approve → low, request_changes → medium by default).
2822
2879
  risk: riskLevelSchema.optional(),
2823
- requestingUserId: z5.string().optional()
2824
- });
2825
- var MoveProjectCardRequestSchema = z5.object({
2826
- projectId: z5.string(),
2827
- taskId: z5.string(),
2828
- destinationProjectId: z5.string(),
2829
- requestingUserId: z5.string().optional()
2830
- });
2831
- var PostToProjectTaskChatRequestSchema = z5.object({
2832
- projectId: z5.string(),
2833
- taskId: z5.string(),
2834
- content: z5.string(),
2835
- requestingUserId: z5.string().optional()
2836
- });
2837
- var GetProjectTaskCliRequestSchema = z5.object({
2838
- projectId: z5.string(),
2839
- taskId: z5.string(),
2840
- limit: z5.number().int().positive().optional().default(50),
2841
- source: z5.string().optional()
2842
- });
2843
- var GetProjectTaskSessionsRequestSchema = z5.object({
2844
- projectId: z5.string(),
2845
- taskId: z5.string()
2846
- });
2847
- var QueryProjectGcpLogsRequestSchema = z5.object({
2848
- projectId: z5.string(),
2849
- env: z5.enum(["prod", "dev", "claudespace"]).optional(),
2850
- severity: z5.enum(["DEBUG", "INFO", "NOTICE", "WARNING", "ERROR", "CRITICAL", "ALERT", "EMERGENCY"]).optional(),
2851
- services: z5.array(z5.string().min(1).max(200)).max(25).optional(),
2852
- sqlInstances: z5.array(z5.string().min(1).max(200)).max(25).optional(),
2853
- allServices: z5.boolean().optional(),
2854
- search: z5.string().max(256).optional(),
2855
- filter: z5.string().max(1e3).optional(),
2856
- startTime: z5.string().optional(),
2857
- endTime: z5.string().optional(),
2858
- limit: z5.number().int().min(1).max(200).optional().default(50),
2859
- pageToken: z5.string().max(4096).optional()
2860
- });
2861
- var QueryProjectGrafanaLogsRequestSchema = z5.object({
2862
- projectId: z5.string(),
2863
- env: z5.enum(["prod", "dev"]).optional(),
2864
- services: z5.array(z5.string().min(1).max(200)).max(25).optional(),
2865
- level: z5.enum(["debug", "info", "warn", "error", "fatal"]).optional(),
2866
- search: z5.string().max(256).optional(),
2867
- logql: z5.string().max(2e3).optional(),
2868
- startTime: z5.string().optional(),
2869
- endTime: z5.string().optional(),
2870
- limit: z5.number().int().min(1).max(200).optional().default(50)
2871
- });
2872
- var driveFileNameSchema = z5.string().min(1).max(255).regex(/^[^/\\\r\n]+$/, "File names cannot contain slashes or line breaks");
2880
+ requestingUserId: z6.string().optional()
2881
+ });
2882
+ var MoveProjectCardRequestSchema = z6.object({
2883
+ projectId: z6.string(),
2884
+ taskId: z6.string(),
2885
+ destinationProjectId: z6.string(),
2886
+ requestingUserId: z6.string().optional()
2887
+ });
2888
+ var PostToProjectTaskChatRequestSchema = z6.object({
2889
+ projectId: z6.string(),
2890
+ taskId: z6.string(),
2891
+ content: z6.string(),
2892
+ requestingUserId: z6.string().optional()
2893
+ });
2894
+ var GetProjectTaskCliRequestSchema = z6.object({
2895
+ projectId: z6.string(),
2896
+ taskId: z6.string(),
2897
+ limit: z6.number().int().positive().optional().default(50),
2898
+ source: z6.string().optional()
2899
+ });
2900
+ var GetProjectTaskSessionsRequestSchema = z6.object({
2901
+ projectId: z6.string(),
2902
+ taskId: z6.string()
2903
+ });
2904
+ var QueryProjectGcpLogsRequestSchema = z6.object({
2905
+ projectId: z6.string(),
2906
+ env: z6.enum(["prod", "dev", "claudespace"]).optional(),
2907
+ severity: z6.enum(["DEBUG", "INFO", "NOTICE", "WARNING", "ERROR", "CRITICAL", "ALERT", "EMERGENCY"]).optional(),
2908
+ services: z6.array(z6.string().min(1).max(200)).max(25).optional(),
2909
+ sqlInstances: z6.array(z6.string().min(1).max(200)).max(25).optional(),
2910
+ allServices: z6.boolean().optional(),
2911
+ search: z6.string().max(256).optional(),
2912
+ filter: z6.string().max(1e3).optional(),
2913
+ startTime: z6.string().optional(),
2914
+ endTime: z6.string().optional(),
2915
+ limit: z6.number().int().min(1).max(200).optional().default(50),
2916
+ pageToken: z6.string().max(4096).optional()
2917
+ });
2918
+ var QueryProjectGrafanaLogsRequestSchema = z6.object({
2919
+ projectId: z6.string(),
2920
+ env: z6.enum(["prod", "dev"]).optional(),
2921
+ services: z6.array(z6.string().min(1).max(200)).max(25).optional(),
2922
+ level: z6.enum(["debug", "info", "warn", "error", "fatal"]).optional(),
2923
+ search: z6.string().max(256).optional(),
2924
+ logql: z6.string().max(2e3).optional(),
2925
+ startTime: z6.string().optional(),
2926
+ endTime: z6.string().optional(),
2927
+ limit: z6.number().int().min(1).max(200).optional().default(50)
2928
+ });
2929
+ var driveFileNameSchema = z6.string().min(1).max(255).regex(/^[^/\\\r\n]+$/, "File names cannot contain slashes or line breaks");
2873
2930
  var DRIVE_MAX_CONTENT_CHARS = 1e6;
2874
- var ListProjectDriveFilesRequestSchema = z5.object({
2875
- projectId: z5.string(),
2876
- folderId: z5.string().max(200).optional(),
2877
- search: z5.string().max(200).optional(),
2878
- limit: z5.number().int().min(1).max(200).optional()
2879
- });
2880
- var ReadProjectDriveFileRequestSchema = z5.object({
2881
- projectId: z5.string(),
2882
- fileId: z5.string().min(1).max(200)
2883
- });
2884
- var CreateProjectDriveFileRequestSchema = z5.object({
2885
- projectId: z5.string(),
2931
+ var ListProjectDriveFilesRequestSchema = z6.object({
2932
+ projectId: z6.string(),
2933
+ folderId: z6.string().max(200).optional(),
2934
+ search: z6.string().max(200).optional(),
2935
+ limit: z6.number().int().min(1).max(200).optional()
2936
+ });
2937
+ var ReadProjectDriveFileRequestSchema = z6.object({
2938
+ projectId: z6.string(),
2939
+ fileId: z6.string().min(1).max(200)
2940
+ });
2941
+ var CreateProjectDriveFileRequestSchema = z6.object({
2942
+ projectId: z6.string(),
2886
2943
  name: driveFileNameSchema,
2887
- content: z5.string().max(DRIVE_MAX_CONTENT_CHARS),
2888
- mimeType: z5.string().max(200).optional(),
2889
- folderId: z5.string().max(200).optional()
2890
- });
2891
- var UpdateProjectDriveFileRequestSchema = z5.object({
2892
- projectId: z5.string(),
2893
- fileId: z5.string().min(1).max(200),
2894
- content: z5.string().max(DRIVE_MAX_CONTENT_CHARS),
2895
- mimeType: z5.string().max(200).optional()
2896
- });
2897
- var DeleteProjectDriveFileRequestSchema = z5.object({
2898
- projectId: z5.string(),
2899
- fileId: z5.string().min(1).max(200)
2900
- });
2901
- var CreateProjectDriveFolderRequestSchema = z5.object({
2902
- projectId: z5.string(),
2944
+ content: z6.string().max(DRIVE_MAX_CONTENT_CHARS),
2945
+ mimeType: z6.string().max(200).optional(),
2946
+ folderId: z6.string().max(200).optional()
2947
+ });
2948
+ var UpdateProjectDriveFileRequestSchema = z6.object({
2949
+ projectId: z6.string(),
2950
+ fileId: z6.string().min(1).max(200),
2951
+ content: z6.string().max(DRIVE_MAX_CONTENT_CHARS),
2952
+ mimeType: z6.string().max(200).optional()
2953
+ });
2954
+ var DeleteProjectDriveFileRequestSchema = z6.object({
2955
+ projectId: z6.string(),
2956
+ fileId: z6.string().min(1).max(200)
2957
+ });
2958
+ var CreateProjectDriveFolderRequestSchema = z6.object({
2959
+ projectId: z6.string(),
2903
2960
  name: driveFileNameSchema,
2904
- folderId: z5.string().max(200).optional()
2961
+ folderId: z6.string().max(200).optional()
2905
2962
  });
2906
- var StartProjectBuildRequestSchema = z5.object({
2907
- projectId: z5.string(),
2908
- taskId: z5.string(),
2909
- requestingUserId: z5.string().optional()
2963
+ var StartProjectBuildRequestSchema = z6.object({
2964
+ projectId: z6.string(),
2965
+ taskId: z6.string(),
2966
+ requestingUserId: z6.string().optional()
2910
2967
  });
2911
- var StopProjectBuildRequestSchema = z5.object({
2912
- projectId: z5.string(),
2913
- taskId: z5.string(),
2914
- requestingUserId: z5.string().optional()
2968
+ var StopProjectBuildRequestSchema = z6.object({
2969
+ projectId: z6.string(),
2970
+ taskId: z6.string(),
2971
+ requestingUserId: z6.string().optional()
2915
2972
  });
2916
- var StartProjectWorkspaceRequestSchema = z5.object({
2917
- projectId: z5.string(),
2918
- requestingUserId: z5.string().optional()
2973
+ var StartProjectWorkspaceRequestSchema = z6.object({
2974
+ projectId: z6.string(),
2975
+ requestingUserId: z6.string().optional()
2919
2976
  });
2920
- var StopProjectWorkspaceRequestSchema = z5.object({
2921
- projectId: z5.string(),
2922
- destroy: z5.boolean().optional(),
2923
- requestingUserId: z5.string().optional()
2977
+ var StopProjectWorkspaceRequestSchema = z6.object({
2978
+ projectId: z6.string(),
2979
+ destroy: z6.boolean().optional(),
2980
+ requestingUserId: z6.string().optional()
2924
2981
  });
2925
- var ListMyLiveSessionsRequestSchema = z5.object({
2926
- projectId: z5.string(),
2982
+ var ListMyLiveSessionsRequestSchema = z6.object({
2983
+ projectId: z6.string(),
2927
2984
  /** Admin-only: list another member's sessions instead of the caller's. */
2928
- targetUserId: z5.string().optional()
2985
+ targetUserId: z6.string().optional()
2929
2986
  });
2930
- var ListProjectSessionGroupsRequestSchema = z5.object({
2931
- projectId: z5.string()
2987
+ var ListProjectSessionGroupsRequestSchema = z6.object({
2988
+ projectId: z6.string()
2932
2989
  });
2933
- var ListMyLiveSessionsAcrossProjectsRequestSchema = z5.object({});
2934
- var ListSessionGroupsAcrossProjectsRequestSchema = z5.object({});
2935
- var GetProjectAvailableTuisRequestSchema = z5.object({
2936
- projectId: z5.string()
2990
+ var ListMyLiveSessionsAcrossProjectsRequestSchema = z6.object({});
2991
+ var ListSessionGroupsAcrossProjectsRequestSchema = z6.object({});
2992
+ var GetProjectAvailableTuisRequestSchema = z6.object({
2993
+ projectId: z6.string()
2937
2994
  });
2938
- var StartAdhocSessionRequestSchema = z5.object({
2939
- projectId: z5.string(),
2940
- label: z5.string().max(200).optional(),
2995
+ var StartAdhocSessionRequestSchema = z6.object({
2996
+ projectId: z6.string(),
2997
+ label: z6.string().max(200).optional(),
2941
2998
  /** Coding-agent key to launch under — validated pick-time (ownership + TUI availability) in the handler. */
2942
- codingAgentKeyId: z5.string().optional(),
2999
+ codingAgentKeyId: z6.string().optional(),
2943
3000
  /** Model override (Claude model id) — overrides the launch key's own model. */
2944
- model: z5.string().max(200).optional(),
3001
+ model: z6.string().max(200).optional(),
2945
3002
  /**
2946
3003
  * Session role. Constrained: other task-less modes fall through to the pm
2947
3004
  * runner in the pod entrypoint, and "review" would crash without a task.
2948
3005
  */
2949
- mode: z5.enum(["adhoc", "pm"]).optional(),
3006
+ mode: z6.enum(["adhoc", "pm"]).optional(),
2950
3007
  /** Base branch to check out (defaults to the project's dev branch). */
2951
- branch: z5.string().max(300).optional(),
3008
+ branch: z6.string().max(300).optional(),
2952
3009
  /**
2953
3010
  * Server-assembled instructions the pod's TUI auto-submits once on first boot
2954
3011
  * (headless kickoff). Used by the onboarding "Set it up for me" flow to seed a
2955
3012
  * setup-driver prompt; the session stays watchable/interactive in the Sessions
2956
3013
  * view. `ensureAdhocWorkspace` persists it and clears it after first submit.
2957
3014
  */
2958
- initialPrompt: z5.string().max(2e4).optional(),
2959
- requestingUserId: z5.string().optional()
2960
- });
2961
- var StopAdhocSessionRequestSchema = z5.object({
2962
- projectId: z5.string(),
2963
- workspaceId: z5.string(),
2964
- destroy: z5.boolean().optional(),
2965
- requestingUserId: z5.string().optional()
2966
- });
2967
- var ResumeAdhocSessionRequestSchema = z5.object({
2968
- projectId: z5.string(),
2969
- workspaceId: z5.string(),
2970
- requestingUserId: z5.string().optional()
2971
- });
2972
- var RefreshCodingAgentKeyUsageRequestSchema = z5.object({
2973
- projectId: z5.string(),
2974
- keyId: z5.string().optional(),
2975
- requestingUserId: z5.string().optional()
2976
- });
2977
- var ListKeysToProbeRequestSchema = z5.object({
2978
- sessionId: z5.string()
2979
- });
2980
- var CreateProjectReleaseRequestSchema = z5.object({
2981
- projectId: z5.string(),
2982
- taskIds: z5.array(z5.string()).optional(),
2983
- requestingUserId: z5.string().optional()
2984
- });
2985
- var AddTasksToProjectReleaseRequestSchema = z5.object({
2986
- projectId: z5.string(),
2987
- taskIds: z5.array(z5.string()).min(1),
2988
- requestingUserId: z5.string().optional()
2989
- });
2990
- var ApproveProjectMergePRRequestSchema = z5.object({
2991
- projectId: z5.string(),
2992
- childTaskId: z5.string(),
2993
- requestingUserId: z5.string().optional()
2994
- });
2995
- var ListProjectSubtasksRequestSchema = z5.object({
2996
- projectId: z5.string(),
2997
- taskId: z5.string()
2998
- });
2999
- var CreateProjectSubtaskRequestSchema = z5.object({
3000
- projectId: z5.string(),
3001
- parentTaskId: z5.string(),
3002
- title: z5.string().min(1),
3015
+ initialPrompt: z6.string().max(2e4).optional(),
3016
+ requestingUserId: z6.string().optional()
3017
+ });
3018
+ var StopAdhocSessionRequestSchema = z6.object({
3019
+ projectId: z6.string(),
3020
+ workspaceId: z6.string(),
3021
+ destroy: z6.boolean().optional(),
3022
+ requestingUserId: z6.string().optional()
3023
+ });
3024
+ var ResumeAdhocSessionRequestSchema = z6.object({
3025
+ projectId: z6.string(),
3026
+ workspaceId: z6.string(),
3027
+ requestingUserId: z6.string().optional()
3028
+ });
3029
+ var RefreshCodingAgentKeyUsageRequestSchema = z6.object({
3030
+ projectId: z6.string(),
3031
+ keyId: z6.string().optional(),
3032
+ requestingUserId: z6.string().optional()
3033
+ });
3034
+ var ListKeysToProbeRequestSchema = z6.object({
3035
+ sessionId: z6.string()
3036
+ });
3037
+ var CreateProjectReleaseRequestSchema = z6.object({
3038
+ projectId: z6.string(),
3039
+ taskIds: z6.array(z6.string()).optional(),
3040
+ requestingUserId: z6.string().optional()
3041
+ });
3042
+ var AddTasksToProjectReleaseRequestSchema = z6.object({
3043
+ projectId: z6.string(),
3044
+ taskIds: z6.array(z6.string()).min(1),
3045
+ requestingUserId: z6.string().optional()
3046
+ });
3047
+ var ApproveProjectMergePRRequestSchema = z6.object({
3048
+ projectId: z6.string(),
3049
+ childTaskId: z6.string(),
3050
+ requestingUserId: z6.string().optional()
3051
+ });
3052
+ var ListProjectSubtasksRequestSchema = z6.object({
3053
+ projectId: z6.string(),
3054
+ taskId: z6.string()
3055
+ });
3056
+ var CreateProjectSubtaskRequestSchema = z6.object({
3057
+ projectId: z6.string(),
3058
+ parentTaskId: z6.string(),
3059
+ title: z6.string().min(1),
3003
3060
  description: cardDescription2,
3004
- plan: z5.string().optional(),
3005
- ordinal: z5.number().int().nonnegative().optional(),
3006
- storyPointValue: z5.number().int().positive().optional(),
3007
- followParentStatus: z5.boolean().optional(),
3061
+ plan: z6.string().optional(),
3062
+ ordinal: z6.number().int().nonnegative().optional(),
3063
+ storyPointValue: z6.number().int().positive().optional(),
3064
+ followParentStatus: z6.boolean().optional(),
3008
3065
  /** Sibling subtask ids or slugs this subtask blocks on (explicit dependency
3009
3066
  * metadata — preferred over encoding order in plan text / ordinal). */
3010
- dependsOn: z5.array(z5.string().min(1)).max(32).optional(),
3011
- requestingUserId: z5.string().optional()
3067
+ dependsOn: z6.array(z6.string().min(1)).max(32).optional(),
3068
+ requestingUserId: z6.string().optional()
3012
3069
  });
3013
- var UpdateProjectSubtaskRequestSchema = z5.object({
3014
- projectId: z5.string(),
3015
- subtaskId: z5.string(),
3016
- title: z5.string().optional(),
3070
+ var UpdateProjectSubtaskRequestSchema = z6.object({
3071
+ projectId: z6.string(),
3072
+ subtaskId: z6.string(),
3073
+ title: z6.string().optional(),
3017
3074
  description: cardDescription2,
3018
- plan: z5.string().optional(),
3019
- status: z5.string().optional(),
3020
- ordinal: z5.number().int().nonnegative().optional(),
3021
- storyPointValue: z5.number().int().positive().optional(),
3022
- followParentStatus: z5.boolean().optional(),
3075
+ plan: z6.string().optional(),
3076
+ status: z6.string().optional(),
3077
+ ordinal: z6.number().int().nonnegative().optional(),
3078
+ storyPointValue: z6.number().int().positive().optional(),
3079
+ followParentStatus: z6.boolean().optional(),
3023
3080
  /** Replace-set of sibling subtask ids/slugs this subtask blocks on ([] clears).
3024
3081
  * Mirrors the in-pod updateSubtask semantics. */
3025
- dependsOn: z5.array(z5.string().min(1)).max(32).optional(),
3026
- requestingUserId: z5.string().optional()
3027
- });
3028
- var DeleteProjectSubtaskRequestSchema = z5.object({
3029
- projectId: z5.string(),
3030
- subtaskId: z5.string(),
3031
- requestingUserId: z5.string().optional()
3032
- });
3033
- var GetProjectTaskChatRequestSchema = z5.object({
3034
- projectId: z5.string(),
3035
- taskId: z5.string(),
3036
- limit: z5.number().int().positive().optional().default(20)
3037
- });
3038
- var AddProjectTaskDependencyRequestSchema = z5.object({
3039
- projectId: z5.string(),
3040
- taskId: z5.string(),
3041
- dependsOnSlugOrId: z5.string(),
3042
- requestingUserId: z5.string().optional()
3043
- });
3044
- var RemoveProjectTaskDependencyRequestSchema = z5.object({
3045
- projectId: z5.string(),
3046
- taskId: z5.string(),
3047
- dependsOnSlugOrId: z5.string(),
3048
- requestingUserId: z5.string().optional()
3049
- });
3050
- var VoteProjectSuggestionRequestSchema = z5.object({
3051
- projectId: z5.string(),
3052
- suggestionId: z5.string(),
3053
- value: z5.union([z5.literal(1), z5.literal(-1)]),
3054
- requestingUserId: z5.string().optional()
3055
- });
3056
- var GetProjectTaskDependenciesRequestSchema = z5.object({
3057
- projectId: z5.string(),
3058
- taskId: z5.string()
3059
- });
3060
- var ListProjectTaskFilesRequestSchema = z5.object({
3061
- projectId: z5.string(),
3062
- taskId: z5.string()
3063
- });
3064
- var GetProjectAttachmentRequestSchema = z5.object({
3065
- projectId: z5.string(),
3066
- taskId: z5.string(),
3067
- fileId: z5.string(),
3082
+ dependsOn: z6.array(z6.string().min(1)).max(32).optional(),
3083
+ requestingUserId: z6.string().optional()
3084
+ });
3085
+ var DeleteProjectSubtaskRequestSchema = z6.object({
3086
+ projectId: z6.string(),
3087
+ subtaskId: z6.string(),
3088
+ requestingUserId: z6.string().optional()
3089
+ });
3090
+ var GetProjectTaskChatRequestSchema = z6.object({
3091
+ projectId: z6.string(),
3092
+ taskId: z6.string(),
3093
+ limit: z6.number().int().positive().optional().default(20)
3094
+ });
3095
+ var AddProjectTaskDependencyRequestSchema = z6.object({
3096
+ projectId: z6.string(),
3097
+ taskId: z6.string(),
3098
+ dependsOnSlugOrId: z6.string(),
3099
+ requestingUserId: z6.string().optional()
3100
+ });
3101
+ var RemoveProjectTaskDependencyRequestSchema = z6.object({
3102
+ projectId: z6.string(),
3103
+ taskId: z6.string(),
3104
+ dependsOnSlugOrId: z6.string(),
3105
+ requestingUserId: z6.string().optional()
3106
+ });
3107
+ var VoteProjectSuggestionRequestSchema = z6.object({
3108
+ projectId: z6.string(),
3109
+ suggestionId: z6.string(),
3110
+ value: z6.union([z6.literal(1), z6.literal(-1)]),
3111
+ requestingUserId: z6.string().optional()
3112
+ });
3113
+ var GetProjectTaskDependenciesRequestSchema = z6.object({
3114
+ projectId: z6.string(),
3115
+ taskId: z6.string()
3116
+ });
3117
+ var ListProjectTaskFilesRequestSchema = z6.object({
3118
+ projectId: z6.string(),
3119
+ taskId: z6.string()
3120
+ });
3121
+ var GetProjectAttachmentRequestSchema = z6.object({
3122
+ projectId: z6.string(),
3123
+ taskId: z6.string(),
3124
+ fileId: z6.string(),
3068
3125
  /** Byte offset into text content (paging large logs/JSON). Default 0. */
3069
- offset: z5.number().int().nonnegative().optional(),
3126
+ offset: z6.number().int().nonnegative().optional(),
3070
3127
  /** Max bytes of text content to return from `offset`. Server default applies. */
3071
- maxBytes: z5.number().int().positive().optional()
3072
- });
3073
- var DeleteProjectTaskFileRequestSchema = z5.object({
3074
- projectId: z5.string(),
3075
- taskId: z5.string(),
3076
- fileId: z5.string(),
3077
- requestingUserId: z5.string().optional()
3078
- });
3079
- var RequestProjectFileUploadRequestSchema = z5.object({
3080
- projectId: z5.string(),
3081
- taskId: z5.string(),
3082
- fileName: z5.string().min(1).max(255),
3083
- mimeType: z5.string().min(1).max(128),
3084
- fileSize: z5.number().int().positive().max(MAX_FILE_SIZE_BYTES),
3085
- requestingUserId: z5.string().optional()
3086
- });
3087
- var ConfirmProjectFileUploadRequestSchema = z5.object({
3088
- projectId: z5.string(),
3089
- taskId: z5.string(),
3090
- fileId: z5.string(),
3128
+ maxBytes: z6.number().int().positive().optional()
3129
+ });
3130
+ var DeleteProjectTaskFileRequestSchema = z6.object({
3131
+ projectId: z6.string(),
3132
+ taskId: z6.string(),
3133
+ fileId: z6.string(),
3134
+ requestingUserId: z6.string().optional()
3135
+ });
3136
+ var RequestProjectFileUploadRequestSchema = z6.object({
3137
+ projectId: z6.string(),
3138
+ taskId: z6.string(),
3139
+ fileName: z6.string().min(1).max(255),
3140
+ mimeType: z6.string().min(1).max(128),
3141
+ fileSize: z6.number().int().positive().max(MAX_FILE_SIZE_BYTES),
3142
+ requestingUserId: z6.string().optional()
3143
+ });
3144
+ var ConfirmProjectFileUploadRequestSchema = z6.object({
3145
+ projectId: z6.string(),
3146
+ taskId: z6.string(),
3147
+ fileId: z6.string(),
3091
3148
  /** When set, the attachment is also posted to the task chat with this text. */
3092
- comment: z5.string().max(2e3).optional(),
3149
+ comment: z6.string().max(2e3).optional(),
3093
3150
  /** Glossary tag names (or ids) this file is an example of. */
3094
- tags: z5.array(z5.string().min(1).max(MAX_FILE_TAG_LENGTH)).max(MAX_FILE_TAGS).optional(),
3095
- requestingUserId: z5.string().optional()
3096
- });
3097
- var CreateProjectPullRequestRequestSchema = z5.object({
3098
- projectId: z5.string(),
3099
- taskId: z5.string(),
3100
- title: z5.string().min(1),
3101
- body: z5.string(),
3102
- head: z5.string().optional(),
3103
- base: z5.string().optional(),
3104
- requestingUserId: z5.string().optional()
3105
- });
3106
- var ListProjectMembersRequestSchema = z5.object({
3107
- projectId: z5.string()
3108
- });
3109
- var AddProjectTaskReviewerRequestSchema = z5.object({
3110
- projectId: z5.string(),
3111
- taskId: z5.string(),
3112
- userId: z5.string(),
3113
- requestingUserId: z5.string().optional()
3114
- });
3115
- var RemoveProjectTaskReviewerRequestSchema = z5.object({
3116
- projectId: z5.string(),
3117
- taskId: z5.string(),
3118
- userId: z5.string(),
3119
- requestingUserId: z5.string().optional()
3120
- });
3121
- var ListProjectManualTestsRequestSchema = z5.object({
3122
- projectId: z5.string(),
3123
- taskId: z5.string()
3124
- });
3125
- var QueryProjectManualTestsRequestSchema = z5.object({
3126
- projectId: z5.string(),
3127
- cardStatuses: z5.array(z5.string()).optional(),
3128
- testStatuses: z5.array(z5.enum(["open", "approved", "rejected"])).optional()
3129
- });
3130
- var SetProjectManualTestsRequestSchema = z5.object({
3131
- projectId: z5.string(),
3132
- taskId: z5.string(),
3151
+ tags: z6.array(z6.string().min(1).max(MAX_FILE_TAG_LENGTH)).max(MAX_FILE_TAGS).optional(),
3152
+ requestingUserId: z6.string().optional()
3153
+ });
3154
+ var CreateProjectPullRequestRequestSchema = z6.object({
3155
+ projectId: z6.string(),
3156
+ taskId: z6.string(),
3157
+ title: z6.string().min(1),
3158
+ body: z6.string(),
3159
+ head: z6.string().optional(),
3160
+ base: z6.string().optional(),
3161
+ requestingUserId: z6.string().optional()
3162
+ });
3163
+ var ListProjectMembersRequestSchema = z6.object({
3164
+ projectId: z6.string()
3165
+ });
3166
+ var AddProjectTaskReviewerRequestSchema = z6.object({
3167
+ projectId: z6.string(),
3168
+ taskId: z6.string(),
3169
+ userId: z6.string(),
3170
+ requestingUserId: z6.string().optional()
3171
+ });
3172
+ var RemoveProjectTaskReviewerRequestSchema = z6.object({
3173
+ projectId: z6.string(),
3174
+ taskId: z6.string(),
3175
+ userId: z6.string(),
3176
+ requestingUserId: z6.string().optional()
3177
+ });
3178
+ var ListProjectManualTestsRequestSchema = z6.object({
3179
+ projectId: z6.string(),
3180
+ taskId: z6.string()
3181
+ });
3182
+ var QueryProjectManualTestsRequestSchema = z6.object({
3183
+ projectId: z6.string(),
3184
+ cardStatuses: z6.array(z6.string()).optional(),
3185
+ testStatuses: z6.array(z6.enum(["open", "approved", "rejected"])).optional()
3186
+ });
3187
+ var SetProjectManualTestsRequestSchema = z6.object({
3188
+ projectId: z6.string(),
3189
+ taskId: z6.string(),
3133
3190
  items: ManualTestItemsSchema,
3134
- requestingUserId: z5.string().optional()
3135
- });
3136
- var EditProjectManualTestRequestSchema = z5.object({
3137
- projectId: z5.string(),
3138
- taskId: z5.string(),
3139
- title: z5.string().min(1),
3140
- newTitle: z5.string().min(1),
3141
- requestingUserId: z5.string().optional()
3142
- });
3143
- var RemoveProjectManualTestRequestSchema = z5.object({
3144
- projectId: z5.string(),
3145
- taskId: z5.string(),
3146
- title: z5.string().min(1),
3147
- requestingUserId: z5.string().optional()
3148
- });
3149
- var ApproveProjectManualTestRequestSchema = z5.object({
3150
- projectId: z5.string(),
3151
- taskId: z5.string(),
3152
- title: z5.string().min(1),
3153
- requestingUserId: z5.string().optional()
3154
- });
3155
- var RejectProjectManualTestRequestSchema = z5.object({
3156
- projectId: z5.string(),
3157
- taskId: z5.string(),
3158
- title: z5.string().min(1),
3159
- reason: z5.string().min(1).max(2e3),
3160
- requestingUserId: z5.string().optional()
3161
- });
3162
- var CreateProjectSuggestionRequestSchema = z5.object({
3163
- projectId: z5.string(),
3164
- title: z5.string().min(1),
3191
+ requestingUserId: z6.string().optional()
3192
+ });
3193
+ var EditProjectManualTestRequestSchema = z6.object({
3194
+ projectId: z6.string(),
3195
+ taskId: z6.string(),
3196
+ title: z6.string().min(1),
3197
+ newTitle: z6.string().min(1),
3198
+ requestingUserId: z6.string().optional()
3199
+ });
3200
+ var RemoveProjectManualTestRequestSchema = z6.object({
3201
+ projectId: z6.string(),
3202
+ taskId: z6.string(),
3203
+ title: z6.string().min(1),
3204
+ requestingUserId: z6.string().optional()
3205
+ });
3206
+ var ApproveProjectManualTestRequestSchema = z6.object({
3207
+ projectId: z6.string(),
3208
+ taskId: z6.string(),
3209
+ title: z6.string().min(1),
3210
+ requestingUserId: z6.string().optional()
3211
+ });
3212
+ var RejectProjectManualTestRequestSchema = z6.object({
3213
+ projectId: z6.string(),
3214
+ taskId: z6.string(),
3215
+ title: z6.string().min(1),
3216
+ reason: z6.string().min(1).max(2e3),
3217
+ requestingUserId: z6.string().optional()
3218
+ });
3219
+ var CreateProjectSuggestionRequestSchema = z6.object({
3220
+ projectId: z6.string(),
3221
+ title: z6.string().min(1),
3165
3222
  description: cardDescription2,
3166
- tagNames: z5.array(z5.string()).optional(),
3167
- requestingUserId: z5.string().optional()
3223
+ tagNames: z6.array(z6.string()).optional(),
3224
+ requestingUserId: z6.string().optional()
3168
3225
  });
3169
- var ListProjectChannelsRequestSchema = z6.object({
3170
- projectId: z6.string()
3226
+ var ListProjectChannelsRequestSchema = z7.object({
3227
+ projectId: z7.string()
3171
3228
  });
3172
3229
  var READ_CHANNEL_MESSAGES_MAX_LIMIT = 50;
3173
- var ReadChannelMessagesRequestSchema = z6.object({
3174
- projectId: z6.string(),
3175
- channelId: z6.string().min(1).max(200),
3176
- limit: z6.number().int().min(1).max(READ_CHANNEL_MESSAGES_MAX_LIMIT).optional(),
3230
+ var ReadChannelMessagesRequestSchema = z7.object({
3231
+ projectId: z7.string(),
3232
+ channelId: z7.string().min(1).max(200),
3233
+ limit: z7.number().int().min(1).max(READ_CHANNEL_MESSAGES_MAX_LIMIT).optional(),
3177
3234
  /** Provider-native cursor: return messages OLDER than this one. */
3178
- before: z6.string().max(100).optional(),
3235
+ before: z7.string().max(100).optional(),
3179
3236
  /** Provider-native cursor: return messages NEWER than this one. */
3180
- after: z6.string().max(100).optional(),
3237
+ after: z7.string().max(100).optional(),
3181
3238
  /**
3182
3239
  * Read one thread instead of the channel surface. Slack calls this a
3183
3240
  * `thread_ts`; on Discord it is the thread channel's id. One field for both,
3184
3241
  * because a caller holding a `threadTs` from a previous read should not have
3185
3242
  * to know which provider produced it.
3186
3243
  */
3187
- threadTs: z6.string().max(100).optional()
3244
+ threadTs: z7.string().max(100).optional()
3188
3245
  });
3189
3246
  var POST_CHANNEL_MESSAGE_MAX_CHARS = 1800;
3190
- var PostChannelMessageRequestSchema = z6.object({
3191
- projectId: z6.string(),
3192
- channelId: z6.string().min(1).max(200),
3193
- text: z6.string().min(1).max(POST_CHANNEL_MESSAGE_MAX_CHARS),
3247
+ var PostChannelMessageRequestSchema = z7.object({
3248
+ projectId: z7.string(),
3249
+ channelId: z7.string().min(1).max(200),
3250
+ text: z7.string().min(1).max(POST_CHANNEL_MESSAGE_MAX_CHARS),
3194
3251
  /** Reply inside a thread rather than to the channel. */
3195
- threadTs: z6.string().max(100).optional()
3252
+ threadTs: z7.string().max(100).optional()
3196
3253
  });
3197
3254
  var GET_ANALYTICS_SUMMARY_MAX_RANGE_DAYS = 90;
3198
- var GetProjectAnalyticsSummaryRequestSchema = z6.object({
3199
- projectId: z6.string(),
3200
- rangeDays: z6.number().int().min(1).max(GET_ANALYTICS_SUMMARY_MAX_RANGE_DAYS).optional(),
3201
- campaign: z6.string().max(200).optional()
3255
+ var GetProjectAnalyticsSummaryRequestSchema = z7.object({
3256
+ projectId: z7.string(),
3257
+ rangeDays: z7.number().int().min(1).max(GET_ANALYTICS_SUMMARY_MAX_RANGE_DAYS).optional(),
3258
+ campaign: z7.string().max(200).optional()
3202
3259
  });
3203
- var RequestWorkspaceRecycleRequestSchema = z7.object({
3204
- sessionId: z7.string(),
3205
- reason: z7.string().max(2e3)
3260
+ var RequestWorkspaceRecycleRequestSchema = z8.object({
3261
+ sessionId: z8.string(),
3262
+ reason: z8.string().max(2e3)
3206
3263
  });
3207
- var ReportApiOutageRequestSchema = z7.object({
3208
- sessionId: z7.string(),
3209
- detail: z7.string().max(2e3),
3210
- attempts: z7.number().int().min(0).max(100)
3264
+ var ReportApiOutageRequestSchema = z8.object({
3265
+ sessionId: z8.string(),
3266
+ detail: z8.string().max(2e3),
3267
+ attempts: z8.number().int().min(0).max(100)
3211
3268
  });
3212
3269
  var CONTEXT_LINK_LOCATOR_MAX = 300;
3213
3270
  var TEST_TITLE = /\b(?:it|test|describe)(?:\.\w+)?\s*\(\s*(['"`])((?:(?!\1)[\s\S])*)\1/g;
@@ -3224,130 +3281,130 @@ function locatorMatchesContent(content, locatorType, locator) {
3224
3281
  var TAG_DESCRIPTION_MAX = CARD_DESCRIPTION_MAX;
3225
3282
  var TAG_OVERVIEW_MAX = 32e3;
3226
3283
  var TAG_REASON_MAX = 500;
3227
- var ProjectTagContextPathSchema = z8.object({
3228
- type: z8.enum(["rule", "doc", "file", "folder"]),
3229
- path: z8.string().min(1).max(500),
3230
- label: z8.string().max(100).optional(),
3284
+ var ProjectTagContextPathSchema = z9.object({
3285
+ type: z9.enum(["rule", "doc", "file", "folder"]),
3286
+ path: z9.string().min(1).max(500),
3287
+ label: z9.string().max(100).optional(),
3231
3288
  /** Verified-link tether — text that must keep existing in the file. */
3232
- locator: z8.string().min(1).max(CONTEXT_LINK_LOCATOR_MAX).regex(/^[^\r\n]*$/, "Locator cannot contain line breaks").optional(),
3289
+ locator: z9.string().min(1).max(CONTEXT_LINK_LOCATOR_MAX).regex(/^[^\r\n]*$/, "Locator cannot contain line breaks").optional(),
3233
3290
  /** test = must appear in a real test/describe title; code = any substring. */
3234
- locatorType: z8.enum(["test", "code"]).optional()
3291
+ locatorType: z9.enum(["test", "code"]).optional()
3235
3292
  }).refine((link) => link.locator === void 0 === (link.locatorType === void 0), {
3236
3293
  message: "locator and locatorType must be provided together"
3237
3294
  }).refine((link) => link.locator === void 0 || link.type !== "folder", {
3238
3295
  message: "folder links cannot carry a locator"
3239
3296
  });
3240
- var hexColor = z8.string().regex(/^#[0-9a-fA-F]{6}$/, "Expected #RRGGBB hex color");
3241
- var overviewPathSchema = z8.string().min(1).max(500).regex(/^[^\r\n]*$/, "Overview path cannot contain line breaks");
3242
- var CreateProjectTagRequestSchema = z8.object({
3243
- projectId: z8.string(),
3244
- name: z8.string().min(1).max(50),
3297
+ var hexColor = z9.string().regex(/^#[0-9a-fA-F]{6}$/, "Expected #RRGGBB hex color");
3298
+ var overviewPathSchema = z9.string().min(1).max(500).regex(/^[^\r\n]*$/, "Overview path cannot contain line breaks");
3299
+ var CreateProjectTagRequestSchema = z9.object({
3300
+ projectId: z9.string(),
3301
+ name: z9.string().min(1).max(50),
3245
3302
  color: hexColor.optional(),
3246
- description: z8.string().max(TAG_DESCRIPTION_MAX).optional(),
3247
- overview: z8.string().max(TAG_OVERVIEW_MAX).optional(),
3303
+ description: z9.string().max(TAG_DESCRIPTION_MAX).optional(),
3304
+ overview: z9.string().max(TAG_OVERVIEW_MAX).optional(),
3248
3305
  /** Source the overview from this repo file (stored overview stays as the pending fallback). */
3249
3306
  overviewPath: overviewPathSchema.optional(),
3250
- contextPaths: z8.array(ProjectTagContextPathSchema).max(20).optional(),
3307
+ contextPaths: z9.array(ProjectTagContextPathSchema).max(20).optional(),
3251
3308
  /** Parents to link at create time (multi-parent DAG). */
3252
- parentTagIds: z8.array(z8.string()).max(25).optional(),
3253
- requestingUserId: z8.string().optional()
3309
+ parentTagIds: z9.array(z9.string()).max(25).optional(),
3310
+ requestingUserId: z9.string().optional()
3254
3311
  });
3255
- var UpdateProjectTagRequestSchema = z8.object({
3256
- projectId: z8.string(),
3257
- tagId: z8.string(),
3258
- name: z8.string().min(1).max(50).optional(),
3312
+ var UpdateProjectTagRequestSchema = z9.object({
3313
+ projectId: z9.string(),
3314
+ tagId: z9.string(),
3315
+ name: z9.string().min(1).max(50).optional(),
3259
3316
  color: hexColor.optional(),
3260
- description: z8.string().max(TAG_DESCRIPTION_MAX).optional(),
3317
+ description: z9.string().max(TAG_DESCRIPTION_MAX).optional(),
3261
3318
  /** Full markdown glossary body; null clears it. Rejected while overviewPath is set. */
3262
- overview: z8.string().max(TAG_OVERVIEW_MAX).nullable().optional(),
3319
+ overview: z9.string().max(TAG_OVERVIEW_MAX).nullable().optional(),
3263
3320
  /** Repo file to source the overview from; null clears back to the stored overview. */
3264
3321
  overviewPath: overviewPathSchema.nullable().optional(),
3265
3322
  /** Full replacement of the tag's context links when provided. */
3266
- contextPaths: z8.array(ProjectTagContextPathSchema).max(20).optional(),
3323
+ contextPaths: z9.array(ProjectTagContextPathSchema).max(20).optional(),
3267
3324
  /** Full-set replacement of the tag's parent tags (multi-parent DAG). */
3268
- parentTagIds: z8.array(z8.string()).max(25).optional(),
3325
+ parentTagIds: z9.array(z9.string()).max(25).optional(),
3269
3326
  /** One-line revision provenance, recorded in the tag's history. */
3270
- reason: z8.string().max(TAG_REASON_MAX).optional(),
3327
+ reason: z9.string().max(TAG_REASON_MAX).optional(),
3271
3328
  /** Card the caller was working in — stamped into the revision history. */
3272
- taskId: z8.string().optional(),
3273
- requestingUserId: z8.string().optional()
3329
+ taskId: z9.string().optional(),
3330
+ requestingUserId: z9.string().optional()
3274
3331
  });
3275
- var PostToProjectChatRequestSchema = z8.object({
3276
- projectId: z8.string(),
3277
- content: z8.string().min(1).max(2e4),
3278
- requestingUserId: z8.string().optional(),
3332
+ var PostToProjectChatRequestSchema = z9.object({
3333
+ projectId: z9.string(),
3334
+ content: z9.string().min(1).max(2e4),
3335
+ requestingUserId: z9.string().optional(),
3279
3336
  /** Marks the post so the server can persist it beyond chat (tag-audit summaries land in tag history). */
3280
- kind: z8.enum(["tag_audit_summary"]).optional()
3281
- });
3282
- var StartTagAuditRequestSchema = z8.object({
3283
- projectId: z8.string(),
3284
- requestingUserId: z8.string().optional()
3285
- });
3286
- var StartTaskAuditRequestSchema = z8.object({
3287
- projectId: z8.string(),
3288
- taskIds: z8.array(z8.string()).min(1).max(20),
3289
- requestingUserId: z8.string().optional()
3290
- });
3291
- var GetActiveAuditSessionsRequestSchema = z8.object({
3292
- projectId: z8.string()
3293
- });
3294
- var ReportTaskAuditResultRequestSchema = z8.object({
3295
- projectId: z8.string(),
3296
- taskId: z8.string(),
3297
- summary: z8.string(),
3298
- turnGrades: z8.array(
3299
- z8.object({
3300
- turnIndex: z8.number(),
3301
- phase: z8.enum(["planning", "building", "human"]),
3302
- grade: z8.enum(["correct", "neutral", "blunder"]),
3303
- reasoning: z8.string(),
3304
- eventType: z8.string(),
3305
- eventSummary: z8.string()
3337
+ kind: z9.enum(["tag_audit_summary"]).optional()
3338
+ });
3339
+ var StartTagAuditRequestSchema = z9.object({
3340
+ projectId: z9.string(),
3341
+ requestingUserId: z9.string().optional()
3342
+ });
3343
+ var StartTaskAuditRequestSchema = z9.object({
3344
+ projectId: z9.string(),
3345
+ taskIds: z9.array(z9.string()).min(1).max(20),
3346
+ requestingUserId: z9.string().optional()
3347
+ });
3348
+ var GetActiveAuditSessionsRequestSchema = z9.object({
3349
+ projectId: z9.string()
3350
+ });
3351
+ var ReportTaskAuditResultRequestSchema = z9.object({
3352
+ projectId: z9.string(),
3353
+ taskId: z9.string(),
3354
+ summary: z9.string(),
3355
+ turnGrades: z9.array(
3356
+ z9.object({
3357
+ turnIndex: z9.number(),
3358
+ phase: z9.enum(["planning", "building", "human"]),
3359
+ grade: z9.enum(["correct", "neutral", "blunder"]),
3360
+ reasoning: z9.string(),
3361
+ eventType: z9.string(),
3362
+ eventSummary: z9.string()
3306
3363
  })
3307
3364
  ),
3308
- planningAccuracy: z8.number().nullable(),
3309
- buildingAccuracy: z8.number().nullable(),
3310
- humanAccuracy: z8.number().nullable(),
3311
- planningCorrect: z8.number(),
3312
- planningNeutral: z8.number(),
3313
- planningBlunder: z8.number(),
3314
- buildingCorrect: z8.number(),
3315
- buildingNeutral: z8.number(),
3316
- buildingBlunder: z8.number(),
3317
- humanCorrect: z8.number(),
3318
- humanNeutral: z8.number(),
3319
- humanBlunder: z8.number(),
3320
- humanEvaluations: z8.array(
3321
- z8.object({
3322
- messageIndex: z8.number(),
3323
- rating: z8.union([z8.literal(-1), z8.literal(0), z8.literal(1)]),
3324
- reasoning: z8.string()
3365
+ planningAccuracy: z9.number().nullable(),
3366
+ buildingAccuracy: z9.number().nullable(),
3367
+ humanAccuracy: z9.number().nullable(),
3368
+ planningCorrect: z9.number(),
3369
+ planningNeutral: z9.number(),
3370
+ planningBlunder: z9.number(),
3371
+ buildingCorrect: z9.number(),
3372
+ buildingNeutral: z9.number(),
3373
+ buildingBlunder: z9.number(),
3374
+ humanCorrect: z9.number(),
3375
+ humanNeutral: z9.number(),
3376
+ humanBlunder: z9.number(),
3377
+ humanEvaluations: z9.array(
3378
+ z9.object({
3379
+ messageIndex: z9.number(),
3380
+ rating: z9.union([z9.literal(-1), z9.literal(0), z9.literal(1)]),
3381
+ reasoning: z9.string()
3325
3382
  })
3326
3383
  ).optional(),
3327
- suggestionIds: z8.array(z8.string()),
3328
- auditCostUsd: z8.number().nullable(),
3329
- model: z8.string().nullable(),
3384
+ suggestionIds: z9.array(z9.string()),
3385
+ auditCostUsd: z9.number().nullable(),
3386
+ model: z9.string().nullable(),
3330
3387
  /** When set, the audit is marked failed with this message instead. */
3331
- error: z8.string().optional()
3388
+ error: z9.string().optional()
3332
3389
  });
3333
- var GetTaskAuditsRequestSchema = z8.object({
3334
- projectId: z8.string(),
3335
- limit: z8.number().int().positive().max(200).optional().default(50)
3390
+ var GetTaskAuditsRequestSchema = z9.object({
3391
+ projectId: z9.string(),
3392
+ limit: z9.number().int().positive().max(200).optional().default(50)
3336
3393
  });
3337
- var GetTaskAuditRequestSchema = z8.object({
3338
- projectId: z8.string(),
3339
- auditId: z8.string()
3394
+ var GetTaskAuditRequestSchema = z9.object({
3395
+ projectId: z9.string(),
3396
+ auditId: z9.string()
3340
3397
  });
3341
- var GetTaskAuditAggregatesRequestSchema = z8.object({
3342
- projectId: z8.string()
3398
+ var GetTaskAuditAggregatesRequestSchema = z9.object({
3399
+ projectId: z9.string()
3343
3400
  });
3344
- var DeleteTaskAuditRequestSchema = z8.object({
3345
- projectId: z8.string(),
3346
- auditId: z8.string(),
3347
- requestingUserId: z8.string().optional()
3401
+ var DeleteTaskAuditRequestSchema = z9.object({
3402
+ projectId: z9.string(),
3403
+ auditId: z9.string(),
3404
+ requestingUserId: z9.string().optional()
3348
3405
  });
3349
- var MarkInitialPromptSubmittedRequestSchema = z8.object({
3350
- sessionId: z8.string()
3406
+ var MarkInitialPromptSubmittedRequestSchema = z9.object({
3407
+ sessionId: z9.string()
3351
3408
  });
3352
3409
  var CRITICAL_AUTOMATED_SOURCES = /* @__PURE__ */ new Set([
3353
3410
  "ci_failure",
@@ -3401,165 +3458,165 @@ var DECISION_DEADLINE_MIN_HOURS = 1;
3401
3458
  var DECISION_DEADLINE_MAX_DAYS = 30;
3402
3459
  var DECISION_DEADLINE_MAX_HOURS = DECISION_DEADLINE_MAX_DAYS * 24;
3403
3460
  var DECISION_LIST_MAX_LIMIT = 200;
3404
- var decisionIdSchema = z9.string().cuid("Invalid decision ID");
3405
- var optionInputSchema = z9.object({
3406
- label: z9.string().min(1, "Option label is required").max(DECISION_OPTION_LABEL_MAX),
3407
- description: z9.string().min(1, "Describe the option as GIVEN / WHEN / THEN"),
3408
- kind: z9.enum(DECISION_OPTION_KINDS).optional()
3461
+ var decisionIdSchema = z10.string().cuid("Invalid decision ID");
3462
+ var optionInputSchema = z10.object({
3463
+ label: z10.string().min(1, "Option label is required").max(DECISION_OPTION_LABEL_MAX),
3464
+ description: z10.string().min(1, "Describe the option as GIVEN / WHEN / THEN"),
3465
+ kind: z10.enum(DECISION_OPTION_KINDS).optional()
3409
3466
  });
3410
- var optionsArraySchema = z9.array(optionInputSchema).min(DECISION_OPTIONS_MIN, `A decision needs at least ${DECISION_OPTIONS_MIN} options`).max(
3467
+ var optionsArraySchema = z10.array(optionInputSchema).min(DECISION_OPTIONS_MIN, `A decision needs at least ${DECISION_OPTIONS_MIN} options`).max(
3411
3468
  DECISION_OPTIONS_MAX,
3412
3469
  `A decision takes at most ${DECISION_OPTIONS_MAX} options \u2014 more than that means the question is not framed yet`
3413
3470
  );
3414
- var CreateDecisionRequestSchema = z9.object({
3415
- projectId: z9.string().cuid("Invalid project ID"),
3471
+ var CreateDecisionRequestSchema = z10.object({
3472
+ projectId: z10.string().cuid("Invalid project ID"),
3416
3473
  /** The question, as one plain sentence. */
3417
- title: z9.string().min(1, "A decision needs a question").max(DECISION_QUESTION_MAX),
3418
- description: z9.string().max(CARD_DESCRIPTION_MAX).optional(),
3419
- context: z9.string().min(1, "Context is required \u2014 say why this is being asked now"),
3474
+ title: z10.string().min(1, "A decision needs a question").max(DECISION_QUESTION_MAX),
3475
+ description: z10.string().max(CARD_DESCRIPTION_MAX).optional(),
3476
+ context: z10.string().min(1, "Context is required \u2014 say why this is being asked now"),
3420
3477
  options: optionsArraySchema,
3421
3478
  /** 1-based position of the option that wins on silence. */
3422
- defaultOptionOrdinal: z9.number().int().min(1).max(DECISION_OPTIONS_MAX),
3423
- deadlineHours: z9.number().min(DECISION_DEADLINE_MIN_HOURS).max(DECISION_DEADLINE_MAX_HOURS).optional(),
3479
+ defaultOptionOrdinal: z10.number().int().min(1).max(DECISION_OPTIONS_MAX),
3480
+ deadlineHours: z10.number().min(DECISION_DEADLINE_MIN_HOURS).max(DECISION_DEADLINE_MAX_HOURS).optional(),
3424
3481
  /** Cards this decision blocks, by cuid or slug. */
3425
- impactedCardRefs: z9.array(z9.string().min(1)).max(50).optional(),
3426
- tagNames: z9.array(z9.string().min(1)).max(10).optional(),
3427
- raisedByTaskId: z9.string().min(1).optional(),
3428
- raisedByPrNumber: z9.number().int().positive().optional()
3482
+ impactedCardRefs: z10.array(z10.string().min(1)).max(50).optional(),
3483
+ tagNames: z10.array(z10.string().min(1)).max(10).optional(),
3484
+ raisedByTaskId: z10.string().min(1).optional(),
3485
+ raisedByPrNumber: z10.number().int().positive().optional()
3429
3486
  });
3430
- var VoteDecisionRequestSchema = z9.object({
3487
+ var VoteDecisionRequestSchema = z10.object({
3431
3488
  decisionId: decisionIdSchema,
3432
- optionId: z9.string().cuid("Invalid option ID"),
3433
- reason: z9.string().max(DECISION_VOTE_REASON_MAX).optional(),
3434
- source: z9.enum(DECISION_VOTE_SOURCES).optional()
3489
+ optionId: z10.string().cuid("Invalid option ID"),
3490
+ reason: z10.string().max(DECISION_VOTE_REASON_MAX).optional(),
3491
+ source: z10.enum(DECISION_VOTE_SOURCES).optional()
3435
3492
  });
3436
- var RemoveDecisionVoteRequestSchema = z9.object({
3493
+ var RemoveDecisionVoteRequestSchema = z10.object({
3437
3494
  decisionId: decisionIdSchema
3438
3495
  });
3439
- var ResolveDecisionRequestSchema = z9.object({
3496
+ var ResolveDecisionRequestSchema = z10.object({
3440
3497
  decisionId: decisionIdSchema,
3441
- chosenOptionId: z9.string().cuid("Invalid option ID"),
3442
- resolution: z9.string().min(1, "A resolution is required \u2014 say what was decided").max(DECISION_RESOLUTION_MAX),
3443
- resolutionNotes: z9.string().optional()
3498
+ chosenOptionId: z10.string().cuid("Invalid option ID"),
3499
+ resolution: z10.string().min(1, "A resolution is required \u2014 say what was decided").max(DECISION_RESOLUTION_MAX),
3500
+ resolutionNotes: z10.string().optional()
3444
3501
  });
3445
- var CancelDecisionRequestSchema = z9.object({
3502
+ var CancelDecisionRequestSchema = z10.object({
3446
3503
  decisionId: decisionIdSchema,
3447
3504
  /** Why it is being dropped. Posted to the decision thread. */
3448
- reason: z9.string().max(DECISION_RESOLUTION_MAX).optional()
3505
+ reason: z10.string().max(DECISION_RESOLUTION_MAX).optional()
3449
3506
  });
3450
- var BulkDecisionIdsRequestSchema = z9.object({
3451
- projectId: z9.string().cuid("Invalid project ID"),
3452
- decisionIds: z9.array(z9.string().cuid()).min(1).max(200)
3507
+ var BulkDecisionIdsRequestSchema = z10.object({
3508
+ projectId: z10.string().cuid("Invalid project ID"),
3509
+ decisionIds: z10.array(z10.string().cuid()).min(1).max(200)
3453
3510
  });
3454
- var ReopenDecisionRequestSchema = z9.object({
3511
+ var ReopenDecisionRequestSchema = z10.object({
3455
3512
  decisionId: decisionIdSchema,
3456
- deadlineHours: z9.number().min(DECISION_DEADLINE_MIN_HOURS).max(DECISION_DEADLINE_MAX_HOURS).optional()
3513
+ deadlineHours: z10.number().min(DECISION_DEADLINE_MIN_HOURS).max(DECISION_DEADLINE_MAX_HOURS).optional()
3457
3514
  });
3458
- var UpdateDecisionRequestSchema = z9.object({
3515
+ var UpdateDecisionRequestSchema = z10.object({
3459
3516
  decisionId: decisionIdSchema,
3460
- title: z9.string().min(1).max(200).optional(),
3461
- description: z9.string().max(CARD_DESCRIPTION_MAX).optional(),
3462
- context: z9.string().min(1).optional(),
3463
- deadlineAt: z9.string().datetime().optional(),
3517
+ title: z10.string().min(1).max(200).optional(),
3518
+ description: z10.string().max(CARD_DESCRIPTION_MAX).optional(),
3519
+ context: z10.string().min(1).optional(),
3520
+ deadlineAt: z10.string().datetime().optional(),
3464
3521
  /** Only accepted while the decision has zero votes. */
3465
3522
  options: optionsArraySchema.optional(),
3466
- defaultOptionOrdinal: z9.number().int().min(1).max(DECISION_OPTIONS_MAX).optional(),
3467
- addImpactedCardRefs: z9.array(z9.string().min(1)).max(50).optional(),
3468
- removeImpactedCardIds: z9.array(z9.string().min(1)).max(50).optional()
3523
+ defaultOptionOrdinal: z10.number().int().min(1).max(DECISION_OPTIONS_MAX).optional(),
3524
+ addImpactedCardRefs: z10.array(z10.string().min(1)).max(50).optional(),
3525
+ removeImpactedCardIds: z10.array(z10.string().min(1)).max(50).optional()
3469
3526
  });
3470
- var GetDecisionRequestSchema = z9.object({
3527
+ var GetDecisionRequestSchema = z10.object({
3471
3528
  /** cuid or slug. A slug needs `projectId` to resolve unambiguously. */
3472
- decisionId: z9.string().min(1),
3473
- projectId: z9.string().cuid().optional()
3529
+ decisionId: z10.string().min(1),
3530
+ projectId: z10.string().cuid().optional()
3474
3531
  });
3475
- var ListDecisionsRequestSchema = z9.object({
3476
- projectId: z9.string().cuid("Invalid project ID"),
3477
- status: z9.enum(DECISION_STATUS_LABELS).optional(),
3532
+ var ListDecisionsRequestSchema = z10.object({
3533
+ projectId: z10.string().cuid("Invalid project ID"),
3534
+ status: z10.enum(DECISION_STATUS_LABELS).optional(),
3478
3535
  /** Tag name, not id — an agent knows the tag it is working under. */
3479
- tag: z9.string().min(1).optional(),
3536
+ tag: z10.string().min(1).optional(),
3480
3537
  /** Decisions that this card is blocked by (cuid or slug). */
3481
- cardId: z9.string().min(1).optional(),
3482
- query: z9.string().min(1).optional(),
3483
- limit: z9.number().int().min(1).max(DECISION_LIST_MAX_LIMIT).optional()
3538
+ cardId: z10.string().min(1).optional(),
3539
+ query: z10.string().min(1).optional(),
3540
+ limit: z10.number().int().min(1).max(DECISION_LIST_MAX_LIMIT).optional()
3484
3541
  });
3485
- var optionInput = z10.object({
3486
- label: z10.string().min(1).max(DECISION_OPTION_LABEL_MAX),
3487
- description: z10.string().min(1),
3488
- kind: z10.enum(DECISION_OPTION_KINDS).optional()
3542
+ var optionInput = z11.object({
3543
+ label: z11.string().min(1).max(DECISION_OPTION_LABEL_MAX),
3544
+ description: z11.string().min(1),
3545
+ kind: z11.enum(DECISION_OPTION_KINDS).optional()
3489
3546
  });
3490
- var optionsInput = z10.array(optionInput).min(DECISION_OPTIONS_MIN).max(DECISION_OPTIONS_MAX);
3491
- var deadlineHours = z10.number().min(DECISION_DEADLINE_MIN_HOURS).max(DECISION_DEADLINE_MAX_HOURS).optional();
3492
- var CreateProjectDecisionRequestSchema = z10.object({
3493
- projectId: z10.string(),
3494
- question: z10.string().min(1).max(200),
3495
- summary: z10.string().max(CARD_DESCRIPTION_MAX).optional(),
3496
- context: z10.string().min(1),
3547
+ var optionsInput = z11.array(optionInput).min(DECISION_OPTIONS_MIN).max(DECISION_OPTIONS_MAX);
3548
+ var deadlineHours = z11.number().min(DECISION_DEADLINE_MIN_HOURS).max(DECISION_DEADLINE_MAX_HOURS).optional();
3549
+ var CreateProjectDecisionRequestSchema = z11.object({
3550
+ projectId: z11.string(),
3551
+ question: z11.string().min(1).max(200),
3552
+ summary: z11.string().max(CARD_DESCRIPTION_MAX).optional(),
3553
+ context: z11.string().min(1),
3497
3554
  options: optionsInput,
3498
- defaultOption: z10.number().int().min(1).max(DECISION_OPTIONS_MAX),
3555
+ defaultOption: z11.number().int().min(1).max(DECISION_OPTIONS_MAX),
3499
3556
  deadlineHours,
3500
- impactedCards: z10.array(z10.string().min(1)).max(50).optional(),
3557
+ impactedCards: z11.array(z11.string().min(1)).max(50).optional(),
3501
3558
  /**
3502
3559
  * Pod surface only: also block the card this session is working on. The
3503
3560
  * session's task id is resolved SERVER-side from `sessionId` — a
3504
3561
  * client-supplied card id would let a pod block any card in the project.
3505
3562
  */
3506
- includeCurrentCard: z10.boolean().optional(),
3507
- sessionId: z10.string().optional(),
3508
- tagNames: z10.array(z10.string().min(1)).max(10).optional(),
3509
- raisedByPr: z10.number().int().positive().optional(),
3563
+ includeCurrentCard: z11.boolean().optional(),
3564
+ sessionId: z11.string().optional(),
3565
+ tagNames: z11.array(z11.string().min(1)).max(10).optional(),
3566
+ raisedByPr: z11.number().int().positive().optional(),
3510
3567
  /** Slug or id of the card that raised the question. A link back, not a block. */
3511
- raisedByCard: z10.string().min(1).optional(),
3568
+ raisedByCard: z11.string().min(1).optional(),
3512
3569
  /** Absolute deadline (ISO 8601). Wins over `deadlineHours` when both are sent. */
3513
- deadlineAt: z10.string().datetime({ offset: true }).optional(),
3514
- requestingUserId: z10.string().optional()
3570
+ deadlineAt: z11.string().datetime({ offset: true }).optional(),
3571
+ requestingUserId: z11.string().optional()
3515
3572
  });
3516
- var ListProjectDecisionsRequestSchema = z10.object({
3517
- projectId: z10.string(),
3518
- status: z10.enum(DECISION_STATUS_LABELS).optional(),
3519
- tag: z10.string().min(1).optional(),
3520
- card: z10.string().min(1).optional(),
3521
- query: z10.string().min(1).optional(),
3522
- limit: z10.number().int().min(1).max(DECISION_LIST_MAX_LIMIT).optional(),
3523
- requestingUserId: z10.string().optional()
3524
- });
3525
- var GetProjectDecisionRequestSchema = z10.object({
3526
- projectId: z10.string(),
3527
- decision: z10.string().min(1),
3528
- requestingUserId: z10.string().optional()
3573
+ var ListProjectDecisionsRequestSchema = z11.object({
3574
+ projectId: z11.string(),
3575
+ status: z11.enum(DECISION_STATUS_LABELS).optional(),
3576
+ tag: z11.string().min(1).optional(),
3577
+ card: z11.string().min(1).optional(),
3578
+ query: z11.string().min(1).optional(),
3579
+ limit: z11.number().int().min(1).max(DECISION_LIST_MAX_LIMIT).optional(),
3580
+ requestingUserId: z11.string().optional()
3581
+ });
3582
+ var GetProjectDecisionRequestSchema = z11.object({
3583
+ projectId: z11.string(),
3584
+ decision: z11.string().min(1),
3585
+ requestingUserId: z11.string().optional()
3529
3586
  });
3530
- var VoteProjectDecisionRequestSchema = z10.object({
3531
- projectId: z10.string(),
3532
- decision: z10.string().min(1),
3587
+ var VoteProjectDecisionRequestSchema = z11.object({
3588
+ projectId: z11.string(),
3589
+ decision: z11.string().min(1),
3533
3590
  /** An option id, or its 1-based position. */
3534
- option: z10.string().min(1),
3535
- reason: z10.string().max(CARD_DESCRIPTION_MAX).optional(),
3536
- requestingUserId: z10.string().optional()
3537
- });
3538
- var ResolveProjectDecisionRequestSchema = z10.object({
3539
- projectId: z10.string(),
3540
- decision: z10.string().min(1),
3541
- option: z10.string().min(1),
3542
- resolution: z10.string().min(1).max(DECISION_RESOLUTION_MAX),
3543
- notes: z10.string().optional(),
3544
- requestingUserId: z10.string().optional()
3545
- });
3546
- var UpdateProjectDecisionRequestSchema = z10.object({
3547
- projectId: z10.string(),
3548
- decision: z10.string().min(1),
3549
- question: z10.string().min(1).max(200).optional(),
3550
- summary: z10.string().max(CARD_DESCRIPTION_MAX).optional(),
3551
- context: z10.string().min(1).optional(),
3591
+ option: z11.string().min(1),
3592
+ reason: z11.string().max(CARD_DESCRIPTION_MAX).optional(),
3593
+ requestingUserId: z11.string().optional()
3594
+ });
3595
+ var ResolveProjectDecisionRequestSchema = z11.object({
3596
+ projectId: z11.string(),
3597
+ decision: z11.string().min(1),
3598
+ option: z11.string().min(1),
3599
+ resolution: z11.string().min(1).max(DECISION_RESOLUTION_MAX),
3600
+ notes: z11.string().optional(),
3601
+ requestingUserId: z11.string().optional()
3602
+ });
3603
+ var UpdateProjectDecisionRequestSchema = z11.object({
3604
+ projectId: z11.string(),
3605
+ decision: z11.string().min(1),
3606
+ question: z11.string().min(1).max(200).optional(),
3607
+ summary: z11.string().max(CARD_DESCRIPTION_MAX).optional(),
3608
+ context: z11.string().min(1).optional(),
3552
3609
  /** Accepted only while nobody has voted. */
3553
3610
  options: optionsInput.optional(),
3554
- defaultOption: z10.number().int().min(1).max(DECISION_OPTIONS_MAX).optional(),
3555
- tagNames: z10.array(z10.string().min(1)).max(10).optional(),
3611
+ defaultOption: z11.number().int().min(1).max(DECISION_OPTIONS_MAX).optional(),
3612
+ tagNames: z11.array(z11.string().min(1)).max(10).optional(),
3556
3613
  deadlineHours,
3557
3614
  /** Absolute deadline (ISO 8601). Wins over `deadlineHours` when both are sent. */
3558
- deadlineAt: z10.string().datetime({ offset: true }).optional(),
3559
- addImpactedCards: z10.array(z10.string().min(1)).max(50).optional(),
3560
- removeImpactedCards: z10.array(z10.string().min(1)).max(50).optional(),
3561
- status: z10.enum(["Cancelled", "Open"]).optional(),
3562
- requestingUserId: z10.string().optional()
3615
+ deadlineAt: z11.string().datetime({ offset: true }).optional(),
3616
+ addImpactedCards: z11.array(z11.string().min(1)).max(50).optional(),
3617
+ removeImpactedCards: z11.array(z11.string().min(1)).max(50).optional(),
3618
+ status: z11.enum(["Cancelled", "Open"]).optional(),
3619
+ requestingUserId: z11.string().optional()
3563
3620
  });
3564
3621
  var EVALUATE_MAX_QUESTIONS = 32;
3565
3622
  var EVALUATE_MAX_ITEMS = 100;
@@ -3567,29 +3624,29 @@ var EVALUATE_ITEM_MAX_CHARS = 8e3;
3567
3624
  var EVALUATE_REQUEST_MAX_CHARS = 4e5;
3568
3625
  var TEXT_MAX = 1e3;
3569
3626
  var QUESTION_KEY = /^[A-Za-z0-9_-]{1,64}$/;
3570
- var EvaluateQuestionSchema = z11.object({
3571
- key: z11.string().regex(QUESTION_KEY, "key must be 1-64 letters, digits, _ or -"),
3572
- type: z11.enum(["noul", "choice", "score"]),
3573
- instructions: z11.string().min(1).max(4e3),
3574
- options: z11.array(
3575
- z11.object({
3576
- key: z11.string().min(1).max(200),
3577
- description: z11.string().min(1).max(TEXT_MAX)
3627
+ var EvaluateQuestionSchema = z12.object({
3628
+ key: z12.string().regex(QUESTION_KEY, "key must be 1-64 letters, digits, _ or -"),
3629
+ type: z12.enum(["noul", "choice", "score"]),
3630
+ instructions: z12.string().min(1).max(4e3),
3631
+ options: z12.array(
3632
+ z12.object({
3633
+ key: z12.string().min(1).max(200),
3634
+ description: z12.string().min(1).max(TEXT_MAX)
3578
3635
  })
3579
3636
  ).optional(),
3580
- levels: z11.array(z11.string().min(1).max(TEXT_MAX)).optional()
3637
+ levels: z12.array(z12.string().min(1).max(TEXT_MAX)).optional()
3581
3638
  }).superRefine((q, ctx) => {
3582
3639
  if (q.type === "choice") {
3583
3640
  const n = q.options?.length ?? 0;
3584
3641
  if (n < 2 || n > 255) {
3585
3642
  ctx.addIssue({
3586
- code: z11.ZodIssueCode.custom,
3643
+ code: z12.ZodIssueCode.custom,
3587
3644
  path: ["options"],
3588
3645
  message: "a choice question needs 2-255 options"
3589
3646
  });
3590
3647
  } else if (new Set(q.options?.map((o) => o.key)).size !== n) {
3591
3648
  ctx.addIssue({
3592
- code: z11.ZodIssueCode.custom,
3649
+ code: z12.ZodIssueCode.custom,
3593
3650
  path: ["options"],
3594
3651
  message: "option keys must be unique"
3595
3652
  });
@@ -3599,36 +3656,36 @@ var EvaluateQuestionSchema = z11.object({
3599
3656
  const n = q.levels?.length ?? 0;
3600
3657
  if (n < 2 || n > 10) {
3601
3658
  ctx.addIssue({
3602
- code: z11.ZodIssueCode.custom,
3659
+ code: z12.ZodIssueCode.custom,
3603
3660
  path: ["levels"],
3604
3661
  message: "a score question needs 2-10 levels"
3605
3662
  });
3606
3663
  }
3607
3664
  }
3608
3665
  });
3609
- var EvaluateQuestionsRequestSchema = z11.object({
3610
- projectId: z11.string(),
3611
- state: z11.string().max(JEV_STATE_MAX_CHARS).optional(),
3612
- items: z11.array(z11.string().max(EVALUATE_ITEM_MAX_CHARS)).max(EVALUATE_MAX_ITEMS).optional(),
3613
- questions: z11.array(EvaluateQuestionSchema).min(1).max(EVALUATE_MAX_QUESTIONS)
3666
+ var EvaluateQuestionsRequestSchema = z12.object({
3667
+ projectId: z12.string(),
3668
+ state: z12.string().max(JEV_STATE_MAX_CHARS).optional(),
3669
+ items: z12.array(z12.string().max(EVALUATE_ITEM_MAX_CHARS)).max(EVALUATE_MAX_ITEMS).optional(),
3670
+ questions: z12.array(EvaluateQuestionSchema).min(1).max(EVALUATE_MAX_QUESTIONS)
3614
3671
  }).superRefine((req, ctx) => {
3615
3672
  if (req.state === void 0 && (!req.items || req.items.length === 0)) {
3616
3673
  ctx.addIssue({
3617
- code: z11.ZodIssueCode.custom,
3674
+ code: z12.ZodIssueCode.custom,
3618
3675
  path: ["state"],
3619
3676
  message: "pass state, or a non-empty items array"
3620
3677
  });
3621
3678
  }
3622
3679
  if (JSON.stringify(req).length > EVALUATE_REQUEST_MAX_CHARS) {
3623
3680
  ctx.addIssue({
3624
- code: z11.ZodIssueCode.custom,
3681
+ code: z12.ZodIssueCode.custom,
3625
3682
  path: [],
3626
3683
  message: `the request is over ${EVALUATE_REQUEST_MAX_CHARS} characters; split the items across calls`
3627
3684
  });
3628
3685
  }
3629
3686
  if (new Set(req.questions.map((q) => q.key)).size !== req.questions.length) {
3630
3687
  ctx.addIssue({
3631
- code: z11.ZodIssueCode.custom,
3688
+ code: z12.ZodIssueCode.custom,
3632
3689
  path: ["questions"],
3633
3690
  message: "question keys must be unique"
3634
3691
  });
@@ -3666,129 +3723,129 @@ var MEETING_TITLE_MAX = 200;
3666
3723
  var MEETING_OCCURRED_AT_MIN_YEAR = 2e3;
3667
3724
  var MEETING_OCCURRED_AT_MAX_FUTURE_MS = 48 * 60 * 60 * 1e3;
3668
3725
  var OCCURRED_AT_RANGE_MESSAGE = `occurredAt must be a real date: no earlier than ${MEETING_OCCURRED_AT_MIN_YEAR}, and no more than 48 hours in the future.`;
3669
- var MeetingOccurredAtSchema = z12.string().datetime().refine((value) => {
3726
+ var MeetingOccurredAtSchema = z13.string().datetime().refine((value) => {
3670
3727
  const ms = Date.parse(value);
3671
3728
  if (Number.isNaN(ms)) return false;
3672
3729
  if (ms > Date.now() + MEETING_OCCURRED_AT_MAX_FUTURE_MS) return false;
3673
3730
  return new Date(ms).getUTCFullYear() >= MEETING_OCCURRED_AT_MIN_YEAR;
3674
3731
  }, OCCURRED_AT_RANGE_MESSAGE);
3675
- var CreateMeetingFromTranscriptRequestSchema = z12.object({
3676
- projectId: z12.string().cuid(),
3677
- rawText: z12.string().min(1).max(MEETING_TRANSCRIPT_MAX_CHARS),
3678
- title: z12.string().min(1).max(MEETING_TITLE_MAX).optional(),
3732
+ var CreateMeetingFromTranscriptRequestSchema = z13.object({
3733
+ projectId: z13.string().cuid(),
3734
+ rawText: z13.string().min(1).max(MEETING_TRANSCRIPT_MAX_CHARS),
3735
+ title: z13.string().min(1).max(MEETING_TITLE_MAX).optional(),
3679
3736
  /** ISO 8601. Defaults to now when the source carries no date. */
3680
3737
  occurredAt: MeetingOccurredAtSchema.optional(),
3681
3738
  /** Override auto-detection. Rarely needed; detection handles the three formats. */
3682
- format: z12.enum(["text", "vtt", "srt"]).optional(),
3683
- source: z12.enum(["manual", "slack"]).optional()
3739
+ format: z13.enum(["text", "vtt", "srt"]).optional(),
3740
+ source: z13.enum(["manual", "slack"]).optional()
3684
3741
  });
3685
- var GetMeetingRequestSchema = z12.object({
3686
- projectId: z12.string().cuid(),
3687
- meetingId: z12.string().cuid()
3742
+ var GetMeetingRequestSchema = z13.object({
3743
+ projectId: z13.string().cuid(),
3744
+ meetingId: z13.string().cuid()
3688
3745
  });
3689
- var UpdateMeetingRequestSchema = z12.object({
3690
- projectId: z12.string().cuid(),
3691
- meetingId: z12.string().cuid(),
3692
- title: z12.string().min(1).max(MEETING_TITLE_MAX).optional(),
3746
+ var UpdateMeetingRequestSchema = z13.object({
3747
+ projectId: z13.string().cuid(),
3748
+ meetingId: z13.string().cuid(),
3749
+ title: z13.string().min(1).max(MEETING_TITLE_MAX).optional(),
3693
3750
  occurredAt: MeetingOccurredAtSchema.optional()
3694
3751
  });
3695
- var RegenerateMeetingSummaryRequestSchema = z12.object({
3696
- projectId: z12.string().cuid(),
3697
- meetingId: z12.string().cuid()
3752
+ var RegenerateMeetingSummaryRequestSchema = z13.object({
3753
+ projectId: z13.string().cuid(),
3754
+ meetingId: z13.string().cuid()
3698
3755
  });
3699
- var DeleteMeetingRequestSchema = z12.object({
3700
- projectId: z12.string().cuid(),
3701
- meetingId: z12.string().cuid()
3756
+ var DeleteMeetingRequestSchema = z13.object({
3757
+ projectId: z13.string().cuid(),
3758
+ meetingId: z13.string().cuid()
3702
3759
  });
3703
- var checklistTitle = z12.string().min(1).max(MEETING_CHECKLIST_TITLE_MAX);
3704
- var ListMeetingChecklistRequestSchema = z12.object({
3705
- projectId: z12.string().cuid(),
3706
- meetingId: z12.string().cuid()
3760
+ var checklistTitle = z13.string().min(1).max(MEETING_CHECKLIST_TITLE_MAX);
3761
+ var ListMeetingChecklistRequestSchema = z13.object({
3762
+ projectId: z13.string().cuid(),
3763
+ meetingId: z13.string().cuid()
3707
3764
  });
3708
- var AddMeetingChecklistItemsRequestSchema = z12.object({
3709
- projectId: z12.string().cuid(),
3710
- meetingId: z12.string().cuid(),
3711
- items: z12.array(z12.object({ title: checklistTitle })).min(1).max(50)
3765
+ var AddMeetingChecklistItemsRequestSchema = z13.object({
3766
+ projectId: z13.string().cuid(),
3767
+ meetingId: z13.string().cuid(),
3768
+ items: z13.array(z13.object({ title: checklistTitle })).min(1).max(50)
3712
3769
  });
3713
- var UpdateMeetingChecklistItemRequestSchema = z12.object({
3714
- projectId: z12.string().cuid(),
3715
- meetingId: z12.string().cuid(),
3716
- itemId: z12.string().cuid(),
3770
+ var UpdateMeetingChecklistItemRequestSchema = z13.object({
3771
+ projectId: z13.string().cuid(),
3772
+ meetingId: z13.string().cuid(),
3773
+ itemId: z13.string().cuid(),
3717
3774
  title: checklistTitle.optional(),
3718
- ordinal: z12.number().int().min(0).optional(),
3775
+ ordinal: z13.number().int().min(0).optional(),
3719
3776
  /** Explicit null clears the link; undefined leaves it alone. */
3720
- linkedTaskId: z12.string().cuid().nullable().optional()
3777
+ linkedTaskId: z13.string().cuid().nullable().optional()
3721
3778
  }).refine(
3722
3779
  (v) => v.title !== void 0 || v.ordinal !== void 0 || v.linkedTaskId !== void 0,
3723
3780
  "Pass at least one of title, ordinal, or linkedTaskId."
3724
3781
  );
3725
- var DeleteMeetingChecklistItemRequestSchema = z12.object({
3726
- projectId: z12.string().cuid(),
3727
- meetingId: z12.string().cuid(),
3728
- itemId: z12.string().cuid()
3729
- });
3730
- var SetMeetingChecklistItemCheckedRequestSchema = z12.object({
3731
- projectId: z12.string().cuid(),
3732
- meetingId: z12.string().cuid(),
3733
- itemId: z12.string().cuid(),
3734
- checked: z12.boolean(),
3782
+ var DeleteMeetingChecklistItemRequestSchema = z13.object({
3783
+ projectId: z13.string().cuid(),
3784
+ meetingId: z13.string().cuid(),
3785
+ itemId: z13.string().cuid()
3786
+ });
3787
+ var SetMeetingChecklistItemCheckedRequestSchema = z13.object({
3788
+ projectId: z13.string().cuid(),
3789
+ meetingId: z13.string().cuid(),
3790
+ itemId: z13.string().cuid(),
3791
+ checked: z13.boolean(),
3735
3792
  /** Attach the card in the same call that ticks the item. */
3736
- linkedTaskId: z12.string().cuid().nullable().optional()
3793
+ linkedTaskId: z13.string().cuid().nullable().optional()
3737
3794
  });
3738
- var ListMeetingsRequestSchema = z12.object({
3739
- projectId: z12.string().cuid(),
3740
- limit: z12.number().int().min(1).max(50).optional(),
3741
- search: z12.string().max(200).optional()
3795
+ var ListMeetingsRequestSchema = z13.object({
3796
+ projectId: z13.string().cuid(),
3797
+ limit: z13.number().int().min(1).max(50).optional(),
3798
+ search: z13.string().max(200).optional()
3742
3799
  });
3743
- var ReadMeetingTranscriptRequestSchema = z12.object({
3744
- projectId: z12.string().cuid(),
3745
- meetingId: z12.string().cuid(),
3746
- offset: z12.number().int().min(0).optional(),
3747
- limit: z12.number().int().min(1).max(500).optional()
3800
+ var ReadMeetingTranscriptRequestSchema = z13.object({
3801
+ projectId: z13.string().cuid(),
3802
+ meetingId: z13.string().cuid(),
3803
+ offset: z13.number().int().min(0).optional(),
3804
+ limit: z13.number().int().min(1).max(500).optional()
3748
3805
  });
3749
3806
  var MEETING_SUMMARY_MAX_CHARS = 5e4;
3750
- var AddProjectMeetingChecklistItemsRequestSchema = z12.object({
3751
- projectId: z12.string().cuid(),
3752
- meetingId: z12.string().cuid(),
3753
- items: z12.array(z12.object({ title: z12.string().min(1).max(MEETING_CHECKLIST_TITLE_MAX) })).min(1).max(50),
3754
- requestingUserId: z12.string().optional()
3755
- });
3756
- var CheckProjectMeetingChecklistItemRequestSchema = z12.object({
3757
- projectId: z12.string().cuid(),
3758
- meetingId: z12.string().cuid(),
3759
- title: z12.string().min(1).max(MEETING_CHECKLIST_TITLE_MAX),
3760
- checked: z12.boolean(),
3807
+ var AddProjectMeetingChecklistItemsRequestSchema = z13.object({
3808
+ projectId: z13.string().cuid(),
3809
+ meetingId: z13.string().cuid(),
3810
+ items: z13.array(z13.object({ title: z13.string().min(1).max(MEETING_CHECKLIST_TITLE_MAX) })).min(1).max(50),
3811
+ requestingUserId: z13.string().optional()
3812
+ });
3813
+ var CheckProjectMeetingChecklistItemRequestSchema = z13.object({
3814
+ projectId: z13.string().cuid(),
3815
+ meetingId: z13.string().cuid(),
3816
+ title: z13.string().min(1).max(MEETING_CHECKLIST_TITLE_MAX),
3817
+ checked: z13.boolean(),
3761
3818
  /** Card id or slug. Resolved server-side and required to be in the project. */
3762
- linkedTask: z12.string().min(1).optional(),
3763
- requestingUserId: z12.string().optional()
3764
- });
3765
- var EditProjectMeetingChecklistItemRequestSchema = z12.object({
3766
- projectId: z12.string().cuid(),
3767
- meetingId: z12.string().cuid(),
3768
- title: z12.string().min(1).max(MEETING_CHECKLIST_TITLE_MAX),
3769
- newTitle: z12.string().min(1).max(MEETING_CHECKLIST_TITLE_MAX),
3770
- requestingUserId: z12.string().optional()
3771
- });
3772
- var RemoveProjectMeetingChecklistItemRequestSchema = z12.object({
3773
- projectId: z12.string().cuid(),
3774
- meetingId: z12.string().cuid(),
3775
- title: z12.string().min(1).max(MEETING_CHECKLIST_TITLE_MAX),
3776
- requestingUserId: z12.string().optional()
3777
- });
3778
- var CreateProjectMeetingRequestSchema = z12.object({
3779
- projectId: z12.string().cuid(),
3780
- rawText: z12.string().min(1).max(MEETING_TRANSCRIPT_MAX_CHARS),
3781
- title: z12.string().min(1).max(MEETING_TITLE_MAX).optional(),
3819
+ linkedTask: z13.string().min(1).optional(),
3820
+ requestingUserId: z13.string().optional()
3821
+ });
3822
+ var EditProjectMeetingChecklistItemRequestSchema = z13.object({
3823
+ projectId: z13.string().cuid(),
3824
+ meetingId: z13.string().cuid(),
3825
+ title: z13.string().min(1).max(MEETING_CHECKLIST_TITLE_MAX),
3826
+ newTitle: z13.string().min(1).max(MEETING_CHECKLIST_TITLE_MAX),
3827
+ requestingUserId: z13.string().optional()
3828
+ });
3829
+ var RemoveProjectMeetingChecklistItemRequestSchema = z13.object({
3830
+ projectId: z13.string().cuid(),
3831
+ meetingId: z13.string().cuid(),
3832
+ title: z13.string().min(1).max(MEETING_CHECKLIST_TITLE_MAX),
3833
+ requestingUserId: z13.string().optional()
3834
+ });
3835
+ var CreateProjectMeetingRequestSchema = z13.object({
3836
+ projectId: z13.string().cuid(),
3837
+ rawText: z13.string().min(1).max(MEETING_TRANSCRIPT_MAX_CHARS),
3838
+ title: z13.string().min(1).max(MEETING_TITLE_MAX).optional(),
3782
3839
  occurredAt: MeetingOccurredAtSchema.optional(),
3783
- requestingUserId: z12.string().optional()
3840
+ requestingUserId: z13.string().optional()
3784
3841
  });
3785
- var UpdateProjectMeetingRequestSchema = z12.object({
3786
- projectId: z12.string().cuid(),
3787
- meetingId: z12.string().cuid(),
3788
- title: z12.string().min(1).max(MEETING_TITLE_MAX).optional(),
3842
+ var UpdateProjectMeetingRequestSchema = z13.object({
3843
+ projectId: z13.string().cuid(),
3844
+ meetingId: z13.string().cuid(),
3845
+ title: z13.string().min(1).max(MEETING_TITLE_MAX).optional(),
3789
3846
  occurredAt: MeetingOccurredAtSchema.optional(),
3790
- summary: z12.string().min(1).max(MEETING_SUMMARY_MAX_CHARS).optional(),
3791
- requestingUserId: z12.string().optional()
3847
+ summary: z13.string().min(1).max(MEETING_SUMMARY_MAX_CHARS).optional(),
3848
+ requestingUserId: z13.string().optional()
3792
3849
  }).refine(
3793
3850
  (v) => v.title !== void 0 || v.occurredAt !== void 0 || v.summary !== void 0,
3794
3851
  "Pass at least one of title, occurredAt, or summary."
@@ -5318,6 +5375,7 @@ export {
5318
5375
  MAX_FILE_SIZE_BYTES,
5319
5376
  isCapabilityServableMime,
5320
5377
  RUNNER_MODES,
5378
+ PTY_CHAT_TURN_FILES_MAX,
5321
5379
  CONTEXT_LINK_LOCATOR_MAX,
5322
5380
  isPlaceholderLocator,
5323
5381
  locatorMatchesContent,