@openacp/cli 2026.401.3 → 2026.401.4

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/cli.js CHANGED
@@ -27259,7 +27259,7 @@ Installs the plugin to ~/.openacp/plugins/.
27259
27259
  `);
27260
27260
  return;
27261
27261
  }
27262
- const pkg = args2[1];
27262
+ const pkg = args2[0];
27263
27263
  if (!pkg) {
27264
27264
  console.error("Usage: openacp install <package>");
27265
27265
  process.exit(1);
@@ -27298,7 +27298,7 @@ async function cmdUninstall(args2, instanceRoot) {
27298
27298
  `);
27299
27299
  return;
27300
27300
  }
27301
- const pkg = args2[1];
27301
+ const pkg = args2[0];
27302
27302
  if (!pkg) {
27303
27303
  console.error("Usage: openacp uninstall <package>");
27304
27304
  process.exit(1);
@@ -27699,7 +27699,7 @@ function printApiHelp() {
27699
27699
  `);
27700
27700
  }
27701
27701
  async function cmdApi(args2, instanceRoot) {
27702
- const subCmd = args2[1];
27702
+ const subCmd = args2[0];
27703
27703
  if (wantsHelp(args2) && (!subCmd || subCmd === "--help" || subCmd === "-h")) {
27704
27704
  printApiHelp();
27705
27705
  return;
@@ -27927,9 +27927,9 @@ Shows the version of the currently running daemon process.
27927
27927
  const call = (urlPath, options) => apiCall(port, urlPath, options, instanceRoot);
27928
27928
  try {
27929
27929
  if (subCmd === "new") {
27930
- const agent = args2[2];
27930
+ const agent = args2[1];
27931
27931
  const workspaceIdx = args2.indexOf("--workspace");
27932
- const workspace = workspaceIdx !== -1 ? args2[workspaceIdx + 1] : args2[3];
27932
+ const workspace = workspaceIdx !== -1 ? args2[workspaceIdx + 1] : args2[2];
27933
27933
  const channelIdx = args2.indexOf("--channel");
27934
27934
  const channel = channelIdx !== -1 ? args2[channelIdx + 1] : void 0;
27935
27935
  const body = {};
@@ -27952,7 +27952,7 @@ Shows the version of the currently running daemon process.
27952
27952
  console.log(` Workspace : ${data.workspace}`);
27953
27953
  console.log(` Status : ${data.status}`);
27954
27954
  } else if (subCmd === "cancel") {
27955
- const sessionId = args2[2];
27955
+ const sessionId = args2[1];
27956
27956
  if (!sessionId) {
27957
27957
  console.error("Usage: openacp api cancel <session-id>");
27958
27958
  process.exit(1);
@@ -28005,7 +28005,7 @@ Shows the version of the currently running daemon process.
28005
28005
  }
28006
28006
  }
28007
28007
  } else if (subCmd === "delete-topic") {
28008
- const sessionId = args2[2];
28008
+ const sessionId = args2[1];
28009
28009
  if (!sessionId) {
28010
28010
  console.error("Usage: openacp api delete-topic <session-id> [--force]");
28011
28011
  process.exit(1);
@@ -28045,12 +28045,12 @@ Shows the version of the currently running daemon process.
28045
28045
  }
28046
28046
  }
28047
28047
  } else if (subCmd === "send") {
28048
- const sessionId = args2[2];
28048
+ const sessionId = args2[1];
28049
28049
  if (!sessionId) {
28050
28050
  console.error("Usage: openacp api send <session-id> <prompt>");
28051
28051
  process.exit(1);
28052
28052
  }
28053
- const prompt = args2.slice(3).join(" ");
28053
+ const prompt = args2.slice(2).join(" ");
28054
28054
  if (!prompt) {
28055
28055
  console.error("Usage: openacp api send <session-id> <prompt>");
28056
28056
  process.exit(1);
@@ -28067,7 +28067,7 @@ Shows the version of the currently running daemon process.
28067
28067
  }
28068
28068
  console.log(`Prompt sent to session ${sessionId} (queue depth: ${data.queueDepth})`);
28069
28069
  } else if (subCmd === "session") {
28070
- const sessionId = args2[2];
28070
+ const sessionId = args2[1];
28071
28071
  if (!sessionId) {
28072
28072
  console.error("Usage: openacp api session <session-id>");
28073
28073
  process.exit(1);
@@ -28092,12 +28092,12 @@ Shows the version of the currently running daemon process.
28092
28092
  console.log(` Channel : ${s.channelId ?? "(none)"}`);
28093
28093
  console.log(` Thread : ${s.threadId ?? "(none)"}`);
28094
28094
  } else if (subCmd === "dangerous" || subCmd === "bypass") {
28095
- const sessionId = args2[2];
28095
+ const sessionId = args2[1];
28096
28096
  if (!sessionId) {
28097
28097
  console.error("Usage: openacp api bypass <session-id> [on|off]");
28098
28098
  process.exit(1);
28099
28099
  }
28100
- const toggle = args2[3];
28100
+ const toggle = args2[2];
28101
28101
  if (!toggle || toggle !== "on" && toggle !== "off") {
28102
28102
  console.error("Usage: openacp api bypass <session-id> [on|off]");
28103
28103
  process.exit(1);
@@ -28148,7 +28148,7 @@ Shows the version of the currently running daemon process.
28148
28148
  console.log("Restart signal sent. OpenACP is restarting...");
28149
28149
  } else if (subCmd === "config") {
28150
28150
  console.warn('\u26A0\uFE0F Deprecated: use "openacp config" or "openacp config set" instead.');
28151
- const subSubCmd = args2[2];
28151
+ const subSubCmd = args2[1];
28152
28152
  if (!subSubCmd) {
28153
28153
  const res = await call("/api/config");
28154
28154
  const data = await res.json();
@@ -28158,8 +28158,8 @@ Shows the version of the currently running daemon process.
28158
28158
  }
28159
28159
  console.log(JSON.stringify(data.config, null, 2));
28160
28160
  } else if (subSubCmd === "set") {
28161
- const configPath = args2[3];
28162
- const configValue = args2[4];
28161
+ const configPath = args2[2];
28162
+ const configValue = args2[3];
28163
28163
  if (!configPath || configValue === void 0) {
28164
28164
  console.error("Usage: openacp api config set <path> <value>");
28165
28165
  process.exit(1);
@@ -28214,7 +28214,7 @@ Shows the version of the currently running daemon process.
28214
28214
  console.log("Tunnel: not enabled");
28215
28215
  }
28216
28216
  } else if (subCmd === "notify") {
28217
- const message = args2.slice(2).join(" ");
28217
+ const message = args2.slice(1).join(" ");
28218
28218
  if (!message) {
28219
28219
  console.error("Usage: openacp api notify <message>");
28220
28220
  process.exit(1);
@@ -28239,12 +28239,12 @@ Shows the version of the currently running daemon process.
28239
28239
  }
28240
28240
  console.log(`Daemon version: ${data.version}`);
28241
28241
  } else if (subCmd === "session-config") {
28242
- const sessionId = args2[2];
28242
+ const sessionId = args2[1];
28243
28243
  if (!sessionId) {
28244
28244
  console.error("Usage: openacp api session-config <session-id> [set <opt> <value> | overrides | dangerous [on|off]]");
28245
28245
  process.exit(1);
28246
28246
  }
28247
- const configSubCmd = args2[3];
28247
+ const configSubCmd = args2[2];
28248
28248
  if (!configSubCmd || configSubCmd === "list") {
28249
28249
  const res = await call(`/api/sessions/${encodeURIComponent(sessionId)}/config`);
28250
28250
  const data = await res.json();
@@ -28282,8 +28282,8 @@ Shows the version of the currently running daemon process.
28282
28282
  Client overrides: ${JSON.stringify(clientOverrides)}`);
28283
28283
  }
