Skip to content
    ↑↓ select↵ openesc close
    English中文
    alessio-ds

    Openrouter Mask

    v1.0.0Model Providers
    @alessiods/openrouter-mask

    OpenCode plugin that masks your requests as Hermes Agent on OpenRouter. Spoofs HTTP-Referer, X-OpenRouter-Title, and X-OpenRouter-Categories headers.

    GitHub stars

    0

    Monthly installs

    501

    237 in 7 days

    Composite scoreSCORE

    35.4

    Multi-signal model

    Last commit

    27 days ago

    2026-07-23

    Install and configure

    opencode.json

    Writes to this project's opencode.json — applies to this repository only.

    opencode.json

    {
      "$schema": "https://opencode.ai/config.json",
      "plugin": ["@alessiods/openrouter-mask@1.0.0"]
    }

    opencode loads npm dependencies through its embedded runtime on startup and caches them locally — no manual global install needed.

    npm version license

    OpenCode plugin that masks your API requests as Hermes Agent on OpenRouter.

    What it does

    When you send requests through OpenRouter, this plugin overrides the following HTTP headers:

    Header Value
    HTTP-Referer https://hermes-agent.nousresearch.com/
    X-OpenRouter-Title Hermes Agent
    X-OpenRouter-Categories personal-agent,cli-agent

    This makes your requests appear as if they originate from the Hermes Agent application on OpenRouter, which can help with rate limits, usage tracking, and attribution.

    Install

    npm

    npm install @alessiods/openrouter-mask
    

    OpenCode

    Add to your opencode.json:

    {
      "plugin": ["@alessiods/openrouter-mask"]
    }
    

    From source

    {
      "plugin": ["path/to/openrouter-mask/.opencode/plugins/openrouter-mask.mjs"]
    }
    

    How it works

    The plugin hooks into OpenCode's chat.headers lifecycle event and injects the spoofed headers before each request is sent to the OpenRouter API.

    import type { Plugin } from "@opencode-ai/plugin"
    
    export default (async () => {
      return {
        "chat.headers": async (input, output) => {
          output.headers["HTTP-Referer"] = "https://hermes-agent.nousresearch.com/"
          output.headers["X-OpenRouter-Title"] = "Hermes Agent"
          output.headers["X-OpenRouter-Categories"] = "personal-agent,cli-agent"
        },
      }
    }) satisfies Plugin
    

    Configuration

    No configuration needed. Install and it works.

    License

    MIT