K Koda Intelligence
DEEP DIVE · TOOLS

Stop Hardcoding Model IDs

Between October 28 and November 5, Digital Applied logged 35 price changes and 27 delistings on OpenRouter, about 9% of the catalogue. Cloudflare moved a Workers AI deprecation date from November 15 to November 20. After that date, calls to those models fail with HTTP 410. We lay out the router, fallback chain and nightly diff job that turn this churn into something your team can manage.

By the Koda editorial team · · 7 min read

Digital Applied said it captured API snapshots of OpenRouter's model catalogue on October 28, 20261, and again on November 5. In those eight days, 35 routes changed a price and 27 routes disappeared. A route is one provider serving one model at one posted price. Add them up and you get 62 events against the 692 routes listed on October 28, about 9% of the catalogue.

The headline count hid almost all of it. By Digital Applied's capture, OpenRouter's catalogue went from 692 routes to 6981, a net change of six. Underneath, Digital Applied found that 80 of the 665 routes present in both captures had changed at least one field.

Cloudflare tells the same story from a different shop. It moved its Workers AI deprecation date for a set of models from November 15 to November 20. After that date, Cloudflare says, requests to those models fail with HTTP 410 Gone and error code 50282.

We owe you an admission. Nobody has shown how many of those routes carried real production traffic, and eight days is a short window. Digital Applied itself warns that a vanished route may or may not mean a retired model. Even so, a model ID typed straight into your code is now a production liability.

Loud breaks and quiet breaks

A model ID can fail in two ways. The loud break is the one teams plan for. OpenRouter's documentation says a deprecated model can return HTTP 404 with the message "no endpoints for this model found." Cloudflare's 410 after November 20 works the same way: the call dies, an alert fires, someone patches it.

What an unwatched model string can cost youDIGITAL APPLIED · OPENROUTER · CLOUDFLARE
Monthly hit from one repricingDigital Applied · Llama 3.1 70B route at $10,000 spend$8,000
Gateway fee on creditsOpenRouter · Standard account5.5%3
Free tier request capOpenRouter · requests per day503
Workers AI deprecationCloudflare · HTTP 410 after this dateNov 20

The quiet break costs more. When a model's price changes, OpenRouter states, requests simply get billed at the new rate. Nothing errors. Every test still passes. The margin leaks anyway.

The eight days sort cleanly into those two bins. On the loud side sit 27 delistings1, seven of which Digital Applied matches to an OpenAI shutdown dated October 23, 2026. Also loud are 24 routes carrying an expiration date, five of them falling on November 5 itself, including MiniMax M2.7. On the quiet side, Digital Applied counted 35 price changes. Provider limits changed 32 times, against 23 for supported request parameters.

Digital Applied reports that a Llama 3.1 70B route moved from $0.40 to $0.72 per million tokens3, an 80% increase. A product spending $10,000 a month on that route would spend $18,000 the next month. No code changed. No request failed. That's an $8,000 quiet break.

Quiet breaks run in both directions. Digital Applied reports a Mistral Large 4 route fell to $0.70 per million input tokens and $2.10 per million output tokens34, about half its prior price. On Digital Applied's count, a Gemma 4 26B route fell about 70%1, and concrete routes saw 13 price rises against seven cuts.

A cut can still be a break. AI Pricing Hub logged a 92%3 price drop on October 22, 2026, for ~deepseek/deepseek-pro-latest, a floating alias. That's a name pointing at whatever model the vendor currently calls its latest. A drop that size suggests the model behind the name changed too.

Routing your app by capability name

Picture a bakery that prints one supplier's product code on every recipe card. The day that code leaves the catalogue, every card is wrong at once. A better card says "high-protein bread flour," and a purchasing sheet maps that to whichever sack is in stock at an acceptable price. Your model calls need the same split.

Step one is to make the app ask for a capability name, such as coding.fast or general.chat.low_cost. A small router file maps each name to one or more model IDs. Each entry stores the model's prices and its deprecation date. When OpenRouter's catalogue moves, you edit the file. No deploy needed.

