@bytesbrains/claude-code-cruise
v0.1.17
Published
BytesBrains Cruise for Claude Code: your key's models, budget and spend over MCP, a skill for lanes and refusals, a spend status line, and guided setup. The package root is the plugin root, for a marketplace's npm source.
Maintainers
Readme
BytesBrains Cruise for Claude Code
BytesBrains Cruise is one endpoint in front of every model provider, with per-project keys, budgets that stop a runaway loop, and a ledger of every request. This package is the Cruise plugin for Claude Code. Its root is the plugin root.
Install
Most people install from the marketplace, which needs nothing from npm:
/plugin marketplace add bytesbrains/cruise-claude-plugin
/plugin install cruise@bytesbrainsThis package is for your own marketplace, for example an internal one that pins versions or serves plugins from a private registry mirror. Point an entry at it:
{
"name": "cruise",
"source": { "source": "npm", "package": "@bytesbrains/claude-code-cruise", "version": "^0.1.17" }
}Then put a Cruise key in your environment, restart Claude Code and run /cruise:setup (or /cruise:connect):
export CRUISE_API_KEY=cru_live_…Standalone CLI Bootstrapper & Launcher
When a Claude subscription is expired or quota is exhausted, Claude Code fails before it can execute any slash command. To bootstrap offline or run on-demand:
# Run Claude on-demand through Cruise without modifying global settings
npx @bytesbrains/claude-code-cruise@latest run [args...]
# or binary alias:
claude-cruise [args...]
# Enable Cruise gateway routing & status line globally
npx @bytesbrains/claude-code-cruise@latest enable
# Or configure Cruise for the current project only (./.claude/settings.json)
npx @bytesbrains/claude-code-cruise@latest enable --local
# Switch active model or lane (globally or with --local)
npx @bytesbrains/claude-code-cruise@latest switch bb/agentic-coding
# Safely revert to standard Anthropic routing
npx @bytesbrains/claude-code-cruise@latest disableTo keep your Anthropic subscription as the default, leave ~/.claude/settings.json alone: run
claude for the subscription and claude-cruise for a session routed through Cruise. Use
enable --local for repositories that should always use Cruise. /cruise:disconnect runs
locally through a plugin hook, so a failing model or a missing key cannot block it; with hooks
turned off, disable does the same from any terminal with no model and no key.
What is inside
- CLI
claude-code-cruise/claude-cruise: standalone bootstrapper and on-demand launcher (claude-cruise,run,enable,disable,switch) for zero-dependency execution and project-level (--local) scope. - MCP server
cruise: three read-only tools,list_models,get_budgetandget_spend, about your key's own project. - Command
/cruise:connect: route Claude Code through Cruise and install the status line in 1 step (including gateway session affinity and traffic class tagging). - Command
/cruise:disconnect: disconnect from Cruise and revert to standard Anthropic routing, locally through aUserPromptExpansionhook, with no model, network or key. - Command
/cruise:models: list reachable models and lanes with pricing and active selection. - Command
/cruise:status: inspect current project budget limits, wallet balance, and serve/refuse status (/cruise:budget). - Command
/cruise:spend: view monthly ledger spend breakdown by lane and by model (/cruise:spend [month]). - Command
/cruise:switch: switch Claude Code's active model or lane in~/.claude/settings.json. It refuses a lane or provider model while Cruise routing is off. - Session start check: a
SessionStarthook that warns, without calling a model, when a model setting names a lane or provider model but no gateway is configured, and says where it is set. - Command
/cruise:update: update the Cruise plugin to the latest release and refresh the status line script. - Skill
cruise: choosing a lane or a pinned model, and what each Cruise refusal means. - Skill
/cruise:setup: guided setup. It runs only when you invoke it, and asks before it changes any file. - Status line: your project's spend this budget period, cached for a minute.
The full guide is in the repository.
Licence
Apache-2.0; see LICENSE.txt and NOTICE. The licence covers this plugin's code only. The Cruise
service is governed by the terms of service of BytesBrains Pte. Ltd., and the BytesBrains and
Cruise names and marks are not licensed.