28284
28284
  } else if (configSubCmd === "set") {
28285
- const configId = args2[4];
28286
- const value = args2[5];
28285
+ const configId = args2[3];
28286
+ const value = args2[4];
28287
28287
  if (!configId || value === void 0) {
28288
28288
  console.error("Usage: openacp api session-config <session-id> set <config-id> <value>");
28289
28289
  process.exit(1);
@@ -28321,7 +28321,7 @@ Client overrides: ${JSON.stringify(clientOverrides)}`);
28321
28321
  }
28322
28322
  }
28323
28323
  } else if (configSubCmd === "dangerous") {
28324
- const toggle = args2[4];
28324
+ const toggle = args2[3];
28325
28325
  if (toggle && toggle !== "on" && toggle !== "off") {
28326
28326
  console.error("Usage: openacp api session-config <session-id> dangerous [on|off]");
28327
28327
  process.exit(1);
@@ -28456,7 +28456,7 @@ init_api_client();
28456
28456
  init_helpers();
28457
28457
  import * as pathMod from "path";
28458
28458
  async function cmdConfig(args2 = [], instanceRoot) {
28459
- const subCmd = args2[1];
28459
+ const subCmd = args2[0];
28460
28460
  if (wantsHelp(args2) && subCmd === "set") {
28461
28461
  console.log(`
28462
28462
  \x1B[1mopenacp config set\x1B[0m \u2014 Set a config value directly
@@ -28504,8 +28504,8 @@ the API for live updates. When stopped, edits config file directly.
28504
28504
  return;
28505
28505
  }
28506
28506
  if (subCmd === "set") {
28507
- const configPath = args2[2];
28508
- const configValue = args2[3];
28507
+ const configPath = args2[1];
28508
+ const configValue = args2[2];
28509
28509
  if (!configPath || configValue === void 0) {
28510
28510
  console.error("Usage: openacp config set <path> <value>");
28511
28511
  process.exit(1);
@@ -28678,8 +28678,8 @@ as a messaging thread. Requires a running daemon.
28678
28678
  `);
28679
28679
  return;
28680
28680
  }
28681
- const agent = args2[1];
28682
- const sessionId = args2[2];
28681
+ const agent = args2[0];
28682
+ const sessionId = args2[1];
28683
28683
  if (!agent || !sessionId) {
28684
28684
  console.log("Usage: openacp adopt <agent> <session_id> [--cwd <path>] [--channel <name>]");
28685
28685
  console.log("Example: openacp adopt claude abc123-def456 --cwd /path/to/project");
@@ -28749,7 +28749,7 @@ a "Handoff" slash command to Claude Code.
28749
28749
  return;
28750
28750
  }
28751
28751
  const { getIntegration: getIntegration2, listIntegrations: listIntegrations2 } = await Promise.resolve().then(() => (init_integrate(), integrate_exports));
28752
- const agent = args2[1];
28752
+ const agent = args2[0];
28753
28753
  const uninstall = args2.includes("--uninstall");
28754
28754
  if (!agent) {
28755
28755
  console.log("Usage: openacp integrate <agent> [--uninstall]");
@@ -28812,7 +28812,7 @@ Fixable issues can be auto-repaired when not using --dry-run.
28812
28812
  return;
28813
28813
  }
28814
28814
  const knownFlags = ["--dry-run"];
28815
- const unknownFlags = args2.slice(1).filter(
28815
+ const unknownFlags = args2.filter(
28816
28816
  (a) => a.startsWith("--") && !knownFlags.includes(a)
28817
28817
  );
28818
28818
  if (unknownFlags.length > 0) {
@@ -28882,7 +28882,7 @@ async function createCatalog(instanceRoot) {
28882
28882
  return new AgentCatalog2();
28883
28883
  }
28884
28884
  async function cmdAgents(args2, instanceRoot) {
28885
- const subcommand = args2[1];
28885
+ const subcommand = args2[0];
28886
28886
  if (wantsHelp(args2) && (!subcommand || subcommand === "--help" || subcommand === "-h")) {
28887
28887
  console.log(`
28888
28888
  \x1B[1mopenacp agents\x1B[0m \u2014 Manage AI coding agents
@@ -28909,9 +28909,9 @@ async function cmdAgents(args2, instanceRoot) {
28909
28909
  }
28910
28910
  switch (subcommand) {
28911
28911
  case "install":
28912
- return agentsInstall(args2[2], args2.includes("--force"), wantsHelp(args2), instanceRoot);
28912
+ return agentsInstall(args2[1], args2.includes("--force"), wantsHelp(args2), instanceRoot);
28913
28913
  case "uninstall":
28914
- return agentsUninstall(args2[2], wantsHelp(args2), instanceRoot);
28914
+ return agentsUninstall(args2[1], wantsHelp(args2), instanceRoot);
28915
28915
  case "refresh":
28916
28916
  if (wantsHelp(args2)) {
28917
28917
  console.log(`
@@ -28927,9 +28927,9 @@ bypassing the normal staleness check.
28927
28927
  }
28928
28928
  return agentsRefresh(instanceRoot);
28929
28929
  case "info":
28930
- return agentsInfo(args2[2], wantsHelp(args2), instanceRoot);
28930
+ return agentsInfo(args2[1], wantsHelp(args2), instanceRoot);
28931
28931
  case "run":
28932
- return agentsRun(args2[2], args2.slice(3), wantsHelp(args2), instanceRoot);
28932
+ return agentsRun(args2[1], args2.slice(2), wantsHelp(args2), instanceRoot);
28933
28933
  case "list":
28934
28934
  case void 0:
28935
28935
  return agentsList(instanceRoot);
@@ -29270,7 +29270,7 @@ ACP-specific flags are automatically stripped.
29270
29270
  // src/cli/commands/tunnel.ts
29271
29271
  init_api_client();
29272
29272
  async function cmdTunnel(args2, instanceRoot) {
29273
- const subCmd = args2[1];
29273
+ const subCmd = args2[0];
29274
29274
  const port = readApiPort(void 0, instanceRoot);
29275
29275
  if (port === null) {
29276
29276
  console.error("OpenACP is not running. Start with `openacp start`");
@@ -29279,7 +29279,7 @@ async function cmdTunnel(args2, instanceRoot) {
29279
29279
  const call = (urlPath, options) => apiCall(port, urlPath, options, instanceRoot);
29280
29280
  try {
29281
29281
  if (subCmd === "add") {
29282
- const tunnelPort = args2[2];
29282
+ const tunnelPort = args2[1];
29283
29283
  if (!tunnelPort) {
29284
29284
  console.error("Usage: openacp tunnel add <port> [--label name] [--session id]");
29285
29285
  process.exit(1);
@@ -29317,7 +29317,7 @@ async function cmdTunnel(args2, instanceRoot) {
29317
29317
  if (t.publicUrl) console.log(` \u2192 ${t.publicUrl}`);
29318
29318
  }
29319
29319
  } else if (subCmd === "stop") {
29320
- const tunnelPort = args2[2];
29320
+ const tunnelPort = args2[1];
29321
29321
  if (!tunnelPort) {
29322
29322
  console.error("Usage: openacp tunnel stop <port>");
29323
29323
  process.exit(1);