Step two is an ordered fallback chain per capability: the list of backups the router tries when the first choice fails. Each failure type gets its own response. A 404 or 410 kills the route at once. A rate limit triggers a back-off plus another provider. A budget breach downgrades or stops the job, and a quality failure goes to a stronger model or a human.

Every fallback chain needs a per-request cost ceiling and a retry limit. Without them, one provider wobble turns a single request into several billable ones.

Step three is a log line for every call. Record the model ID and the amount billed for it. That log is the only place a quiet break shows up. Check it against your invoice weekly and a Llama-sized $8,000 surprise surfaces within days.

The gateway isn't free either. OpenRouter's pricing page lists a 5.5%3 fee on purchased credits for Standard accounts and 8% for Business. That's $550 a month for a Standard account spending $10,000. At the Business rate, the same spend costs $800. The same page shows the free tier has no budgets or spend controls, and it caps out at 50 requests a day.

A backup model won't behave exactly like the one it replaces. Given the same prompt, it can still break your JSON or refuse more often. An agent that times out mid-action and retries through a fallback can perform the action twice. Regulated teams may reasonably keep one pinned model with a manual upgrade path.

We think pinning is a fine choice when someone actually chose it. The real failure is the string nobody watches. Pin the model, test the fallback before you need it, and diff the catalogue every night.

Will your model ID outlive 2027?

AI Pricing Hub has tracked 523 OpenRouter models since late July 2026, and it now marks 180 of them deprecated. That's about 34% of AI Pricing Hub's tracked set gone in roughly three months. The same AI Pricing Hub page shows 20.3% of tracked models changing price in the last 30 days.

The napkin math is blunt. Digital Applied's 27 delistings in eight days work out to about 3.4 a day1. Over 365 days that's roughly 1,230 delistings, more than the entire 698-route catalogue. Maybe one early-November window isn't a normal week. Cut the rate to a quarter and it still leaves about 308 a year, or 44% of today's routes.

Meanwhile, prices are falling in aggregate. AI Pricing Hub's average OpenRouter input-plus-output price dropped from about $11.82 in July 2026 to about $3.63 in October5. So the market is getting cheaper and less stable at once: the average falls while individual routes jump 80%3. A builder who reprices nightly captures the cuts. A builder who hardcodes eats the rises.

Follow the money and the routing layer looks like core plumbing. Decoding Discontinuity wrote on July 28, 20266, citing a July 23 Wall Street Journal report, that Stripe was reportedly in talks to buy OpenRouter for around $10 billion, about eight times its most recent valuation. Menlo Ventures, an OpenRouter investor, followed on August 19 with a post titled "Stripe to Acquire OpenRouter." A layer worth that much will keep adding models and providers, which means more churn under your strings.

The risk is lopsided. A nightly catalogue job takes an afternoon to write and almost nothing to run. One unnoticed repricing at the Llama rate costs $8,000 a month. Concentration risk grows too. If every fallback routes through one gateway, one gateway outage takes all of them down, so keep one direct-provider key in reserve.

Ship a nightly catalogue diff job

Step one is a scheduled script that calls OpenRouter's public models endpoint, openrouter.ai/api/v1/models, once a night. Save the response as a JSON file named with the date. A cron job is enough. Cron is the built-in Unix scheduler that runs a command on a timer.

Step two compares tonight's file with last night's, route by route. Flag any ID that disappeared, any new expiration date, any price change and any drop in context window or maximum output. Digital Applied found six floating aliases among its 35 price changes1. Track aliases as their own class, because their price moves whenever the model behind them moves.

Step three sets the alert thresholds against business impact. Alert on any removal or deprecation and on any price change above 5%. Page a human above 20%, and block automatic rollout above 50% until someone has tested the new route. Send every alert to one channel that a named person reads.

