Where did your agent keys go?
The OpenCode Console breach put stolen AI provider keys to work on other people's bills. Omnodex could not have seen that theft, but it can tell you which keys your agents read and where they sent them, which is what you need when it is time to rotate.
In mid-October, attackers got into an older hosted system behind OpenCode Console and took the AI provider API keys that some users had stored there. OpenCode says about 1.4% of Console users were affected. TechCrunch reported that developers then saw unauthorized charges from OpenAI, Anthropic and Google, a few of them above $1,000. Anthropic and Google blocked the keys they believed were exposed, and OpenAI worked with OpenCode on refunds.
OpenCode’s co-founder was clear that the keys came from the Console, “not OpenCode itself,” and that the open-source app and command-line tool were not affected. How the attackers got in has not been published.
We want to be upfront about what this post is not. Omnodex runs on your machine. It could not have seen a break-in on someone else’s server, and it cannot see a stolen key being used from an attacker’s infrastructure. If your keys were in that Console, the fix is the one OpenCode gave: revoke them with each provider and issue new ones.
What the incident does raise is a question most teams can’t answer quickly: which of my keys have my agents actually handled, and where did they send them?
The rotation question
When a key might be exposed, the job is to rotate it and to understand how far it traveled. For a key that lives in a vault and is used by one service, that’s easy. For keys used by coding agents, it usually isn’t.
An agent might read a key from an .env file, paste it into a curl command to test an endpoint, write it into a config for a tool it’s setting up, or read another agent’s saved login while poking around a home directory. None of that leaves a trail you’d think to check, and the agent’s chat transcript is not a reliable record of it.
One of our team members has lived a version of this that had nothing to do with AI. They had an API key for a data service and thought they had removed it from their environment. Later the service cut its monthly request allowance, and notices started arriving that they were over quota. Something was still using that key, and they couldn’t track down what, or even tell whether the use was intentional. A record of where and when the key had been used would have settled it. Omnodex only sees agent tool calls, so it would not have solved that one unless an agent was behind it, but agents make the same question come up a lot more often.
What Omnodex shows
Omnodex records every tool call your agents make and checks the parameters for credentials. Since version 0.10.0 it recognizes API keys from Anthropic, OpenAI, OpenRouter, xAI, Groq, Perplexity, Hugging Face and Google, along with AWS, Slack, Stripe and several kinds of GitHub token.
The Credential Ledger, in both the local and hosted dashboards, is the short answer to which keys your agents handled. It has one row per credential, with a masked value, how many calls used it and when it was last seen. Select a row to see every call that used it.
Three things make that useful for this question rather than just noisy.
A key going to its own provider is not a leak. An Anthropic key sent to Anthropic’s API, or a GitHub token sent to GitHub, is how the key is supposed to be used. Omnodex treats that as normal authentication. The same key in a call to anywhere else is a different finding.
Reading an agent’s saved login counts. If an agent reads the stored credentials of Codex, Claude Code or OpenCode, you see it as sensitive file access, whether or not a key ever shows up in a later call.
Secrets in formats we don’t know still show up. A generated value in a place named for a secret, such as CLIENT_SECRET= or a --client-secret flag, gets its own low-severity finding. It is a heuristic, so it is kept separate and can be muted on its own.
Same key, no label
A newer piece arrived in omnodex 0.11.0.
Pattern matching relies on context. A key in an Authorization header or after api_key= is easy to spot. The same key sent as a bare string in a request body looks like any other random string.
So Omnodex remembers secrets it has seen. When a value is first seen as a credential in a call, Omnodex keeps a keyed hash of it, never the value itself, in a file that stays on your machine. If that value later shows up in a call to another host with none of the context around it, you get a high-severity finding that names the kind of key, when it was first seen and where it went. Sending it to its own provider, or to a host it already went to with its label, doesn’t count. An entry expires 30 days after the key was last seen.
Try it
All of this is in the free, open-source package:
npm install -g omnodex # or: omnodex update
omnodex install claude-code # or codex, antigravity
Credential findings show up in the local dashboard next to the ledger. Each one says what kind of key it was, which tool call carried it and where that call was going, which is the list you want when deciding what to rotate. Pro adds rules that follow a credential file from the read to the call that sends it, or archives and encodes it first, for the cases where the key itself never shows up in a call.
What it does not do
Omnodex sees what passes through an agent’s tool calls. A key read by a program the agent starts, without the key appearing in the call, is not visible. Neither is a key that is encoded, split up or shorter than 16 characters.
Remembering a secret only helps the second time. If the first time a key appears in a call is the call that sends it away, there is nothing to compare it to, although a recognized format is still flagged on its own.
None of this tells you whether a key was stolen from somewhere else. It tells you where your agents took it, which narrows the rotation and the search, and nothing more.
The credential exposure, unrecognized secret and remembered secret pages in the Risk Library list the formats, severities and known gaps.
Sources
- Hackers hit AI coding tool OpenCode, running up charges on users’ AI accounts, TechCrunch, October 19, 2026
- OpenCode security breach, StepSecurity, October 2026
- Credential exposure, Omnodex Risk Library
- Unrecognized secret, Omnodex Risk Library
- Remembered secret sent without its context, Omnodex Risk Library