<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Alex</title>
    <description>The latest articles on DEV Community by Alex (@alex_uberllm).</description>
    <link>https://dev.to/alex_uberllm</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4253280%2Fbc9d6784-76cc-4c8d-8f53-dcb95f67b602.png</url>
      <title>DEV Community: Alex</title>
      <link>https://dev.to/alex_uberllm</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/alex_uberllm"/>
    <language>en</language>
    <item>
      <title>Run Claude Code on DeepSeek, GLM or Kimi: settings, what breaks, and fixes</title>
      <dc:creator>Alex</dc:creator>
      <pubDate>Thu, 19 Nov 2026 07:54:29 +0000</pubDate>
      <link>https://dev.to/alex_uberllm/run-claude-code-on-deepseek-glm-or-kimi-settings-what-breaks-and-fixes-2l0p</link>
      <guid>https://dev.to/alex_uberllm/run-claude-code-on-deepseek-glm-or-kimi-settings-what-breaks-and-fixes-2l0p</guid>
      <description>&lt;p&gt;&lt;em&gt;Disclosure: I'm Alex, the founder of &lt;a href="https://uberllm.dev" rel="noopener noreferrer"&gt;UberLLM&lt;/a&gt;, a marketplace API with an Anthropic-compatible endpoint. The examples use it because it is the one I know. The settings themselves apply to any Anthropic-compatible endpoint, and the last section gives each model maker's own endpoint, which is the most direct route.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Claude Code talks to one API: Anthropic's Messages API. It does not care who answers, as long as the answer has the right shape. So it can run on DeepSeek, GLM or Kimi models. It also breaks in quiet ways when one setting is missing. This post is the settings, what changes on a model that is not Claude, and the errors people have hit with their fixes.&lt;/p&gt;

&lt;h2&gt;
  
  
  1. The address and the key
&lt;/h2&gt;

&lt;p&gt;Claude Code reads two settings to use another endpoint. It adds &lt;code&gt;/v1/messages&lt;/code&gt; to the base URL itself, so the base URL has &lt;strong&gt;no &lt;code&gt;/v1&lt;/code&gt; at the end&lt;/strong&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;ANTHROPIC_BASE_URL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;https://api.uberllm.dev
&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;ANTHROPIC_AUTH_TOKEN&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;ull_your_key
claude
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Run &lt;code&gt;/status&lt;/code&gt; inside Claude Code to see which address it is using.&lt;/p&gt;

&lt;h2&gt;
  
  
  2. Map every model slot
&lt;/h2&gt;

&lt;p&gt;This is the part people get wrong. Claude Code does not use one model. It has slots, and each one asks for a Claude model name unless you say otherwise:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Variable&lt;/th&gt;
&lt;th&gt;What it sets&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;ANTHROPIC_MODEL&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;The model the session starts on&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;ANTHROPIC_DEFAULT_OPUS_MODEL&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;What &lt;code&gt;opus&lt;/code&gt; means&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;ANTHROPIC_DEFAULT_SONNET_MODEL&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;What &lt;code&gt;sonnet&lt;/code&gt; means&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;ANTHROPIC_DEFAULT_HAIKU_MODEL&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;What &lt;code&gt;haiku&lt;/code&gt; means; also used for background work such as titles and summaries&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;CLAUDE_CODE_SUBAGENT_MODEL&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;The model subagents run on&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;A slot left unset keeps asking for a Claude model. On a single-maker endpoint that request fails. On a multi-model endpoint it is served, and you pay Claude prices for it.&lt;/p&gt;

&lt;h2&gt;
  
  
  3. Tell Claude Code the context size
&lt;/h2&gt;

&lt;p&gt;Claude Code knows the context size of Claude models only. For any other model it assumes 200,000 tokens and compacts the conversation before that.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;If the model has a 1M-token context, end the main model id with &lt;code&gt;[1m]&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;For any other size, set &lt;code&gt;CLAUDE_CODE_MAX_CONTEXT_TOKENS&lt;/code&gt; to the real size.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Do not round up. A context set larger than the model has makes requests fail once the conversation outgrows the model.&lt;/p&gt;

&lt;h2&gt;
  
  
  4. One block per model family
&lt;/h2&gt;

