OpenCode / Hermes Agent

OpenAI-compatible coding agents such as OpenCode and Hermes Agent can route their requests through Qubax by setting a custom provider. Both read a base_urland api_key, after which every model call is billed against your Qubax credits.

ℹ️
You will need a Qubax API key (starts with qbx_live_) and the base URL https://api.qubax.ai/v1.

OpenCode

OpenCode supports custom OpenAI-compatible providers in its config file. Add a Qubax provider entry pointing at the Qubax base URL.

JSON
{
  "providers": {
    "qubax": {
      "base_url": "https://api.qubax.ai/v1",
      "api_key": "qbx_live_your_api_key_here",
      "models": {
        "gpt-5": {},
        "claude-sonnet-4.5": {}
      }
    }
  },
  "default_provider": "qubax"
}

You can also pass the credentials via environment variables so they are never written to disk:

Shell
export OPENAI_BASE_URL="https://api.qubax.ai/v1"
export OPENAI_API_KEY="qbx_live_your_api_key_here"
💡
List any Qubax model IDs you want to use in the modelsblock. Run curl https://api.qubax.ai/v1/models to see the full list available on your account.

Hermes Agent

Hermes Agent reads its model provider from a profile config. Add Qubax as a provider in the profile and reference it from your agents.

YAML
# ~/.hermes/profiles/default/config.yaml
providers:
  qubax:
    base_url: "https://api.qubax.ai/v1"
    api_key: "qbx_live_your_api_key_here"
    models:
      - gpt-5
      - claude-sonnet-4.5

model:
  provider: qubax
  name: gpt-5

The same fields also work as environment variables, which take precedence over the config file:

Shell
export QUBAX_BASE_URL="https://api.qubax.ai/v1"
export QUBAX_API_KEY="qbx_live_your_api_key_here"

Verifying the connection

After configuring, confirm the provider responds with a quick model list call:

Shell
curl https://api.qubax.ai/v1/models \
  -H "Authorization: Bearer $QUBAX_API_KEY"

If the call returns a JSON list of models, the provider is wired up correctly and your agent will route all requests through Qubax.