Hermes Agent
Hermes Agent with OpenCode Go and OpenCode Zen: use them as your model provider
Updated 31 October 2026
Hermes Agent can send its model calls to OpenCode, the service behind the OpenCode coding tool. It offers two routes, a flat monthly subscription called Go and a pay-as-you-go gateway called Zen, and each has its own provider in Hermes. This guide covers what they are, how to connect them, which models you get, what the limits look like, and what to do when a request fails.
Hermes facts are checked against Hermes Agent version 0.22.5, the version new ReadyHermes assistants use in October 2026. OpenCode’s prices, limits, models and endpoints were read from its own documentation pages on 31 October 2026 and change often, so check them before you pay.
What OpenCode Go and Zen are (and what they are not)
Two different things share the name. OpenCode is a coding agent you run in a terminal. OpenCode Go and OpenCode Zen are the model services its makers run, and they work as providers in other tools too. This page is about using those two services as the “brain” of Hermes Agent. It is not about running the OpenCode tool itself.
- OpenCode Go is a subscription to a bundle of open and other coding-oriented models. OpenCode’s Go page says it works with other harnesses and names Hermes among them, with the caveat that it does not guarantee they will keep working.
- OpenCode Zen is described as a gateway to models the OpenCode team has tested. You buy credits and each request is charged against them.
Hermes treats both as ordinary providers with a key. If you are new to Hermes, start with how to install Hermes Agent. Hermes also bundles a skill that lets the agent hand coding jobs to the OpenCode CLI, which is a separate feature from the provider setup below.
Go or Zen: which one fits
As read from OpenCode’s documentation on 31 October 2026:
- Go costs $10 a month. There are also Go Plus at $40 a month with higher limits, and Go Teams at $20 per member per month. Usage is capped per model in rolling windows: 20% of the monthly limit every 5 hours, 50% per week, 100% per month. On base Go the monthly limits differ by model and range from $15 to $100; Plus and Teams have their own. If you also hold Console credits you can switch on Extra Usage to keep going past the limits at pay-as-you-go rates.
- Zen is pay as you go. You add credits and are charged per request. A processing fee of 4.6% plus $0.31 is added to each credit purchase. OpenCode says auto-recharge tops up your balance when it runs low and budgets cap monthly spend. Its page also lists some models as free for limited periods, but those free chat models only work through OpenCode’s own client, so use paid models or Go with Hermes.
The practical difference for an agent: Go gives a predictable bill with a ceiling, but a busy agent can hit a window limit and stop until it resets. Zen has no such window, so the bill follows usage. An always-on agent that runs scheduled jobs can use more than you expect, so whichever you pick, watch usage for the first week. On privacy, OpenCode’s pages say most models are not used for training and have zero retention, with exceptions for some free or contributor models and 30-day retention at OpenAI and Anthropic. Read the table for the model you choose.
Connect Hermes to OpenCode Go or Zen
Create the key in the OpenCode Console: sign in, subscribe to Go (or add billing details and credits for Zen) and copy the API key. Then pick the provider in Hermes:
hermes modelChoose the OpenCode entry for the route you pay for, paste the key and pick a model. The picker lists Zen as pay-as-you-go and Go as the open-models subscription. The model choices can come from a public catalog, from lists bundled with Hermes or from the provider, so check OpenCode’s current pages for what is available.
To do it by hand, put the key in ~/.hermes/.env:
- Go:
OPENCODE_GO_API_KEY, provider idopencode-go(aliasesgoandopencode-go-sub). - Zen:
OPENCODE_ZEN_API_KEY, provider idopencode-zen(aliasesopencodeandzen).
Then select the provider and model in config.yaml:
model:
provider: opencode-go
default: glm-5.2Use the bare model name. OpenCode’s relays reject names with a vendor prefix. Hermes strips its own opencode-go/ and opencode-zen/ prefixes, but not a vendor prefix copied from an aggregator, so remove that yourself.
The built-in base URLs are https://opencode.ai/zen/v1 for Zen and https://opencode.ai/zen/go/v1 for Go. They can be overridden with OPENCODE_ZEN_BASE_URL and OPENCODE_GO_BASE_URL. Hermes picks the wire format per model on its own: GPT, Grok and Muse Spark models use the Responses format, Claude, Qwen and Union Alpha models use the Anthropic messages format, and on Go so do MiniMax models; the rest use chat completions. Hermes also sends an anonymous per-conversation header so OpenCode can keep a conversation on one backend and its prompt cache warm.
One thing to check. OpenCode’s current pages list endpoints under opencode.ai/inference/ and do not mention the older /zen paths that 0.22.5 still uses by default. We could not confirm from the docs whether the old paths keep working. If requests start failing for no clear reason, look at the base URL first and compare it with the endpoint shown on OpenCode’s page.
Which models you can use
The list depends on the route and changes. OpenCode’s Go page on 31 October 2026 listed models from families such as Kimi, Qwen, DeepSeek, MiMo, GLM and Grok. Zen carries a wider set that includes GPT and Claude models, and its page lists per-million-token prices that vary a lot between models. Because model names and prices move, treat any list in a blog post, this one included, as a snapshot. The picker in hermes model can include cached or bundled entries, so a successful request is the real proof that your key can use a model.
Two Hermes details are worth knowing. Go cannot take images inside tool results, so Hermes passes a text summary instead. Images in your own messages are sent directly when the model supports them, and Hermes falls back to a text description when it does not. And Hermes tunes reasoning settings for several families on these providers, such as GLM, Kimi and DeepSeek, so the reasoning level you set is translated into what each model accepts. For a tour of one popular family, see Hermes Agent with DeepSeek.
Profiles and sub-bots need the key too
A Hermes profile is a separate home directory with its own config.yaml and its own .env. A fresh profile does not copy your main agent’s .env, though it can reuse credentials saved with hermes auth when it has none of its own. Create it with --clone and the current .env is copied; otherwise set the key inside the profile:
hermes -p work modelThe -p flag works with every subcommand. If a second agent answers with a connection error while your first one is fine, check that its provider and key are set; its own .env should hold OPENCODE_GO_API_KEY or OPENCODE_ZEN_API_KEY. More on how profiles work is in Hermes Agent profiles.
Common errors and fixes
- Authentication errors (401) after changing a key. Hermes keeps credentials in a pool as well as in
.env. If the new key is in.envand requests still fail, runhermes auth add opencode-go --type api-key(oropencode-zen). - 401 on a model that exists. A vendor-prefixed name or the wrong Go or Zen endpoint can cause this. Use the bare model name and check the base URL and key.
- Provider “opencode-free” not found. The keyless free provider was removed from Hermes because OpenCode ended anonymous free access outside its own client. Switch to Go or Zen with a key.
- It works, then stops for hours. On Go that is a usage window. Run
hermes usage, or/usageinside a chat, to see the rolling, weekly and monthly percentages Hermes reads from Go. Options are to wait for the reset, move up a plan, turn on Extra Usage, or add a fallback. - A health check passes or is skipped, yet chat fails.
hermes doctorchecks Zen’s model list but skips Go, which has no shared model-list endpoint, so a green doctor is not proof that Go works. Send a real message.
To keep an agent answering when a window runs out, add a second provider to the chain with hermes fallback add. Entries are saved under fallback_providers in config.yaml and need both a provider and a model.
OpenCode on ReadyHermes
ReadyHermes does not list OpenCode Go or Zen as a named provider. The Model key panel offers OpenRouter, OpenAI, Anthropic, Google Gemini, DeepSeek, Groq, Qwen, Z.AI, Moonshot and MiniMax, plus a custom option where you enter your own HTTPS base URL. The panel is open during the free trial and on paid plans, and a key added in the trial stays when you choose a plan.
The custom option talks to an OpenAI-style chat endpoint. OpenCode says it translates its text models across the API formats it serves, but we have not tested its endpoints through that panel, so we do not promise it works. If you want OpenCode as your provider today, self-hosting Hermes is the better route, though check that your endpoint and model work with 0.22.5. If you would rather not manage keys and servers, a ReadyHermes assistant comes with AI included, and you can read how the options compare in self-hosting versus managed hosting.
Questions
How do I use OpenCode Go with Hermes Agent?
Subscribe to Go in the OpenCode Console and copy your API key. Run hermes model, choose OpenCode Go, paste the key and pick a model. Or put OPENCODE_GO_API_KEY in ~/.hermes/.env and set provider to opencode-go in config.yaml.
What is the difference between OpenCode Go and Zen?
Go is a subscription at $10 a month with usage windows of 20% of the monthly limit per 5 hours, 50% per week and 100% per month, as read from OpenCode's Go page on 31 October 2026. Zen is pay as you go: you buy credits and each request is charged, with a 4.6% plus $0.31 fee on credit purchases.
Which environment variables does Hermes use for OpenCode?
OPENCODE_GO_API_KEY for Go and OPENCODE_ZEN_API_KEY for Zen, both in ~/.hermes/.env. The optional OPENCODE_GO_BASE_URL and OPENCODE_ZEN_BASE_URL override the default endpoints.
Why does my second Hermes profile fail with OpenCode?
Each profile has its own .env, and a fresh one does not copy the main agent's key (it can reuse credentials saved with hermes auth). Run hermes -p followed by the profile name and model, or copy the key into that profile's .env, or create the profile with --clone.
Can I use OpenCode Go or Zen on ReadyHermes?
Not as a named provider. The Model key panel lists OpenRouter, OpenAI, Anthropic, Google Gemini, DeepSeek, Groq, Qwen, Z.AI, Moonshot and MiniMax, plus a custom HTTPS endpoint option. We have not tested OpenCode's endpoints through the custom option.