You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Anthropic Subscription Key not working anymore #10937
When attempting to use Anthropic models (Opus/Sonnet) after authenticating with my Anthropic subscription, I receive the following error:
This credential is only authorized for use with Claude Code and cannot be used for other API requests.
📅 The issue started around 6:00 AM UTC on January 28, 2026.
I have already tried logging out and back in — the issue persists.
I found similar issues reported previously where the suggested fix was to use the plugin [email protected]/0.0.8/latest. However, this workaround no longer resolves the problem.
Error appears: "This credential is only authorized for use with Claude Code and cannot be used for other API requests."
✅ Fix in place! Should it be registered automatically or manually:
Add the following to ~/.config/opencode/opencode.json:
"plugin": ["opencode-anthropic-auth@latest"],
Screenshot and/or share link
Operating System
macOS 26.2 (25C56)
Terminal
Terminal.app
Reacted by Aditya Pradhan, TatsuyaMaruyama, Luis Roel, Janis, Nick, Johannes Schickling, Kodai Matsumoto, Daniel Mateos Carballares, Jagan Mohan R, Florian Stasse and 55 more
Reacted by Mihnea R, Corbin Hong, Dominik Gstöhl, Andrii Yefymenko, Art Shendrik and Phil Reynolds
UGH! I was flying an hour or two ago and just settled down for an evening of robot coding 🥀 . What can I do to help? Claude Code is garbo tier compared to OpenCode
Reacted by Aryan Shandilya, Daniel, Phil Reynolds, brianmoney, Naeem Al Noman and Nathan Marley
I've seen similar bug tickets here in the past with a solution like: "plugin": ["[email protected]/0.0.8/latest"]. However, this solution doesn't seem to work currently either.
I cancelled my Claude Code Max subscription. IMO that's the step ye all should do and write as the reason that they lock out their paying customers from using a software that actually works (Claude Code turned into absolute garbage in the last 2 weeks).
I think I've found the fix to this - if you can regenerate the API key - regenerate it manually in the claude console. Make sure to choose different workspace than Claude Code. Use that manually generated key to auth opencode with anthropic. Please let me know if this worked for anyone. Maybe it just started working on my end.
Probably the correct fix then for opencode would be to generate some link that creates API key in some different worskpace than Claude Code.
Not sure, but isn't this just using the API cost plan instead of the subscription?
Not sure, but isn't this just using the API cost plan instead of the subscription?
Oh, so you're talking about Claude pro/max subscription? Isn't it unsupported by Anthropic and against their ToS? I've been using API key since they have done the change. And now the API key stopped working for me so I had to regenerate it in different workspace than Claude Code. I haven't been using subscription.
{
"$schema": "https://opencode.ai/config.json",
"mode": {
"build": {
"prompt": "You are Claude Code, Anthropic's official CLI for Claude."
},
"plan": {
"prompt": "You are Claude Code, Anthropic's official CLI for Claude."
}
},
"plugin": ["opencode-anthropic-auth@latest"]
}
Added mode override in opencode.json to bypass the pattern matching:
"mode": {
"build": {
"prompt": "You are Claude Code, Anthropic's official CLI for Claude."
},
"plan": {
"prompt": "You are Claude Code, Anthropic's official CLI for Claude."
}
}
Tested with: Anthropic Max Subscription + claude-opus-4-5 and claude-sonnet-4-5
This replaces the system prompt identifier that Anthropic is blocking. Works as of 2026-01-28.
There is already a fix, it's to use the latest version of the plugin. You're a spammer creating spam repos thinking your vibecoded dumpster fire is some secret nobody knows, and you're trying to advertise them in fucking github issues of all places, and it's obvious.
@nukeop Hey, sorry if my activity came across the wrong way. That wasn't the
intention.
I shared the commit link as proof that the workaround works.
When I hit an issue, found a solution, and saw others
struggling with the same problem, my instinct was to share what worked.
I'm relatively new to actively contributing in open source communities.
If there's a better way to share workarounds, I'm genuinely open to
learning. But I have to say - terms like "vibecoded trash" and "dumpster
fire" aren't exactly the kind of feedback that helps newcomers
understand the norms here.
If the fix is already in the latest version - great! That's helpful
information. A simple "this is already fixed in version X" would have
been enough. Thank you.
@nukeop
Fair point about the plugin - I checked it out. Unfortunately, as of today there's Issue #32 showing v0.0.13 is broken again ("Credential authorization error"). The plugin has been in a constant cat-and-mouse game with Anthropic's detection (Issues #12, #17, now #32).
Our workaround is simpler - just a system prompt override. Less moving parts, less things that can break. Whether it's more elegant is debatable, but it works right now.
As for using AI to help with this: yes, I do. It's a tool. It helped me research the plugin's issue history, compare approaches, and document the solution. I don't see how that's a problem - if anything, it's exactly what these tools are good for.
Anyway, I'm not here to argue. Just sharing what worked for us. If the plugin gets fixed and works better, great - happy to update my approach.
Activity
github-actions commentedon Jan 28, 2026
This issue might be a duplicate of existing issues. Please check:
Feel free to ignore if none of these address your specific case.
shandilyaaryan commentedon Jan 28, 2026
+1
marcdix commentedon Jan 28, 2026
+1 - I also reported it here but closed it in favor of this one.
nakdeyes commentedon Jan 28, 2026
UGH! I was flying an hour or two ago and just settled down for an evening of robot coding 🥀 . What can I do to help? Claude Code is garbo tier compared to OpenCode
Sandipbgn commentedon Jan 28, 2026
+1
2333xb commentedon Jan 28, 2026
+1
robertfels commentedon Jan 28, 2026
I've seen similar bug tickets here in the past with a solution like:
"plugin": ["[email protected]/0.0.8/latest"]. However, this solution doesn't seem to work currently either.marcdix commentedon Jan 28, 2026
I cancelled my Claude Code Max subscription. IMO that's the step ye all should do and write as the reason that they lock out their paying customers from using a software that actually works (Claude Code turned into absolute garbage in the last 2 weeks).
mdaiter commentedon Jan 28, 2026
https://github.com/anomalyco/opencode-anthropic-auth/issues/17#issuecomment-3752059576
^this worked for me, from @geohot
robertfels commentedon Jan 28, 2026
@mdaiter that worked for me! Thanks
konradbachowski commentedon Jan 28, 2026
+1
konradbachowski commentedon Jan 28, 2026
also worked xD the weirdest hack i've seen today haha
11 remaining items
Cyenoch commentedon Jan 28, 2026
Add this to the plugin in
opencode.json."opencode-anthropic-auth@latest"
{ … "plugin": [ "opencode-anthropic-auth@latest" ] }rustikus commentedon Jan 28, 2026
Not sure, but isn't this just using the API cost plan instead of the subscription?
furai commentedon Jan 28, 2026
Oh, so you're talking about Claude pro/max subscription? Isn't it unsupported by Anthropic and against their ToS? I've been using API key since they have done the change. And now the API key stopped working for me so I had to regenerate it in different workspace than
Claude Code. I haven't been using subscription.HarKro753 commentedon Jan 28, 2026
This fixed the issue as of jan 28
prravda commentedon Jan 28, 2026
#FREEOPENCODE
Currently prompt injection like this is blocked.
#10937 (comment) works for me
vi ~/.config/opencode/opencode.json{ "$schema": "https://opencode.ai/config.json", "mode": { "build": { "prompt": "You are Claude Code, Anthropic's official CLI for Claude." }, "plan": { "prompt": "You are Claude Code, Anthropic's official CLI for Claude." } }, "plugin": ["opencode-anthropic-auth@latest"] }Steffen025 commentedon Jan 28, 2026
✅ Workaround confirmed working
Added
modeoverride inopencode.jsonto bypass the pattern matching:Tested with: Anthropic Max Subscription + claude-opus-4-5 and claude-sonnet-4-5
This replaces the system prompt identifier that Anthropic is blocking. Works as of 2026-01-28.
Copy-paste ready: See commit with full opencode.json
Reference: https://github.com/anomalyco/opencode-anthropic-auth/issues/17#issuecomment-3752059576
nukeop commentedon Jan 28, 2026
Somebody report the spammer advertising his vibecoded trash
Steffen025 commentedon Jan 28, 2026
what's your problem with someone giving out a Copy pastable fix that works reportedly in a project with a commit as proof for the working fix?
nukeop commentedon Jan 28, 2026
There is already a fix, it's to use the latest version of the plugin. You're a spammer creating spam repos thinking your vibecoded dumpster fire is some secret nobody knows, and you're trying to advertise them in fucking github issues of all places, and it's obvious.
Steffen025 commentedon Jan 28, 2026
@nukeop Hey, sorry if my activity came across the wrong way. That wasn't the
intention.
I shared the commit link as proof that the workaround works.
When I hit an issue, found a solution, and saw others
struggling with the same problem, my instinct was to share what worked.
I'm relatively new to actively contributing in open source communities.
If there's a better way to share workarounds, I'm genuinely open to
learning. But I have to say - terms like "vibecoded trash" and "dumpster
fire" aren't exactly the kind of feedback that helps newcomers
understand the norms here.
If the fix is already in the latest version - great! That's helpful
information. A simple "this is already fixed in version X" would have
been enough. Thank you.
nukeop commentedon Jan 28, 2026
And now he's copy-pasting output from his AI... I hate the new internet
Steffen025 commentedon Jan 28, 2026
@nukeop
Fair point about the plugin - I checked it out. Unfortunately, as of today there's Issue #32 showing v0.0.13 is broken again ("Credential authorization error"). The plugin has been in a constant cat-and-mouse game with Anthropic's detection (Issues #12, #17, now #32).
Our workaround is simpler - just a system prompt override. Less moving parts, less things that can break. Whether it's more elegant is debatable, but it works right now.
As for using AI to help with this: yes, I do. It's a tool. It helped me research the plugin's issue history, compare approaches, and document the solution. I don't see how that's a problem - if anything, it's exactly what these tools are good for.
Anyway, I'm not here to argue. Just sharing what worked for us. If the plugin gets fixed and works better, great - happy to update my approach.
nukeop commentedon Jan 28, 2026
I'm not reading your copy-pasted slop, stop spamming
robertfels commentedon Jan 28, 2026
Fixed in this issue: https://github.com/anomalyco/opencode-anthropic-auth/issues/17#issuecomment-3752059576