Metadata-Version: 2.5
Name: zen-cli
Version: 0.1.4
Summary: Command-line toolbox for Zen Cloud PC. Operate orgs, pools, VMs, and tasks; call ZDS APIs; expose a stdio MCP server.
Project-URL: Homepage, https://pypi.org/project/zen-cli/
Author: zen-cli authors
License-Expression: MIT
License-File: LICENSE
Requires-Python: >=3.12
Requires-Dist: authlib
Requires-Dist: click>=8.1
Requires-Dist: coloredlogs
Requires-Dist: httpx2
Requires-Dist: mcp>=2
Requires-Dist: portalocker[win32]
Requires-Dist: pydantic
Requires-Dist: pyjwt
Requires-Dist: python-dotenv
Requires-Dist: pyyaml
Requires-Dist: questionary
Requires-Dist: tabulate
Requires-Dist: yumako
Provides-Extra: dev
Requires-Dist: build; extra == 'dev'
Requires-Dist: mypy; extra == 'dev'
Requires-Dist: pre-commit; extra == 'dev'
Requires-Dist: ruff; extra == 'dev'
Provides-Extra: release
Requires-Dist: build; extra == 'release'
Requires-Dist: twine; extra == 'release'
Description-Content-Type: text/markdown

# zen-cli

[![PyPI](https://img.shields.io/pypi/v/zen-cli?logo=pypi&logoColor=white)](https://pypi.org/project/zen-cli/) [![Python](https://img.shields.io/badge/python-3.12%2B-3776AB?logo=python&logoColor=white)](https://www.python.org/downloads/) [![License: MIT](https://img.shields.io/badge/license-MIT-green)](LICENSE) [![PyPI downloads](https://img.shields.io/pypi/dm/zen-cli)](https://pypi.org/project/zen-cli/) [![Wheel](https://img.shields.io/pypi/wheel/zen-cli)](https://pypi.org/project/zen-cli/) [![OS](https://img.shields.io/badge/OS-macOS%20%7C%20Linux%20%7C%20Windows-informational)](https://pypi.org/project/zen-cli/) [![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff) [![Checked with mypy](https://img.shields.io/badge/mypy-checked-2A6DB2)](https://mypy-lang.org/) [![Click](https://img.shields.io/badge/cli-Click%208-4584b6)](https://click.palletsprojects.com/) [![Hatch](https://img.shields.io/badge/%F0%9F%A5%9A-Hatch-4051b5)](https://github.com/pypa/hatch)

Command-line toolbox for Zen Cloud PC, designed for AI and human.

## Contents

- [Try it out](#try-it-out)
  - [Prerequisites](#prerequisites)
  - [Installation](#installation)
    - [Mac & Linux](#mac--linux)
    - [Windows](#windows)
  - [Use the CLI](#use-the-cli)
- [Documentation](#documentation)
- [License](#license)

## Try it out

### Prerequisites

* Python 3.12 or newer
* Pip

### Installation

#### Mac & Linux

```text
pip install zen-cli
```

#### Windows

```text
pip install zen-cli
```

If Python was installed without “Add python to PATH”, add Python and its `Scripts` directory to PATH.

### Use the CLI

```text
zen login
zen auth status
zen auth details
zen auth token
```

`zen login` reuses a valid cached token or configured credentials (API token, client id/secret). If neither is available it starts device-code login. It does not print the access token. Machine login is `zen login --client-id` / `--client-secret`. `zen auth status` is JSON (`logged_in`, `method`, `ttl`). `zen auth details` is the JWT and org. `zen auth token` is the bearer (`--service` on details/token). `zen auth refresh` refreshes the cached token.

Run a command, for example, list pools:

```text
zen pool list
```

## Documentation

* [User guide](docs/user-guide.md) — profiles, flags, payloads, and command conventions
* [Cheatsheet](docs/cheatsheet.md) — command examples
* [Developer guide](docs/dev.md) — build, test, and package layout

## License

Licensed under the MIT License. See [LICENSE](LICENSE).
