Claude Code is Anthropic's terminal CLI. On Guard it works with a gd-… key: no Claude Pro and no OAuth at anthropic.com.
npm i -g @anthropic-ai/claude-code(Node.js required).- Set the variables:
- Run regular
claude. - On first launch, approve the API key with Yes / Approve.
$env:ANTHROPIC_BASE_URL = "https://api.guardrelay.ai"
$env:ANTHROPIC_AUTH_TOKEN = "gd-your-key-from-bot"
claudeTo avoid typing it every time — save a start-claude-guard.ps1 and run it.
export ANTHROPIC_BASE_URL="https://api.guardrelay.ai"
export ANTHROPIC_AUTH_TOKEN="gd-your-key-from-bot"
claude$env:ANTHROPIC_BASE_URL = "https://api.guardrelay.ai"
$env:ANTHROPIC_AUTH_TOKEN = "gd-your-key-from-bot"
claudeClaude Code calls /v1/messages and sends its own toolset in the tools field. All three families serve that surface and accept that field.
| Family | Claude Code | Why |
|---|---|---|
| Kimi | works | both the /v1/messages surface and the tools field are accepted; Claude Code runs the tools itself. The model is named by its exact Kimi id at launch |
| Composer, Grok | works | both the /v1/messages surface and the tools field are accepted; Claude Code runs the tools itself. Typed Anthropic tools (computer use, text editor, web search) are unavailable — Cursor exposes no such contract |
Kimi runs in Claude Code itself, and equally in clients that speak plain Chat Completions: Cline, Roo Code, n8n, Python SDK, Node SDK. In Cline, kimi-for-coding and kimi-for-coding-highspeed may return 403 kimi_agent_not_allowed: use a supported client such as Roo Code or Kilo Code. Do not remove or impersonate the agent name in the system prompt to bypass this restriction.
It is the same CLI, installed and configured the same way: npm i -g @anthropic-ai/claude-code, then the Guard address and the key in environment variables. Only the model differs: name it by its exact id at launch. Mac / Linux:
export ANTHROPIC_BASE_URL="https://api.guardrelay.ai"
export ANTHROPIC_AUTH_TOKEN="gd-your-key-from-bot"
claude --model k3$env:ANTHROPIC_BASE_URL = "https://api.guardrelay.ai"
$env:ANTHROPIC_AUTH_TOKEN = "gd-your-key-from-bot"
claude --model k3Windows PowerShell:
$env:ANTHROPIC_BASE_URL = "https://api.guardrelay.ai"
$env:ANTHROPIC_AUTH_TOKEN = "gd-your-key-from-bot"
claude --model k3If an editor agent or your own code suits you better, the gd-… key works there as well. You can check it right in the terminal:
curl -X POST https://api.guardrelay.ai/v1/chat/completions \
-H "Authorization: Bearer gd-your-key-from-bot" \
-H "Content-Type: application/json" \
-d '{
"model": "k3",
"messages": [{"role": "user", "content": "Hello!"}],
"max_tokens": 128
}'For work inside an editor, take an agent that speaks plain Chat Completions: Cline or Roo Code. In their settings pick a provider with an OpenAI-compatible API and fill the fields like this: In Cline, kimi-for-coding and kimi-for-coding-highspeed may return 403 kimi_agent_not_allowed: use a supported client such as Roo Code or Kilo Code. Do not remove or impersonate the agent name in the system prompt to bypass this restriction.
| Field in the agent settings | Value |
|---|---|
| API Provider | OpenAI-compatible |
| Base URL | https://api.guardrelay.ai/v1 |
| API Key | gd-… from the bot |
| Model | k3, k3-256k, kimi-for-coding or kimi-for-coding-highspeed |
The same CLI is installed and configured the same way: npm i -g @anthropic-ai/claude-code, then the Guard address and the key in environment variables. Only the model differs: you pass its exact id at launch.
export ANTHROPIC_BASE_URL="https://api.guardrelay.ai"
export ANTHROPIC_AUTH_TOKEN="gd-your-key-from-bot"
claude --model cursor-grok-4.6-medium$env:ANTHROPIC_BASE_URL = "https://api.guardrelay.ai"
$env:ANTHROPIC_AUTH_TOKEN = "gd-your-key-from-bot"
claude --model cursor-grok-4.6-mediumWindows PowerShell:
$env:ANTHROPIC_BASE_URL = "https://api.guardrelay.ai"
$env:ANTHROPIC_AUTH_TOKEN = "gd-your-key-from-bot"
claude --model cursor-grok-4.6-mediumThe same CLI is installed and configured the same way: npm i -g @anthropic-ai/claude-code, then the Guard address and the key in environment variables. Only the model differs: you pass its exact id at launch.
export ANTHROPIC_BASE_URL="https://api.guardrelay.ai"
export ANTHROPIC_AUTH_TOKEN="gd-your-key-from-bot"
claude --model composer-2.5$env:ANTHROPIC_BASE_URL = "https://api.guardrelay.ai"
$env:ANTHROPIC_AUTH_TOKEN = "gd-your-key-from-bot"
claude --model composer-2.5Windows PowerShell:
$env:ANTHROPIC_BASE_URL = "https://api.guardrelay.ai"
$env:ANTHROPIC_AUTH_TOKEN = "gd-your-key-from-bot"
claude --model composer-2.5