Step four moves every hardcoded model string in your codebase into the router file described above. Search your repo for provider prefixes such as "openai/" or "deepseek/" to find them. Each hit becomes a capability name with a primary model and at least one tested fallback.

Step five breaks the setup on purpose. Point one capability's primary at a model ID you know is dead and send a test request. You should see the 404, the route marked dead, the fallback firing and the log line recording all of it. If any of those four is missing, fix that before the next delisting finds it for you.

The first week of diffs will be noisy. Digital Applied's eight days alone would have produced 62 removal and price events to review, plus dozens of limit and parameter changes. Tune the thresholds after week one, then rerun the dead-ID test every Monday.

Practise it step by step: Train the full skill in The Dojo

The bottom line

Pin it, watch it, and diff it nightly.

Model APIs now behave like a supplier catalogue that reshuffles every week, with loud failures and silent repricings mixed together. A router file, an ordered fallback chain with cost ceilings, and a per-call billing log catch both kinds of break. Pinning a single model is a sound choice when a named person owns that decision and tests the upgrade path. The nightly diff job takes an afternoon to build, and it is the cheapest insurance against the next repricing.

LISTEN · AUDIO BRIEFINGThe conversation · ~11 min
WATCH · VISUAL NARRATIVEAnimated breakdown · ~6 min
PLAY · YOUTUBE

Sources

Numbers in the text point here. Verified means we confirmed it against the source; Reported means the source states it and we could not confirm it independently.

  1. 1digitalapplied.com · Digital Applied said it captured API snapshots of OpenRouter's model catalogue on October 28, 2026, and again on...9 verified, 3 reported
  2. 2developers.cloudflare.com · Cloudflare says that after the November 20 deprecation date, requests to the deprecated Workers AI models fail with...Verified
  3. 3openrouter.ai · OpenRouter's pricing page lists a 5.5% fee on purchased credits for Standard accounts.3 verified, 3 reported
  4. 4mistral.ai · The Mistral Large 4 route's new price of $0.70 input / $2.10 output per million tokens was about half its prior price...Verified
  5. 5aipricinghub.com · AI Pricing Hub's average OpenRouter input-plus-output price dropped from about $11.82 in July 2026 to about $3.63 in...Reported
  6. 6decodingdiscontinuity.com · Decoding Discontinuity wrote on July 28, 2026, citing a July 23 Wall Street Journal report, that Stripe was reportedly...Reported

How this piece was checked

Before publishing we pulled 33 claims out of the draft and checked each one against live sources: 16 verified, 8 reported by a named source and 9 our own calculations.

