Leaked AI Keys and Surprise Bills: Three Scenarios for Teams After the OpenCode Console Breach
An intruder reached a legacy OpenCode system and may have exposed OpenAI, Anthropic and Google keys that some customers had stored in its hosted Console, and some users say they have already been billed for usage they did not run. What to do depends on how your team uses the tool.
AI coding assistants have become everyday tools for developers, and many of them run on API keys that work like a company credit card: whoever holds the key can spend on the account. That is why a breach disclosed over the weekend by OpenCode, the company behind the OpenCode AI coding tool, matters well beyond its own users.
According to reporting from The Hacker News, someone got into a legacy OpenCode system on the night of October 16 and may have exposed the third-party AI provider keys that customers had saved in OpenCode Console, the company’s optional hosted service. Console lets a workspace store its own OpenAI, Anthropic or Google key so team members can use those models without ever seeing the key itself.
Scenario 1: Your team saved a provider key in OpenCode Console
This is the group at risk. OpenCode says it affects 1.4% of Console users, all of whom had linked an outside provider, and it emailed them on the morning of October 17 with the subject line “Action Required: Potential provider key breach.” If you received that message, work through these steps:
- Revoke the key in the provider’s own dashboard and issue a new one. Removing it from Console is not enough, because the old key keeps working until the provider cancels it.
- Swap the new key into every application and script that used the old one.
- Check the provider’s usage and billing records for activity you do not recognize, going back at least to October 16. OpenCode has not said when the unauthorized access began.
- Set spending limits or alerts with the provider, and give each tool its own key so misuse is easier to contain and trace.
Note that a Console budget cannot cap misuse of a copied key, since Console only sees requests that pass through its own gateway.
Scenario 2: Your developers use only the command-line or desktop app
OpenCode says keys added in those apps are stored locally, in a SQLite database on the developer’s own machine, and never reach the company. Co-founder Dax Raad wrote on X that the incident involves the Console, not OpenCode itself. OpenCode also said that anyone who did not receive its email was not affected.
Scenario 3: You are not sure who uses what
This is the most common situation in small companies, where developers or contractors pick their own tools. Ask the question directly this week: who uses OpenCode or similar AI coding tools, which accounts pay for the AI usage, and where the keys are stored. Then review the billing pages of any AI providers your company pays for.
Why this is trending
Real money appears to be involved. The Hacker News relays user reports, cited by Dealroom and Notebookcheck, of unauthorized charges ranging from about €200 to $1,700. Those are claims made by users about their own accounts. OpenCode itself says the keys “may have been exposed” and has not said that any key was copied or used.
Several questions remain open. OpenCode has called the incident ongoing, said it is working with Anthropic, OpenAI and Google, and linked it to a “large-scale distillation attack,” the term AI labs use for mass harvesting of a model’s answers to train a competitor. It has not explained that connection, what the legacy system was, how the intruder got in or how many keys were stored there. Raad wrote on October 18 that attackers had been trying to break in non-stop for 48 hours.
What this means for your company
Treat AI API keys the way you would treat a stored payment card or an admin password. Keep an inventory of which keys exist and who owns them, use a separate key for each tool or project, set hard spending limits wherever the provider allows it, and make sure billing alerts go to someone who will actually read them. Before pasting a key into any hosted service, ask whether the convenience is worth trusting a third party with something that can spend your money.
Need help managing the API keys, accounts and spending limits behind the AI tools your team relies on? Reach out to Layer 7 Data Solutions to discuss how we’ve helped companies similar to yours.
