@actiondock/cli 2.0.0 → 2.0.1

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/README.md CHANGED
@@ -6,20 +6,19 @@ The official Command Line Interface (CLI) toolchain for ActionDock 2.0.
6
6
  [![TypeScript](https://img.shields.io/badge/TypeScript-5.0+-blue?logo=typescript)](https://www.typescriptlang.org/)
7
7
  [![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://opensource.org/licenses/Apache-2.0)
8
8
 
9
- > **Runtime requirement**: [Bun](https://bun.sh/) >= 1.2.0 is required.
10
- > *(ActionDock CLI relies natively on Bun. Even if you install via `npm install -g @actiondock/cli`, Bun must be installed on your machine as the executable shebang runs via `#!/usr/bin/env bun`.)*
9
+ > **Runtime requirement**: [Bun](https://bun.sh/) >= 1.2.0.
11
10
 
12
- `@actiondock/cli` provides the `ac` command to develop, test, build, deploy, and export AI Agent Actions and Skills across MCP, HTTP, CLI, and standalone executables.
11
+ `@actiondock/cli` provides the `ad` command to develop, test, build, deploy, and export AI Agent Actions and Skills across MCP, HTTP, CLI, and standalone executables.
13
12
 
14
13
  ---
15
14
 
16
15
  ## Installation
17
16
 
18
17
  ```bash
19
- # Global installation via Bun
20
- bun add -g @actiondock/cli
18
+ # 1. Install Bun runtime (if not already installed)
19
+ npm install -g bun
21
20
 
22
- # Or via npm
21
+ # 2. Install ActionDock CLI
23
22
  npm install -g @actiondock/cli
24
23
  ```
25
24
 
@@ -29,20 +28,20 @@ npm install -g @actiondock/cli
29
28
 
30
29
  ```bash
31
30
  # 1. Initialize a new Action package scaffold
32
- ac init my-tools
31
+ ad init my-tools
33
32
  cd my-tools
34
33
 
35
34
  # 2. Run an Action locally (outputs standard JSON envelope)
36
- ac run sample.greet --input '{"name": "Alice"}'
35
+ ad run sample.greet --input '{"name": "Alice"}'
37
36
 
38
37
  # 3. Run in-memory unit tests
39
- ac test
38
+ ad test
40
39
 
41
40
  # 4. Compile into a single standalone binary
42
- ac build
41
+ ad build
43
42
 
44
43
  # 5. Export as a portable Agent Skill (with SOPs)
45
- ac export skill
44
+ ad export skill
46
45
  ```
47
46
 
48
47
  ---
@@ -51,35 +50,35 @@ ac export skill
51
50
 
52
51
  | Command | Purpose |
53
52
  |---|---|
54
- | `ac init [dir]` | Initialize an Action package scaffold |
55
- | `ac info [patterns...]` | Explore capabilities and display metadata (supports fuzzy matching and `--tree`) |
56
- | `ac doctor` | Run environment, global registry health, and project diagnostics |
57
- | `ac action list` / `ac run <id>` | List and execute Actions |
58
- | `ac playbook list` / `show` | Inspect agent task SOP Playbooks |
59
- | `ac config list` / `get` / `set` | Manage runtime configurations |
60
- | `ac state list` / `get` / `set` / `delete` / `clear` | Inspect and manage persistent state (with namespaces, TTL, and clear) |
61
- | `ac runs list` / `show` | Inspect execution history and traces |
62
- | `ac test` | Run fast unit tests |
63
- | `ac build` | Compile into a zero-dependency standalone binary |
64
- | `ac export skill` | Export Skill bundle for AI Agent platforms |
65
- | `ac link` / `unlink` | Manage global router (with live subproject auto-discovery and prune) |
66
- | `ac profile` / `ac serve` | Manage remote node profiles and start HTTP Runner |
67
- | `ac mcp` | Start ActionDock as STDIO or HTTP MCP server |
53
+ | `ad init [dir]` | Initialize an Action package scaffold |
54
+ | `ad info [patterns...]` | Explore capabilities and display metadata (supports fuzzy matching and `--tree`) |
55
+ | `ad doctor` | Run environment, global registry health, and project diagnostics |
56
+ | `ad action list` / `ad run <id>` | List and execute Actions |
57
+ | `ad playbook list` / `show` | Inspect agent task SOP Playbooks |
58
+ | `ad config list` / `get` / `set` | Manage runtime configurations |
59
+ | `ad state list` / `get` / `set` / `delete` / `clear` | Inspect and manage persistent state (with namespaces, TTL, and clear) |
60
+ | `ad runs list` / `show` | Inspect execution history and traces |
61
+ | `ad test` | Run fast unit tests |
62
+ | `ad build` | Compile into a zero-dependency standalone binary |
63
+ | `ad export skill` | Export Skill bundle for AI Agent platforms |
64
+ | `ad link` / `unlink` | Manage global router (with live subproject auto-discovery and prune) |
65
+ | `ad profile` / `ad serve` | Manage remote node profiles and start HTTP Runner |
66
+ | `ad mcp` | Start ActionDock as STDIO or HTTP MCP server |
68
67
 
69
68
  ---
70
69
 
71
70
  ## 📖 Complete Documentation
72
71
 
73
- For the full list of flags, options, remote profiles, and advanced usage, refer to the [ActionDock Documentation Center](https://github.com/team4u/actiondock#readme):
72
+ For the full list of flags, options, remote profiles, and advanced usage, refer to the [ActionDock Documentation Center](../../docs/README.md):
74
73
 
75
- - [CLI Reference Manual](https://github.com/team4u/actiondock/blob/main/docs/reference/cli.md)
76
- - [Quick Start Guide](https://github.com/team4u/actiondock/blob/main/docs/getting-started/quick-start.md)
77
- - [MCP Integration Guide](https://github.com/team4u/actiondock/blob/main/docs/guides/mcp.md)
78
- - [Standalone Binary Build Guide](https://github.com/team4u/actiondock/blob/main/docs/guides/standalone-build.md)
79
- - [Skill Export Guide](https://github.com/team4u/actiondock/blob/main/docs/guides/skill-export.md)
74
+ - [CLI Reference Manual](../../docs/reference/cli.md)
75
+ - [Quick Start Guide](../../docs/developer/quick-start.md)
76
+ - [MCP Integration Guide](../../docs/consumer/use-as-mcp.md)
77
+ - [Standalone Binary Build Guide](../../docs/developer/build-and-export.md)
78
+ - [Agent Skill Usage Guide](../../docs/consumer/use-as-skill.md)
80
79
 
81
80
  ---
82
81
 
83
82
  ## License
84
83
 
85
- [Apache-2.0](LICENSE) © team4u
84
+ [Apache-2.0](../../LICENSE) © team4u
package/package.json CHANGED
@@ -1,10 +1,11 @@
1
1
  {
2
2
  "name": "@actiondock/cli",
3
- "version": "2.0.0",
3
+ "version": "2.0.1",
4
4
  "description": "ActionDock CLI facade for developing, testing, building, and exporting standalone Agent Actions and Skills",
5
5
  "type": "module",
6
6
  "bin": {
7
- "ac": "./bin/ac.js"
7
+ "ad": "./bin/ad.js",
8
+ "actiondock": "./bin/ad.js"
8
9
  },
9
10
  "main": "./src/index.ts",
10
11
  "module": "./src/index.ts",
@@ -36,7 +37,7 @@
36
37
  "@types/bun": "latest",
37
38
  "typescript": "^5.7.0"
38
39
  },
39
- "keywords": ["actiondock", "ac", "agent", "cli", "skill", "builder", "mcp"],
40
+ "keywords": ["actiondock", "ad", "agent", "cli", "skill", "builder", "mcp"],
40
41
  "author": "team4u",
41
42
  "license": "Apache-2.0",
42
43
  "repository": {
@@ -113,7 +113,7 @@ export function registerActionCommands(program: Command): void {
113
113
  const linkedList = listLinkedPackages();
114
114
  if (linkedList.length === 0) {
115
115
  console.log("No ActionDock project in current directory, and no packages linked.");
116
- console.log("Run 'ac link' inside an Action package to register it.");
116
+ console.log("Run 'ad link' inside an Action package to register it.");
117
117
  return;
118
118
  }
119
119
 
@@ -283,7 +283,7 @@ export default defineAction<Input, Output>({
283
283
  writeFileSync(targetFullFile, template, "utf-8");
284
284
  console.log(`[OK] Created Action '${id}' at ${targetFullFile}`);
285
285
  console.log(`\nTo run this action:`);
286
- console.log(` ac action run ${id} --input '{"exampleParam": "hello"}'`);
286
+ console.log(` ad action run ${id} --input '{"exampleParam": "hello"}'`);
287
287
  } catch (err: any) {
288
288
  console.error(`Error: ${err.message}`);
289
289
  process.exit(1);
@@ -454,10 +454,10 @@ export default defineAction<Input, Output>({
454
454
  await executeAction(id, options);
455
455
  });
456
456
 
457
- // Root level alias: ac run <id>
457
+ // Root level alias: ad run <id>
458
458
  program
459
459
  .command("run <id>")
460
- .description("Alias for 'ac action run <id>'")
460
+ .description("Alias for 'ad action run <id>'")
461
461
  .option("-i, --input <json>", "Input as JSON string")
462
462
  .option("-f, --input-file <path>", "Input from JSON file")
463
463
  .option("-c, --config <key=value...>", "Temporary config override")
@@ -551,7 +551,7 @@ async function executeAction(id: string, options: any): Promise<void> {
551
551
  // Local execution
552
552
  if (options.async) {
553
553
  console.error(
554
- "Error: Async execution requires a long-running ActionDock server.\nUse --profile, --server, or start `ac serve`."
554
+ "Error: Async execution requires a long-running ActionDock server.\nUse --profile, --server, or start `ad serve`."
555
555
  );
556
556
  process.exit(1);
557
557
  }
@@ -28,7 +28,7 @@ export function registerConfigCommands(program: Command): void {
28
28
  const root = resolvePackageRoot(identifier || options.package);
29
29
  if (!root) {
30
30
  console.error(
31
- "Error: Not in an ActionDock project.\nUsage: ac config schema [package-id] or cd into a project directory."
31
+ "Error: Not in an ActionDock project.\nUsage: ad config schema [package-id] or cd into a project directory."
32
32
  );
33
33
  process.exit(1);
34
34
  }
@@ -123,7 +123,7 @@ export function registerConfigCommands(program: Command): void {
123
123
  if (missingRequired.length > 0) {
124
124
  console.log(`\n[WARNING] ${missingRequired.length} required config(s) not set:`);
125
125
  for (const m of missingRequired) {
126
- console.log(` - ${m.key}: Run 'ac config set ${m.key} <value>' to configure.`);
126
+ console.log(` - ${m.key}: Run 'ad config set ${m.key} <value>' to configure.`);
127
127
  }
128
128
  } else {
129
129
  console.log("\n[OK] All configuration dependencies are satisfied.");
@@ -19,9 +19,9 @@ export function createCliProgram(): Command {
19
19
  const program = new Command();
20
20
 
21
21
  program
22
- .name("ac")
23
- .description("ActionDock (ac) 2.0 - Toolchain for building and shipping standalone AI Agent Actions & Skills")
24
- .version("2.0.0");
22
+ .name("ad")
23
+ .description("ActionDock (ad) 2.0 - Toolchain for building and shipping standalone AI Agent Actions & Skills")
24
+ .version("2.0.1");
25
25
 
26
26
  registerInitCommand(program);
27
27
  registerInfoCommand(program);
@@ -122,7 +122,7 @@ function printAggregatedPackages(
122
122
  }
123
123
  if (options?.showTip !== false) {
124
124
  console.log(
125
- "Tip: Run 'ac info <package-id>' to view detailed package configuration and schema."
125
+ "Tip: Run 'ad info <package-id>' to view detailed package configuration and schema."
126
126
  );
127
127
  }
128
128
  }
@@ -133,7 +133,7 @@ function printRegistryTree(status: ReturnType<typeof getRegistryStatus>): void {
133
133
 
134
134
  if (!hasWorkspaces && !hasPackages) {
135
135
  console.log("[INFO] No ActionDock packages or workspaces currently linked.");
136
- console.log(" Run 'ac link' inside an Action package or workspace to register it.");
136
+ console.log(" Run 'ad link' inside an Action package or workspace to register it.");
137
137
  return;
138
138
  }
139
139
 
@@ -165,7 +165,7 @@ function printRegistryTree(status: ReturnType<typeof getRegistryStatus>): void {
165
165
 
166
166
  console.log(`\n[Summary] Total: ${status.totalPackagesCount} active package(s), ${status.workspaces.length} workspace(s)`);
167
167
  if (status.staleCount > 0) {
168
- console.log(`[WARN] ${status.staleCount} stale entry/entries detected. Run 'ac unlink --prune' to clean up.`);
168
+ console.log(`[WARN] ${status.staleCount} stale entry/entries detected. Run 'ad unlink --prune' to clean up.`);
169
169
  }
170
170
  }
171
171
 
@@ -423,7 +423,7 @@ export function registerInfoCommand(program: Command): void {
423
423
  "No ActionDock project in current directory, and no packages linked."
424
424
  );
425
425
  console.log(
426
- "Run 'ac link' inside an Action package to register it."
426
+ "Run 'ad link' inside an Action package to register it."
427
427
  );
428
428
  return;
429
429
  }
@@ -6,7 +6,7 @@ import {
6
6
  import { Command } from "commander";
7
7
 
8
8
  export function registerLinkCommands(program: Command): void {
9
- // ac link [path]
9
+ // ad link [path]
10
10
  program
11
11
  .command("link [path]")
12
12
  .option("-r, --recursive", "Recursively discover and link packages in subdirectories")
@@ -32,7 +32,7 @@ export function registerLinkCommands(program: Command): void {
32
32
  }
33
33
  });
34
34
 
35
- // ac unlink [id|path]
35
+ // ad unlink [id|path]
36
36
  program
37
37
  .command("unlink [identifier]")
38
38
  .option("-p, --prune", "Automatically scan and prune any stale/missing paths from registry")
@@ -65,7 +65,7 @@ export function registerPlaybookCommands(program: Command): void {
65
65
  const linkedList = listLinkedPackages();
66
66
  if (linkedList.length === 0) {
67
67
  console.log("No ActionDock project in current directory, and no packages linked.");
68
- console.log("Run 'ac link' inside an Action package to register it.");
68
+ console.log("Run 'ad link' inside an Action package to register it.");
69
69
  return;
70
70
  }
71
71
 
@@ -20,7 +20,7 @@ export function registerProfileCommands(program: Command): void {
20
20
  .command("profile")
21
21
  .description("Manage multi-cloud and remote execution profiles");
22
22
 
23
- // ac profile list
23
+ // ad profile list
24
24
  profileCmd
25
25
  .command("list [patterns...]")
26
26
  .description("List all configured profiles")
@@ -86,7 +86,7 @@ export function registerProfileCommands(program: Command): void {
86
86
  );
87
87
  }
88
88
  console.log(
89
- "\nUse 'ac profile use <name>' to switch or 'ac run <action> --profile <name>' to execute on a specific target."
89
+ "\nUse 'ad profile use <name>' to switch or 'ad run <action> --profile <name>' to execute on a specific target."
90
90
  );
91
91
  }
92
92
  } catch (err: any) {
@@ -95,7 +95,7 @@ export function registerProfileCommands(program: Command): void {
95
95
  }
96
96
  });
97
97
 
98
- // ac profile add <name>
98
+ // ad profile add <name>
99
99
  profileCmd
100
100
  .command("add <name>")
101
101
  .description("Add or update a remote execution profile")
@@ -123,7 +123,7 @@ export function registerProfileCommands(program: Command): void {
123
123
  }
124
124
  });
125
125
 
126
- // ac profile use <name>
126
+ // ad profile use <name>
127
127
  profileCmd
128
128
  .command("use <name>")
129
129
  .description("Switch active default profile")
@@ -137,7 +137,7 @@ export function registerProfileCommands(program: Command): void {
137
137
  }
138
138
  });
139
139
 
140
- // ac profile show [name]
140
+ // ad profile show [name]
141
141
  profileCmd
142
142
  .command("show [name]")
143
143
  .description("Display details of a profile (defaults to active profile)")
@@ -200,7 +200,7 @@ export function registerProfileCommands(program: Command): void {
200
200
  }
201
201
  });
202
202
 
203
- // ac profile rm / remove <name>
203
+ // ad profile rm / remove <name>
204
204
  profileCmd
205
205
  .command("rm <name>")
206
206
  .alias("remove")
@@ -223,7 +223,7 @@ export function registerProfileCommands(program: Command): void {
223
223
  }
224
224
  });
225
225
 
226
- // ac profile test [name]
226
+ // ad profile test [name]
227
227
  profileCmd
228
228
  .command("test [name]")
229
229
  .description("Test connection latency and health of a profile")
@@ -107,7 +107,7 @@ export function registerRunsCommands(program: Command): void {
107
107
  const linkedList = listLinkedPackages();
108
108
  if (linkedList.length === 0) {
109
109
  console.log("No ActionDock project in current directory, and no packages linked.");
110
- console.log("Run 'ac link' inside an Action package to register it.");
110
+ console.log("Run 'ad link' inside an Action package to register it.");
111
111
  return;
112
112
  }
113
113
 
@@ -293,7 +293,7 @@ export function registerRunsCommands(program: Command): void {
293
293
 
294
294
  if (target.type === "local") {
295
295
  console.error(
296
- "Error: 'ac runs cancel' is only supported for remote execution targets. Use --profile <name> or --server <url>."
296
+ "Error: 'ad runs cancel' is only supported for remote execution targets. Use --profile <name> or --server <url>."
297
297
  );
298
298
  process.exit(1);
299
299
  }
@@ -80,7 +80,7 @@ export function registerServeCommand(program: Command): void {
80
80
  console.log(` * Max Body Size: ${options.maxBody || "1mb"}`);
81
81
  console.log(` * Health Endpoint: http://${host === "0.0.0.0" ? "127.0.0.1" : host}:${server.port}/api/v1/health`);
82
82
  console.log(`======================================================\n`);
83
- console.log(`Server is ready to accept remote 'ac run' requests.`);
83
+ console.log(`Server is ready to accept remote 'ad run' requests.`);
84
84
  console.log(`Press Ctrl+C to terminate.\n`);
85
85
 
86
86
  // Keep process running
@@ -124,7 +124,7 @@ export function registerStateCommands(program: Command): void {
124
124
  const linkedList = listLinkedPackages();
125
125
  if (linkedList.length === 0) {
126
126
  console.log("No ActionDock project in current directory, and no packages linked.");
127
- console.log("Run 'ac link' inside an Action package to register it.");
127
+ console.log("Run 'ad link' inside an Action package to register it.");
128
128
  return;
129
129
  }
130
130