Skip to content
DOCS / Claude Code

Claude Code

Route Claude Code through Inference.net's Anthropic-compatible endpoint.

fast claude on points Claude Code at Inference.net's Anthropic-compatible /v1/messages endpoint by editing ~/.claude/settings.json.

Connect Claude Code

  1. Install

    bash
    npm install -g @inference/fast
  2. Activate

    bash
    fast claude on

    The first run signs you in through the browser and creates an API key for this machine. The command backs up Claude Code's config before editing it.

  3. Restart Claude Code

    Restart Claude Code and send a prompt; the request appears under Usage.

Choose a model

Claude Code has a model slot for each agent type. main, opus, sonnet, and fable default to kimi-k3-fast; haiku and subagents default to deepseek-v4-flash-0731. Set every slot to the same model with --model, or set slots individually with the per-slot flags. Any model catalog ID works.

bash
# Set the model for every slot
fast claude on --model kimi-k3-fast

# Set the model per slot
fast claude on \
  --main kimi-k3-fast \
  --opus kimi-k3-fast \
  --sonnet kimi-k3-fast \
  --haiku deepseek-v4-flash-0731 \
  --fable kimi-k3-fast \
  --subagents deepseek-v4-flash-0731

Run on again to change the defaults. Restart Claude Code afterward.

Switch models in Claude Code

Every model from the model catalog is in Claude Code's /model picker; the built-in Anthropic entries are hidden because they all route through the slots above. Pick one and press Enter to make it the default for new sessions, or s to use it for the current session only.

Check status

bash
fast claude status

Shows the connection, model, and config paths.

Disconnect

bash
fast claude off

Restores settings.json to the backup taken by on, so edits made after connecting are lost. Restart Claude Code afterward.

Troubleshooting

  • fast claude status says off — run fast claude on and restart Claude Code.
  • Requests return 401 — run fast status, then fast claude on.
  • Model rejected — pick an ID from the model catalog.