@hiway2llm/cli
v0.1.1
Published
HiWay2LLM CLI — one API, every model, save 40-60%. Sign up, mint keys, chat from your terminal.
Maintainers
Readme
@hiway2llm/cli
HiWay2LLM CLI — smart LLM routing with BYOK, from your terminal.
Save 40–60 % on your LLM bill by routing every request to the cheapest capable model. You keep your own Anthropic / OpenAI / Google / Mistral / DeepSeek keys — HiWay never marks up inference.
Install
npm install -g @hiway2llm/cliCross-platform (Windows, macOS, Linux). Requires Node.js 18.17 or newer. No binary download, no SmartScreen prompt.
Quick start
# 1. Sign up (30 seconds, no credit card)
hw signup
# 2. Mint an API key (after email verification)
hw keys create "laptop"
# 3. First routed request
hw chat "Explain the pigeonhole principle in 3 bullets"The first key you mint is cached as the default for hw chat. You can override it in ~/.hiway/config.json.
Commands
| Command | What it does |
|---------------------------------|-------------------------------------------------------|
| hw signup | Create an account (interactive) |
| hw login | Sign in to an existing account |
| hw logout | Wipe local credentials |
| hw whoami | Show current user + plan |
| hw keys list | List your HiWay API keys |
| hw keys create <name> | Mint a new hw_live_… key |
| hw keys revoke <id> | Revoke a key |
| hw providers list | List your BYOK provider keys and their status |
| hw chat "<prompt>" | Single-turn chat via smart routing (model=auto) |
| hw chat -m <model> "<prompt>" | Force a specific model (e.g. openai/gpt-4o) |
| hw chat --json "<prompt>" | Print the raw API response |
Config
~/.hiway/config.json # chmod 600 — holds session token + api_key
HIWAY_API_URL # override the API base (default: https://app.hiway2llm.com)See also
- Python SDK —
pip install hiway2llm - TypeScript SDK —
npm install @hiway2llm/client - OpenAI-compatible API — point any OpenAI SDK at
https://app.hiway2llm.com/v1with yourhw_live_…key - Dashboard — app.hiway2llm.com — BYOK vault, Guardian anti-loop, Budget Control, A/B experiments, semantic cache, PII masking
License
MIT — © Mytm-Group SAS
