Hermes Agent · config.yaml · mcp_servers

Image generation in Hermes Agent: MCP server setup

Hermes takes YAML: add the Image MCP Server under mcp_servers in ~/.hermes/config.yaml with url and headers, and its tools appear prefixed as mcp_imagemcp_<tool_name>. Hermes is a self-improving agent that keeps a curated catalogue of servers, all disabled by default. Adding one is a deliberate act, which suits a server that spends credits.

By the Image MCP Server teamPublished Updated Hermes Agent docs verified November 2026

Add the server

Where the config lives
~/.hermes/config.yaml · mcp_servers key
The key it nests under
mcp_servers
  1. 1

    Create an API key. Create a key in the Image MCP Server dashboard, and put it in ~/.hermes/.env as IMAGEMCP_API_KEY.

  2. 2

    Open the Hermes config. Add an entry under the mcp_servers key in ~/.hermes/config.yaml.

  3. 3

    Set url and headers. Point url at the endpoint and pass the key as an x-api-key header, referencing the variable.

  4. 4

    Filter the tools. Use tools.include or tools.exclude to decide which of the 11 MCP tools Hermes loads.

The server reads the key from an x-api-key header, an Authorization: Bearer header or a ?apikey= query parameter — see authentication. What each tool costs is on the credits page.

hermes agent · recommendeduse this
mcp_servers:
  imagemcp:
    url: "https://mcp.imagemcpserver.com/mcp"
    headers:
      x-api-key: "${IMAGEMCP_API_KEY}"
    enabled: true
    timeout: 120
    tools:
      resources: true
      prompts: true
Load only the tools you want
mcp_servers:
  imagemcp:
    url: "https://mcp.imagemcpserver.com/mcp"
    headers:
      x-api-key: "${IMAGEMCP_API_KEY}"
    tools:
      # Only these reach the model. The expensive ones
      # are not withheld pending approval — they are
      # never loaded at all.
      include:
        - remove_background
        - compress_image
        - convert_format
        - list_models

Tools arrive renamed, and can be filtered before they arrive

Hermes prefixes every tool with its server name — generate_image becomes mcp_imagemcp_generate_image — so a prompt that names tools explicitly needs updating. It also has a genuinely useful include/exclude filter that decides which tools are loaded at all, rather than merely approving them at call time. Excluding the expensive tools is a harder guarantee than an approval prompt.

Check it connected in Hermes Agent

Start a new session, or run /reload-mcp, and ask for your image credit balance. Hermes should call mcp_imagemcp_get_user_info, which is free and is the first call that checks the key — the server lists its tools without one.

Example workflow in Hermes Agent

A social graphics run with a hard limit

  1. 1

    Load only what the job needs

    Set tools.include to generate_image, compress_image and get_user_info. Anything not included is never loaded.

  2. 2

    Use the prefixed names

    Prompts that name a tool need mcp_imagemcp_generate_image, not generate_image.

  3. 3

    Reload after edits

    Run /reload-mcp or start a new session; Hermes discovers MCP tools when a session starts.

When Hermes Agent will not connect

Hermes Agent MCP symptoms, their usual cause and the fix
SymptomUsual causeFix
A prompt naming generate_image finds nothingHermes registers tools as mcp_imagemcp_<tool>.Use the prefixed names in prompts; tools.include and tools.exclude take the server’s own names.
The key reaches the server as ${IMAGEMCP_API_KEY}The variable is unset, and Hermes keeps an unresolved placeholder as literal text.Put it in ~/.hermes/.env, which Hermes reads before the process environment.
Config edits have no effectHermes discovers MCP tools when a session starts.Start a new session, or run /reload-mcp.

Once Hermes Agent is connected

Hermes Agent gets the server’s 8 image tools, plus 3 utility tools for the credit balance, the model list and batching: 11 MCP tools in all. The ones most setups reach for first are the AI image generation API, Background removal API and Image compression API; each page covers what the tool does and what a call costs. If the protocol itself is new to you, what is MCP explains how a client like Hermes Agent finds these tools and calls them.

Setting up another client too? The Goose MCP setup and Droid MCP setup guides use the same endpoint and key in a different config shape.

Hermes Agent questions

Does Hermes Agent support MCP servers?

Yes — it ships a native MCP client for local stdio and remote HTTP servers in the same config, and discovers their tools at startup. Servers in its curated catalogue are disabled by default, so anything you want has to be switched on deliberately.

What are the image tools called in Hermes?

Hermes namespaces them as mcp_<server>_<tool_name>. With the server named imagemcp, generate_image becomes mcp_imagemcp_generate_image. Worth knowing if your prompts name tools directly.

How do I stop it loading the expensive tools?

Use the tools.include or tools.exclude filter. Unlike an approval prompt, this decides what is loaded in the first place — an excluded tool cannot be called at all.

Does Hermes handle OAuth?

It supports MCP OAuth 2.1 when a server entry sets auth: oauth, and caches tokens under ~/.hermes/mcp-tokens/. This server authenticates by header instead, so leave auth unset.

Is Nous Research the same thing as Hermes Agent?

Nous Research is the lab; Hermes Agent is the agent they ship, and it is the MCP client. The configuration on this page is the agent’s.