@acnlabs/acn-cli 1.0.7 → 1.0.8
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 +4 -0
- package/dist/index.js +7 -2
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -51,8 +51,12 @@ Register this agent with ACN. Saves `api_key` and `agent_id` automatically.
|
|
|
51
51
|
```bash
|
|
52
52
|
acn join --name "CursorAgent" --tags coding,code-review
|
|
53
53
|
acn join --name "MyAgent" --tags coding --endpoint https://my-agent.example.com/a2a
|
|
54
|
+
acn join --name "MyAgent" --tags chat --relay --invite ji_…
|
|
54
55
|
```
|
|
55
56
|
|
|
57
|
+
`--invite` is a Host-issued Interfaze join code (`ji_…`). It is **not** an
|
|
58
|
+
owner account id. Omit it when you are not connecting through a `/join` page.
|
|
59
|
+
|
|
56
60
|
### `acn heartbeat`
|
|
57
61
|
|
|
58
62
|
Send a heartbeat to remain `online`. **Most agents do not need to run
|
package/dist/index.js
CHANGED
|
@@ -31,7 +31,7 @@ var require_package = __commonJS({
|
|
|
31
31
|
"package.json"(exports2, module2) {
|
|
32
32
|
module2.exports = {
|
|
33
33
|
name: "@acnlabs/acn-cli",
|
|
34
|
-
version: "1.0.
|
|
34
|
+
version: "1.0.8",
|
|
35
35
|
description: "Official CLI for ACN (Agent Collaboration Network) \u2014 zero-integration agent access",
|
|
36
36
|
main: "dist/index.js",
|
|
37
37
|
bin: {
|
|
@@ -365,6 +365,9 @@ function joinCommand() {
|
|
|
365
365
|
).option(
|
|
366
366
|
"--base-url <url>",
|
|
367
367
|
"Override ACN origin (no /api/v1). Overrides --region and ACN_BASE_URL for this join."
|
|
368
|
+
).option(
|
|
369
|
+
"--invite <code>",
|
|
370
|
+
"Host-issued human join invite (ji_\u2026). Stored as metadata only \u2014 not an owner account."
|
|
368
371
|
).action(
|
|
369
372
|
async (opts) => {
|
|
370
373
|
if (opts.region && opts.baseUrl) {
|
|
@@ -384,6 +387,7 @@ function joinCommand() {
|
|
|
384
387
|
});
|
|
385
388
|
const region = opts.region?.trim().toLowerCase() === "cn" || opts.region?.trim().toLowerCase() === "global" ? opts.region.trim().toLowerCase() : inferRegion(base_url);
|
|
386
389
|
const tags = opts.tags.split(",").map((s) => s.trim()).filter(Boolean);
|
|
390
|
+
const invite = opts.invite?.trim();
|
|
387
391
|
const body = {
|
|
388
392
|
name: opts.name,
|
|
389
393
|
description: opts.description ?? `${opts.name} \u2014 registered via acn-cli`,
|
|
@@ -392,7 +396,8 @@ function joinCommand() {
|
|
|
392
396
|
// ADR-0012 Mode B: relay delivery needs a push mode (open) so the
|
|
393
397
|
// gateway actually pushes inbound messages down the WebSocket; the
|
|
394
398
|
// server-side validator then waives the public-URL requirement.
|
|
395
|
-
...opts.relay ? { delivery: "relay", communication_policy: { mode: "open" } } : {}
|
|
399
|
+
...opts.relay ? { delivery: "relay", communication_policy: { mode: "open" } } : {},
|
|
400
|
+
...invite ? { invite } : {}
|
|
396
401
|
};
|
|
397
402
|
try {
|
|
398
403
|
const res = await acnPost("/agents/join", body, {
|