@fabricorg/cli 0.1.0 → 0.2.0

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/fabric.js CHANGED
@@ -314,12 +314,17 @@ function getClient() {
314
314
  }
315
315
 
316
316
  // src/lib/context.ts
317
+ function refusePersonal(source) {
318
+ return printError(
319
+ `${source} selects personal context, which no longer exists \u2014 every command runs inside an organization.
320
+ Name one with --org <slug>, or set a default with:
321
+ fabric ctx use org <slug>`,
322
+ 2
323
+ );
324
+ }
317
325
  function resolveContext(personal, org, required = true) {
318
- if (personal && org) {
319
- printError("Cannot use --personal and --org together", 2);
320
- }
321
326
  if (personal) {
322
- return { type: "personal" };
327
+ refusePersonal("--personal");
323
328
  }
324
329
  if (org) {
325
330
  return { type: "org", slug: org };
@@ -327,7 +332,9 @@ function resolveContext(personal, org, required = true) {
327
332
  const stored = getDefaultContext();
328
333
  if (stored) {
329
334
  if (stored.type === "personal") {
330
- return { type: "personal" };
335
+ refusePersonal(
336
+ process.env.FABRIC_PERSONAL === "1" ? "FABRIC_PERSONAL=1" : "Your stored default context"
337
+ );
331
338
  }
332
339
  if (stored.type === "org") {
333
340
  return { type: "org", slug: stored.slug };
@@ -335,7 +342,7 @@ function resolveContext(personal, org, required = true) {
335
342
  }
336
343
  if (required) {
337
344
  printError(
338
- "Context is required. Use --personal, --org <slug>, or set a default with:\n fabric ctx use personal\n fabric ctx use org <slug>",
345
+ "Context is required. Use --org <slug>, or set a default with:\n fabric ctx use org <slug>",
339
346
  2
340
347
  );
341
348
  }
@@ -345,7 +352,7 @@ function resolveContext(personal, org, required = true) {
345
352
  // src/commands/agents/index.ts
346
353
  function buildAgentsCommand() {
347
354
  const agents = new Command("agents").description("Manage agents");
348
- agents.command("list").description("List agents").option("--org <slug>", "Organization context").option("--personal", "Personal context").option("--status <status>", "Filter: ACTIVE|INACTIVE|DEPRECATED").option("--limit <n>", "Max results", "50").option(
355
+ agents.command("list").description("List agents").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option("--status <status>", "Filter: ACTIVE|INACTIVE|DEPRECATED").option("--limit <n>", "Max results", "50").option(
349
356
  "--format <format>",
350
357
  "Output format: table|json|yaml|csv",
351
358
  "table"
@@ -357,7 +364,6 @@ function buildAgentsCommand() {
357
364
  try {
358
365
  list = yield client.agents.list({
359
366
  org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
360
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0,
361
367
  status: opts.status,
362
368
  limit: Number(opts.limit)
363
369
  });
@@ -384,7 +390,7 @@ function buildAgentsCommand() {
384
390
  });
385
391
  })
386
392
  );
387
- agents.command("show <id>").description("Show agent details").option("--org <slug>", "Organization context").option("--personal", "Personal context").option("--format <format>", "Output format: table|json|yaml", "table").action(
393
+ agents.command("show <id>").description("Show agent details").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option("--format <format>", "Output format: table|json|yaml", "table").action(
388
394
  (id, opts) => __async(null, null, function* () {
389
395
  var _a2;
390
396
  const ctx = resolveContext(opts.personal, opts.org, false);
@@ -392,8 +398,7 @@ function buildAgentsCommand() {
392
398
  let agent;
393
399
  try {
394
400
  agent = yield client.agents.get(id, {
395
- org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
396
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0
401
+ org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0
397
402
  });
398
403
  } catch (err) {
399
404
  printError(err.message, 1);
@@ -415,7 +420,7 @@ function buildAgentsCommand() {
415
420
  });
416
421
  })
417
422
  );
418
- agents.command("execute <id>").description("Execute an agent").option("--org <slug>", "Organization context").option("--personal", "Personal context").option("--input <json>", `Input JSON (e.g. '{"key":"value"}')`).option("--format <format>", "Output format: table|json|yaml", "table").action(
423
+ agents.command("execute <id>").description("Execute an agent").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option("--input <json>", `Input JSON (e.g. '{"key":"value"}')`).option("--format <format>", "Output format: table|json|yaml", "table").action(
419
424
  (id, opts) => __async(null, null, function* () {
420
425
  var _a2;
421
426
  const ctx = resolveContext(opts.personal, opts.org, false);
@@ -432,8 +437,7 @@ function buildAgentsCommand() {
432
437
  try {
433
438
  result = yield client.agents.execute(id, {
434
439
  input: inputObj,
435
- org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
436
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0
440
+ org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0
437
441
  });
438
442
  } catch (err) {
439
443
  printError(err.message, 1);
@@ -660,7 +664,7 @@ function buildWhoamiCommand() {
660
664
  import { Command as Command6 } from "commander";
661
665
  function buildChatsCommand() {
662
666
  const chats = new Command6("chats").description("Manage AI chat sessions");
663
- chats.command("list").description("List AI chat sessions").option("--org <slug>", "Organization context").option("--personal", "Personal context").option("--limit <n>", "Max results (default 20)", "20").option(
667
+ chats.command("list").description("List AI chat sessions").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option("--limit <n>", "Max results (default 20)", "20").option(
664
668
  "--format <format>",
665
669
  "Output format: table|json|yaml|csv",
666
670
  "table"
@@ -672,7 +676,6 @@ function buildChatsCommand() {
672
676
  try {
673
677
  list = yield client.chats.list({
674
678
  org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
675
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0,
676
679
  limit: Number(opts.limit)
677
680
  });
678
681
  } catch (err) {
@@ -691,7 +694,7 @@ function buildChatsCommand() {
691
694
  });
692
695
  })
693
696
  );
694
- chats.command("show <id>").description("Show chat details").option("--org <slug>", "Organization context").option("--personal", "Personal context").option("--format <format>", "Output format: table|json|yaml", "table").action(
697
+ chats.command("show <id>").description("Show chat details").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option("--format <format>", "Output format: table|json|yaml", "table").action(
695
698
  (id, opts) => __async(null, null, function* () {
696
699
  var _a2;
697
700
  const ctx = resolveContext(opts.personal, opts.org, false);
@@ -699,8 +702,7 @@ function buildChatsCommand() {
699
702
  let chat;
700
703
  try {
701
704
  chat = yield client.chats.get(id, {
702
- org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
703
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0
705
+ org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0
704
706
  });
705
707
  } catch (err) {
706
708
  printError(err.message, 1);
@@ -964,29 +966,33 @@ function buildCompletionCommand() {
964
966
  import { Command as Command8 } from "commander";
965
967
  function buildCtxCommand() {
966
968
  const ctx = new Command8("ctx").description(
967
- "Manage tenant context (personal vs org)"
969
+ "Manage the organization commands run in"
968
970
  );
969
971
  ctx.command("current").description("Show the active default context").action(() => {
970
972
  const stored = getDefaultContext();
971
973
  if (!stored) {
972
974
  printWarning(
973
- "No default context set. Use --personal or --org <slug> on each command, or run:\n fabric ctx use personal\n fabric ctx use org <slug>"
975
+ "No default context set. Use --org <slug> on each command, or run:\n fabric ctx use org <slug>"
974
976
  );
975
977
  return;
976
978
  }
977
979
  if (stored.type === "personal") {
978
- process.stdout.write("Context: personal\n");
979
- } else {
980
- process.stdout.write(`Context: org:${stored.slug}
981
- `);
980
+ printWarning(
981
+ "Context: personal \u2014 retired, and no command will accept it.\nReplace it with:\n fabric ctx use org <slug>"
982
+ );
983
+ return;
982
984
  }
985
+ process.stdout.write(`Context: org:${stored.slug}
986
+ `);
983
987
  });
984
988
  const use = new Command8("use").description(
985
- "Set the default context for commands"
989
+ "Set the default organization for commands"
986
990
  );
987
- use.command("personal").description("Use personal context by default").action(() => {
988
- saveDefaultContext({ type: "personal" });
989
- printSuccess("Default context set to: personal");
991
+ use.command("personal").description("Retired \u2014 context is organization-only").action(() => {
992
+ printError(
993
+ "Personal context no longer exists \u2014 every command runs inside an organization.\nSet one with:\n fabric ctx use org <slug>",
994
+ 2
995
+ );
990
996
  });
991
997
  use.command("org <slug>").description("Use an org context by default").action((slug) => {
992
998
  saveDefaultContext({ type: "org", slug });
@@ -1002,7 +1008,7 @@ function buildFeaturesCommand() {
1002
1008
  const features = new Command9("features").description(
1003
1009
  "Manage project features"
1004
1010
  );
1005
- features.command("list").description("List features in a project").requiredOption("-p, --project <id>", "Project ID").option("--org <slug>", "Organization context").option("--personal", "Personal context").option(
1011
+ features.command("list").description("List features in a project").requiredOption("-p, --project <id>", "Project ID").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option(
1006
1012
  "--priority <priority>",
1007
1013
  "Filter: P0_CRITICAL|P1_HIGH|P2_MEDIUM|P3_LOW"
1008
1014
  ).option("--search <query>", "Search by title").option("--limit <n>", "Max results (default 50)", "50").option(
@@ -1017,7 +1023,6 @@ function buildFeaturesCommand() {
1017
1023
  try {
1018
1024
  list = yield client.projects.listFeatures(opts.project, {
1019
1025
  org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
1020
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0,
1021
1026
  priority: opts.priority,
1022
1027
  search: opts.search,
1023
1028
  limit: Number(opts.limit)
@@ -1038,7 +1043,7 @@ function buildFeaturesCommand() {
1038
1043
  });
1039
1044
  })
1040
1045
  );
1041
- features.command("show <id>").description("Show feature details").requiredOption("-p, --project <projectId>", "Project ID").option("--org <slug>", "Organization context").option("--personal", "Personal context").option("--format <format>", "Output format: table|json|yaml", "table").action(
1046
+ features.command("show <id>").description("Show feature details").requiredOption("-p, --project <projectId>", "Project ID").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option("--format <format>", "Output format: table|json|yaml", "table").action(
1042
1047
  (id, opts) => __async(null, null, function* () {
1043
1048
  var _a2, _b, _c;
1044
1049
  const ctx = resolveContext(opts.personal, opts.org, false);
@@ -1049,8 +1054,7 @@ function buildFeaturesCommand() {
1049
1054
  opts.project,
1050
1055
  id,
1051
1056
  {
1052
- org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
1053
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0
1057
+ org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0
1054
1058
  }
1055
1059
  );
1056
1060
  } catch (err) {
@@ -1074,7 +1078,7 @@ function buildFeaturesCommand() {
1074
1078
  });
1075
1079
  })
1076
1080
  );
1077
- features.command("create <title>").description("Create a feature in a project").requiredOption("-p, --project <projectId>", "Project ID").option("--org <slug>", "Organization context").option("--personal", "Personal context").option("-d, --description <text>", "Feature description").option(
1081
+ features.command("create <title>").description("Create a feature in a project").requiredOption("-p, --project <projectId>", "Project ID").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option("-d, --description <text>", "Feature description").option(
1078
1082
  "--priority <priority>",
1079
1083
  "Priority: P0_CRITICAL|P1_HIGH|P2_MEDIUM|P3_LOW (default: P2_MEDIUM)"
1080
1084
  ).option("--format <format>", "Output format: table|json|yaml", "table").action(
@@ -1089,8 +1093,7 @@ function buildFeaturesCommand() {
1089
1093
  title,
1090
1094
  description: opts.description,
1091
1095
  priority: opts.priority,
1092
- org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
1093
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0
1096
+ org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0
1094
1097
  }
1095
1098
  );
1096
1099
  } catch (err) {
@@ -1112,7 +1115,7 @@ function buildFeaturesCommand() {
1112
1115
  });
1113
1116
  })
1114
1117
  );
1115
- features.command("tasks").description("List tasks (sub-items) for a feature").requiredOption("-p, --project <projectId>", "Project ID").requiredOption("-f, --feature <featureId>", "Feature ID").option("--org <slug>", "Organization context").option("--personal", "Personal context").option(
1118
+ features.command("tasks").description("List tasks (sub-items) for a feature").requiredOption("-p, --project <projectId>", "Project ID").requiredOption("-f, --feature <featureId>", "Feature ID").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option(
1116
1119
  "--format <format>",
1117
1120
  "Output format: table|json|yaml|csv",
1118
1121
  "table"
@@ -1126,8 +1129,7 @@ function buildFeaturesCommand() {
1126
1129
  opts.project,
1127
1130
  opts.feature,
1128
1131
  {
1129
- org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
1130
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0
1132
+ org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0
1131
1133
  }
1132
1134
  );
1133
1135
  } catch (err) {
@@ -1151,7 +1153,7 @@ function buildFeaturesCommand() {
1151
1153
  });
1152
1154
  })
1153
1155
  );
1154
- features.command("update <id>").description("Update a feature").requiredOption("-p, --project <projectId>", "Project ID").option("--org <slug>", "Organization context").option("--personal", "Personal context").option("--title <title>", "New title").option("-d, --description <text>", "New description").option(
1156
+ features.command("update <id>").description("Update a feature").requiredOption("-p, --project <projectId>", "Project ID").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option("--title <title>", "New title").option("-d, --description <text>", "New description").option(
1155
1157
  "--priority <priority>",
1156
1158
  "Priority: P0_CRITICAL|P1_HIGH|P2_MEDIUM|P3_LOW"
1157
1159
  ).option("--format <format>", "Output format: table|json|yaml", "table").action(
@@ -1167,8 +1169,7 @@ function buildFeaturesCommand() {
1167
1169
  title: opts.title,
1168
1170
  description: opts.description,
1169
1171
  priority: opts.priority,
1170
- org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
1171
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0
1172
+ org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0
1172
1173
  }
1173
1174
  );
1174
1175
  } catch (err) {
@@ -1197,7 +1198,7 @@ function buildFramesCommand() {
1197
1198
  const frames = new Command10("frames").description(
1198
1199
  "Manage AI-generated frames and slideshows"
1199
1200
  );
1200
- frames.command("list").description("List frames and slideshows").option("--org <slug>", "Organization context").option("--personal", "Personal context").option("--limit <n>", "Max results (default 50)", "50").option(
1201
+ frames.command("list").description("List frames and slideshows").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option("--limit <n>", "Max results (default 50)", "50").option(
1201
1202
  "--format <format>",
1202
1203
  "Output format: table|json|yaml|csv",
1203
1204
  "table"
@@ -1209,7 +1210,6 @@ function buildFramesCommand() {
1209
1210
  try {
1210
1211
  list = yield client.frames.list({
1211
1212
  org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
1212
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0,
1213
1213
  limit: Number(opts.limit)
1214
1214
  });
1215
1215
  } catch (err) {
@@ -1235,7 +1235,7 @@ function buildFramesCommand() {
1235
1235
  });
1236
1236
  })
1237
1237
  );
1238
- frames.command("show <id>").description("Show frame details").option("--org <slug>", "Organization context").option("--personal", "Personal context").option("--format <format>", "Output format: table|json|yaml", "table").action(
1238
+ frames.command("show <id>").description("Show frame details").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option("--format <format>", "Output format: table|json|yaml", "table").action(
1239
1239
  (id, opts) => __async(null, null, function* () {
1240
1240
  var _a2, _b, _c;
1241
1241
  const ctx = resolveContext(opts.personal, opts.org, false);
@@ -1243,8 +1243,7 @@ function buildFramesCommand() {
1243
1243
  let frame;
1244
1244
  try {
1245
1245
  frame = yield client.frames.get(id, {
1246
- org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
1247
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0
1246
+ org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0
1248
1247
  });
1249
1248
  } catch (err) {
1250
1249
  printError(err.message, 1);
@@ -1276,7 +1275,7 @@ function buildMcpCommand() {
1276
1275
  const mcp = new Command11("mcp").description(
1277
1276
  "Manage MCP servers and configurations"
1278
1277
  );
1279
- mcp.command("servers").description("List accessible MCP servers (system + custom)").option("--org <slug>", "Organization context").option("--personal", "Personal context").option(
1278
+ mcp.command("servers").description("List accessible MCP servers (system + custom)").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option(
1280
1279
  "--format <format>",
1281
1280
  "Output format: table|json|yaml|csv",
1282
1281
  "table"
@@ -1287,8 +1286,7 @@ function buildMcpCommand() {
1287
1286
  let list;
1288
1287
  try {
1289
1288
  list = yield client.mcp.listServers({
1290
- org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
1291
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0
1289
+ org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0
1292
1290
  });
1293
1291
  } catch (err) {
1294
1292
  printError(err.message, 1);
@@ -1315,7 +1313,7 @@ function buildMcpCommand() {
1315
1313
  const configs = new Command11("configs").description(
1316
1314
  "Manage MCP configurations"
1317
1315
  );
1318
- configs.command("list", { isDefault: true }).description("List your MCP configurations").option("--org <slug>", "Organization context").option("--personal", "Personal context").option(
1316
+ configs.command("list", { isDefault: true }).description("List your MCP configurations").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option(
1319
1317
  "--format <format>",
1320
1318
  "Output format: table|json|yaml|csv",
1321
1319
  "table"
@@ -1326,8 +1324,7 @@ function buildMcpCommand() {
1326
1324
  let list;
1327
1325
  try {
1328
1326
  list = yield client.mcp.listConfigs({
1329
- org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
1330
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0
1327
+ org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0
1331
1328
  });
1332
1329
  } catch (err) {
1333
1330
  printError(err.message, 1);
@@ -1352,7 +1349,7 @@ function buildMcpCommand() {
1352
1349
  });
1353
1350
  })
1354
1351
  );
1355
- configs.command("show <id>").description("Show a specific MCP configuration").option("--org <slug>", "Organization context").option("--personal", "Personal context").option("--format <format>", "Output format: table|json|yaml", "table").action(
1352
+ configs.command("show <id>").description("Show a specific MCP configuration").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option("--format <format>", "Output format: table|json|yaml", "table").action(
1356
1353
  (id, opts) => __async(null, null, function* () {
1357
1354
  var _a2, _b, _c, _d, _e, _f, _g;
1358
1355
  const ctx = resolveContext(opts.personal, opts.org, false);
@@ -1360,8 +1357,7 @@ function buildMcpCommand() {
1360
1357
  let config2;
1361
1358
  try {
1362
1359
  config2 = yield client.mcp.getConfig(id, {
1363
- org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
1364
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0
1360
+ org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0
1365
1361
  });
1366
1362
  } catch (err) {
1367
1363
  printError(err.message, 1);
@@ -1386,7 +1382,7 @@ function buildMcpCommand() {
1386
1382
  });
1387
1383
  })
1388
1384
  );
1389
- configs.command("delete <id>").description("Delete an MCP configuration").option("--org <slug>", "Organization context").option("--personal", "Personal context").option("-y, --yes", "Skip confirmation prompt").action(
1385
+ configs.command("delete <id>").description("Delete an MCP configuration").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option("-y, --yes", "Skip confirmation prompt").action(
1390
1386
  (id, opts) => __async(null, null, function* () {
1391
1387
  const ctx = resolveContext(opts.personal, opts.org, false);
1392
1388
  const client = getClient();
@@ -1399,8 +1395,7 @@ function buildMcpCommand() {
1399
1395
  }
1400
1396
  try {
1401
1397
  yield client.mcp.deleteConfig(id, {
1402
- org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
1403
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0
1398
+ org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0
1404
1399
  });
1405
1400
  } catch (err) {
1406
1401
  printError(err.message, 1);
@@ -1482,7 +1477,7 @@ function buildOrgsCommand() {
1482
1477
  import { Command as Command13 } from "commander";
1483
1478
  function buildProjectsCommand() {
1484
1479
  const projects = new Command13("projects").description("Manage projects");
1485
- projects.command("list").description("List projects").option("--org <slug>", "Organization context").option("--personal", "Personal context").option(
1480
+ projects.command("list").description("List projects").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option(
1486
1481
  "--status <status>",
1487
1482
  "Filter by status: ACTIVE|DRAFT|COMPLETED|ARCHIVED"
1488
1483
  ).option("--search <query>", "Search by name").option("--limit <n>", "Max results (default 20)", "20").option(
@@ -1497,7 +1492,6 @@ function buildProjectsCommand() {
1497
1492
  try {
1498
1493
  list = yield client.projects.list({
1499
1494
  org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
1500
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0,
1501
1495
  status: opts.status,
1502
1496
  search: opts.search,
1503
1497
  limit: Number(opts.limit)
@@ -1518,7 +1512,7 @@ function buildProjectsCommand() {
1518
1512
  });
1519
1513
  })
1520
1514
  );
1521
- projects.command("show <id>").description("Show project details").option("--org <slug>", "Organization context").option("--personal", "Personal context").option("--format <format>", "Output format: table|json|yaml", "table").action(
1515
+ projects.command("show <id>").description("Show project details").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option("--format <format>", "Output format: table|json|yaml", "table").action(
1522
1516
  (id, opts) => __async(null, null, function* () {
1523
1517
  var _a2, _b;
1524
1518
  const ctx = resolveContext(opts.personal, opts.org, false);
@@ -1526,8 +1520,7 @@ function buildProjectsCommand() {
1526
1520
  let project;
1527
1521
  try {
1528
1522
  project = yield client.projects.get(id, {
1529
- org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
1530
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0
1523
+ org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0
1531
1524
  });
1532
1525
  } catch (err) {
1533
1526
  printError(err.message, 1);
@@ -1547,7 +1540,7 @@ function buildProjectsCommand() {
1547
1540
  });
1548
1541
  })
1549
1542
  );
1550
- projects.command("create <name>").description("Create a new project").option("--org <slug>", "Organization context").option("--personal", "Personal context").option("-d, --description <text>", "Project description").option("--repo <url>", "Repository URL").option(
1543
+ projects.command("create <name>").description("Create a new project").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option("-d, --description <text>", "Project description").option("--repo <url>", "Repository URL").option(
1551
1544
  "--status <status>",
1552
1545
  "Initial status: DRAFT|ACTIVE (default: DRAFT)",
1553
1546
  "DRAFT"
@@ -1563,8 +1556,7 @@ function buildProjectsCommand() {
1563
1556
  description: opts.description,
1564
1557
  repositoryUrl: opts.repo,
1565
1558
  status: opts.status,
1566
- org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
1567
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0
1559
+ org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0
1568
1560
  });
1569
1561
  } catch (err) {
1570
1562
  printError(err.message, 1);
@@ -1584,7 +1576,7 @@ function buildProjectsCommand() {
1584
1576
  });
1585
1577
  })
1586
1578
  );
1587
- projects.command("update <id>").description("Update a project").option("--org <slug>", "Organization context").option("--personal", "Personal context").option("--name <name>", "New name").option("-d, --description <text>", "New description").option("--repo <url>", "Repository URL").option("--status <status>", "Status: DRAFT|ACTIVE|COMPLETED|ARCHIVED").option("--format <format>", "Output format: table|json|yaml", "table").action(
1579
+ projects.command("update <id>").description("Update a project").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option("--name <name>", "New name").option("-d, --description <text>", "New description").option("--repo <url>", "Repository URL").option("--status <status>", "Status: DRAFT|ACTIVE|COMPLETED|ARCHIVED").option("--format <format>", "Output format: table|json|yaml", "table").action(
1588
1580
  (id, opts) => __async(null, null, function* () {
1589
1581
  var _a2;
1590
1582
  const ctx = resolveContext(opts.personal, opts.org, false);
@@ -1596,8 +1588,7 @@ function buildProjectsCommand() {
1596
1588
  description: opts.description,
1597
1589
  repositoryUrl: opts.repo,
1598
1590
  status: opts.status,
1599
- org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
1600
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0
1591
+ org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0
1601
1592
  });
1602
1593
  } catch (err) {
1603
1594
  printError(err.message, 1);
@@ -1625,7 +1616,7 @@ function buildPromptsCommand() {
1625
1616
  const prompts = new Command14("prompts").description(
1626
1617
  "Manage prompt templates"
1627
1618
  );
1628
- prompts.command("list").description("List prompt templates").option("--org <slug>", "Organization context").option("--personal", "Personal context").option("--search <query>", "Search by name").option("--category <cat>", "Filter by category").option("--limit <n>", "Max results", "50").option(
1619
+ prompts.command("list").description("List prompt templates").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option("--search <query>", "Search by name").option("--category <cat>", "Filter by category").option("--limit <n>", "Max results", "50").option(
1629
1620
  "--format <format>",
1630
1621
  "Output format: table|json|yaml|csv",
1631
1622
  "table"
@@ -1637,7 +1628,6 @@ function buildPromptsCommand() {
1637
1628
  try {
1638
1629
  list = yield client.prompts.list({
1639
1630
  org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
1640
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0,
1641
1631
  search: opts.search,
1642
1632
  category: opts.category,
1643
1633
  limit: Number(opts.limit)
@@ -1665,7 +1655,7 @@ function buildPromptsCommand() {
1665
1655
  });
1666
1656
  })
1667
1657
  );
1668
- prompts.command("get <id>").description("Get a prompt (prints latest version content by default)").option("--org <slug>", "Organization context").option("--personal", "Personal context").option(
1658
+ prompts.command("get <id>").description("Get a prompt (prints latest version content by default)").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option(
1669
1659
  "--format <format>",
1670
1660
  "Output format: raw|table|json|yaml (default: raw)",
1671
1661
  "raw"
@@ -1677,8 +1667,7 @@ function buildPromptsCommand() {
1677
1667
  let prompt;
1678
1668
  try {
1679
1669
  prompt = yield client.prompts.get(id, {
1680
- org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
1681
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0
1670
+ org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0
1682
1671
  });
1683
1672
  } catch (err) {
1684
1673
  printError(err.message, 1);
@@ -1712,7 +1701,7 @@ ${content}
1712
1701
  `);
1713
1702
  })
1714
1703
  );
1715
- prompts.command("create").description("Create a new prompt").option("--org <slug>", "Organization context").option("--personal", "Personal context").requiredOption("--key <key>", "Prompt key (unique identifier)").requiredOption("--name <name>", "Prompt name").option("-d, --description <text>", "Prompt description").option("--content <text>", "Initial prompt content").option("--category <cat>", "Category").option("--format <format>", "Output format: table|json|yaml", "table").action(
1704
+ prompts.command("create").description("Create a new prompt").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").requiredOption("--key <key>", "Prompt key (unique identifier)").requiredOption("--name <name>", "Prompt name").option("-d, --description <text>", "Prompt description").option("--content <text>", "Initial prompt content").option("--category <cat>", "Category").option("--format <format>", "Output format: table|json|yaml", "table").action(
1716
1705
  (opts) => __async(null, null, function* () {
1717
1706
  const ctx = resolveContext(opts.personal, opts.org, false);
1718
1707
  const client = getClient();
@@ -1724,8 +1713,7 @@ ${content}
1724
1713
  description: opts.description,
1725
1714
  content: opts.content,
1726
1715
  category: opts.category,
1727
- org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
1728
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0
1716
+ org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0
1729
1717
  });
1730
1718
  } catch (err) {
1731
1719
  printError(err.message, 1);
@@ -1745,7 +1733,7 @@ ${content}
1745
1733
  });
1746
1734
  })
1747
1735
  );
1748
- prompts.command("update <id>").description("Update a prompt").option("--org <slug>", "Organization context").option("--personal", "Personal context").option("--name <name>", "New name").option("-d, --description <text>", "New description").option("--category <cat>", "Category").option("--format <format>", "Output format: table|json|yaml", "table").action(
1736
+ prompts.command("update <id>").description("Update a prompt").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option("--name <name>", "New name").option("-d, --description <text>", "New description").option("--category <cat>", "Category").option("--format <format>", "Output format: table|json|yaml", "table").action(
1749
1737
  (id, opts) => __async(null, null, function* () {
1750
1738
  const ctx = resolveContext(opts.personal, opts.org, false);
1751
1739
  const client = getClient();
@@ -1755,8 +1743,7 @@ ${content}
1755
1743
  name: opts.name,
1756
1744
  description: opts.description,
1757
1745
  category: opts.category,
1758
- org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
1759
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0
1746
+ org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0
1760
1747
  });
1761
1748
  } catch (err) {
1762
1749
  printError(err.message, 1);
@@ -1787,7 +1774,7 @@ function buildReportsCommand() {
1787
1774
  const templates = new Command15("templates").description(
1788
1775
  "Manage report templates"
1789
1776
  );
1790
- templates.command("list", { isDefault: true }).description("List report templates").option("--org <slug>", "Organization context").option("--personal", "Personal context").option("--search <query>", "Search by name").option("--category <cat>", "Filter by category").option("--limit <n>", "Max results (default 20)", "20").option(
1777
+ templates.command("list", { isDefault: true }).description("List report templates").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option("--search <query>", "Search by name").option("--category <cat>", "Filter by category").option("--limit <n>", "Max results (default 20)", "20").option(
1791
1778
  "--format <format>",
1792
1779
  "Output format: table|json|yaml|csv",
1793
1780
  "table"
@@ -1799,7 +1786,6 @@ function buildReportsCommand() {
1799
1786
  try {
1800
1787
  list = yield client.reports.listTemplates({
1801
1788
  org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
1802
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0,
1803
1789
  search: opts.search,
1804
1790
  category: opts.category,
1805
1791
  limit: Number(opts.limit)
@@ -1826,7 +1812,7 @@ function buildReportsCommand() {
1826
1812
  });
1827
1813
  })
1828
1814
  );
1829
- templates.command("show <id>").description("Show report template details").option("--org <slug>", "Organization context").option("--personal", "Personal context").option("--format <format>", "Output format: table|json|yaml", "table").action(
1815
+ templates.command("show <id>").description("Show report template details").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option("--format <format>", "Output format: table|json|yaml", "table").action(
1830
1816
  (id, opts) => __async(null, null, function* () {
1831
1817
  var _a2, _b;
1832
1818
  const ctx = resolveContext(opts.personal, opts.org, false);
@@ -1834,8 +1820,7 @@ function buildReportsCommand() {
1834
1820
  let tmpl;
1835
1821
  try {
1836
1822
  tmpl = yield client.reports.getTemplate(id, {
1837
- org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
1838
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0
1823
+ org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0
1839
1824
  });
1840
1825
  } catch (err) {
1841
1826
  printError(err.message, 1);
@@ -1863,7 +1848,7 @@ function buildReportsCommand() {
1863
1848
  const executions = new Command15("executions").description(
1864
1849
  "View report executions"
1865
1850
  );
1866
- executions.command("list", { isDefault: true }).description("List report executions").option("--org <slug>", "Organization context").option("--personal", "Personal context").option("--limit <n>", "Max results (default 20)", "20").option(
1851
+ executions.command("list", { isDefault: true }).description("List report executions").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option("--limit <n>", "Max results (default 20)", "20").option(
1867
1852
  "--format <format>",
1868
1853
  "Output format: table|json|yaml|csv",
1869
1854
  "table"
@@ -1875,7 +1860,6 @@ function buildReportsCommand() {
1875
1860
  try {
1876
1861
  list = yield client.reports.listExecutions({
1877
1862
  org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
1878
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0,
1879
1863
  limit: Number(opts.limit)
1880
1864
  });
1881
1865
  } catch (err) {
@@ -1910,7 +1894,7 @@ function buildSkillsCommand() {
1910
1894
  const skills = new Command16("skills").description(
1911
1895
  "Browse skill definitions"
1912
1896
  );
1913
- skills.command("list").description("List skills").option("--org <slug>", "Organization context").option("--personal", "Personal context").option("--search <query>", "Search by name").option("--category <cat>", "Filter by category").option("--limit <n>", "Max results", "50").option(
1897
+ skills.command("list").description("List skills").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option("--search <query>", "Search by name").option("--category <cat>", "Filter by category").option("--limit <n>", "Max results", "50").option(
1914
1898
  "--format <format>",
1915
1899
  "Output format: table|json|yaml|csv",
1916
1900
  "table"
@@ -1922,7 +1906,6 @@ function buildSkillsCommand() {
1922
1906
  try {
1923
1907
  list = yield client.skills.list({
1924
1908
  org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
1925
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0,
1926
1909
  search: opts.search,
1927
1910
  category: opts.category,
1928
1911
  limit: Number(opts.limit)
@@ -1978,7 +1961,7 @@ function buildSkillsCommand() {
1978
1961
  import { Command as Command17 } from "commander";
1979
1962
  function buildWorkflowsCommand() {
1980
1963
  const workflows = new Command17("workflows").description("Manage workflows");
1981
- workflows.command("list").description("List workflows").option("--org <slug>", "Organization context").option("--personal", "Personal context").option("--status <status>", "Filter: DRAFT|ACTIVE|PAUSED|ARCHIVED").option("--search <query>", "Search by name").option("--limit <n>", "Max results", "20").option(
1964
+ workflows.command("list").description("List workflows").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option("--status <status>", "Filter: DRAFT|ACTIVE|PAUSED|ARCHIVED").option("--search <query>", "Search by name").option("--limit <n>", "Max results", "20").option(
1982
1965
  "--format <format>",
1983
1966
  "Output format: table|json|yaml|csv",
1984
1967
  "table"
@@ -1990,7 +1973,6 @@ function buildWorkflowsCommand() {
1990
1973
  try {
1991
1974
  list = yield client.workflows.list({
1992
1975
  org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
1993
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0,
1994
1976
  status: opts.status,
1995
1977
  search: opts.search,
1996
1978
  limit: Number(opts.limit)
@@ -2017,15 +1999,14 @@ function buildWorkflowsCommand() {
2017
1999
  });
2018
2000
  })
2019
2001
  );
2020
- workflows.command("show <id>").description("Show workflow details").option("--org <slug>", "Organization context").option("--personal", "Personal context").option("--format <format>", "Output format: table|json|yaml", "table").action(
2002
+ workflows.command("show <id>").description("Show workflow details").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option("--format <format>", "Output format: table|json|yaml", "table").action(
2021
2003
  (id, opts) => __async(null, null, function* () {
2022
2004
  const ctx = resolveContext(opts.personal, opts.org, false);
2023
2005
  const client = getClient();
2024
2006
  let wf;
2025
2007
  try {
2026
2008
  wf = yield client.workflows.get(id, {
2027
- org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
2028
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0
2009
+ org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0
2029
2010
  });
2030
2011
  } catch (err) {
2031
2012
  printError(err.message, 1);
@@ -2045,7 +2026,7 @@ function buildWorkflowsCommand() {
2045
2026
  });
2046
2027
  })
2047
2028
  );
2048
- workflows.command("trigger <id>").description("Trigger a workflow execution").option("--org <slug>", "Organization context").option("--personal", "Personal context").option("--input <json>", "JSON input for triggerData", "{}").option("--vars <json>", "JSON variables", "{}").action(
2029
+ workflows.command("trigger <id>").description("Trigger a workflow execution").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option("--input <json>", "JSON input for triggerData", "{}").option("--vars <json>", "JSON variables", "{}").action(
2049
2030
  (id, opts) => __async(null, null, function* () {
2050
2031
  const ctx = resolveContext(opts.personal, opts.org, false);
2051
2032
  const client = getClient();
@@ -2061,7 +2042,6 @@ function buildWorkflowsCommand() {
2061
2042
  try {
2062
2043
  result = yield client.workflows.trigger(id, {
2063
2044
  org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
2064
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0,
2065
2045
  triggerData,
2066
2046
  variables
2067
2047
  });
@@ -2075,7 +2055,7 @@ function buildWorkflowsCommand() {
2075
2055
  `);
2076
2056
  })
2077
2057
  );
2078
- workflows.command("status <id> <execId>").description("Get workflow execution status").option("--org <slug>", "Organization context").option("--personal", "Personal context").option("--format <format>", "Output format: table|json|yaml", "table").action(
2058
+ workflows.command("status <id> <execId>").description("Get workflow execution status").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option("--format <format>", "Output format: table|json|yaml", "table").action(
2079
2059
  (id, execId, opts) => __async(null, null, function* () {
2080
2060
  var _a2, _b, _c, _d, _e;
2081
2061
  const ctx = resolveContext(opts.personal, opts.org, false);
@@ -2083,8 +2063,7 @@ function buildWorkflowsCommand() {
2083
2063
  let exec;
2084
2064
  try {
2085
2065
  exec = yield client.workflows.getExecution(id, execId, {
2086
- org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
2087
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0
2066
+ org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0
2088
2067
  });
2089
2068
  } catch (err) {
2090
2069
  printError(err.message, 1);
@@ -2114,7 +2093,7 @@ function buildWorkspacesCommand() {
2114
2093
  const workspaces = new Command18("workspaces").description(
2115
2094
  "Manage workspaces"
2116
2095
  );
2117
- workspaces.command("list").description("List workspaces").option("--org <slug>", "Organization context").option("--personal", "Personal context").option("--search <query>", "Search by name").option("--status <status>", "Filter: ACTIVE|ARCHIVED").option("--limit <n>", "Max results (default 20)", "20").option(
2096
+ workspaces.command("list").description("List workspaces").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option("--search <query>", "Search by name").option("--status <status>", "Filter: ACTIVE|ARCHIVED").option("--limit <n>", "Max results (default 20)", "20").option(
2118
2097
  "--format <format>",
2119
2098
  "Output format: table|json|yaml|csv",
2120
2099
  "table"
@@ -2126,7 +2105,6 @@ function buildWorkspacesCommand() {
2126
2105
  try {
2127
2106
  list = yield client.workspaces.list({
2128
2107
  org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
2129
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0,
2130
2108
  search: opts.search,
2131
2109
  status: opts.status,
2132
2110
  limit: Number(opts.limit)
@@ -2154,7 +2132,7 @@ function buildWorkspacesCommand() {
2154
2132
  });
2155
2133
  })
2156
2134
  );
2157
- workspaces.command("show <id>").description("Show workspace details").option("--org <slug>", "Organization context").option("--personal", "Personal context").option("--format <format>", "Output format: table|json|yaml", "table").action(
2135
+ workspaces.command("show <id>").description("Show workspace details").option("--org <slug>", "Organization context").option("--personal", "Retired \u2014 context is organization-only").option("--format <format>", "Output format: table|json|yaml", "table").action(
2158
2136
  (id, opts) => __async(null, null, function* () {
2159
2137
  var _a2;
2160
2138
  const ctx = resolveContext(opts.personal, opts.org, false);
@@ -2162,8 +2140,7 @@ function buildWorkspacesCommand() {
2162
2140
  let ws;
2163
2141
  try {
2164
2142
  ws = yield client.workspaces.get(id, {
2165
- org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0,
2166
- personal: (ctx == null ? void 0 : ctx.type) === "personal" ? true : void 0
2143
+ org: (ctx == null ? void 0 : ctx.type) === "org" ? ctx.slug : void 0
2167
2144
  });
2168
2145
  } catch (err) {
2169
2146
  printError(err.message, 1);