Last updated: August 27, 2026
Claude Code can be connected to the Logicc API using the Anthropic-compatible endpoint. The interface runs in the terminal. Only enabled Claude models are recommended for this integration.
Beta: Claude Code is updated regularly. New client features may place additional demands on the gateway. Check the version used and the intended workflow before production use.
Quick start
- Install Claude Code.
- Set the Logicc API key and base URL as environment variables.
- Start Claude Code with an unlocked Claude model.
- Check connection with
/statusand model with/model. - Check quota after the first test request.
Requirements
- Active Logicc API key
- Unlocked Claude model
- Current Claude Code version
- Terminal on macOS, Linux, Windows or WSL
1. Install Claude Code
macOS, Linux or WSL:
curl -fsSL https://claude.ai/install.sh | bash
Alternatively on macOS:
brew install --cask claude-code
Check installation:
claude --version
2. Configure the Logicc API
macOS, Linux or WSL
export LOGICC_API_KEY="YOUR_LOGICC_API_KEY"
export ANTHROPIC_AUTH_TOKEN="$LOGICC_API_KEY"
export ANTHROPIC_BASE_URL="https://api.logicc.cloud/anthropic"
export CLAUDE_CODE_ENABLE_GATEWAY_MODEL_DISCOVERY="1"
Windows PowerShell
$env:LOGICC_API_KEY = "YOUR_LOGICC_API_KEY"
$env:ANTHROPIC_AUTH_TOKEN = $env:LOGICC_API_KEY
$env:ANTHROPIC_BASE_URL = "https://api.logicc.cloud/anthropic"
$env:CLAUDE_CODE_ENABLE_GATEWAY_MODEL_DISCOVERY = "1"
ANTHROPIC_AUTH_TOKEN is sent to the Logicc gateway as a bearer token. The base URL replaces the direct Anthropic endpoint for this session.
3. Check models and quota
curl "https://api.logicc.cloud/v1/models" \
-H "Authorization: Bearer $LOGICC_API_KEY"
Only use model IDs returned by this endpoint.
4. Start Claude Code
cd /path/to/project
claude --model claude-sonnet-5
Windows PowerShell:
Set-Location "C:\Path\To\Project"
claude --model claude-sonnet-5
Check connection and model:
/status
/model
When gateway detection is enabled, additional gateway models appear under /model with the note From gateway.
5. Permanent settings
Non-secret settings can be stored in ~/.claude/settings.json:
{
"model": "claude-sonnet-5",
"env": {
"ANTHROPIC_BASE_URL": "https://api.logicc.cloud/anthropic",
"CLAUDE_CODE_ENABLE_GATEWAY_MODEL_DISCOVERY": "1"
}
}
On Windows the path is %USERPROFILE%\.claude\settings.json.
Do not store the API key in a project-specific .claude/settings.json, Git, or shared scripts. For long-term use, use a Secret Manager or Credential Helper.
Model choice
Recommended models
| Model | Model ID | Recommendation | Cost profile |
|---|---|---|---|
| Claude Sonnet 5 | claude-sonnet-5 |
Standard for most coding tasks | Medium |
| Claude Haiku 4.5 | claude-haiku-4-5 |
Quick routine tasks | Lower |
| Claude Opus 5 | claude-opus-5 |
Complex planning and demanding tasks | High |
Other documented IDs
claude-opus-4-8, claude-opus-4-6, claude-sonnet-4@20250514, claude-3-7-sonnet@20250219, claude-3-5-sonnet-v2@20241022 and claude-haiku-4-5@20251001.
Newer models may require a current Claude Code version. If there are missing entries, run claude update.
Compatibility
| Model type | Status | Notice |
|---|---|---|
| Enabled Claude models | Recommended | Native Anthropic Messages compatibility |
| Non-Claude models | Not officially supported | Tool calling, reasoning, prompt caching and model switching may fail |
For GPT models, use Codex or OpenCode.
Costs and quota
Agentic coding sessions can automatically execute many model and tool steps. Check the remaining budget regularly:
curl "https://api.logicc.cloud/api/governance/virtual-keys/quota" \
-H "Authorization: Bearer $LOGICC_API_KEY"
Budget, usage, and remaining budget are tracked in euros.
Data protection
Claude Code works locally with shared project files and terminal tools. Model processing does not take place locally. Prompts and selected file or code snippets are transferred to the established model provider via the Logicc API. Web search, MCP servers and plugins can create additional data flows.
Troubleshooting
| Error | Resolution |
|---|---|
401 |
Check ANTHROPIC_AUTH_TOKEN |
403 |
Check model availability and API key status |
404 |
Set ANTHROPIC_BASE_URL exactly to https://api.logicc.cloud/anthropic |
429 |
Check quota and rate limit |
| Model is missing | Check /v1/models, run claude update and restart session |
| Direct Anthropic access active | Start Claude Code from the same terminal where the variables are set, then check /status |
| GPT tool calls fail | Switch to a Claude model, Codex, or OpenCode |
Support
If you have any questions, write to [email protected] with the subject API. Include the Claude Code version, operating system, model ID, HTTP status, timestamp, and complete error message. Do not include the API key.
Further documentation:
- Logicc Help Center: https://help.logicc.com/docs
- Gateway connection: https://code.claude.com/docs/en/llm-gateway-connect
- Model configuration: https://code.claude.com/docs/en/model-config
