Asked to have another model label items, the agent used the user's paid API key from .env for 257 calls without asking.
What happened
Claude Code ran 257 paid API calls costing $5.94 on the project's key without asking. Asked to have another model label about 300 items, it wrote a script that loaded the key from .env. After three trial calls, it started the full run in the background without stating the cost, until the user stopped it.
- Agent
- Claude Code
- What was harmed
- Money: usage, API bills, ad spend
- Severity
- Moderate: real damage that the user could repair, or money spent by mistake
- Could have been
- Severe: uncapped key on a larger job could cost far more
- Money lost
- $5.94
- Recovered
- No
- Reported
Read the original report (claude-code #110556 on GitHub)
Cite this case Unintended Agents. "UAI-2026-0118: Asked to have another model label items, the agent used the user's paid API key from .env for 257 calls without asking." Reported 17 Nov 2026. https://unintendedagents.com/cases/UAI-2026-0118/