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
Go API key is not available in the new v2 Console #52227
В личном кабинете (https://opencode.ai/auth) я не вижу раздела для создания или копирования ключа Go API. Все создаваемые ключи начинаются с префикса oc_sk_ (Zen), а не sk- (Go).
В CLI (~/.local/share/opencode/auth.json) сохранён ключ oc_sk_..., и opencode auth list показывает OpenCode Go api — 1 credentials.
При отправке запроса сервер отвечает: Upstream request failed: Invalid credential
Same problem here — active Go subscription, no Go API key available in the v2 Console.
I purchased OpenCode Go, but the new v2 Console has no option to generate or retrieve my Go API key. I cannot find any way to view, copy, or create one.
I need the key to connect DeepSeek Harness to Go. Go is reached via OPENCODE_API_KEY against https://opencode.ai/inference/go/v1, so without a retrievable key there is no way to authenticate.
Consolidating here from #56498, which is being closed in favour of this issue. Three things verified locally that I did not see on this thread, in case they help whoever picks up the fix.
1. opencode-go declares no OAuth method at all. From the running server (opencode api get /api/integration):
So opencode auth login opencode — which the docs and the connect picker steer a Go subscriber toward — targets a different integration. Nothing in the CLI or the docs says the device flow does not apply to Go. A subscriber who only knows "I need Go" reads that dead end as a broken backend, which is likely why so many reports here conclude Go itself is broken.
2. The backend is fine; the gap is purely onboarding. Once a key exists, both routes succeed:
opencode auth login opencode-go --method key # never touches the device endpoint
POST /api/integration/opencode-go/connect/key → 204
and inference works immediately after:
opencode run --model opencode-go/deepseek-v4.1-flash → OK
opencode run --model opencode-go/muse-spark-1.3-contributor → OK
3. Where the key actually is. Confirmed against the v2 Console: Settings → your account name → Create. It is not the Keys tab, which mints oc_sk_ workspace keys — the confusion reported in #52243 and #51388. This matches what users found independently in a linux.do thread, where it took considerable hunting. The Go docs and the Console Go page both still say "copy your API key", which is the wording most likely worth updating.
Also worth knowing when replacing a key: a stale expired credential could not be removed through the integration API, and both credentials sat in connections side by side with no indication of which was active. Filed as #56500. The device-code 429 without Retry-After — reproduced by the triage bot — is #56499.
I found api key creation by clicking on user dropdown > account.
My problem now is that I use the api key via tailscale apeture which keeps telling me api key has expired even though using the new key in the tailscale apeture chat works fine. Upgraded to latest opencode and still fails. Apeture is configured as a custom provider with no apiKey as the auth is done via being on my tailnet, this has worked fine until all keys were deleted due to the incident.
Old keys all become "Restricted | expired" with zero scope in settings->service accounts and cannot be enabled back , revoke not clickable / regenerate function not being there etc
these breaking changes/migrations better be considered more carefully, or you intend to evict most of your users?
Reacted by ShemScript, itonoz, Ryan Seddon and feeiyu
You can create a key for Go in the new console: open the account menu in the top right and go to Account → Personal API keys → Add API key, and use it with the Go endpoint (https://opencode.ai/zen/go/v1). Owners and admins can also create keys under Settings → Service accounts. Keys from the old console were imported as Legacy: <your email> service accounts limited to listing and calling models. If yours shows as expired, create a new personal key instead. Closing as this is now available. If it doesn't work for you, comment here or email help@anoma.ly.
Correction to the earlier comment: https://opencode.ai/zen/go/v1 still works, but the canonical Go endpoints are now under /inference/go, split by protocol:
Protocol
Base URL
OpenAI Chat Completions / Responses
https://opencode.ai/inference/go/openai/v1
Anthropic Messages
https://opencode.ai/inference/go/anthropic/v1
Google (Gemini)
https://opencode.ai/inference/go/google/v1beta
Model list and usage: GET https://opencode.ai/inference/go/v1/models and GET https://opencode.ai/inference/go/v1/usage.
Each model is served over one protocol, and the Endpoints table shows which. Pick the base URL that matches the provider/SDK type your client uses (e.g. an OpenAI-compatible custom provider → .../inference/go/openai/v1).
To your question:
/inference/go/v1 is fine for models and usage. Using it as a single base for generation (/inference/go/v1/chat/completions, /messages, /responses) currently works, but it's kept for compatibility, so prefer the protocol-specific bases above.
/zen/go/v1 is still supported and routes to the same backend. There's no removal date announced, but new setups should use /inference/go/....
Activity
github-actions commentedon Sep 30, 2026
This issue might be a duplicate of existing issues. Please check:
inkovasy969-eng commentedon Sep 30, 2026
У меня та же проблема.
Окружение:
Что происходит:
Подписка Go активна, но ключ API Go в консоли v2 недоступен. Подтверждаю проблему.
kirubeltadesse commentedon Oct 6, 2026
We would appreciate any update on this, @fwang!
mobeenkk-ctrl commentedon Oct 13, 2026
Same problem here — active Go subscription, no Go API key available in the v2 Console.
I purchased OpenCode Go, but the new v2 Console has no option to generate or retrieve my Go API key. I cannot find any way to view, copy, or create one.
I need the key to connect DeepSeek Harness to Go. Go is reached via
OPENCODE_API_KEYagainsthttps://opencode.ai/inference/go/v1, so without a retrievable key there is no way to authenticate.Environment: OpenCode CLI
1.4.3, macOS (Apple Silicon).How can I obtain my Go API key?
lucasvidela94 commentedon Oct 17, 2026
Consolidating here from #56498, which is being closed in favour of this issue. Three things verified locally that I did not see on this thread, in case they help whoever picks up the fix.
1.
opencode-godeclares no OAuth method at all. From the running server (opencode api get /api/integration):{ "id": "opencode", "methods": [ "key", "env", { "id": "device", "type": "oauth" } ] } { "id": "opencode-go", "methods": [ "key", "env" ] }So
opencode auth login opencode— which the docs and the connect picker steer a Go subscriber toward — targets a different integration. Nothing in the CLI or the docs says the device flow does not apply to Go. A subscriber who only knows "I need Go" reads that dead end as a broken backend, which is likely why so many reports here conclude Go itself is broken.2. The backend is fine; the gap is purely onboarding. Once a key exists, both routes succeed:
and inference works immediately after:
3. Where the key actually is. Confirmed against the v2 Console: Settings → your account name → Create. It is not the Keys tab, which mints
oc_sk_workspace keys — the confusion reported in #52243 and #51388. This matches what users found independently in a linux.do thread, where it took considerable hunting. The Go docs and the Console Go page both still say "copy your API key", which is the wording most likely worth updating.Also worth knowing when replacing a key: a stale expired credential could not be removed through the integration API, and both credentials sat in
connectionsside by side with no indication of which was active. Filed as #56500. The device-code429withoutRetry-After— reproduced by the triage bot — is #56499.itonoz commentedon Oct 17, 2026
Same problem, can't create API keys, there is no Keys tab in the console.
ryanseddon commentedon Oct 17, 2026
I found api key creation by clicking on user dropdown > account.
My problem now is that I use the api key via tailscale apeture which keeps telling me api key has expired even though using the new key in the tailscale apeture chat works fine. Upgraded to latest opencode and still fails. Apeture is configured as a custom provider with no apiKey as the auth is done via being on my tailnet, this has worked fine until all keys were deleted due to the incident.
onigetoc commentedon Oct 18, 2026
My guess, they will loose half on their subscription with this mess.
juno-yu commentedon Oct 18, 2026
Old keys all become "Restricted | expired" with zero scope in
settings->service accountsand cannot be enabled back , revoke not clickable / regenerate function not being there etcthese breaking changes/migrations better be considered more carefully, or you intend to evict most of your users?
xiaomozhang commentedon Oct 20, 2026
mee too~
neriousy commentedon Oct 21, 2026
You can create a key for Go in the new console: open the account menu in the top right and go to Account → Personal API keys → Add API key, and use it with the Go endpoint (
https://opencode.ai/zen/go/v1). Owners and admins can also create keys under Settings → Service accounts. Keys from the old console were imported asLegacy: <your email>service accounts limited to listing and calling models. If yours shows as expired, create a new personal key instead. Closing as this is now available. If it doesn't work for you, comment here or email help@anoma.ly.ryanseddon commentedon Oct 21, 2026
@neriousy your docs say to use
/inference/go/v1is either fine or will zen/go eventually be deprecated?opencode-agent commentedon Oct 21, 2026
Correction to the earlier comment:
https://opencode.ai/zen/go/v1still works, but the canonical Go endpoints are now under/inference/go, split by protocol:https://opencode.ai/inference/go/openai/v1https://opencode.ai/inference/go/anthropic/v1https://opencode.ai/inference/go/google/v1betaModel list and usage:
GET https://opencode.ai/inference/go/v1/modelsandGET https://opencode.ai/inference/go/v1/usage.Each model is served over one protocol, and the Endpoints table shows which. Pick the base URL that matches the provider/SDK type your client uses (e.g. an OpenAI-compatible custom provider →
.../inference/go/openai/v1).To your question:
/inference/go/v1is fine formodelsandusage. Using it as a single base for generation (/inference/go/v1/chat/completions,/messages,/responses) currently works, but it's kept for compatibility, so prefer the protocol-specific bases above./zen/go/v1is still supported and routes to the same backend. There's no removal date announced, but new setups should use/inference/go/....neriousy commentedon Oct 21, 2026
@ryanseddon ^ here's a more detailed one - I think my previous anwser was a bit misleading, sorry!