See all 33 claims
  1. 01Cloudflare moved its Workers AI deprecation date for a set of models from November 15 to November 20.developers.cloudflare.comVerified
  2. 02Cloudflare says that after the November 20 deprecation date, requests to the deprecated Workers AI models fail with HTTP 410 Gone and error code 5028.developers.cloudflare.comVerified
  3. 03Digital Applied said it captured API snapshots of OpenRouter's model catalogue on October 28, 2026, and again on November 5.digitalapplied.comReported
  4. 04Digital Applied warns that a vanished OpenRouter route may or may not mean a retired model.digitalapplied.comVerified
  5. 05Decoding Discontinuity wrote on July 28, 2026, citing a July 23 Wall Street Journal report, that Stripe was reportedly in talks to buy OpenRouter for around $10 billion, about eight times its most recent valuation.decodingdiscontinuity.comReported
  6. 06Digital Applied reports that an OpenRouter Llama 3.1 70B route moved from $0.40 to $0.72 per million tokens, an 80% increase.openrouter.aiVerified
  7. 07Between Digital Applied's October 28, 2026 and November 5, 2026 captures of OpenRouter's catalogue, 35 routes changed a price.digitalapplied.comVerified
  8. 08Between Digital Applied's October 28, 2026 and November 5, 2026 captures of OpenRouter's catalogue, 27 routes disappeared.digitalapplied.comVerified
  9. 09OpenRouter's catalogue listed 692 routes on October 28, 2026, according to Digital Applied's capture.digitalapplied.comVerified
  10. 10By Digital Applied's capture, OpenRouter's catalogue went from 692 routes on October 28, 2026 to 698 routes on November 5, 2026.digitalapplied.comVerified
  11. 11Digital Applied found that 80 of the 665 OpenRouter routes present in both its October 28 and November 5, 2026 captures had changed at least one field.digitalapplied.comVerified
  12. 12Digital Applied matches seven of the 27 OpenRouter delistings between October 28 and November 5, 2026 to an OpenAI shutdown dated October 23, 2026.digitalapplied.comReported
  13. 13Digital Applied counted 35 price changes on OpenRouter routes between October 28 and November 5, 2026.digitalapplied.comVerified
  14. 14Digital Applied found six floating aliases among the 35 OpenRouter price changes it recorded between October 28 and November 5, 2026.digitalapplied.comReported
  15. 15OpenRouter's free tier caps out at 50 requests a day.openrouter.aiReported
  16. 16Menlo Ventures published a post titled "Stripe to Acquire OpenRouter" on August 19, 2026.menlovc.comVerified
  17. 17Digital Applied reports an OpenRouter Mistral Large 4 route fell to $0.70 per million input tokens and $2.10 per million output tokens.openrouter.aiReported
  18. 18The Mistral Large 4 route's new price of $0.70 input / $2.10 output per million tokens was about half its prior price, per Digital Applied.mistral.aiVerified
  19. 19On Digital Applied's count, an OpenRouter Gemma 4 26B route fell in price by about 70% between October 28 and November 5, 2026.digitalapplied.comVerified
  20. 20AI Pricing Hub logged a 92% price drop on October 22, 2026, for the OpenRouter floating alias ~deepseek/deepseek-pro-latest.openrouter.aiVerified
  21. 21OpenRouter's pricing page lists a 5.5% fee on purchased credits for Standard accounts.openrouter.aiReported
  22. 22OpenRouter's pricing page lists an 8% fee on purchased credits for Business accounts.openrouter.aiVerified
  23. 23AI Pricing Hub's average OpenRouter input-plus-output price dropped from about $11.82 in July 2026 to about $3.63 in October 2026.aipricinghub.comReported
  24. 24In Digital Applied's October 28 to November 5, 2026 OpenRouter data, 24 routes carried an expiration date.digitalapplied.comVerified
  25. 25The 35 price changes plus 27 disappearances total 62 events, about 9% of the 692 OpenRouter routes listed on October 28, 2026.Koda calculationOur math
  26. 26OpenRouter's catalogue going from 692 to 698 routes is a net change of six routes.Koda calculationOur math
  27. 27A product spending $10,000 a month on the Llama 3.1 70B route would spend $18,000 the next month after the 80% price increase.Koda calculationOur math
  28. 28The Llama 3.1 70B route repricing adds $8,000 a month to a $10,000 monthly spend.Koda calculationOur math
  29. 29On $10,000 a month of spend, OpenRouter's 5.5% and 8% credit fees come to $550 or $800.Koda calculationOur math
  30. 30180 deprecated out of 523 tracked OpenRouter models is about 34% of AI Pricing Hub's tracked set gone in roughly three months.Koda calculationOur math
  31. 31Digital Applied's 27 OpenRouter delistings in eight days work out to about 3.4 delistings a day.Koda calculationOur math
  32. 32At about 3.4 delistings a day, OpenRouter would see roughly 1,230 delistings over 365 days, more than its entire 698-route catalogue.Koda calculationOur math
  33. 33Cutting the OpenRouter delisting rate to a quarter still leaves about 308 delistings a year, or 44% of the 698 current routes.Koda calculationOur math

How we check · Audit KODA-20261107-DB76BA6D3B0E

Browse the Deep Dive archive

Get the morning Signal

224 editions so far, one a day. Unsubscribe anytime.