@kitionstage/cli
v0.1.1-stage.20
Published
Kition's command line from npm: `npm install -g @kition/cli` gives the `kition` command, and `npx -y @kition/cli mcp --workspace <folder>` serves the kits' tools to any agent over MCP. It downloads each published kit on first use.
Maintainers
Readme
@kition/cli
Kition's command line, from npm. kition holds no kit: it downloads each published kit the first
time you or your agent need it, into ~/.kition/kits, and serves the kits' tools to any agent
over MCP (Claude Code, Claude Desktop, Cursor, Codex, or your own MCP client). No Kition app has
to run, nothing is compiled on your machine, and no license key is needed.
npm install -g @kition/cli
kition --version
kition kit install note
kition agent add claude # in your project folder: Claude Code runs `kition mcp` thereor, without installing:
npx -y @kition/cli kit list
npx -y @kition/cli mcp --workspace <folder>Node.js 20 or later, on macOS (arm64, x64), Linux with glibc (arm64, x64) or Windows (x64). The
same kition, without Node.js: this package carries an install script (dist/install.sh,
dist/install.ps1 on Windows) that downloads @kition/cli-<platform> from the npm registry
(registry.npmjs.org, else registry.npmmirror.com, or KITION_NPM_REGISTRY) with curl and tar,
checks its integrity, and installs ~/.kition/bin/kition:
curl -fsSL https://unpkg.com/@kition/cli/dist/install.sh | shEvery command (kit, agent, mcp, serve, doctor) is in
docs/sdk/cli.md.
Connect your agent
kition agent add claude (or codex, cursor) registers kition mcp with the agent and prints
what it ran or wrote. Installed with npm install -g @kition/cli, it registers npm's kition command;
run through npx -y @kition/cli agent add ..., it registers npx -y @kition/cli mcp, so the agent can
start it again after npm clears its cache. By hand:
claude mcp add kition -- npx -y @kition/cli mcp --workspace "$PWD"Claude Desktop, Cursor, and any client with an mcpServers file (claude_desktop_config.json,
.cursor/mcp.json, .mcp.json, ...). Use an absolute path where the client does not start
servers in your project folder (Claude Desktop); Cursor fills in ${workspaceFolder}:
{
"mcpServers": {
"kition": {
"command": "npx",
"args": ["-y", "@kition/cli", "mcp", "--workspace", "/absolute/path/to/folder"]
}
}
}Codex: ~/.codex/config.toml:
[mcp_servers.kition]
command = "npx"
args = ["-y", "@kition/cli", "mcp", "--workspace", "/absolute/path/to/folder"]With kition installed globally, put kition as the command and drop -y and @kition/cli
from the arguments. On Windows, an agent starts npx (a batch file) as cmd /c npx -y @kition/cli mcp ....
The server's tools, the workspace and its sandbox, drafts and kits installed on first use are in docs/sdk/agent.md and docs/sdk/cli.md.
How the kition command finds kition
The kition command here is a small Node launcher. It starts the kition executable for this
platform with your arguments and your standard input, output and error, and exits with its exit
code or signal; a client's SIGTERM or SIGINT is passed on, and when the client closes standard
input, kition mcp ends by itself. The launcher itself never writes to standard output. It runs:
KITION_BINARY, an executable you name, for example a development build. If the variable names a missing file, the launcher stops with an error.- Otherwise the
bin/kitionof the optional package@kition/cli-<platform>, which npm installs with this one ondarwin-arm64,darwin-x64,linux-arm64(glibc),linux-x64(glibc) andwin32-x64. It holdskitionand nothing else.
It never looks on the PATH, where npm install -g puts this launcher itself. If there is no
kition for this platform, the launcher says why on standard error: the platform is not one of
those, Linux runs musl (Alpine), or npm left the optional package out (--omit=optional,
--no-optional); and it names install.sh (install.ps1 on Windows) as the way without npm.
The launcher tells kition how it was started in KITION_LAUNCHER, a JSON object with via
(npx or npm), command (the words that start this kition again) and executable (the
kition it started), which kition agent add registers and kition doctor checks on the PATH.
Programs that start kition themselves can use the same lookup:
import { launchedAs, resolveKition, thisMachine } from '@kition/cli'
// resolveKition(thisMachine(file)) -> { ok, command } or { ok: false, message }Part of the Kition SDK
@kition/cli is a package of the Kition SDK (its source), which lets you put Kition's editors in your product, and give the same files to your AI agent. Guides and reference: developer.kition.ai.
The Kition family
Kition is the open pro suite for AI: 16 kits, editors that people and AI agents use on the same files, and the products around them (all repositories).
| Product | What it is | Links |
| --- | --- | --- |
| Kition Desktop | The open pro suite for AI: 16 editors and an agent in one desktop app | GitHub · kition.ai |
| Kition Showcase | Sample files for every kit | GitHub · kition.ai/showcase |
| Kition SDK | Put Kition's editors in your product, and give the same files to your AI agent | GitHub · developer.kition.ai |
| kition command line | Install kits on demand and run them for your agent: npx @kition/cli | developer.kition.ai · Guide |
| Kition One | A self-hosted team workspace built on Kition's kits, with real-time co-editing | one.kition.ai |
| Kit Harness Protocol (KHP) | The open protocol between a kit and its host | GitHub · kitharness.org |
| Kition Tessera | The design system for kits | GitHub · tessera.kition.ai |
| Kition Universe | A 3D map of the kits and what they make | GitHub · universe.kition.ai |
| Kition Fonts | The open fonts the editors use | GitHub |
| Product line | Kits | | --- | --- | | Office | Note · Table · Board · Doc · Sheet · Slide · PDF · HTML | | Design | Photo · Vector · Layout · Design | | Media | Film · Motion | | Engineering | CAD · Scene |
License
Apache-2.0 (LICENSE).
