@ekanos packages — from any Node project, with no bundler and no dependency on @ekanos/sdk at runtime.
Install
validate/dev/test automatically delegate to that project’s own pinned @ekanos/cli devDependency whenever it differs from the globally invoked binary — the same wrapper pattern as Gradle’s ./gradlew or npx. A partner with several integrations on different @ekanos/sdk versions gets the right toolchain per project without juggling installs.
Machine-level verbs (init, login, logout, whoami, sources, use, status, upgrade) and publish, which sends your session token to the host, never delegate — they always run on the binary you invoked. Set EKANOS_NO_DELEGATE=1 to opt out for one invocation.
Verbs at a glance
Global flags
Short flags are not supported — the parser rejects them rather than guessing.
JSON-first design
Every verb speaks JSON. JSON mode is inferred from:- Non-TTY stdout (piped output)
CLAUDECODE=1environment variable
--json or --no-json overrides that inference.
On --help, an unknown command and an out-of-date toolchain, the CLI also writes one short claude-code-hint: {…} line to stderr: the command list, the suggested fix, or that command’s usage. It appears only with --json or when a coding agent is detected (CLAUDECODE=1, CODEX_SANDBOX, CURSOR_AGENT=1, GEMINI_CLI=1, AI_AGENT). At a terminal you see the readable error alone. A mistyped command suggests the closest one, and a whole command passed as one quoted argument (ekanos "teams list") is answered with ekanos teams list.
In JSON mode, stdout carries exactly one JSON object:
error key. An error envelope carries error, plus data only when the verb has something to report (for example validate’s findings). Every progress line goes to stderr. Errors always carry an imperative hint telling you what to do:
publish asks for a y/N confirm at a real terminal when the publish target is ambiguous (implicit source + multiple developer seats). Every other verb, and publish itself in JSON/non-TTY mode or with an explicit --source, never prompts.
Toolchain updates
Three independent defenses against a stale toolchain:-
Schema-skew gate —
validateandpublishfail fast withprecondition_failed(exit 9) if the project resolves a newer@ekanos/integration-schemathan the CLI bundles. -
ekanos upgrade— Resolves a coherent version set, installs, verifies withvalidate+ the test script, and rolls back automatically on failure. -
Update notice — every command except
init,login,logout, andupgradechecks in the background (at most every 4 hours, 1.5s timeout) whether a newer CLI exists, and says so once on stderr after the command.validate,dev,publish, andstatusalso carrydata.toolchainin the JSON envelope. SetEKANOS_NO_UPDATE_CHECK=1to disable it.
What’s next
- Commands — Detailed reference for each verb
- ekanos.json — Configuration reference
- Authentication — Auth flow and credential storage
- Publishing — Publish target verification
- Exit codes — Exit code taxonomy