@rudderhq/cli 0.2.0-canary.12 → 0.2.0-canary.14

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.
package/dist/index.js CHANGED
@@ -1505,7 +1505,8 @@ var init_issue = __esm({
1505
1505
  updateIssueSchema = createIssueSchema.partial().extend({
1506
1506
  comment: z13.string().min(1).optional(),
1507
1507
  reopen: z13.boolean().optional(),
1508
- hiddenAt: z13.string().datetime().nullable().optional()
1508
+ hiddenAt: z13.string().datetime().nullable().optional(),
1509
+ reviewDecision: z13.enum(["approve", "request_changes", "needs_followup", "blocked"]).optional()
1509
1510
  });
1510
1511
  reorderIssueSchema = z13.object({
1511
1512
  issueId: z13.string().uuid(),
@@ -14517,7 +14518,7 @@ var AGENT_CLI_CAPABILITIES = [
14517
14518
  id: "agent.inbox",
14518
14519
  command: "rudder agent inbox",
14519
14520
  category: "agent",
14520
- description: "List the compact assigned-work inbox for the authenticated agent.",
14521
+ description: "List the compact assignee and reviewer work inbox for the authenticated agent.",
14521
14522
  mutating: false,
14522
14523
  contract: "agent-v1",
14523
14524
  requiresOrgId: false,
@@ -14729,6 +14730,18 @@ var AGENT_CLI_CAPABILITIES = [
14729
14730
  requiresRunId: false,
14730
14731
  attachesRunIdWhenAvailable: true
14731
14732
  },
14733
+ {
14734
+ id: "issue.review",
14735
+ command: "rudder issue review <issue> --decision <decision> --comment <text>",
14736
+ category: "issue",
14737
+ description: "Record a structured reviewer decision with a required comment.",
14738
+ mutating: true,
14739
+ contract: "agent-v1",
14740
+ requiresOrgId: false,
14741
+ requiresAgentId: false,
14742
+ requiresRunId: false,
14743
+ attachesRunIdWhenAvailable: true
14744
+ },
14732
14745
  {
14733
14746
  id: "issue.done",
14734
14747
  command: "rudder issue done <issue> --comment <text>",
@@ -15145,6 +15158,24 @@ function registerIssueCommands(program) {
15145
15158
  }
15146
15159
  })
15147
15160
  );
15161
+ addCommonClientOptions(
15162
+ issue.command("review").description(getAgentCliCapabilityById("issue.review").description).argument("<issueId>", "Issue ID").requiredOption(
15163
+ "--decision <decision>",
15164
+ "Review decision: approve, request_changes, needs_followup, or blocked"
15165
+ ).requiredOption("--comment <text>", "Required review comment").action(async (issueId, opts) => {
15166
+ try {
15167
+ const ctx = resolveCommandContext(opts);
15168
+ const decision = parseReviewDecision(opts.decision);
15169
+ const updated = await ctx.api.patch(`/api/issues/${issueId}`, {
15170
+ reviewDecision: decision,
15171
+ comment: opts.comment
15172
+ });
15173
+ printOutput(updated, { json: ctx.json });
15174
+ } catch (err) {
15175
+ handleCommandError(err);
15176
+ }
15177
+ })
15178
+ );
15148
15179
  addCommonClientOptions(
15149
15180
  issue.command("done").description(getAgentCliCapabilityById("issue.done").description).argument("<issueId>", "Issue ID").requiredOption("--comment <text>", "Required completion comment").action(async (issueId, opts) => {
15150
15181
  try {
@@ -15306,6 +15337,13 @@ function parseHiddenAt(value) {
15306
15337
  if (value.trim().toLowerCase() === "null") return null;
15307
15338
  return value;
15308
15339
  }
15340
+ function parseReviewDecision(value) {
15341
+ const normalized = value.trim();
15342
+ if (normalized === "approve" || normalized === "request_changes" || normalized === "needs_followup" || normalized === "blocked") {
15343
+ return normalized;
15344
+ }
15345
+ throw new Error("Invalid review decision. Use approve, request_changes, needs_followup, or blocked.");
15346
+ }
15309
15347
  function filterIssueRows(rows, match) {
15310
15348
  if (!match?.trim()) return rows;
15311
15349
  const needle = match.trim().toLowerCase();
@@ -15526,6 +15564,7 @@ function registerAgentCommands(program) {
15526
15564
  formatInlineRecord({
15527
15565
  identifier: row.identifier,
15528
15566
  id: row.id,
15567
+ relationship: row.relationship ?? "assignee",
15529
15568
  status: row.status,
15530
15569
  priority: row.priority,
15531
15570
  title: row.title,