&lt;p&gt;Model ids are as they were in our catalog on November 19, 2026. All three models take tool calls, which Claude Code needs.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;DeepSeek&lt;/strong&gt; (DeepSeek V4.1 Flash, 1,048,576 tokens of context):&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;ANTHROPIC_BASE_URL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;https://api.uberllm.dev
&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;ANTHROPIC_AUTH_TOKEN&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;ull_your_key
&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;ANTHROPIC_MODEL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s1"&gt;'deepseek/deepseek-v4.1-flash[1m]'&lt;/span&gt;
&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;ANTHROPIC_DEFAULT_OPUS_MODEL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s1"&gt;'deepseek/deepseek-v4.1-flash'&lt;/span&gt;
&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;ANTHROPIC_DEFAULT_SONNET_MODEL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s1"&gt;'deepseek/deepseek-v4.1-flash'&lt;/span&gt;
&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;ANTHROPIC_DEFAULT_HAIKU_MODEL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s1"&gt;'deepseek/deepseek-v4.1-flash'&lt;/span&gt;
&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;CLAUDE_CODE_SUBAGENT_MODEL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s1"&gt;'deepseek/deepseek-v4.1-flash'&lt;/span&gt;
claude
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;GLM&lt;/strong&gt; (GLM 5.3, 1,000,000 tokens of context):&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;ANTHROPIC_BASE_URL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;https://api.uberllm.dev
&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;ANTHROPIC_AUTH_TOKEN&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;ull_your_key
&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;ANTHROPIC_MODEL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s1"&gt;'z-ai/glm-5.3[1m]'&lt;/span&gt;
&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;ANTHROPIC_DEFAULT_OPUS_MODEL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s1"&gt;'z-ai/glm-5.3'&lt;/span&gt;
&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;ANTHROPIC_DEFAULT_SONNET_MODEL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s1"&gt;'z-ai/glm-5.3'&lt;/span&gt;
&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;ANTHROPIC_DEFAULT_HAIKU_MODEL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s1"&gt;'z-ai/glm-5.3'&lt;/span&gt;
&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;CLAUDE_CODE_SUBAGENT_MODEL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s1"&gt;'z-ai/glm-5.3'&lt;/span&gt;
claude
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Kimi&lt;/strong&gt; (Kimi K3.1 Pro, 1,048,576 tokens of context):&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;ANTHROPIC_BASE_URL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;https://api.uberllm.dev
&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;ANTHROPIC_AUTH_TOKEN&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;ull_your_key
&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;ANTHROPIC_MODEL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s1"&gt;'moonshotai/kimi-k3.1-pro[1m]'&lt;/span&gt;
&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;ANTHROPIC_DEFAULT_OPUS_MODEL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s1"&gt;'moonshotai/kimi-k3.1-pro'&lt;/span&gt;
&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;ANTHROPIC_DEFAULT_SONNET_MODEL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s1"&gt;'moonshotai/kimi-k3.1-pro'&lt;/span&gt;
&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;ANTHROPIC_DEFAULT_HAIKU_MODEL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s1"&gt;'moonshotai/kimi-k3.1-pro'&lt;/span&gt;
&lt;span class="kd"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;CLAUDE_CODE_SUBAGENT_MODEL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s1"&gt;'moonshotai/kimi-k3.1-pro'&lt;/span&gt;
claude
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  5. Keep it in a settings file, with the key out of it
&lt;/h2&gt;

&lt;p&gt;Save the key to a file only you can read:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;mkdir -p ~/.uberllm &lt;span class="o"&gt;&amp;amp;&amp;amp;&lt;/span&gt; chmod 700 ~/.uberllm
&lt;span class="nb"&gt;printf&lt;/span&gt; &lt;span class="s1"&gt;'%s\n'&lt;/span&gt; &lt;span class="s1"&gt;'ull_your_key'&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; ~/.uberllm/key &lt;span class="o"&gt;&amp;amp;&amp;amp;&lt;/span&gt; chmod 600 ~/.uberllm/key
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then put the address, a key helper and the model variables in &lt;code&gt;~/.claude/settings.json&lt;/code&gt; (every project) or &lt;code&gt;&amp;lt;project&amp;gt;/.claude/settings.local.json&lt;/code&gt; (one project; your other projects stay on your Anthropic plan):&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;"apiKeyHelper"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"cat ~/.uberllm/key"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"env"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;"ANTHROPIC_BASE_URL"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"https://api.uberllm.dev"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"ANTHROPIC_MODEL"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"deepseek/deepseek-v4.1-flash[1m]"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"ANTHROPIC_DEFAULT_OPUS_MODEL"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"deepseek/deepseek-v4.1-flash"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"ANTHROPIC_DEFAULT_SONNET_MODEL"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"deepseek/deepseek-v4.1-flash"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"ANTHROPIC_DEFAULT_HAIKU_MODEL"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"deepseek/deepseek-v4.1-flash"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"CLAUDE_CODE_SUBAGENT_MODEL"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"deepseek/deepseek-v4.1-flash"&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Claude Code runs &lt;code&gt;apiKeyHelper&lt;/code&gt; to get the key, so the key is never written into a settings file. Once the file is in place, remove every &lt;code&gt;ANTHROPIC_*&lt;/code&gt; variable from your shell and shell profile: a token exported in the shell replaces the saved key, and &lt;code&gt;ANTHROPIC_MODEL&lt;/code&gt; exported in the shell beats the model setting.&lt;/p&gt;

