CLI overview
Install wtree-cloud-cli and learn the command shape, JSON output and help.
wtree-cloud-cli manages a running wtree Cloud server from your terminal. Commands are generated from the OpenAPI spec, one per endpoint, and call the API through the SDK.
To install wtree Cloud on a server, use the installer instead.
Install
npm install -g @wtree/cloud-cli
# or
bun add -g @wtree/cloud-cliRequires Node.js 20 or newer, or Bun. Then authenticate.
Command shape
wtree-cloud-cli <group> <action> [options]A group is a resource (one per API router, such as application, compose, postgres, project, server or settings). Options are --name value flags that match the endpoint's fields.
wtree-cloud-cli project all
wtree-cloud-cli project one --projectId abc123
wtree-cloud-cli application create --name "my-app" --environmentId env123
wtree-cloud-cli application deploy --applicationId app123
wtree-cloud-cli postgres stop --postgresId pg123Global options and values
| Option or form | What it does |
|---|---|
--json | Prints the raw JSON response. Piped output is always raw JSON. |
--env-file <path> | Reads W3PANEL_URL and W3PANEL_API_KEY from a file. See Authentication. |
--help | On the root, lists groups; on a group, lists actions; on an action, lists options. |
| List of strings | Comma-separated or a JSON array. |
| Object, other array, or several types | JSON. The command's help shows the expected shape. |
wtree-cloud-cli application save-github-provider --applicationId app123 ... --watchPaths "src/**,package.json"
wtree-cloud-cli admin setup-monitoring --metricsConfig '{"server": {"refreshRate": 20, ...}, "containers": {...}}'
wtree-cloud-cli project all --json
wtree-cloud-cli --help
wtree-cloud-cli application --help
wtree-cloud-cli application deploy --helpCommand groups
| Page | Groups |
|---|---|
| Project | project |
| Environment | environment |
| Application | application |
| Databases | postgres, mysql, mariadb, mongo, redis |
Other groups are available through wtree-cloud-cli --help.
Commands match the API of the version the CLI was built from. Use a CLI version that matches your server.
