@mcpcloud/cli 0.18.0 → 0.19.0-next-20260901020935

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.
Files changed (3) hide show
  1. package/README.md +193 -42
  2. package/dist/index.js +535 -181
  3. package/package.json +1 -1
package/README.md CHANGED
@@ -1,6 +1,8 @@
1
1
  # @mcpcloud/cli
2
2
 
3
- The official command-line interface for [MCPCloud](https://mcpcloud.sh) — build, deploy, and operate MCP servers and Skills from your terminal. Everything the dashboard does, scriptable: ingest an OpenAPI/GraphQL spec into a typed MCP server, deploy it to the edge, watch metrics, manage custom domains, and wire skills into your coding agent.
3
+ The official command-line interface for [MCPCloud](https://mcpcloud.sh) — build, test, deploy, and operate MCP servers and Skills from your terminal. Everything the dashboard does, scriptable: ingest an OpenAPI/GraphQL spec into a typed MCP server, deploy it to the edge, sync tool metadata and handler code like a working tree, run sandbox test suites as a CI gate, watch metrics, manage custom domains, and wire servers and skills into your coding agent. Every server you deploy serves **MCP 2026-07-28 ("v2")** and the 2025 protocol side by side on the same endpoint — see [MCP v2](#mcp-v2--the-2026-07-28-revision).
4
+
5
+ The CLI is built to be driven by agents as much as by people: every command honors a machine-readable output contract (`--json`, stable exit codes, structured error envelopes), and the authoring loop — `mcp pull` / `mcp push`, sandbox tests, AI enrichment — is designed so a coding agent can take a server from spec to verified deployment without ever opening a browser.
4
6
 
5
7
  ```sh
6
8
  npm install -g @mcpcloud/cli
@@ -14,6 +16,7 @@ The package installs three equivalent binaries — `mcp` (primary), `mcpsh`, and
14
16
 
15
17
  - Node.js 18 or newer
16
18
  - An MCPCloud account (sign up at https://mcpcloud.sh)
19
+ - Optional: the `claude` CLI, if you want `--apply` flags to auto-register connections with Claude Code (`mcp doctor` checks for it)
17
20
 
18
21
  ## Installation
19
22
 
@@ -33,27 +36,29 @@ The CLI ships with the **MCPCloud production base URL baked in**, so a fresh mac
33
36
 
34
37
  ```sh
35
38
  mcp login # browser sign-in (recommended)
36
- mcp login --key mck_xxx # non-interactive (writes to shell history — prefer the env var)
37
- export MCPCLOUD_API_KEY=mck_xxx # or use an env var for CI
39
+ mcp login --key mcf_xxx # non-interactive (writes to shell history — prefer the env var)
40
+ export MCPCLOUD_API_KEY=mcf_xxx # or use an env var for CI
38
41
 
39
42
  mcp whoami # identity, resolved base URL (marked "(production)"), active profile
40
43
  mcp servers list # your deployed MCP servers
41
44
  mcp servers get srv_123 # detail view
42
45
  mcp tools list --server srv_123 # tools that server exposes
46
+ mcp init --from-spec ./openapi.yaml --deploy --wait
47
+ # spec → typed MCP server → live deployment, one command
43
48
  mcp skills connect skl_123 --agent claude-code --apply
44
49
  # auto-register a skill with Claude Code
45
50
  ```
46
51
 
47
- Run `mcp <command> --help` for the full option list, or `mcp help <topic>` for guided walkthroughs.
52
+ Run `mcp <command> --help` for the full option list, `mcp help <topic>` for guided walkthroughs, or read the full CLI documentation at https://mcpcloud.sh/docs/cli.
48
53
 
49
- ### Pointing at staging or a self-host
54
+ ### Pointing at a self-hosted deployment
50
55
 
51
56
  The production default is only a default — override it per environment. Precedence is `--base-url` flag → `MCPCLOUD_BASE_URL` → the saved profile's `baseUrl` → the built-in production default:
52
57
 
53
58
  ```sh
54
- export MCPCLOUD_BASE_URL=https://staging.example.com # env (CI / scripts)
55
- mcp config set-url https://staging.example.com # persist to the active profile
56
- mcp --base-url https://staging.example.com whoami # one-off override
59
+ export MCPCLOUD_BASE_URL=https://selfhost.example.com # env (CI / scripts)
60
+ mcp config set-url https://selfhost.example.com # persist to the active profile
61
+ mcp --base-url https://selfhost.example.com whoami # one-off override
57
62
  ```
58
63
 
59
64
  ## Authentication & config
@@ -72,21 +77,163 @@ mcp config set-org <name|id> # persist a default organization (accepts name,
72
77
 
73
78
  ## Profiles
74
79
 
75
- Keep separate credentials + base URLs for prod, staging, and self-host, and always know which one you're about to mutate:
80
+ Keep separate credentials + base URLs for production and any self-hosted deployments, and always know which one you're about to mutate:
76
81
 
77
82
  ```sh
78
- mcp config profile add staging --url https://staging.example.com --key mck_stg
79
- mcp config profile list # ✓ marks the active profile
80
- mcp config use staging # switch the active profile
81
- mcp --profile prod servers list # one-off override
82
- export MCPCLOUD_PROFILE=staging # or select via env
83
+ mcp config profile add selfhost --url https://selfhost.example.com --key mcf_xxx
84
+ mcp config profile list # ✓ marks the active profile
85
+ mcp config use selfhost # switch the active profile
86
+ mcp --profile prod servers list # one-off override
87
+ export MCPCLOUD_PROFILE=selfhost # or select via env
83
88
  ```
84
89
 
85
90
  `mcp whoami` prints the active profile and its source, and appends `(production)` to the base URL when it resolves to the production host — so a profile named "local" pointed at prod can't surprise you. `mcp doctor` runs the same resolution as an 8-point health check.
86
91
 
92
+ ## From spec to deployed server
93
+
94
+ `mcp init` walks the whole path in one guided command; the individual verbs compose the same loop for scripts:
95
+
96
+ ```sh
97
+ mcp init --from-spec ./openapi.yaml --deploy --wait # org → project → generated server → live
98
+
99
+ mcp servers ingest --project proj_123 --spec ./openapi.yaml # or a URL, @- stdin, or a GraphQL endpoint
100
+ mcp servers generate my-api --store # rebuild the bundle `deploy` will ship (see note below)
101
+ mcp servers deploy my-api --wait # deploy to Cloudflare Workers; --wait blocks until terminal
102
+ mcp servers get my-api --probe # verify the endpoint serves what the config promises
103
+ mcp invoke my-api getUser --args '{"id":"abc"}'
104
+ ```
105
+
106
+ Servers are addressable by id, name, or memorable slug throughout the CLI. Two verbs keep a server current after its API changes: `mcp servers push-spec` diffs a local spec against the stored tools (preview by default; `--apply` reconciles schemas by stable operation key, preserving curated descriptions, tags, risk classes, and enrichment), and `mcp servers regenerate` re-fetches the original source spec and rebuilds with the current codegen.
107
+
108
+ Two behaviors worth internalizing:
109
+
110
+ - **`--store` matters.** `deploy` ships a server's existing bundle unchanged, so after editing prompts, resources, or tool metadata, run `mcp servers generate --store` before deploying — otherwise the change never reaches the worker.
111
+ - **`--probe` is a drift detector.** Configuration and the endpoint are two different facts: a server can be *configured* for code mode while the edge answers "unknown tool". `--probe` calls the deployed endpoint, reports what it actually serves, and exits non-zero on drift, so CI can gate on it.
112
+
113
+ ## MCP v2 — the 2026-07-28 revision
114
+
115
+ Every server deployed through the CLI runs on the MCPCloud runtime, which serves the MCP **2026-07-28 revision ("v2")** and the 2025 protocol on the same endpoint. v2 clients connect with no `initialize` handshake and get `server/discover`, `resultType`, and cacheable tool catalogs; 2025-era clients keep working unchanged on the same URL. There is nothing to configure and no flag to pass — new deployments speak v2 automatically, and redeploying an existing server brings it onto the current runtime. (Servers created before the thin-bundle layout vendor their own runtime copy and need `mcp servers regenerate` + `deploy` to pick it up — a plain redeploy cannot update them.)
116
+
117
+ ## Edit a server like a working tree
118
+
119
+ `mcp pull` materializes a server into the current directory — every tool as a `.md` file, every handler override as `.ts`, plus an `AGENTS.md` carrying the same authoring rules the push gate enforces — and records the sync baseline `mcp push` diffs against:
120
+
121
+ ```sh
122
+ mcp pull --server my-api # cloud → files under .mcpcloud/ (cloud is the source of truth)
123
+ $EDITOR .mcpcloud/tools/<serverId>/get_user.md
124
+ # edit descriptions, tags, riskClass, handler code
125
+ mcp push --dry-run # print the exact change set without writing
126
+ mcp push # apply; exits non-zero if anything was refused
127
+ ```
128
+
129
+ Tool *shape* (schemas, method, path) is spec-owned and travels through `mcp servers push-spec`; `push` carries voice (description, tags, riskClass, idempotent) and handler code. A tool changed in the cloud since your pull is refused, never overwritten — re-run `mcp pull` and reapply. For single-tool round trips there are also `mcp tools pull` / `edit` / `diff` / `show` / `reset-handler`, and `mcp tools handlers list` shows which tools carry handler overrides.
130
+
87
131
  ## The dev loop
88
132
 
89
- `mcp dev` runs a deployed server **locally** with hot reload: it downloads the server's generated bundle, serves it on `localhost` (HTTP/SSE/stdio), watches your files (and optionally an OpenAPI spec) to regenerate on change, auto-wires the running instance into your coding agent (`--auto-connect claude-code`), and exposes an inspector UI at `/__inspect`. Pair it with the round-trip tool editors (`tools pull` / `tools edit` / `tools diff` / `tools reset-handler`) to iterate on tool metadata and handler source against the live bundle.
133
+ `mcp dev` runs a deployed server **locally** with hot reload: it downloads the server's generated bundle, serves it on `localhost` (HTTP/SSE/stdio), watches your files (and optionally an OpenAPI spec) to regenerate on change, auto-wires the running instance into your coding agent (`--auto-connect claude-code`), and exposes an inspector UI at `/__inspect`. The running session is scriptable too: `mcp dev list` shows sessions on this machine, `mcp dev invoke <tool>` calls into one, `mcp dev tail` streams inspector records as JSON lines, and `mcp dev replay` re-fires recorded calls.
134
+
135
+ **The git loop, end to end from the terminal:** `--git-repo <owner/name>` on `mcp init`, `mcp servers create`, and `mcp servers ingest` links a repository at creation — the repo fills itself the moment the server is first generated. For an existing server, `mcp servers git link <server> --repo <owner/name>` links a GitHub repository the MCPCloud GitHub App can access and runs the initial mirror sync (an empty repo is fine — the first push bootstraps it). `mcp servers git status` shows the whole picture: repo, mirror and reconcile state, and uncommitted working-tree changes. After a `git push` reconciles into the platform's working tree, `mcp servers commit -m "…"` cuts the internal version that makes it mirrorable and deployable, and `mcp servers git sync` pushes committed HEAD to the repo without waiting for the auto-sync sweep. `unlink` stops the loop without touching the repository.
136
+
137
+ Pushes to the linked branch also run the server's sandbox test suite against exactly the pushed code and report the verdict as a `mcpcloud/tests` commit status on GitHub (when the MCPCloud GitHub App has the Commit statuses permission) — CI for your MCP server with zero setup. And a committed version mirrors to the repo within seconds, not on the next sweep.
138
+
139
+ **Git-native mode (automatic):** if the server is linked to a GitHub repository, `mcp dev` clones it under `.mcpcloud/git/<owner>__<repo>` and runs against the working copy instead of the downloaded bundle — no flag needed. Prefer your own existing checkout? `mcp dev --repo <path>` serves from it (after verifying its origin is the linked repo), and the choice is remembered per server, so every later run — from any directory — reuses the same checkout instead of hiding a second clone. An existing checkout is reused across sessions (refreshed with a best-effort `git fetch`; local edits are never touched or reset), session byproducts are kept out of `git status` via `.git/info/exclude`, and the clone opens in your configured editor (`mcp config set-editor`, or `--open` / `--editor` per run). In this mode native git is the version control — the CLI's own edit watchers switch off; you edit, commit, and push, and the platform's GitHub App reconciles your source changes back into MCPCloud while the running session watches the sync status and tells you when a push has landed. Deploying stays an explicit step (`mcp servers deploy`).
140
+
141
+ ## Invoking tools
142
+
143
+ `mcp invoke` calls a tool on a deployed server — and understands every tool-surface mode a server can be in:
144
+
145
+ ```sh
146
+ mcp invoke my-api getUser --args '{"id":"abc"}' # args inline, @path/to/args.json, or @- for stdin
147
+ mcp invoke my-api --list # what can I call? (sees through wrapper discovery)
148
+ mcp invoke my-api --code @script.js # code mode: run JS inside the server's sandbox
149
+ mcp invoke --local getPet --args '{"id":"1"}' # boot the pulled tree once — no deploy, no daemon
150
+ mcp invoke my-api ping --deployment previous # target a selector: latest | active | previous
151
+ ```
152
+
153
+ - **Wrapper discovery:** a wrapper-mode server advertises only `searchTools` / `getToolDefinition` / `useTool` on `tools/list`. `--list` reads the real catalog through `searchTools`, and invoking an operation by name routes through `useTool` when it has to — so the command works the same either way.
154
+ - **Code mode:** `--code` runs your JavaScript next to the server's tools — `await tool(name, args)` calls them and only the final result crosses the wire. Requires code mode on the server (`mcp servers update --code-mode opt-in|default`).
155
+ - **Local boot:** `--local` runs the working tree as-is, unpushed edits included. The boot resolves no stored secrets — pass what you need with `--env` / `--env-file`; an upstream 401 means "no credential here", not a broken handler.
156
+
157
+ ## Sandbox tests as a deploy gate
158
+
159
+ Servers carry authorable test scenarios, grouped into suites and executed in a sandbox — all headless:
160
+
161
+ ```sh
162
+ mcp servers test-scenarios generate my-api # seed one baseline smoke test per tool (safe to re-run)
163
+ mcp servers variables list my-api # which {{variables}} still need values
164
+ mcp servers variables set my-api --set BASE_URL=https://api.example.com --set USER_ID=42
165
+ mcp servers test-suites run my-api # exit 0 = every scenario passed
166
+ mcp servers test-runs get run_123 # assertions, trace, and the tool response
167
+ ```
168
+
169
+ `test-suites run` picks an execution profile with `--execution-profile`: `mockBindings` (the default — needs no upstream credentials and answers "does this server work"), or `previewBindings` / `liveEndpoint`, which call the real upstream. `variables set` exits non-zero while any referenced variable still lacks a value, so CI can gate on that too. The same rung exists for skills: `mcp skills test-scenarios` / `test-runs`.
170
+
171
+ ## Tool quality: enrich, score, shape
172
+
173
+ ```sh
174
+ mcp tools enrich --all # AI-rewrite every tool's metadata as one job (--only, --no-apply)
175
+ mcp servers score my-api --start # agent-usability score, reported with its spread across runs
176
+ mcp servers shape my-api --start # propose task-shaped tools over the raw endpoints
177
+ ```
178
+
179
+ `enrich` rewrites tool descriptions for agent comprehension — per tool with a suggested-vs-applied diff, or the whole server as one background job. `score` measures whether an agent handed this catalog picks the right tool; the score is reported *with* its spread, and a move smaller than the spread is noise, not an improvement. `shape` proposals are inspectable artifacts — nothing is created until a proposal is accepted in the dashboard.
180
+
181
+ ## Prompts, resources, and composition
182
+
183
+ Servers expose more than tools. `mcp servers prompts set|list|rm` and `mcp servers resources set|list|rm` author the prompts and resources clients read from the server; content embeds into the bundle at generate time, so follow an edit with `mcp servers generate --store` and a deploy to ship it. `mcp servers deps add <server> <child>` composes another server's tools into this one — configuration, not copy-paste.
184
+
185
+ ## Skills, end to end
186
+
187
+ The whole skill lifecycle runs from the terminal — create a draft, author its content, cut a version, serve it as an MCP endpoint, and call it:
188
+
189
+ ```sh
190
+ mcp skills create --project proj_123 --name "triage"
191
+ mcp skills set-content triage --skill-md @SKILL.md \
192
+ --dependencies tool:abc123,server:def456 # + guardrails, schemas, composition graph
193
+ mcp skills publish triage # cut an immutable version
194
+ mcp skills deploy triage # serve the newest version as an MCP endpoint
195
+ mcp skills invoke triage --input '{"issue":"…"}' # auto-discovers the skill's tool and calls it
196
+ mcp skills connect triage --agent claude-code --apply
197
+ ```
198
+
199
+ `mcp skills token` reveals (or `--rotate`s) the skill's runtime bearer token, `mcp skills pull` downloads an installed skill as `SKILL.md` + `mcpcloud.json` for your coding agent, and `mcp skills installations` shows a skill's install footprint.
200
+
201
+ ## Connecting your coding agent
202
+
203
+ `mcp connect-agent` enrolls the active profile's key with the **official MCPCloud MCP server** and prints the connection snippet — the platform itself (servers, skills, deploys, tests) becomes tools your agent can call. `--status` shows the connection state; `--revoke` disconnects.
204
+
205
+ For individual skills, `mcp skills connect --agent <preset>` emits ready-to-paste configuration for a dozen agents — `claude-code`, `codex`, `claude-desktop`, `vscode`, `cursor`, `windsurf`, `antigravity`, `continue`, `cline`, `aider`, `zed`, `goose` — and `--apply` registers with Claude Code automatically via `claude mcp add`.
206
+
207
+ ## Distribution
208
+
209
+ - **Marketplace** — `mcp marketplace publish` a deployed server or versioned skill to the public registry; `install` one into your org; `fork` any artifact into a project as an editable draft.
210
+ - **Custom domains (Pro+)** — `mcp domains add` serves a server from a hostname you own. Domain **namespaces** go further: verify a parent domain once (`mcp domains namespaces add`), then attach subdomains to any server with no further DNS work. `transfer` moves a hostname between servers without certificate churn.
211
+ - **Self-host** — `mcp servers export` produces a self-host bundle (Dockerfile + Node entry + config) so a server can run outside MCPCloud entirely.
212
+
213
+ ## Operations
214
+
215
+ - **Upstream keys (BYOK)** — `mcp connections add <server>` stores *your* upstream API key for a server (rotation is just adding again); `list` shows hints only, never secrets.
216
+ - **Runtime secrets** — `mcp servers env set` manages encrypted, write-only env bindings the proxy injects at request time; plaintext is never returned, and setting a value schedules a runtime push to the active deployment.
217
+ - **OAuth** — `mcp oauth connections` lists provider connections across the org; `mcp oauth connection delete` revokes one (best-effort upstream revoke included). `mcp deployments runtime-auth` inspects a deployment's runtime-auth posture.
218
+ - **Recovery** — `mcp deployments rollback` flips a prior deployment back to active and demotes the current one in one shot; `mcp servers pause` / `resume` stop and restore traffic without tearing anything down.
219
+ - **Observability** — `mcp analytics` (workspace rollup: readiness, funnel, usage), `mcp metrics deployment` (error-rate budgets), `mcp deployments logs --follow`, `mcp orgs usage`, `mcp usage ledger` (credit ledger), and `mcp audit list` (admin/owner audit log).
220
+ - **Key hygiene** — `mcp api-keys rotate` mints a replacement key with a 24-hour grace window on the old one.
221
+
222
+ ## The terminal UI: `mcp ui`
223
+
224
+ `mcp ui` opens a full-screen terminal UI over the whole workspace — the fastest way to look around without memorizing verbs:
225
+
226
+ ```sh
227
+ mcp ui # splash → list view
228
+ mcp ui --no-splash # straight to the list
229
+ ```
230
+
231
+ Six tabs (keys `1`–`6`): **Servers**, **Projects**, **Skills**, **Deployments**, **Marketplace**, and **Dev sessions** — the last one shows local `mcp dev` runtimes alongside the live inspector. From any list you can open a detail view (`Enter`), tail deployment logs (`l`), switch organizations (`o`), and filter (`/`) or sort (`s` / `S`) the rows. Beyond browsing:
232
+
233
+ - `:` or `Ctrl-P` opens a command palette that reaches any verb by name.
234
+ - `D` opens a searchable docs view covering every command plus task playbooks.
235
+ - `,` opens a settings overlay that edits `~/.mcpcloud/config.json` in place.
236
+ - `?` shows the full key map at any time.
90
237
 
91
238
  ## Scripting & CI
92
239
 
@@ -112,6 +259,21 @@ mcp servers list --field id,name,status --format jsonl
112
259
  mcp servers list --filter status=active --no-table | cut -f1
113
260
  ```
114
261
 
262
+ ### Pagination
263
+
264
+ List commands follow the API's `nextCursor` to the end of the collection by default, so a workspace past one page is never silently truncated — and neither are the name/slug resolvers behind every `<server>` argument. `--limit <n>` caps the rows *shown*, not the page size, so `--limit 500` works even though the API pages at 100.
265
+
266
+ ### Aliases and completion
267
+
268
+ `mcp alias set <name> <kind>:<ref>` saves a per-profile shortcut for a `server:`, `project:`, or `skill:` reference; the name then works anywhere that kind of reference is accepted:
269
+
270
+ ```sh
271
+ mcp alias set forge server:forge-code-issues-api
272
+ mcp servers deploy forge --wait
273
+ ```
274
+
275
+ `mcp completion bash|zsh|fish` prints a shell completion script.
276
+
115
277
  ### Exit codes
116
278
 
117
279
  | Code | Meaning |
@@ -137,12 +299,14 @@ Mutations accept `--idempotency-key <key>` (1–255 ASCII chars, no whitespace).
137
299
 
138
300
  ### CI deploy gate
139
301
 
140
- The observability commands compose into a deploy gate that exits non-zero on failure — no output parsing required:
302
+ The testing and observability commands compose into a deploy gate that exits non-zero on failure — no output parsing required:
141
303
 
142
304
  ```sh
305
+ mcp servers test-suites run srv_123 --quiet # exit non-zero unless every scenario passes
143
306
  mcp servers deploy srv_123 --wait # block until the deploy is terminal
307
+ mcp servers get srv_123 --probe --quiet # exit non-zero if the endpoint drifts from config
144
308
  mcp deployments health <deploymentId> --quiet # exit non-zero unless healthy
145
- mcp metrics deployment <deploymentId> --since 15m --max-error-rate 0.02
309
+ mcp metrics deployment <deploymentId> --since 24h --max-error-rate 0.02
146
310
  # exit non-zero if the error rate breaches the budget
147
311
  ```
148
312
 
@@ -217,7 +381,7 @@ _Generated from the live command tree by `bun run docs:readme` — do not edit b
217
381
  | `mcp config set-org <organization>` | Save a default organization (by name, slug, or id) |
218
382
  | `mcp config set-url <url>` | Save the API base URL to ~/.mcpcloud/config.json |
219
383
  | `mcp config show` | Print the active profile (API key is redacted) |
220
- | `mcp config use <name>` | Switch the active profile (e.g. staging, prod) |
384
+ | `mcp config use <name>` | Switch the active profile (e.g. selfhost, prod) |
221
385
 
222
386
  ### `mcp connections` — Manage your per-server upstream API keys (BYOK) from the terminal
223
387
 
@@ -332,6 +496,7 @@ _Generated from the live command tree by `bun run docs:readme` — do not edit b
332
496
 
333
497
  | Command | Description |
334
498
  | --- | --- |
499
+ | `mcp servers commit <server>` | Commit the working tree as a new internal version (advances the branch — mirror + deploy see it) |
335
500
  | `mcp servers create` | Create an empty server skeleton in a project |
336
501
  | `mcp servers delete <server>` | Permanently delete a server and all its data. Requires --confirm "<exact name>". |
337
502
  | `mcp servers deploy <server>` | Deploy a server's generated bundle to Cloudflare Workers (closes the spec → deploy loop) |
@@ -348,6 +513,11 @@ _Generated from the live command tree by `bun run docs:readme` — do not edit b
348
513
  | `mcp servers export <server>` | Export a self-host bundle (Dockerfile + node entry + config) for a server |
349
514
  | `mcp servers generate <server>` | Generate the server's TypeScript bundle (the exact code `deploy` ships) and optionally write it to disk — a dry-run for the codegen path. Wraps POST /api/v1/server/generate. |
350
515
  | `mcp servers get <server>` | Get details for a single server (accepts id, name, or slug) |
516
+ | `mcp servers git` | Link a server to a GitHub repo and drive the sync loop from the terminal |
517
+ | `mcp servers git link <server>` | Link an existing GitHub repo (App installation must have access) and run the initial sync |
518
+ | `mcp servers git status <server>` | Show the server's git link, mirror + reconcile state, and working-tree changes |
519
+ | `mcp servers git sync <server>` | Push committed HEAD to the linked repo now (no cron wait) |
520
+ | `mcp servers git unlink <server>` | Unlink the GitHub repo — the repo is untouched, mirroring and reconciliation stop |
351
521
  | `mcp servers ingest` | Create a server from an OpenAPI spec (file, URL, or @- stdin) or a GraphQL endpoint. Wraps POST /api/v1/server/ingest. |
352
522
  | `mcp servers list` | List servers |
353
523
  | `mcp servers logs <server>` | Show recent deployment events for a server's latest deployment |
@@ -455,42 +625,23 @@ _Generated from the live command tree by `bun run docs:readme` — do not edit b
455
625
 
456
626
  ```jsonc
457
627
  {
458
- "apiKey": "mck_...", // saved by `mcp login`
628
+ "apiKey": "mcf_...", // saved by `mcp login`
459
629
  "baseUrl": "https://your-deployment...", // saved by `mcp config set-url` (omit to use the production default)
460
630
  "defaultOrganizationId": "org_...", // saved by `mcp config set-org`
461
- "profiles": { "staging": { /* apiKey + baseUrl + defaultOrganizationId */ } }
631
+ "profiles": { "selfhost": { /* apiKey + baseUrl + defaultOrganizationId */ } }
462
632
  }
463
633
  ```
464
634
 
465
635
  ## Reliability
466
636
 
467
637
  - **Timeout:** every request is bounded by a 30-second `AbortController`.
468
- - **Retry:** transient failures (network errors, HTTP 502/503/504) are retried once with jittered backoff. 4xx responses are never retried.
638
+ - **Retry:** transient failures (network errors, HTTP 502/503/504) are retried once with jittered backoff, and a 429 carrying a `Retry-After` header is retried once after the server-suggested delay. Other 4xx responses are never retried.
469
639
  - **Error envelope:** server errors carry their `code`, `message`, `requestId`, and `docsUrl` so you can correlate with backend logs.
470
640
 
471
- ## Development
472
-
473
- ```sh
474
- git clone https://github.com/MCPCloud-sh/mcp-hub
475
- cd mcp-hub/packages/cli
476
-
477
- bun install
478
- bun run dev -- --help # run from source
479
- bun run typecheck # tsc --noEmit
480
- bun run test # vitest
481
- bun run build # bundle to dist/index.js
482
- bun run docs:readme # regenerate the command reference above
483
- ```
484
-
485
- The command reference between the markers is generated from the live Commander tree by `bun run docs:readme`; a conformance test fails if it drifts, so a new command can't ship with a stale README.
486
-
487
- ## Releasing
488
-
489
- The CLI is released independently of the dashboard via [Changesets](https://github.com/changesets/changesets).
490
-
491
641
  ## Support
492
642
 
493
- - Documentation: https://mcpcloud.sh/docs
643
+ - CLI documentation: https://mcpcloud.sh/docs/cli
644
+ - Platform documentation: https://mcpcloud.sh/docs
494
645
  - Email: support@mail.mcpcloud.sh
495
646
 
496
647
  ## License