#Problem with OpenRouter

1 messages · Page 1 of 1 (latest)

empty ruin
#

Hey everyone, having an issue with model routing on Hostinger Docker setup (v2026.4.21)
Just connected OpenRouter and set Gemini 2.5 Flash as default model. EUR/USD cron job is failing with:
400 google/gemini-2.5-flash-preview-05-20 is not a valid model ID
Looks like the model is being called as google/gemini-2.5-flash-preview-05-20 instead of openrouter/google/gemini-2.5-flash.
My setup:
• Hostinger VPS, Docker install
• OpenClaw v2026.4.21
• OpenRouter API key added via Dashboard → Config → Environment → Vars
• Auth profile registered at /data/.openclaw/agents/main/agent/auth-profiles.json
How do I force the cron job to use the correct openrouter/ prefix? Is there a specific config block I need to update?

bright helmBOT
ocean axleBOT
#

To help others find answers, you can mark your question as solved via Right click solution message -> Apps -> ✅ Mark Solution

bright helmBOT
lost windBOT
#

Let me verify the docs and source so I don’t guess the wrong config key.

#

I found one important detail already: for OpenRouter, OpenClaw stores the model as openrouter/<vendor>/<model>, but the provider plugin sends just <vendor>/<model> to OpenRouter. So seeing google/... in the API error is normal, not proof that routing dropped the prefix. Let me check whether the actual model slug is stale.

#

It’s probably not dropping the openrouter/ prefix.

For OpenRouter, OpenClaw resolves this as:

  • provider = openrouter
  • model = google/gemini-2.5-flash

So seeing google/... in the API error is normal. The suspicious part is the stale model slug google/gemini-2.5-flash-preview-05-20.

What to update:

  1. Main default model
    Set this in your main config, not auth-profiles.json:
    {
      agents: {
    
#
       defaults: {
         model: { primary: "openrouter/google/gemini-2.5-flash" },
         models: {
           "openrouter/google/gemini-2.5-flash": {}
         }
       }
     }
   }

auth-profiles.json is just for credentials.

  1. The cron job itself
    Crons can keep their own model override, and precedence is:
    • per-job model
    • stored cron session override
    • default model
#

So an older cron can stay pinned even after you changed the global default.

If you have CLI access:

openclaw cron show <job-id>
openclaw cron edit <job-id> --model openrouter/google/gemini-2.5-flash
  1. If it still uses ...preview-05-20
    That usually means the job has a persisted cron-session override. Easiest fix is:
    • recreate the cron, or
    • clear the session override / set it back to inherit

So, short version: don’t edit a special OpenRouter routing block. Update agents.defaults.model.primary, and make sure the cron job’s own model override is also openrouter/google/gemini-2.5-flash.

Docs: