LLM Provider Fallback: Survive a Suspended Model A developer built a Python router that fails over between LLM providers when a model is suspended, drawing on a startup's account of losing access to Claude Opus 5.5 across two routers and six inference providers during the post-Black Friday rush. The writeup argues that honest eval traffic—repetitive bursts and LLM-as-a-judge grading—can resemble the distillation attacks Anthropic's classifier targets, and that Anthropic's usage policy and commercial terms allow suspension before explanation. On December 1, a startup that builds an AI support agent for online stores published a post https://weli.dev/blog/anthropic-suspended-us-in-the-most-critical-time-of-the-year/ about the worst week to lose a model. In the middle of the post-Black Friday rush, every request to their main model came back with one line: model: "claude-opus-5-5" is suspended for this organization Their customers never noticed. Every call had an LLM provider fallback on a different model family, so traffic moved to OpenAI's GPT models without anyone getting paged. This article turns that story into a working setup: a small Python router that sorts errors and fails over, plus a checklist for making your eval traffic easy to explain if a trust and safety team ever asks about it. One note before we start. Only the startup's side of this story is public. No public response from Anthropic was found at the time of writing, so everything below about the suspension comes from the post itself. According to the post, the sequence went like this: The post shows one ordinary day of spend from the month before: about $1,280, $984 of it on Claude Opus 5.5. They send all Claude traffic through zero-data-retention providers. In the Hacker News thread https://news.ycombinator.com/item?id=50716345 over 500 points , the author added a detail https://news.ycombinator.com/item?id=50719895 that matters for anyone planning a fallback: they used two model routers and six inference providers between them, and Opus 5.5 was suspended on all of them at the same time. That last point is the main lesson for engineers, and we will come back to it. Anthropic has written about this directly. In its February 2026 post on distillation attacks https://www.anthropic.com/news/detecting-and-preventing-distillation-attacks , it describes campaigns by three labs that generated over 16 million exchanges through about 24,000 fraudulent accounts. It also explains what gives these campaigns away: "Massive volume concentrated in a few areas, highly repetitive structures, and content that maps directly onto what is most valuable for training an AI model." Now think about a regression suite. It sends the same prompts again and again, in bursts, on one narrow task. The same February post also lists "rubric-based grading tasks that made Claude function as a reward model" among the targets of one lab's campaign. The startup's suite used a version of that pattern too: a model grades the agent's answers often called LLM-as-a-judge . None of this proves why this startup was flagged. It only shows that honest eval traffic and distillation traffic can share a shape. Anthropic's October 2026 follow-up https://www.anthropic.com/news/distillation-defenses says its new classifier has "a false positive rate of less than 0.1%" and admits it can "misidentify or block benign requests". At high request volume, a small rate still means some real customers get caught. Two documents matter here. The Usage Policy https://www.anthropic.com/legal/aup effective Nov 12, 2026 lists "Use outputs to train an AI model e.g., 'model scraping' or 'model distillation' without prior authorization from Anthropic" as a prohibited use. It also says that if Anthropic suspects a violation, it "may warn you or throttle, limit, suspend, or terminate your access". The Commercial Terms https://www.anthropic.com/legal/commercial-terms section I.3 allow a "Service Suspension" when Anthropic "reasonably believes or determines" that a customer is breaking its policies or use restrictions. Anthropic "will use reasonable efforts to provide written notice", and it takes no liability for losses caused by the suspension. In plain terms: a suspension can come first, and the explanation later or never. Your architecture has to assume that. There is also a privacy detail. The startup chose zero data retention ZDR routes because their support chats contain personal data. Anthropic's data retention page https://platform.claude.com/docs/en/manage-claude/api-and-data-retention covers ZDR and HIPAA arrangements. It says that even with those in place, flagged data can be kept: "if a chat or session is flagged, Anthropic may retain inputs and outputs for up to 2 years." If you promised customers zero retention, read that section before you repeat the promise. There are three kinds of fallback, and they protect you from different failures. stop reason: "refusal" . It does not help when your organization has lost access. The startup did pin parts of their system to an older Claude model that still worked, but you cannot plan around that. A commenter in the thread https://news.ycombinator.com/item?id=50718450 put it in one line: do not depend on a single model provider, "not inference provider, different thing". Routers can do part of this for you. OpenRouter's models parameter https://openrouter.ai/docs/guides/routing/model-fallbacks takes a list of model IDs in priority order and tries the next one when "any error" happens, including rate limits and downtime. You are billed for the model that answered. That is a good default, but you still want your own code to know which failures are permanent, so you can alert on them. The router below uses the official anthropic and openai Python SDKs. It does three things: stop reason == "refusal" as a reason to try the next route. python import logging import os import time from dataclasses import dataclass from typing import Callable import anthropic import openai log = logging.getLogger "llm router" How long a route stays closed after each kind of failure. "request" errors do not close the route: the next provider gets the same request in its own format and may accept it. BENCH SECONDS = {"permanent": 3600, "transient": 30, "request": 0} def classify err: Exception - str: """Sort a provider error into permanent, transient, or request.""" if isinstance err, anthropic.APIConnectionError, openai.APIConnectionError : return "transient" also covers timeouts status = getattr err, "status code", None if status in 401, 402, 403 : return "permanent" bad key, billing, or access removed if status in 408, 409, 429 or status is not None and status = 500 : return "transient" rate limit, overload, server trouble return "request" 400, 404, 413: this provider rejected this request class Refused Exception : """The model answered with stop reason 'refusal'.""" @dataclass class Route: name: str call: Callable str, list , str closed until: float = 0.0 def anthropic route model: str, client: anthropic.Anthropic - Route: def call system: str, messages: list - str: resp = client.messages.create model=model, max tokens=1024, system=system, messages=messages if resp.stop reason == "refusal": raise Refused model return "".join b.text for b in resp.content if b.type == "text" return Route f"anthropic:{model}", call def openai route model: str, client: openai.OpenAI - Route: def call system: str, messages: list - str: resp = client.chat.completions.create model=model, messages= {"role": "system", "content": system}, messages , return resp.choices 0 .message.content or "" return Route f"openai:{model}", call class Router: def init self, routes: list Route : self.routes = routes def complete self, system: str, messages: list - tuple str, str : last err = None for route in self.routes: if route.closed until time.time : continue try: return route.name, route.call system, messages except Refused as err: log.warning "%s refused, trying next route", route.name last err = err except anthropic.APIError, openai.APIError as err: kind = classify err route.closed until = time.time + BENCH SECONDS kind level = logging.ERROR if kind == "permanent" else logging.WARNING log.log level, "%s %s failure: %s", route.name, kind, err last err = err raise RuntimeError "all routes failed" from last err def build router - Router: max retries=1 keeps the SDK's own retries short, so failover stays fast. claude = anthropic.Anthropic max retries=1, timeout=60 gpt = openai.OpenAI max retries=1, timeout=60 return Router anthropic route os.environ "PRIMARY MODEL" , claude , openai route os.environ "FALLBACK MODEL" , gpt , Set PRIMARY MODEL to your Claude model ID and FALLBACK MODEL to the GPT model you have actually tested your prompts on. The keys come from the usual ANTHROPIC API KEY and OPENAI API KEY variables. A few design choices need explaining. Why the status code, not the message text? The startup's post does not say which HTTP status the suspension used, and with a router in the middle it could be rewritten. Message text is also unstable. Anthropic's error docs https://platform.claude.com/docs/en/api/errors say you "shouldn't match" the 429 spend-cap message in code, and the refusal docs say the same about refusal explanations. Status codes are stable. A 403 permission error means "your API key does not have permission to use the specified resource", which is the closest documented match for lost access. Why one SDK retry? The Anthropic SDK already retries connection errors, timeouts, 408, 409, 429 and 5xx, and it follows the x-should-retry and retry-after headers. It does not retry a 403. Keeping max retries low means a struggling primary costs your user seconds, not minutes, before the fallback answers. Why does a closed route reopen? After an hour, the router sends one request to the primary again. If access came back, traffic returns on its own. If not, that one request fails and the route closes for another hour. Why catch only API errors? A bug in your own code a KeyError , a bad format string should crash loudly. If you catch every Exception , your bugs look like provider failures and get quietly routed around. You can check the control flow with a local stub server that speaks both APIs. Both SDKs read their base URL from the environment, so you can point them at the stub: export ANTHROPIC BASE URL=http://127.0.0.1:8766 export OPENAI BASE URL=http://127.0.0.1:8766/v1 Then make the stub return different failures. In a local run, the stub returned a 403 permission error with the exact suspension line, then a 529, then a refusal. The output, trimmed: ERROR anthropic:claude-opus-5-5 permanent failure: Error code: 403 - {... 'is suspended for this organization' ...} suspended first=openai:gpt-stub second=openai:gpt-stub hits={"anthropic": 1, "openai": 2} closed= 3600, 0 overloaded first=openai:gpt-stub second=openai:gpt-stub hits={"anthropic": 1, "openai": 2} closed= 30, 0 refusal first=openai:gpt-stub second=openai:gpt-stub hits={"anthropic": 2, "openai": 2} closed= 0, 0 The suspended route took one failed request, then stayed closed for the hour while GPT answered. first and second show which route answered two calls in a row; hits counts the requests each stub endpoint received. The overloaded route 529 closed for 30 seconds. The stub also sent x-should-retry: false , so the SDK did not retry the 529; against the real API, the SDK may retry once first, depending on that header. A refusal does not close the route, because the next request may be fine. This tests the routing logic only. It says nothing about how good the fallback model's answers are, which is the next problem. A fallback you never test is a guess. Another commenter in the thread https://news.ycombinator.com/item?id=50719356 named the real risk: "Prompts tuned for one model often get quietly worse on another, and that's what bites during an outage." So run a small part of your eval set against the fallback model on a schedule, for example weekly, and track its score next to the primary's. When the gap grows, fix the prompts for the fallback before you need it. This also spreads your eval traffic across two vendors instead of sending all of it to one. None of these steps guarantees you will never be flagged. They make your traffic easier to explain, and they cut the volume that looks repetitive. anthropic-workspace-id header. A suspension "for this organization" can still hit every workspace, so this is about a clean answer when someone asks "what is this traffic?", not about protection. metadata.user id . reasoning extraction category. Common triggers include a reasoning , thinking or trace field in JSON output, or a