&lt;h2&gt;
  
  
  6. Check that it works
&lt;/h2&gt;

&lt;p&gt;Start Claude Code and run &lt;code&gt;/status&lt;/code&gt;. Then test the Messages API directly, which is the address Claude Code calls:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl https://api.uberllm.dev/v1/messages \
  -H &lt;span class="s2"&gt;"Authorization: Bearer $(cat ~/.uberllm/key)"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"anthropic-version: 2023-06-01"&lt;/span&gt; \
  -H &lt;span class="s2"&gt;"content-type: application/json"&lt;/span&gt; \
  -d &lt;span class="s1"&gt;'{"model":"deepseek/deepseek-v4.1-flash","max_tokens":16,"messages":[{"role":"user","content":"ping"}]}'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then run a real task in a scratch folder and check that files actually change. Some models are weaker at long tool loops than Claude, and no endpoint fixes that.&lt;/p&gt;

&lt;h2&gt;
  
  
  7. What changes on a model that is not Claude
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Tool calls.&lt;/strong&gt; Claude Code works through tool calls, so it needs a model that takes them. On our endpoint a request with tools sent to a model that cannot call them is refused with &lt;code&gt;400 tools_not_supported&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Thinking blocks.&lt;/strong&gt; Claude Code requires a &lt;code&gt;signature&lt;/code&gt; field on thinking it gets back. Some providers sent DeepSeek's reasoning without it, and a long session could stop. We fixed that on our side on October 28, 2026.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;DeepSeek, thinking and tools.&lt;/strong&gt; DeepSeek's thinking mode wants the reasoning of every earlier turn sent back when tools are used, and answers 400 when it is missing. When a DeepSeek provider refuses a tool call for that reason, we answer the call with thinking off instead of failing it.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Kimi sampling.&lt;/strong&gt; Kimi K3 and Kimi K3.1 Pro run at a fixed temperature and top_p and refuse a request that sets its own.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;The cost Claude Code shows is not your bill.&lt;/strong&gt; It is worked out on your computer from Anthropic's list prices. Look at your provider's usage page.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Your claude.ai login is not used.&lt;/strong&gt; Features that need it, such as claude.ai connectors, &lt;code&gt;/schedule&lt;/code&gt; and Remote Control, are not available.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Your code goes to whoever serves the model.&lt;/strong&gt; See the trade-offs below.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  8. Troubleshooting
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;What you see&lt;/th&gt;
&lt;th&gt;Cause and fix&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;Missing required field in assistant message: 'signature'&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;The endpoint returned thinking without a signature. Fixed on ours since October 28, 2026; on another endpoint, turn thinking off.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;Parameter 'temperature'=0.5 is not supported for kimi-k3 model.&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Kimi runs at a fixed temperature. Since November 18, 2026 we resend such a request without that setting; elsewhere, remove it.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;Your apiKeyHelper script is failing.&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;The key file is missing or unreadable. Save the key again with the two commands in section 5.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Claude Code still asks you to log in, or still uses your Anthropic plan&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;ANTHROPIC_AUTH_TOKEN&lt;/code&gt; or &lt;code&gt;ANTHROPIC_API_KEY&lt;/code&gt; exported in the shell wins over the saved key. Also, Claude Code reads a project's settings only after you trust that folder.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Claude models on your bill&lt;/td&gt;
&lt;td&gt;A model slot was left unset. Set &lt;code&gt;ANTHROPIC_MODEL&lt;/code&gt; and all four slot variables.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Requests fail once the conversation gets long&lt;/td&gt;
&lt;td&gt;The context you told Claude Code is larger than the model has. Use the real size.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;400 context_length_exceeded&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;The prompt is longer than the model takes. The message gives both sizes.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;404 model_not_found&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;The model id is not in the catalog. &lt;code&gt;GET https://api.uberllm.dev/v1/models&lt;/code&gt; lists the ids.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;402 insufficient_credits&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;The prepaid balance cannot cover the request, so it was not sent.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;503 no_available_provider&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Nobody can serve that model right now, even after retries. Retry shortly or pick another model. Nothing was charged.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;429 rate_limited&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;The key went over its request limit per minute. Wait and retry.&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;h2&gt;
  
  
  9. Switch back to Claude
