Skip to main content
Point Claude Code at the Modellix LLM gateway using the Anthropic-compatible Messages API. Auth and base URL match the Anthropic SDK pattern.

Configure with environment variables

Do not append /v1 to ANTHROPIC_BASE_URL. Claude Code / the Anthropic SDK append /v1/messages themselves.
If the tool expects Bearer auth, use ANTHROPIC_AUTH_TOKEN instead of ANTHROPIC_API_KEY. Do not set both to different values.

Persist in settings

You can write the same values to ~/.claude/settings.json:
Replace mdlx-xxxxxxxx with a key from the Modellix console.

Session headers

Claude Code may send its own session header (for example X-Claude-Code-Session-Id). Modellix also accepts X-Mdlx-Session-Id; if both are present, X-Mdlx-Session-Id wins. See Session header.