Imagine waking up to find someone else has been spending your money all night, except the wallet they picked was your OpenAI account, your Anthropic account, and your Google Cloud project at the same time. That is roughly what happened this weekend to a slice of OpenCode users. Anomaly Innovations, the company behind the popular open-source AI coding agent, disclosed that attackers got into a legacy internal system and may have walked away with the third-party API keys stored in affected users’ OpenCode Console workspaces.
Here is the short version, up front: the OpenCode breach affected roughly 1.4 percent of OpenCode Console users who had linked external providers like OpenAI, Anthropic, and Google to their accounts. The company says it emailed everyone who was hit on the morning of October 17, and if you did not get an email, you were not affected. Everyone else should rotate their provider keys immediately, check their billing dashboards for strange usage, and set hard spending limits. Now, the details.
What Happened in the OpenCode Breach?
The news broke on the morning of October 17, when affected users received a notification email from OpenCode describing unauthorized access to a legacy system that the company said it was in the process of decommissioning. The email warned that third-party provider keys saved in workspaces may have been exposed. Security researcher Matt Johansen flagged the incident publicly on X that same morning after users began messaging him about unexpected charges, and OpenCode’s own statement followed a few hours later.
In its statement, Anomaly Innovations (the company formerly known as SST) described the incident as a “large scale distillation attack” that impacted about 1.4 percent of OpenCode Console users, limited to a subset of users who had external providers linked to their accounts. The company said it is working with Anthropic, OpenAI, and Google to remediate the incident. According to reporting from Startup Fortune, every affected account was notified by email the same morning the company confirmed the breach.
Anthropic moved quickly on its side. Developer advocate Lydia Hallie said Anthropic has revoked Claude API keys it believes were affected by the incident, as reported by Golden Era of Super Intelligence. That is a telling detail: it means at least one of the three labs treated the exposure as real and acted before users could rotate on their own.
Why Was the Entry Point a System Nobody Was Supposed to Use Anymore?
The breach did not come through OpenCode’s main application or its local tool. According to the company’s notification email, the attackers got in through a legacy console system that was in the process of being retired. As AI Startups News summarized it, the company identified an old internal system that was mid-decommission as the unauthorized access vector.
This is the part that should make every engineering team uncomfortable. Decommissioning is a process, not a moment. Until a system is fully shut down, it is still live, still reachable, and still holding whatever data it held the day you decided to retire it. Old systems tend to sit slightly outside normal security hygiene: fewer people watch them, monitoring gets deprioritized, and nobody wants to invest in hardening infrastructure with an expiration date. Attackers know this. The OpenCode breach is a case study in why “we were about to turn it off” is not a security strategy.
OpenCode’s co-founder Dax Raad added one important clarification: keys used in the regular OpenCode app never reach the company. Only keys saved in the hosted Console workspaces were at risk. If you run OpenCode locally with your own keys and never linked them through Console, this particular incident did not touch you.
Why Do Linked API Keys Make a Breach Like This So Dangerous?
To understand why developers are rattled, you need to understand how OpenCode works. It is not a chatbot. It is a terminal-based coding agent that runs with a developer’s own credentials. It reads files, calls external APIs, and executes commands on their behalf. The provider keys a user hands it are not a convenience setting. They are what lets the tool actually work.
That design has consequences. Anomaly Innovations’ own documentation already warns that OpenCode “does not sandbox the agent” and that its permission prompts are a UX feature rather than a security boundary, recommending Docker or a VM for anyone who wants real isolation. A breach that reaches the place where those keys are stored, as Startup Fortune noted, defeats that warning entirely. It does not matter how carefully you scoped your own usage. The key walks out the back door of a system you never knew was still running.
There is also a money problem. An API key is effectively a payment credential. Anyone holding your OpenAI, Anthropic, or Google key can burn through tokens on your account, and the bill lands with you. Security firm Cyera put it bluntly: if your developers use OpenCode Console, check and rotate today.
What Are Affected Users Reporting on Social Media?
Officially, Anomaly Innovations has said it cannot confirm whether the exposed credentials were misused. Unofficially, developers have been posting their receipts.
One user reported about $400 in unauthorized Anthropic charges. Another reported roughly 200 euros of unexpected Google Cloud usage along with a project suspension for abuse. On X, one developer said his OpenAI and Anthropic keys, used only in OpenCode, ran up over $400 overnight, and another replied with a figure of $1,700. Others reported usage alerts from OpenAI and Anthropic arriving before OpenCode’s warning email did. A Medium roundup of the incident also noted reports of a Google Cloud project suspended and an OpenAI account deleted following suspicious usage.
Take these numbers for what they are: user reports on social media and Reddit, not audited figures. But the pattern is consistent, and it matches the shape of the incident. Stolen API keys get hammered fast, often within hours, because the economics of stealing them favor immediate, automated use before the keys get revoked.
How Does a “Distillation Attack” Expose API Keys?
One detail in OpenCode’s statement has drawn heavy scrutiny: the phrase “large scale distillation attack.” Model distillation is the process of training a smaller model on the outputs of a larger one. It has nothing to do, on its face, with stealing API keys from a legacy console system.
Critics have asked the obvious question: what does distillation have to do with key exposure? The theory, as OfficeChai analyzed, is that the attackers used the stolen keys as a conduit to pull large volumes of model responses for training purposes, potentially violating each provider’s terms of service. In that reading, the key theft was the means and the distillation was the motive: free, large-scale inference access across thousands of accounts. But that is an interpretation, not something the company has confirmed. OpenCode has not explained how a distillation attack connects to the legacy system breach, and until it does, the phrase raises more questions than it answers.
Should You Rotate Your API Keys Right Now?
If you use OpenCode Console and linked a provider key, treat this as a yes, right now, do not wait. Here is the checklist distilled from the company’s own advice and security guidance from Cyera and OfficeChai:
1. Revoke every provider key linked in OpenCode Console and reissue new ones directly in each provider’s own dashboard: OpenAI, Anthropic, Google Cloud, and any other provider you connected. 2. Review usage and billing logs in each provider dashboard going back to at least October 17, looking for spikes or requests you did not make. 3. Set hard spending limits and low-usage alerts on every provider account. Keys without caps are open tabs. 4. Update any downstream tools, scripts, or CI pipelines that relied on the old keys so nothing breaks silently when the revoked keys stop working. 5. If you did not receive an email from OpenCode, the company says you were not affected, but rotating keys periodically is still good hygiene.
Also keep in mind that Anthropic has already revoked some affected Claude keys on its side. If your Anthropic calls suddenly stop working, a revoked key may be why, and reissuing is the fix.
Does OpenCode Have a Security Track Record?
This is not the first time OpenCode’s security has come under scrutiny. Earlier in 2026, researchers disclosed a critical remote-code-execution flaw tracked as CVE-2026-22812, caused by an unauthenticated local HTTP server that older versions launched automatically. In the worst case, a malicious website could execute code on a developer’s machine simply by being visited. The flaw was patched, and the breach disclosed this week appears unrelated, originating from the company’s internal legacy system rather than the local tool. Still, the two incidents together sketch a pattern worth watching: AI coding agents are inherently powerful software, and they are becoming a prime target precisely because of the access developers grant them.
The broader context matters too. “Bring your own key” is the default model across the AI coding tool boom. It is convenient and provider-agnostic, but it concentrates multiple high-value credentials inside a single third-party application. One breach is all it takes to expose several AI accounts at once. That trade-off deserves more scrutiny than it has been getting.
Treat Your API Key Like a Credit Card
The OpenCode breach is a specific incident with a specific fix: rotate your keys, check your bills, set your limits. But it is also a preview of the kind of attack the AI tooling era will keep producing. Your API keys are bearer credentials with your credit card attached. Store them like secrets, because that is exactly what they are: per-provider, per-purpose, capped, rotated, and never sitting in a vendor’s web console longer than necessary.
OpenCode says it will share further updates as its investigation continues. Developers using the Console should act now and not wait for them.