&lt;/h2&gt;

&lt;p&gt;Close the terminal, or clear the variables in it:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="kd"&gt;unset&lt;/span&gt; ANTHROPIC_BASE_URL ANTHROPIC_AUTH_TOKEN ANTHROPIC_MODEL \
  ANTHROPIC_DEFAULT_OPUS_MODEL ANTHROPIC_DEFAULT_SONNET_MODEL \
  ANTHROPIC_DEFAULT_HAIKU_MODEL CLAUDE_CODE_SUBAGENT_MODEL \
  CLAUDE_CODE_MAX_CONTEXT_TOKENS
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;For a settings file, remove &lt;code&gt;apiKeyHelper&lt;/code&gt; and the &lt;code&gt;ANTHROPIC_*&lt;/code&gt; entries of its &lt;code&gt;env&lt;/code&gt; block. Claude Code goes back to your Anthropic login on the next start.&lt;/p&gt;

&lt;h2&gt;
  
  
  10. The direct route: each maker's own endpoint
&lt;/h2&gt;

&lt;p&gt;You do not need a marketplace for this. Each maker publishes an Anthropic-compatible endpoint, used with a key from that maker. From each maker's own docs, read on November 19, 2026:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Kimi (Moonshot AI):&lt;/strong&gt; &lt;code&gt;ANTHROPIC_BASE_URL&lt;/code&gt; is &lt;code&gt;https://api.moonshot.ai/anthropic&lt;/code&gt; and the model is &lt;code&gt;kimi-k3[1m]&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;GLM (Z.ai):&lt;/strong&gt; &lt;code&gt;ANTHROPIC_BASE_URL&lt;/code&gt; is &lt;code&gt;https://api.z.ai/api/anthropic&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;DeepSeek:&lt;/strong&gt; &lt;code&gt;ANTHROPIC_BASE_URL&lt;/code&gt; is &lt;code&gt;https://api.deepseek.com/anthropic&lt;/code&gt;. Their page lists what that endpoint ignores, such as &lt;code&gt;cache_control&lt;/code&gt; and the &lt;code&gt;budget_tokens&lt;/code&gt; of thinking.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;A maker's endpoint serves that maker's models, billed by that maker. Sections 2, 3, 8 and 9 apply to them too.&lt;/p&gt;

&lt;h2&gt;
  
  
  The trade-offs of doing this through UberLLM
&lt;/h2&gt;

&lt;p&gt;I would rather you read these from me than find them later:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Third-party sellers.&lt;/strong&gt; We do not run the models. Each request is served by a third-party provider through a seller's account, and everything the session reads is sent there. Do not use it in a repository that holds secrets, credentials or customer data.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;We save requests for 90 days by default.&lt;/strong&gt; Each API key has a "Do not save my requests and answers" switch that turns this off.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Our checks have limits.&lt;/strong&gt; No software check proves which weights produced an answer. What we test, and what we cannot prove, is at &lt;a href="https://uberllm.dev/verification" rel="noopener noreferrer"&gt;uberllm.dev/verification&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;It is prepaid, from $5, by card or PayPal. There is no free credit.&lt;/strong&gt; If you only want to try one model family, the maker's own endpoint in section 10 is the simpler test.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;We are a new company&lt;/strong&gt; with no independent reviews yet.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The full guide, with the current model table, lives at &lt;a href="https://uberllm.dev/answers/claude-code-with-deepseek-glm-kimi" rel="noopener noreferrer"&gt;uberllm.dev/answers/claude-code-with-deepseek-glm-kimi&lt;/a&gt;. If a setting here is wrong for your version of Claude Code, tell me in the comments and I will fix the post.&lt;/p&gt;

</description>
      <category>claudecode</category>
      <category>ai</category>
      <category>llm</category>
      <category>tutorial</category>
    </item>
  </channel>
</rss>
