All guides

Set Up OpenClaw with MonoRouter

Route OpenClaw (Cline) through your Claude Pro or Max subscription. Paste the config, save, and you're live.


Already have an openclaw.json?

Skip the walkthrough. Use the config merger at the bottom of this page to paste your existing config — we'll fold MonoRouter in for you, and nothing leaves your browser.

What you need

  • A Claude Pro or Max subscription at claude.ai — whichever tier you have is fine; MonoRouter routes through both.
  • Claude Code installed locally (needed for the OAuth token extraction). Install with npm i -g @anthropic-ai/claude-code or see claude.com/claude-code. Only required once, during the connect step.
  • OpenClaw installed on your machine. Configuration details below.

Sign up for MonoRouter

Open /signup, enter your email and set a password. Save the six recovery codes — they're your offline fallback if you lose your password; you can also always reset it by email at /forgot-password.

Connect your Claude subscription

From the dashboard, go to /tokens, click [ + add token ], and pick ANTHROPIC. Use the auto-connect tab — it's the fastest.

The modal shows a one-liner like this:

bash
curl -sSL https://api.monorouter.dev/connect.sh | bash -s -- mrc_xxxxxxxxxxxx

Paste it into a terminal. The script runs claude setup-token, which opens a browser window for authorization and creates a long-lived token (valid for 1 year). When the dashboard flips to connected, you're done.

Get your MonoRouter API key

A default mrk_* key was created for you on signup. Go to /keys and copy it — you'll paste it into OpenClaw next.

Treat this like a password. Anyone with it can burn your Claude quota.

Add MonoRouter as an OpenClaw provider

OpenClaw's config lives at ~/.openclaw/openclaw.json. Drop your MonoRouter key into apiKey and merge the two blocks below into the file. Already have config there? Merge alongside what's in your root object — don't replace the whole thing.

json
{
  "models": {
    "providers": {
      "monorouter": {
        "baseUrl": "https://api.monorouter.dev",
        "apiKey": "mrk_...",
        "api": "anthropic-messages",
        "models": [
          { "id": "claude-fable-5",            "name": "Fable 5" },
          { "id": "claude-opus-4-8",           "name": "Opus 4.8" },
          { "id": "claude-opus-4-7",           "name": "Opus 4.7" },
          { "id": "claude-opus-4-6",           "name": "Opus 4.6" },
          { "id": "claude-sonnet-5",           "name": "Sonnet 5" },
          { "id": "claude-sonnet-4-6",         "name": "Sonnet 4.6" },
          { "id": "claude-haiku-4-5-20251001", "name": "Haiku 4.5" }
        ]
      }
    }
  },
  "agents": {
    "defaults": {
      "model": {
        "primary": "monorouter/claude-opus-4-8",
        "fallbacks": ["monorouter/claude-opus-4-7", "monorouter/claude-sonnet-4-6"]
      },
      "models": {
        "monorouter/claude-fable-5":            {},
        "monorouter/claude-opus-4-8":           {},
        "monorouter/claude-opus-4-7":           {},
        "monorouter/claude-opus-4-6":           {},
        "monorouter/claude-sonnet-5":           {},
        "monorouter/claude-sonnet-4-6":         {},
        "monorouter/claude-haiku-4-5-20251001": {}
      }
    }
  }
}

Understanding the default + fallback model

The agents.defaults block has two important pieces:

  • model.primary: monorouter/claude-opus-4-8 — the most capable model. Your daily driver.
  • model.fallbacks — kicks in when Opus 4.8 is unavailable (capacity, retry exhausted). Tried in order.
  • models — explicit allowlist of every model the agent may touch. If a model isn't listed here — even a valid one you registered under models.providers — OpenClaw won't use it.
Keep the allowlist in sync with the models array you set in the providers block above.

Save openclaw.json, restart OpenClaw, and every call now routes through MonoRouter — which in turn routes through your Claude Pro / Max subscription.


Verify it works

Quick curl sanity check:

bash
curl -X POST https://api.monorouter.dev/v1/messages \
  -H "Content-Type: application/json" \
  -H "x-api-key: mrk_..." \
  -H "anthropic-version: 2023-06-01" \
  -d '{
    "model": "claude-sonnet-4-6",
    "max_tokens": 128,
    "messages": [{"role": "user", "content": "hi"}]
  }'

A 200 with a JSON response means you're done. The call also shows up on /dashboard within a second or two.

Pricing

  • 1,500 successful calls are free for the lifetime of your account. Failed calls don't count.
  • After that, paid plans start at $9/month (Hobby, 10,000 calls). Pro is $29/month for unlimited personal use; Team is $99/month for 5 pooled seats. See /billing for the payment flow.

Ready to get started?

Sign up in 30 seconds — no credit card required. 1,500 free API calls included.

Config merger

Already have an openclaw.json? Paste it in and we'll merge MonoRouter additively — nothing leaves your browser.

// openclaw config merger
paste your existing config — get the updated one
✦ runs locallyRuns entirely in your browser. Your pasted config is parsed, transformed, and rendered locally — nothing about it is sent to MonoRouter or anywhere else. Open DevTools → Network to verify zero requests fire as you type. Sensitive keys you have for OTHER providers stay private.
// your openclaw.json
// diff (your file → merged)
// before · your file
// after · merged
// paste your openclaw.json above to see what would change
// changes
  • ·started from scratch — paste your existing openclaw.json on the left to merge.

Setup snippets

Copy-paste-ready config blocks for OpenClaw, Claude Code, and a curl sanity check.

Models · Providers
"models": {
  "providers": {
    "monorouter": {
      "baseUrl": "https://api.monorouter.dev",
      "apiKey": "mrk_...",
      "api": "anthropic-messages",
      "models": [
        { "id": "claude-fable-5",            "name": "Fable 5 (via MonoRouter)" },
        { "id": "claude-opus-4-8",           "name": "Opus 4.8 (via MonoRouter)" },
        { "id": "claude-opus-4-7",           "name": "Opus 4.7 (via MonoRouter)" },
        { "id": "claude-opus-4-6",           "name": "Opus 4.6 (via MonoRouter)" },
        { "id": "claude-sonnet-4-6",         "name": "Sonnet 4.6 (via MonoRouter)" },
        { "id": "claude-haiku-4-5-20251001", "name": "Haiku 4.5 (via MonoRouter)" }
      ]
    }
  }
}
Agents · Defaults
"agents": {
  "defaults": {
    "model": {
      "primary": "monorouter/claude-opus-4-8",
      "fallbacks": ["monorouter/claude-opus-4-7", "monorouter/claude-sonnet-4-6"]
    },
    "models": {
      "monorouter/claude-fable-5":            {},
      "monorouter/claude-opus-4-8":           {},
      "monorouter/claude-opus-4-7":           {},
      "monorouter/claude-sonnet-4-6":         {},
      "monorouter/claude-opus-4-6":           {},
      "monorouter/claude-haiku-4-5-20251001": {}
    }
  }
}
Drop into ~/.openclaw/openclaw.json. Replace apiKey with one of your mrk_* keys. Merge both sections with any existing keys — don't replace the whole file. Restart OpenClaw when done.
guide: set up OpenClaw with MonoRouter · monorouter