mcp-agent CLI is the primary interface for project scaffolding, deployment, and day‑to‑day management of MCP Agent Cloud. Run commands ad hoc with uvx mcp-agent … (no install required). If mcp-agent is listed in your project dependencies, uv run mcp-agent … executes inside that environment.
Quick reference
Primary workflows
Log in to MCP Agent Cloud
After authenticating,
uvx mcp-agent cloud auth whoami confirms the active account (use uv run mcp-agent … if you prefer to stay inside your project environment). Run uvx mcp-agent cloud auth logout to clear stored credentials.
Initialise a project (mcp-agent init)
Recent CLI changes fold the old quickstart command into mcp-agent init. You can now scaffold config files or copy full examples from one entry point.
Scaffolding templates
Quickstart examples (
--quickstart <name>)
Examples:
Deploy an application (mcp-agent deploy)
Use
--dry-run for validation without uploading, and let the CLI guide you through classifying developer versus user secrets.
When deployment completes you will see two new artefacts next to your source:
mcp_agent.deployed.secrets.yaml– transformed secrets file containing opaque handles plus anenvsection.mcp_agent.deployed.config.yaml– the configuration snapshot that the control plane consumes (safe to commit).
env list to mcp_agent.config.yaml whenever you want to capture environment variables as deployment secrets:
os.environ first, then the optional fallback literal. Each value is stored as a secret handle under env: in mcp_agent.deployed.secrets.yaml.
List deployed servers (mcp-agent cloud servers list)
cloud servers describe <SERVER_ID> and cloud servers workflows <SERVER_ID> share the same formatting flag and surface deep metadata such as server URLs, current status, and published workflows.
Install a deployed MCP server (mcp-agent install)
For authenticated clients, the CLI injects
MCP_API_KEY automatically. Use --dry-run when sharing configuration snippets or validating changes before committing them.
Tail logs for a running application (mcp-agent cloud logger tail)
Use streaming (
--follow) when you need real-time visibility; combine --since with --grep to audit historical runs.
Configure a deployed server (mcp-agent cloud configure)
This workflow lets you adopt a published server template, supply your credentials (LLM keys, database passwords, etc.), and produce a new server deployment associated with your account.
Cloud management commands
-
Apps (
mcp-agent cloud apps …) – manage logical applications.apps status <APP_ID>displays health, version, and associated servers.apps workflows <APP_ID>enumerates workflows exposed by that app.apps delete <APP_ID>removes the application;apps updaterefreshes metadata.
-
Logs (
mcp-agent cloud logger tail …) – fetch or stream logs.--since 1h,--grep,--limit/-n, and--order-by timestamp|severitytune batch retrieval.--follow/-fenables streaming (mutually exclusive with the filtering flags).--format text|json|yamlcontrols output.
-
Configure (
mcp-agent cloud configure --id <SERVER_URL> …) – collect user secrets after deployment.--secrets-file/-sreuses an authored secrets.yaml.--secrets-output-file/-ochooses where prompted secrets are written (defaults tomcp_agent.configured.secrets.yaml).--paramslists required secrets and exits.--dry-runvalidates using mock clients without persisting anything.
-
Env (
mcp-agent cloud env …) – manage environment secrets captured during deploy.env list [APP]displays stored environment keys with masked handles.env add <KEY> <VALUE> [APP](or--from-env-file .env.local) creates or updates secret values (apps/<app_id>/env/<KEY>).env remove <KEY> [APP]deletes the stored handle.env pull [APP] --format env|yaml --output <FILE>downloads resolved values as either a dotenv file (default.env.mcp-cloud) or a YAML file..envis loaded first (developer overrides), followed by.env.mcp-cloud, before config-driven fallbacks are applied.--app/-a,--api-url,--api-keyallow per-command overrides (use--appwhen omitting positional arguments or when using--from-env-file).
-
Auth (
mcp-agent cloud auth …) – the same login, whoami, and logout commands exposed at the top level, handy for scripts. -
Workflows (
mcp-agent cloud workflows …) – inspect and control durable workflow runs.workflows list <SERVER|URL> [--format text|json|yaml]lists workflow definitions.workflows runs <SERVER|URL>surfaces recent executions.workflows describe|status <SERVER> <RUN_ID>shows execution details.workflows resume|suspend|cancel <SERVER> <RUN_ID>manipulates in-flight runs.
Local development helpers
mcp-agent dev start– run your app locally with optional file watching (auto-detectsmain.py, thenagent.pywhen--scriptis omitted). Companion subcommands includedev chat,dev go,dev invoke,dev serve,dev logs,dev keys, anddev models.mcp-agent config show|check|edit|builder– inspect YAML, validate schemas, or generate config files with an interactive questionnaire (buildersupports templates and expert mode).mcp-agent doctor– end-to-end diagnostics across configuration, secrets, provider keys, required MCP servers, and network connectivity.mcp-agent install --dry-run– even for local experiments, emit ready-to-paste client snippets without touching disk.
MCP_APP_SETTINGS_PRELOAD), explicit paths, discovered mcp_agent.config.yaml/mcp_agent.secrets.yaml, and environment variables. Append --help whenever you need the latest options or examples.