refactor!: rebrand CCAM to AgentHub
Clean break, no compatibility alias. Renames the product name, the CLI binary (`ccam` -> `agenthub`), the env var prefix (`CCAM_` -> `AGENTHUB_`), the Prometheus metric namespace (`ccam_*` -> `agenthub_*`), the tmux session prefix (`ccam-lane-<id>` -> `agenthub-lane-<id>`), the per-repo runtime profile directory (`.ccam/profile` -> `.agenthub/profile`), the lanes state root (`~/.claude/ccam-lanes` -> `~/.claude/agenthub-lanes`), the bundled plugins (`plugins/ccam*` -> `plugins/agenthub*`) and their slash commands (`/ccam-doctor` -> `/agenthub-doctor`, `/ccam:*` -> `/agenthub:*`). Because there is no alias, an existing install has to be updated by hand: rename its `.ccam/profile` directory and any `CCAM_*` variables, and reinstall the plugin under its new name. Two other name families are deliberately left alone here, since they are not just strings: the `Claude-Code-Monitor` repository/marketplace name, and the `agent-dashboard` npm package plus its `~/.claude/agent-dashboard` runtime directory, which holds the live database and needs a migration rather than a rename. Verified: server 1406/1406, client 459/459, `grep -i ccam` clean across tracked files, `openapi.yaml` regenerated (95 paths, unchanged count).
This commit is contained in:
@@ -285,7 +285,7 @@ const paths = {
|
||||
tags: ["Lanes"],
|
||||
summary: "A lane's own application stack",
|
||||
description:
|
||||
"Slot, ports, per-service liveness, log paths and the last boot error. Recomputed on every call from pid files and port probes rather than cached, because a process can die to OOM or a stray kill without telling anyone. Read-only, so no same-origin guard. Kept out of GET /api/lanes because it opens a socket per declared port and stats every pid file. A lane whose repository declares no .ccam/profile returns available:false with HTTP 200 — most lanes never run a stack, which is a normal state, not a fault.",
|
||||
"Slot, ports, per-service liveness, log paths and the last boot error. Recomputed on every call from pid files and port probes rather than cached, because a process can die to OOM or a stray kill without telling anyone. Read-only, so no same-origin guard. Kept out of GET /api/lanes because it opens a socket per declared port and stats every pid file. A lane whose repository declares no .agenthub/profile returns available:false with HTTP 200 — most lanes never run a stack, which is a normal state, not a fault.",
|
||||
operationId: "getLaneRuntime",
|
||||
parameters: [{ name: "id", in: "path", required: true, schema: { type: "integer" } }],
|
||||
responses: {
|
||||
@@ -325,7 +325,7 @@ const paths = {
|
||||
},
|
||||
responses: {
|
||||
202: { description: "Accepted; the boot runs in the background." },
|
||||
400: { description: "ENOPROFILE — no .ccam/profile, with the paths searched." },
|
||||
400: { description: "ENOPROFILE — no .agenthub/profile, with the paths searched." },
|
||||
403: { description: "The browser request was not same-origin/loopback." },
|
||||
404: { description: "Lane not found." },
|
||||
409: { description: "ESLOTS (every slot taken) or EPORTBUSY (with the occupying pids)." },
|
||||
|
||||
@@ -211,7 +211,7 @@ const RESET_PRICING_EXAMPLE = {
|
||||
};
|
||||
|
||||
const EXPORT_EXAMPLE = {
|
||||
format: "ccam-export",
|
||||
format: "agenthub-export",
|
||||
version: 1,
|
||||
exported_at: "2026-06-26T01:12:44.913Z",
|
||||
sessions: [
|
||||
@@ -1101,7 +1101,7 @@ const paths = {
|
||||
tags: ["Settings"],
|
||||
summary: "Export all dashboard data as JSON",
|
||||
description:
|
||||
'Exports the entire dataset as a single versioned JSON document — all sessions, agents, events, token_usage rows, workflows, dashboard_runs, alert_rules, and model_pricing — stamped with `format: "ccam-export"`, `version`, and `exported_at`. Served with a `Content-Disposition: attachment` header (filename `agent-monitor-export-YYYY-MM-DD.json`) so browsers download it. Use it to back up before a destructive operation (clear-data / cleanup with purge_days) or to migrate/consolidate data across machines — the bundle is re-importable via POST /api/settings/import. Read-only; nothing is modified.',
|
||||
'Exports the entire dataset as a single versioned JSON document — all sessions, agents, events, token_usage rows, workflows, dashboard_runs, alert_rules, and model_pricing — stamped with `format: "agenthub-export"`, `version`, and `exported_at`. Served with a `Content-Disposition: attachment` header (filename `agent-monitor-export-YYYY-MM-DD.json`) so browsers download it. Use it to back up before a destructive operation (clear-data / cleanup with purge_days) or to migrate/consolidate data across machines — the bundle is re-importable via POST /api/settings/import. Read-only; nothing is modified.',
|
||||
operationId: "exportData",
|
||||
responses: {
|
||||
200: {
|
||||
@@ -1122,7 +1122,7 @@ const paths = {
|
||||
tags: ["Settings"],
|
||||
summary: "Restore (import) a previously exported data bundle",
|
||||
description:
|
||||
'Restores a bundle produced by GET /api/settings/export. Supply it either as `multipart/form-data` with a single `file` field (browser upload) or as a JSON body `{ "path": "<absolute path>" }` (the server reads the file from disk — used by the `ccam import-data` CLI, and it also sidesteps the global 1 MB JSON body cap for large bundles). The restore is idempotent and NON-DESTRUCTIVE: it is session-atomic, so a session already present (matched by its UUID) is skipped whole together with its agents/events/token_usage/workflows, and independent config rows (dashboard_runs, alert_rules, model_pricing) are inserted only when absent. Nothing existing is overwritten — ideal for consolidating several machines into one dashboard. The response reports per-table counts.',
|
||||
'Restores a bundle produced by GET /api/settings/export. Supply it either as `multipart/form-data` with a single `file` field (browser upload) or as a JSON body `{ "path": "<absolute path>" }` (the server reads the file from disk — used by the `agenthub import-data` CLI, and it also sidesteps the global 1 MB JSON body cap for large bundles). The restore is idempotent and NON-DESTRUCTIVE: it is session-atomic, so a session already present (matched by its UUID) is skipped whole together with its agents/events/token_usage/workflows, and independent config rows (dashboard_runs, alert_rules, model_pricing) are inserted only when absent. Nothing existing is overwritten — ideal for consolidating several machines into one dashboard. The response reports per-table counts.',
|
||||
operationId: "importData",
|
||||
requestBody: {
|
||||
required: true,
|
||||
@@ -1147,7 +1147,7 @@ const paths = {
|
||||
},
|
||||
},
|
||||
},
|
||||
example: { path: "/Users/you/ccam-export-2026-06-26.json" },
|
||||
example: { path: "/Users/you/agenthub-export-2026-06-26.json" },
|
||||
},
|
||||
},
|
||||
},
|
||||
@@ -1160,7 +1160,7 @@ const paths = {
|
||||
example: {
|
||||
ok: true,
|
||||
source: "agent-monitor-export-2026-06-26.json",
|
||||
format: "ccam-export",
|
||||
format: "agenthub-export",
|
||||
sessions_imported: 42,
|
||||
sessions_skipped: 3,
|
||||
agents: 96,
|
||||
|
||||
Reference in New Issue
Block a user