freshcrate
Skin:/
Home > AI Agents > ClawRouter

ClawRouter

The agent-native LLM router for OpenClaw. 41+ models, <1ms routing, USDC payments on Base & Solana via x402.

Why this rank:Strong adoptionRecent releaseHealthy release cadence

Description

The agent-native LLM router for OpenClaw. 41+ models, <1ms routing, USDC payments on Base & Solana via x402.

README

ClawRouter Banner

The LLM router built for autonomous agents

Agents can't sign up for accounts. Agents can't enter credit cards.
Agents can only sign transactions.

ClawRouter is the only LLM router that lets agents operate independently.


Agent nativeNo API keysLocal routingx402 USDCOpen sourcenpm versionnpm downloadsGitHub starsCITypeScriptLicense: MITUSDC Hackathon Winnerx402 ProtocolBase NetworkSolanaOpenClaw PluginTelegramClawRouter is an open-source smart LLM router that reduces AI API costs by up to 92%. It analyzes each request across 15 dimensions and routes to the cheapest capable model in under 1ms, entirely locally. ClawRouter is the only LLM router built for autonomous AI agents โ€” it uses wallet signatures for authentication (no API keys) and USDC micropayments via the x402 protocol (no credit cards). 55+ models from OpenAI, Anthropic, Google, xAI, DeepSeek, and more. MIT licensed.


Every other LLM router was built for human developers โ€” create an account, get an API key, pick a model from a dashboard, pay with a credit card.

Agents can't do any of that.

ClawRouter is built for the agent-first world:

  • No accounts โ€” a wallet is generated locally, no signup
  • No API keys โ€” your wallet signature IS authentication
  • No model selection โ€” 15-dimension scoring picks the right model automatically
  • No credit cards โ€” agents pay per-request with USDC via x402
  • No trust required โ€” runs locally, <1ms routing, zero external dependencies

This is the stack that lets agents operate autonomously: x402 + USDC + local routing.


How it compares

OpenRouter LiteLLM Martian Portkey ClawRouter
Models 200+ 100+ Smart routing Gateway 55+
Routing Manual selection Manual selection Smart (closed) Observability Smart (open source)
Auth Account + API key Your API keys Account + API key Account + API key Wallet signature
Payment Credit card BYO keys Credit card $49-499/mo USDC per-request
Runs locally No Yes No No Yes
Open source No Yes No Partial Yes
Agent-ready No No No No Yes

โœ“ Open source ยท โœ“ Smart routing ยท โœ“ Runs locally ยท โœ“ Crypto native ยท โœ“ Agent ready

We're the only one that checks all five boxes.


Quick Start

Option A โ€” OpenClaw Agent

OpenClaw is an AI coding agent. If you're using it, ClawRouter installs as a plugin:

curl -fsSL https://blockrun.ai/ClawRouter-update | bash
openclaw gateway restart

Done. Smart routing (blockrun/auto) is now your default model.

Option B โ€” Standalone (continue.dev, Cursor, VS Code, any OpenAI-compatible client)

Using Claude Code? Check out BRCC โ€” it's purpose-built for Claude Code with the same smart routing and x402 payments.

No OpenClaw required. ClawRouter runs as a local proxy on port 8402.

1. Start the proxy

npx @blockrun/clawrouter

2. Fund your wallet Your wallet address is printed on first run. Send a few USDC on Base or Solana โ€” $5 covers thousands of requests.

3. Point your client at http://localhost:8402

continue.dev โ€” ~/.continue/config.yaml

Important: apiBase must end with /v1/ (including the trailing slash). Without it, continue.dev constructs the URL as /chat/completions instead of /v1/chat/completions, and the proxy returns 404.

models:
  - name: ClawRouter Auto
    provider: openai
    model: blockrun/auto
    apiBase: http://localhost:8402/v1/
    apiKey: x402
    roles:
      - chat
      - edit
      - apply

To pin a specific model, replace blockrun/auto with any model from blockrun.ai/models, e.g. anthropic/claude-opus-4.6, xai/grok-4-0709.

Both provider: openai and provider: clawrouter work โ€” just make sure apiBase ends with /v1/.

Legacy JSON format (~/.continue/config.json)
{
  "models": [
    {
      "title": "ClawRouter Auto",
      "provider": "openai",
      "model": "blockrun/auto",
      "apiBase": "http://localhost:8402/v1/",
      "apiKey": "x402"
    }
  ]
}
Cursor โ€” Settings โ†’ Models โ†’ OpenAI-compatible

Set base URL to http://localhost:8402, API key to x402, model to blockrun/auto.

Any OpenAI SDK
from openai import OpenAI
client = OpenAI(base_url="http://localhost:8402", api_key="x402")
response = client.chat.completions.create(model="blockrun/auto", messages=[...])

Routing Profiles

Choose your routing strategy with /model <profile>:

Profile Strategy Savings Best For
/model auto Balanced (default) 74-100% General use
/model eco Cheapest possible 95-100% Maximum savings
/model premium Best quality 0% Mission-critical

Shortcuts: /model grok, /model br-sonnet, /model gpt5, /model o3


How It Works

100% local routing. <1ms latency. Zero external API calls.

Request โ†’ Weighted Scorer (15 dimensions) โ†’ Tier โ†’ Best Model โ†’ Response
Tier ECO Model AUTO Model PREMIUM Model
SIMPLE nvidia/gpt-oss-120b (FREE) gemini-2.5-flash ($0.30/$2.50) kimi-k2.5
MEDIUM gemini-3.1-flash-lite ($0.25/$1.50) kimi-k2.5 ($0.60/$3.00) gpt-5.3-codex ($1.75/$14.00)
COMPLEX gemini-3.1-flash-lite ($0.25/$1.50) gemini-3.1-pro ($2/$12) claude-opus-4.6 ($5/$25)
REASONING grok-4-1-fast ($0.20/$0.50) grok-4-1-fast-reasoning ($0.20/$0.50) claude-sonnet-4.6 ($3/$15)

Blended average: $2.05/M vs $25/M for Claude Opus = 92% savings


Image Generation

Generate images directly from chat with /imagegen:

/imagegen a dog dancing on the beach
/imagegen --model dall-e-3 a futuristic city at sunset
/imagegen --model banana-pro --size 2048x2048 mountain landscape
Model Provider Price Max Size
nano-banana Google Gemini Flash $0.05/image 1024x1024
banana-pro Google Gemini Pro $0.10/image 4096x4096
dall-e-3 OpenAI DALL-E 3 $0.04/image 1792x1024
gpt-image OpenAI GPT Image 1 $0.02/image 1536x1024
flux Black Forest Flux 1.1 $0.04/image 1024x1024
xai/grok-imagine-image xAI Grok Imagine $0.02/image 1024x1024
xai/grok-imagine-image-pro xAI Grok Imagine Pro $0.07/image 1024x1024
zai/cogview-4 Zhipu CogView-4 $0.015/image 1440x1440

Video Generation

Generate short AI videos via POST http://localhost:8402/v1/videos/generations. ClawRouter proxies the BlockRun gateway, handles x402 payment, and downloads the returned MP4 to local disk โ€” the response url points to http://localhost:8402/videos/<file>.mp4 so the asset survives past xAI's temporary bucket.

curl -X POST http://localhost:8402/v1/videos/generations \
  -H "Content-Type: application/json" \
  -d '{"model":"xai/grok-imagine-video","prompt":"a red apple slowly spinning"}'
Model Provider Price Duration
xai/grok-imagine-video xAI Grok Imagine $0.05/sec 8s default

Calls block for 30โ€“120s while xAI polls the job. Text-to-video and image-to-video (image_url parameter) are both supported.

Image Editing (img2img)

Edit existing images with /img2img:

/img2img --image ~/photo.png change the background to a starry sky
/img2img --image ./cat.jpg --mask ./mask.png remove the background
Option Required Description
--image <path> Yes Local image file path (supports ~/)
--mask <path> No Mask image (white = area to edit)
--model <model> No Model to use (default: gpt-image-1)
--size <WxH> No Output size (default: 1024x1024)

API endpoint: POST http://localhost:8402/v1/images/image2image โ€” see full docs.


Models & Pricing

55+ models across 9 providers, one wallet. Starting at $0.0002/request.

๐Ÿ’ก "Cost per request" = estimated cost for a typical chat message (~500 input + 500 output tokens).

Budget Models (under $0.001/request)

Model Input $/M Output $/M ~$/request Context Features
nvidia/gpt-oss-120b FREE FREE $0 128K
nvidia/gpt-oss-20b FREE FREE $0 128K
nvidia/nemotron-ultra-253b FREE FREE $0 131K reasoning
nvidia/nemotron-3-super-120b FREE FREE $0 131K reasoning
nvidia/nemotron-super-49b FREE FREE $0 131K reasoning
nvidia/deepseek-v3.2 FREE FREE $0 131K reasoning
nvidia/mistral-large-3-675b FREE FREE $0 131K reasoning
nvidia/qwen3-coder-480b FREE FREE $0 131K
nvidia/devstral-2-123b FREE FREE $0 131K
nvidia/glm-4.7 FREE FREE $0 131K reasoning
nvidia/llama-4-maverick FREE FREE $0 131K reasoning
openai/gpt-5-nano $0.05 $0.40 $0.0002 128K tools
openai/gpt-4.1-nano $0.10 $0.40 $0.0003 128K tools
google/gemini-2.5-flash-lite $0.10 $0.40 $0.0003 1M tools
openai/gpt-4o-mini $0.15 $0.60 $0.0004 128K tools
xai/grok-4-fast $0.20 $0.50 $0.0004 131K tools
xai/grok-4-fast-reasoning $0.20 $0.50 $0.0004 131K reasoning, tools
xai/grok-4-1-fast $0.20 $0.50 $0.0004 131K tools
xai/grok-4-1-fast-reasoning $0.20 $0.50 $0.0004 131K reasoning, tools
xai/grok-4-0709 $0.20 $1.50 $0.0009 131K reasoning, tools
openai/gpt-5-mini $0.25 $2.00 $0.0011 200K tools
deepseek/deepseek-chat $0.28 $0.42 $0.0004 128K tools
deepseek/deepseek-reasoner $0.28 $0.42 $0.0004 128K reasoning, tools
xai/grok-3-mini $0.30 $0.50 $0.0004 131K tools
minimax/minimax-m2.7 $0.30 $1.20 $0.0008 205K reasoning, agentic, tools
minimax/minimax-m2.5 $0.30 $1.20 $0.0008 205K reasoning, agentic, tools
google/gemini-2.5-flash $0.30 $2.50 $0.0014 1M vision, tools
openai/gpt-4.1-mini $0.40 $1.60 $0.0010 128K tools
google/gemini-3-flash-preview $0.50 $3.00 $0.0018 1M vision
nvidia/kimi-k2.5 $0.55 $2.50 $0.0015 262K tools
moonshot/kimi-k2.5 $0.60 $3.00 $0.0018 262K reasoning, vision, agentic, tools
moonshot/kimi-k2.6 $0.95 $4.00 $0.0025 262K reasoning, vision, agentic, tools

Mid-Range Models ($0.001โ€“$0.01/request)

Model Input $/M Output $/M ~$/request Context Features
anthropic/claude-haiku-4.5 $1.00 $5.00 $0.0030 200K vision, agentic, tools
zai/glm-5 $1.00 $3.20 $0.0021 200K tools
openai/o1-mini $1.10 $4.40 $0.0028 128K reasoning, tools
openai/o3-mini $1.10 $4.40 $0.0028 128K reasoning, tools
openai/o4-mini $1.10 $4.40 $0.0028 128K reasoning, tools
zai/glm-5-turbo $1.20 $4.00 $0.0026 200K tools
google/gemini-2.5-pro $1.25 $10.00 $0.0056 1M reasoning, vision, tools
openai/gpt-5.2 $1.75 $14.00 $0.0079 400K reasoning, vision, agentic, tools
openai/gpt-5.3 $1.75 $14.00 $0.0079 128K reasoning, vision, agentic, tools
openai/gpt-5.3-codex $1.75 $14.00 $0.0079 400K agentic, tools
openai/gpt-4.1 $2.00 $8.00 $0.0050 128K vision, tools
openai/o3 $2.00 $8.00 $0.0050 200K reasoning, tools
google/gemini-3-pro-preview $2.00 $12.00 $0.0070 1M reasoning, vision, tools
google/gemini-3.1-pro $2.00 $12.00 $0.0070 1M reasoning, vision, tools
xai/grok-2-vision $2.00 $10.00 $0.0060 131K vision, tools
openai/gpt-4o $2.50 $10.00 $0.0063 128K vision, agentic, tools
openai/gpt-5.4 $2.50 $15.00 $0.0088 400K reasoning, vision, agentic, tools

Premium Models ($0.01+/request)

Model Input $/M Output $/M ~$/request Context Features
anthropic/claude-sonnet-4.6 $3.00 $15.00 $0.0090 200K reasoning, vision, agentic, tools
xai/grok-3 $3.00 $15.00 $0.0090 131K reasoning, tools
anthropic/claude-opus-4.6 $5.00 $25.00 $0.0150 200K reasoning, vision, agentic, tools
openai/o1 $15.00 $60.00 $0.0375 200K reasoning, tools
openai/gpt-5.2-pro $21.00 $168.00 $0.0945 400K reasoning, tools
openai/gpt-5.4-pro $30.00 $180.00 $0.1050 400K reasoning, tools

Free tier: 11 models cost nothing โ€” /model free points to nemotron-ultra-253b, or pick any free model directly (e.g., /model nemotron, /model deepseek-free, /model devstral). Best value: gpt-5-nano and gemini-2.5-flash-lite deliver strong results at ~$0.0003/request.


Payment

No account. No API key. Payment IS authentication via x402.

Request โ†’ 402 (price: $0.003) โ†’ wallet signs USDC โ†’ retry โ†’ response

USDC stays in your wallet until spent โ€” non-custodial. Price is visible in the 402 header before signing.

Dual-chain support: Pay with USDC on Base (EVM) or USDC on Solana. Both wallets are derived from a single BIP-39 mnemonic on first run.

/wallet              # Check balance and address (both chains)
/wallet export       # Export mnemonic + keys for backup
/wallet recover      # Restore wallet from mnemonic on a new machine
/wallet solana       # Switch to Solana USDC payments
/wallet base         # Switch back to Base (EVM) USDC payments
/chain solana        # Alias for /wallet solana
/stats               # View usage and savings
/stats clear         # Reset usage statistics
/exclude             # Show excluded models
/exclude add <model> # Block a model from routing (aliases work: "grok-4", "free")
/exclude remove <model> # Unblock a model
/exclude clear       # Remove all exclusions

Fund your wallet:

  • Base (EVM): Send USDC on Base to your EVM address
  • Solana: Send USDC on Solana to your Solana address
  • Coinbase/CEX: Withdraw USDC to either network
  • Credit card: Reach out to @bc1max on Telegram

Screenshots

Smart Routing in Action

ClawRouter savings
Telegram Integration

Telegram demo

Configuration

For basic usage, no configuration needed. For advanced options:

Variable Default Description
BLOCKRUN_WALLET_KEY auto-generated Your wallet private key
BLOCKRUN_PROXY_PORT 8402 Local proxy port
CLAWROUTER_DISABLED false Disable smart routing
CLAWROUTER_SOLANA_RPC_URL https://api.mainnet-beta.solana.com Solana RPC endpoint

Full reference: docs/configuration.md

Model Exclusion

Block specific models from being routed to. Useful if a model doesn't follow your agent instructions or you want to control costs.

/exclude add nvidia/gpt-oss-120b   # Block the free model
/exclude add grok-4                # Aliases work โ€” blocks all grok-4 variants
/exclude add gpt-5.4               # Skip expensive models
/exclude                           # Show current exclusions
/exclude remove grok-4             # Unblock a model
/exclude clear                     # Remove all exclusions

Exclusions persist across restarts (~/.openclaw/blockrun/exclude-models.json). If all models in a tier are excluded, the safety net ignores the filter so routing never breaks.


Troubleshooting

When things go wrong, run the doctor:

npx @blockrun/clawrouter doctor

This collects diagnostics and sends them to Claude Sonnet for AI-powered analysis:

๐Ÿฉบ BlockRun Doctor v0.12.24

System
  โœ“ OS: darwin arm64
  โœ“ Node: v20.11.0

Wallet
  โœ“ Address: 0x1234...abcd
  โœ“ Balance: $12.50

Network
  โœ“ BlockRun API: reachable (142ms)
  โœ— Local proxy: not running on :8402

๐Ÿ“ค Sending to Claude Sonnet 4.6 (~$0.003)...

๐Ÿค– AI Analysis:
The local proxy isn't running. Run `openclaw gateway restart` to fix.

Use Opus for complex issues:

npx @blockrun/clawrouter doctor opus

Ask a specific question:

npx @blockrun/clawrouter doctor "why is my request failing?"
npx @blockrun/clawrouter doctor opus "ๆทฑๅบฆๅˆ†ๆžๆˆ‘็š„้…็ฝฎ"

Cost: Sonnet ~$0.003 (default) | Opus ~$0.01


Development

git clone https://github.com/BlockRunAI/ClawRouter.git
cd ClawRouter
npm install
npm run build
npm test

Support

Channel Link
๐Ÿ“… Schedule Demo calendly.com/vickyfu9/30min
๐Ÿ’ฌ Community Telegram t.me/blockrunAI
๐Ÿฆ X / Twitter x.com/blockrunai
๐Ÿ“ฑ Founder Telegram @bc1max
โœ‰๏ธ Email vicky@blockrun.ai

From the BlockRun Ecosystem

โšก ClawRouter

The LLM router built for autonomous agents

You're here. 55+ models, local smart routing, x402 USDC payments โ€” the only stack that lets agents operate independently.

curl -fsSL https://blockrun.ai/ClawRouter-update | bash

๐Ÿค– BRCC

BlockRun for Claude Code

Run Claude Code with 50+ models, no rate limits, no Anthropic account, no phone verification. Pay per request with USDC โ€” your wallet is your identity.

curl -fsSL https://blockrun.ai/brcc-install | bash


More Resources

Resource Description
Documentation Full docs
Model Pricing All models & prices
Image Generation & Editing API examples, 5 models
Routing Profiles ECO/AUTO/PREMIUM details
Architecture Technical deep dive
Configuration Environment variables
Troubleshooting Common issues

Blog

Article Topic
11 Free AI Models, Zero Cost How BlockRun gives developers top-tier LLMs for nothing
ClawRouter Cuts LLM API Costs 500ร— Deep dive into cost savings
ClawRouter vs OpenRouter Head-to-head comparison
Smart LLM Router: 14-Dimension Classifier How the routing engine works
LLM Router Benchmark: 46 Models, Sub-1ms Performance benchmarks
Anthropic Cost Savings Reducing Claude API spend

Frequently Asked Questions

What is ClawRouter?

ClawRouter is an open-source (MIT licensed) smart LLM router built for autonomous AI agents. It analyzes each request across 15 dimensions and routes to the cheapest capable model in under 1ms, entirely locally โ€” no external API calls needed for routing decisions.

How much can ClawRouter save on LLM costs?

ClawRouter's blended average cost is $2.05 per million tokens compared to $25/M for Claude Opus, representing 92% savings. Actual savings depend on your workload โ€” simple queries are routed to free models ($0/request), while complex tasks get premium models.

How does ClawRouter compare to OpenRouter?

ClawRouter is open source and runs locally. It uses wallet-based authentication (no API keys) and USDC per-request payments (no credit cards or subscriptions). OpenRouter requires an account, API key, and credit card. ClawRouter also features smart routing โ€” it automatically picks the best model for each request, while OpenRouter requires manual model selection.

How does ClawRouter compare to LiteLLM?

Both are open source and run locally. But ClawRouter adds smart routing (automatic model selection), wallet-based auth, and USDC payments. LiteLLM requires you to bring your own API keys and manually choose models.

What agents does ClawRouter work with?

ClawRouter works with any tool that makes OpenAI-compatible API calls โ€” point it at http://localhost:8402. This includes continue.dev, Cursor, VS Code extensions, ElizaOS, and custom agents. It also integrates as a plugin with OpenClaw (an AI coding agent), which enables additional features like slash commands and usage reports.

Is ClawRouter free?

ClawRouter itself is free and MIT licensed. You pay only for the LLM API calls routed through it โ€” and 11 models (DeepSeek V3.2, Nemotron Ultra 253B, Mistral Large 675B, Llama 4 Maverick, and more) are completely free. Use /model free for Nemotron Ultra 253B, or pick any free model by name.


MIT License ยท BlockRun โ€” Agent-native AI infrastructure

โญ If ClawRouter powers your agents, consider starring the repo!

Release History

VersionChangesUrgencyDate
v0.12.196 - **Updater recovers from OpenClaw size-drop rejection.** OpenClaw v2026.4.5+ refuses to write a config that would shrink the file by a large amount (data-loss guard). Users on a pre-v0.12.175 install carry ~175 entries in `models.providers.blockrun.models`; upgrading to a current ClawRouter legitimately trims that to ~38 (โ‰ˆ90 KB โ†’ 25 KB), tripping OpenClaw's guard. The updater previously surfaced this as a hard failure and rolled back, stranding users on the old version. Fix in `scripts/updateHigh5/24/2026
v0.12.194## v0.12.194 โ€” May 18, 2026 - **Seedance video pricing aligned with blockrun's token-priced model.** Last week blockrun replaced the flat per-second Seedance pricing with `duration ร— tokens/sec ร— $/1M tokens ร— 1.05 margin` after a verification call against `bytedance/seedance-2.0-fast` measured 10,128 tokens/sec at 480p (token360's default, not the 720p we'd guessed). The old ClawRouter `VIDEO_PRICING` table was both wrong-shaped and ~3โ€“4ร— off on the high side. Updated `src/proxy.ts`: - `VIDEHigh5/18/2026
v0.12.190## Fix Renames the `/imagegen` slash command to `/cr-imagegen` to resolve a collision with Telegram channel commands. OpenClaw runtime previously emitted: ``` Plugin command "/imagegen" conflicts with an existing Telegram command ``` because Telegram channels reserve `/imagegen` for their own image-gen bots (HuggingFace Spaces et al.). The OpenClaw command registry can't claim the same prefix without inconsistent routing behavior in Telegram. ## What changed - `src/index.ts:1768` โ€” `api.reHigh5/13/2026
v0.12.185## v0.12.185 โ€” May 4, 2026 - **`clawrouter setup` โ€” new CLI command for users who installed via bare `npm install -g`.** A user reported `/models` in their Telegram bot showing only 7 entries despite having `@blockrun/clawrouter@0.12.184` installed and the gateway restarted. Investigation: bare `npm install -g @blockrun/clawrouter` puts the package on disk and adds the `clawrouter` binary to PATH but performs **zero** OpenClaw integration โ€” no `plugins.entries.clawrouter` registration, no modelHigh5/4/2026
v0.12.171## v0.12.171 โ€” Apr 29, 2026 - **Three new free NVIDIA-hosted models added.** BlockRun refreshed the free catalog on 2026-04-29 with three additions, all wired into ClawRouter as `free/`-prefixed entries: - `free/deepseek-v4-pro` โ€” 1.6T MoE / 49B active, 1M context, MMLU-Pro 87.5, GPQA 90.1, SWE-bench 80.6, LiveCodeBench 93.5. NIM ~150 tok/s on Blackwell. Strongest free reasoning model. - `free/deepseek-v4-flash` โ€” 284B / 13B active MoE, 1M context, ~5x faster than v4-pro. Strong on chat/sumHigh4/30/2026
v0.12.161 - **De-Gemini the Anthropic-primary fallback chains.** When Anthropic hiccups (503s, capacity), Gemini's own "high demand" 503s correlate with the same events โ€” agents fall back from Claude to Gemini together, both overloaded. Reordered `src/router/config.ts` fallback arrays in the two places Anthropic sits primary: `premiumTiers.COMPLEX` (claude-opus-4.7 primary) and `agenticTiers.COMPLEX` (claude-sonnet-4.6 primary). New order: in-family Anthropic hot swap (opus-4.6 / sonnet-4.6) โ†’ xAI Grok (High4/22/2026
v0.12.159 - **Market data tools** โ€” BlockRun gateway now exposes realtime and historical market data; ClawRouter wires them into OpenClaw as 6 first-class agent tools so the model stops scraping finance sites. Paid ($0.001 via x402, same wallet as LLM calls): `blockrun_stock_price` and `blockrun_stock_history` across **12 global equity markets** (US, HK, JP, KR, UK, DE, FR, NL, IE, LU, CN, CA). Free (no x402 charge): `blockrun_stock_list` (ticker lookup / company-name search), `blockrun_crypto_price` (BTHigh4/21/2026
v0.12.158- **SKILL.md data-flow + key-storage transparency** โ€” second-pass fix for the OpenClaw scanner on clawhub.ai. v0.12.157 cleared the original scanner flags (opaque credentials, implied multi-provider keys, no install artifact). A deeper rescan surfaced three new nuanced flags: prompts go to blockrun.ai (data-privacy framing), wallet private-key storage location/encryption undocumented, and users may expect strictly-local routing. All three addressed: description reframed as "Hosted-gateway LLM roHigh4/20/2026
v0.12.157- **SKILL.md credential transparency** โ€” rewrote `skills/clawrouter/SKILL.md` to clear the OpenClaw scanner's medium-confidence suspicious verdict on clawhub.ai. Frontmatter now declares `repository: https://github.com/BlockRunAI/ClawRouter`, `license: MIT`, and a structured `metadata.openclaw.install` array (`kind: node`, `package: @blockrun/clawrouter`, `bins: [clawrouter]`) so the registry entry has an auditable install artifact instead of a bare bash block. Body adds a **Credentials & Data HHigh4/20/2026
v0.12.156## v0.12.156 โ€” Apr 20, 2026 - **Kimi K2.6 added** โ€” Moonshot's new flagship (`moonshot/kimi-k2.6`, 256K context, vision + reasoning, $0.95 in / $4.00 out per 1M) registered in `BLOCKRUN_MODELS` with `kimi-k2.6` alias. Added to the curated `/model` picker list (`src/index.ts`, `scripts/update.sh`, `scripts/reinstall.sh`), the README pricing table, `docs/routing-profiles.md`, and the AI-agent-facing model catalog in `skills/clawrouter/SKILL.md`. Premium routing tier (`blockrun/premium`) now uses High4/20/2026
v0.12.149### Bug Fix - **Suppress remaining duplicate startup logs** โ€” The v0.12.147 fix only guarded provider registration logs. This release extends the guard to cover all repeated diagnostic messages on multi-call `register()`: - "Proxy already started by earlier register() call โ€” skipping" (main offender, fired on every call after proxy start) - "pluginConfig empty โ€” deferring proxy startup 250ms..." - Non-gateway wallet source logs + "Not in gateway mode" ### Improvements - **Explicit-pin mHigh4/13/2026
v0.12.148### Bug Fixes **Suppress duplicate registration log spam.** OpenClaw calls \`register()\` 4+ times per gateway startup. Each call re-registers providers, commands, and tools (idempotent โ€” last loaded plugin wins) but previously also logged 6 info lines per call, producing 24+ identical lines on every startup. Now only the first \`register()\` call emits verbose info logs. Subsequent calls silently re-register without logging. **Before:** \`\`\` Commands registered: /wallet, /blockrun, /stats,Medium4/12/2026
v0.12.146### New Feature **Every routed response now carries a \`usage.cost\` breakdown.** Users on \`blockrun/auto\` previously had no visible signal of which model actually answered or how much each call cost. Now every response includes: \`\`\`json { \"model\": \"google/gemini-2.5-flash\", \"usage\": { \"prompt_tokens\": 120, \"completion_tokens\": 80, \"total_tokens\": 200, \"cost\": { \"total\": 0.00023, \"input\": 0.000018, \"output\": 0.000048, \"baseHigh4/10/2026
v0.12.145### Improvements - **eco/premium null fallback** (router/strategy.ts): when \`ecoTiers\` or \`premiumTiers\` is set to \`null\`, fall back to regular \`tiers\` instead of dropping into auto routing. Preserves the eco/premium profile semantics even when the special tier set is disabled. - **provider.ts**: \`setActiveProxy\` now accepts \`null\` (used by the deactivate path). - **debug-command test**: 2s client-side timeout so the test no longer hangs on slow upstream. - **CI green**: prettier foMedium4/10/2026
v0.12.144### Bug Fixes **\`/model\` command now actually switches the model.** When a user ran \`/model blockrun/free/glm-4.7\` in OpenClaw, the bot's next response often still claimed to be the previously pinned model (typically Sonnet). The model wasn't really switching โ€” it was being silently overridden by ClawRouter's session pinning, which was designed to prevent mid-task model switching but was too aggressive. ### What changed - \`SessionEntry\` now carries a \`userExplicit\` flag. - When ClawRMedium4/10/2026
v0.12.143### Chore Prettier formatting fix in \`src/web-search-provider.ts\` and \`src/web-search-provider.test.ts\` to keep CI green. No functional changes.Medium4/10/2026
v0.12.142### Bug Fixes (#147) **User routing config in openclaw.json was silently ignored.** OpenClaw calls \`register()\` twice during gateway startup. The first call runs in a pre-gateway phase before \`openclaw.json\` has been parsed, so \`api.pluginConfig\` is empty. The previous \`proxyAlreadyStarted\` guard caused the proxy to start with \`DEFAULT_ROUTING_CONFIG\` on that first call, then the second call (the one with the user's actual \`plugins.entries.clawrouter.config.routing\`) bailed out as Medium4/10/2026
v0.12.141### Bug Fixes (#148) Fixes two related bugs that prevented users from customizing agent routing via \`routingConfig\`: 1. **Custom tier sets weren't merged.** \`mergeRoutingConfig\` only deep-merged \`tiers\`, ignoring \`agenticTiers\`, \`ecoTiers\`, and \`premiumTiers\`. Users defining custom \`agenticTiers\` had no effect on routing โ€” agent requests always used the defaults. 2. **\`overrides.agenticMode: false\` didn't disable agentic tiers.** \`hasToolsInRequest\` was OR'ed in unconditionaMedium4/10/2026
v0.12.140### Bug Fixes - **Fix doctor on Solana chain** โ€” `npx @blockrun/clawrouter doctor` was hardcoding an EVM signer and sending test requests to `blockrun.ai` regardless of the user's configured payment chain. On Solana users, it produced a misleading \`Payment verification failed\` error showing an EVM payer address that didn't match their actual Solana wallet. Now doctor registers the Solana scheme and routes to \`sol.blockrun.ai\` when \`paymentChain=solana\`.Medium4/10/2026
v0.12.139### Bug Fixes - **Fix baseUrl overwrite after plugin install** โ€” OpenClaw's async config persistence was overwriting the correct local proxy URL (`127.0.0.1:8402`) with the remote `blockrun.ai/api` fallback. Root cause: `provider.ts` models getter returned the remote URL before proxy startup; OpenClaw serialized that into `openclaw.json`. Now always returns the local proxy URL. (reported by Cheetah) - **Post-install baseUrl verification** โ€” `update.sh` and `reinstall.sh` now re-verify and fix `Medium4/9/2026
v0.12.92## Bug Fix: Existing chat always fails in continue.dev (#135) ### Root cause `moonshot/kimi-k2.5` (primary MEDIUM-tier model in `blockrun/auto`) is a reasoning model that requires `reasoning_content` on **all** assistant messages in multi-turn history โ€” not just tool-call messages. When continue.dev sent an existing chat, the plain-text assistant message from the previous turn was missing `reasoning_content`, causing a 400 from the model. Since that 400 didn't match any `PROVIDER_ERROR_PATTERMedium3/31/2026
v0.12.90## What's Fixed ### Empty turn responses now trigger model fallback **Problem:** Under the eco profile (and sometimes auto), agentic clients like Roo Code would receive silent empty responses โ€” the model returned HTTP 200 with no content and no tool calls, just `finish_reason: stop`. The proxy treated this as success and forwarded the empty turn to the client, causing the agent to loop or stall. **Root cause:** Models like `gemini-3.1-flash-lite` sometimes refuse complex agentic requests (larMedium3/31/2026
v0.12.87Release v0.12.87Medium3/30/2026
v0.12.70### Fixed - **Plugin crash on string model config** โ€” ClawRouter crashed during OpenClaw plugin registration with `TypeError: Cannot create property 'primary' on string 'blockrun/auto'`. This happened when `agents.defaults.model` in the OpenClaw config was a plain string instead of the expected object `{ primary: "blockrun/auto" }`. Now auto-converts string/array/non-object model values to the correct object form. ### Install / Update ```bash npm i -g @blockrun/clawrouter@latest ```Medium3/24/2026
v0.12.69## What's Changed ### โœจ Features - feat: add GPT-5.4 Nano + Gemini 3.1 Flash Lite, SOLโ†’USDC swap hint - feat: GEO optimize README with definition and FAQ section ### ๐Ÿ› Bug Fixes - fix: config duplication on update โ€” full model allowlist reconciliation (#112) - fix: /stats under-reporting costs โ€” use actual x402 payment amounts - fix: save npm install error log to ~/clawrouter-npm-install.log - fix: remove redundant deprecated models list from reinstall step 2 - fix: sync package-lock.json (miMedium3/23/2026
v0.12.66## Bug Fixes **Fix: payment settlement failure now falls back to free model** When payment settlement fails on-chain (insufficient funds, simulation failure), ClawRouter now skips all remaining paid models and falls back to `nvidia/gpt-oss-120b` (free). Previously, payment settlement errors returned non-standard HTTP codes that weren't recognized as provider errors, so the fallback loop broke immediately with "Payment settlement failed" โ€” even though the free model was available. **Fix: pre-aLow3/21/2026
v0.12.65## Bug Fix **Fix: payment error when using free model** โ€” The pre-auth cache keyed on URL path alone, so cached payment requirements from a paid model (e.g. sonnet) would be applied to `nvidia/gpt-oss-120b`. Users switching to free model with an empty wallet got payment errors even though the server never charged for free requests. Cache key now includes model ID. ``` npm install -g @blockrun/clawrouter@0.12.65 ```Low3/21/2026
v0.12.64## What's New ### Cost Visibility & Routing Transparency - **Cost headers on every response**: `x-clawrouter-cost` and `x-clawrouter-savings` show per-request cost and savings percentage - **SSE cost comment**: Streaming responses include a cost summary before `[DONE]` - **Model field injection**: SSE chunks and non-streaming responses now show the actual routed model (not the upstream provider's name) ### Improved Error Handling - **Structured fallback error**: When all models fail, error mesLow3/21/2026
v0.12.56- Add `zai/glm-5` and `zai/glm-5-turbo` models to model picker - Aliases: `glm`, `glm-5`, `glm-5-turbo`Low3/17/2026
v0.12.30Release v0.12.30Low3/10/2026
v0.12.25 - **Image generation docs** โ€” new `docs/image-generation.md` with API reference, curl/TypeScript/Python/OpenAI SDK examples, model pricing table, and `/imagegen` command reference - **Comprehensive docs refresh** โ€” architecture updated for dual-chain (Base + Solana), configuration updated with all env vars (`CLAWROUTER_SOLANA_RPC_URL`, `CLAWROUTER_WORKER`), troubleshooting updated for USDC-on-Solana funding, CHANGELOG backfilled for v0.11.14โ€“v0.12.24Low3/9/2026
v0.12.24 - **Preserve user-defined blockrun/* allowlist entries** โ€” `injectModelsConfig()` no longer removes user-added `blockrun/*` allowlist entries on gateway restartsLow3/8/2026
v0.12.10## What's New ### `/stats clear` โ€” Reset usage statistics Users can now wipe all local usage logs and start fresh: - **`/stats clear`** (or `/stats reset`) โ€” deletes all `usage-*.jsonl` log files and confirms how many were removed - **`DELETE /stats`** HTTP endpoint โ€” programmatic access for the same operation, returns `{ cleared: true, deletedFiles: N }` These are local usage tracking files only โ€” billing records on BlockRun's server are unaffected. ### Use cases - Clean metrics after testLow3/6/2026
v0.12.9### Fix: Gemini 3 models break tool calling (#73) - Removed `toolCalling` from `google/gemini-3-flash-preview` โ€” this model returns empty responses on tool calls, so it's now excluded from tool-heavy routing entirely - Added `google/gemini-3-pro-preview` and `google/gemini-3.1-pro` to `TOOL_NONCOMPLIANT_MODELS` โ€” these models return tool JSON as plain text instead of structured `tool_calls`, so they're deprioritized when better alternatives exist in the fallback chainLow3/6/2026
v0.12.8## New Models - **GPT-5.4** (`openai/gpt-5.4`) โ€” $2.50/$15 per 1M tokens, 400K context, reasoning + vision + agentic + tool calling - **GPT-5.4 Pro** (`openai/gpt-5.4-pro`) โ€” $30/$180 per 1M tokens, 400K context, reasoning + tool calling ## Aliases - `gpt5` now points to `openai/gpt-5.4` (was 5.2) - New: `gpt-5.4`, `gpt-5.4-pro` ## Smart Router Updates - **Auto COMPLEX**: GPT-5.4 replaces GPT-5.2 as fallback (newer, same price tier) - **Premium COMPLEX**: GPT-5.4 added as fallback option - Low3/6/2026
v0.12.5### Bug Fix - **Force agentic tiers when tools are present in API request** โ€” OpenClaw (and other agentic clients) always send tools in their API requests, but the router only checked prompt keywords to decide whether to use agentic-capable models. Simple prompts like "create a markdown file" scored too low on keyword detection and got routed to cheaper models that don't handle tool use reliably (the "model just talks instead of creating files" bug). Now when the request contains tools, agenticLow3/4/2026
v0.12.4### Bug Fix - **Fix Solana wallet migration missing signatures** โ€” `signTransactionMessageWithSigners` was producing unsigned transactions because only plain `Address` strings were in the instruction account metas. Added `addSignersToTransactionMessage` to bind both the fee payer (new wallet) and token transfer authority (old wallet) before signing. Fixes "Transaction is missing signatures for addresses" error on `/wallet migrate-solana`.Low3/4/2026
v0.12.3## Fixes - **[P1] Multi-account sweep**: Transfer from each USDC token account individually instead of accumulating balance but only keeping the last account โ€” fixes failure when USDC is split across multiple accounts - **[P2] Partial file reads**: `fs-read` now loops until all bytes are consumed, respecting `bytesRead` return value - **[P3] JSONL resilience**: Stats parser skips malformed lines instead of dropping all entries when one line fails **Full Changelog**: https://github.com/BlockRunLow3/4/2026
v0.12.2## Fix: Correct SPL Token Program ID in migration sweep The `TOKEN_PROGRAM` constant in `solana-sweep.ts` had an invalid address (`TokenkegQfeN4jV6bme4LphiJbfPe2VopRsimuVSoZ5K`) that decoded to 33 bytes instead of the required 32, causing the sweep to fail with: > Expected base58 encoded address to decode to a byte array of length 32. Actual length: 33. Fixed to the correct SPL Token Program address: `TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA` **Full Changelog**: https://github.com/BlockRuLow3/4/2026
v0.12.1## Fix: New wallet pays gas for migration sweep When migrating from the old (BIP-32 secp256k1) Solana wallet to the new (SLIP-10 Ed25519) wallet, the **new wallet now funds the gas** for the sweep transaction. Previously the old wallet was expected to pay gas, but users can't access the old wallet from Phantom to top up SOL โ€” making migration impossible if the old wallet had zero SOL balance. **Full Changelog**: https://github.com/BlockRunAI/ClawRouter/compare/v0.12.0...v0.12.1Low3/4/2026
v0.12.0## Breaking Change: Solana Wallet Derivation Fixed **Existing Solana wallets will derive a different address.** Run `/wallet migrate-solana` to sweep funds from old โ†’ new wallet. ### What Changed The Solana key derivation was using **secp256k1 BIP-32** (`@scure/bip32` HDKey), but all Solana wallets (Phantom, Solflare, Backpack) use **SLIP-10 Ed25519**. Same mnemonic + same path (`m/44'/501'/0'/0'`) + different elliptic curve = completely different address. **Before:** Mnemonic recovery in PhLow3/4/2026
v0.10.18## Problem v0.10.17 pinned the session to the **routing decision** (primary model), not the **actual model used**. When the primary was rate-limited and fell back to gemini-flash: - Session pinned to kimi-k2.5 (the routing decision) - Next request: session says kimi-k2.5 โ†’ rate-limited again โ†’ falls back to gemini-flash again - Conversation stayed stuck in a retry-and-fallback loop ## Fix After the fallback loop resolves \`actualModelUsed\`, update the session pin to the actual responding moLow2/27/2026
v0.10.17## Problem Users in group chats reported models constantly jumping back to \`gemini-flash\`, even after setting a primary model in the dashboard. Each message was being re-routed from scratch. ## Root Cause Two bugs working together: 1. **Session persistence was disabled by default** โ€” \`SessionStore\` had \`enabled: false\`, so model pinning never activated 2. **No session ID without the header** โ€” \`getSessionId()\` only read the \`x-session-id\` header. OpenClaw sends no such header, so eLow2/27/2026
v0.10.15## feat: `toolCalling` capability flag + routing filter ### Why v0.10.14 was directionally correct but incomplete v0.10.14 removed `grok-code-fast-1` from tier configs. That stopped the immediate bleeding, but the root cause remained: ClawRouter had no mechanism to *prevent* incompatible models from entering the routing chain when a request includes tool schemas. Any future model added to tier configs with the same issue would cause the same bug. ### What v0.10.15 adds A `toolCalling` capabiLow2/26/2026
v0.10.14## Fix: Replace grok-code-fast-1 with kimi-k2.5 in MEDIUM routing tiers ### Problem Multiple users reported that ClawRouter was "talking to itself" โ€” showing raw JSON like `{"command":"..."}` as visible chat messages instead of silently executing tool calls. A large error block would sometimes appear in the chat as a result. **Root cause:** `xai/grok-code-fast-1` (Grok Code Fast) does not properly handle OpenClaw's function call format. When given tool schemas, it outputs tool invocations as Low2/26/2026
v0.10.13## Fix: make `register()` synchronous for OpenClaw compatibility **Reported by:** @KevinkeVarson in #56 โ€” thank you for the detailed reproduction steps and version bisect\! ### Problem After upgrading from `0.10.10` to `0.10.12`, OpenClaw logs: ``` [gateway] [plugins] plugin register returned a promise; async registration is ignored (plugin=clawrouter, source=~/.openclaw/extensions/clawrouter/dist/index.js) ``` Routing never initializes โ€” `blockrun/auto` and all BlockRun models stop workingLow2/26/2026
v0.10.12## Fix: Score all keyword dimensions against user text only **Reported by:** @Machiel692 in #50 โ€” thank you for the exceptionally detailed bug report and follow-up testing! ### Problem When ClawRouter is used as an OpenClaw plugin, the system prompt (~6,000 tokens with 20+ tool definitions) contains keywords that match nearly every scoring dimension. This caused **all requests to score identically (~0.47)** regardless of user intent, making `blockrun/auto` routing completely non-functional. Low2/26/2026
v0.10.11## What's New ### Routing Debug Headers Added `x-clawrouter-*` response headers that expose the full routing decision for every request โ€” making it easy to see exactly which profile, tier, model, and scoring was used. **Debug mode is ON by default.** To disable, send `x-clawrouter-debug: false` header. #### Non-streaming responses Returns these HTTP response headers: | Header | Example | Description | |--------|---------|-------------| | `x-clawrouter-profile` | `eco`, `auto`, `premium` | Low2/26/2026
v0.10.10# ClawRouter v0.10.9 โ€” Fix Agentic Mode False Trigger (Auto Mode Routing to Sonnet) **Release Date:** 2026-02-24 --- ## ๐Ÿ› Bug Fix: `blockrun/auto` no longer routes all requests to Sonnet **Root cause:** `agenticScore` was computed from `systemPrompt + userPrompt` combined text. Coding assistant system prompts (e.g., OpenClaw's) contain words like "edit files", "fix bugs", "check", "verify", "deploy", "make sure" โ€” matching 3+ agentic keywords and triggering agentic mode (`agenticScore โ‰ฅ 0.6Low2/25/2026
v0.10.9# ClawRouter v0.10.9 โ€” Fix x402 Payment Verification Failures **Release Date:** 2026-02-24 --- ## ๐Ÿ› Bug Fixes: x402 Payment Reliability Three root causes behind intermittent "Payment verification failed" errors, all in ClawRouter's local pre-processing logic. The BlockRun server was working correctly throughout. ### Fix 1: Payment failures no longer silently surface to users ClawRouter checks errors against `PROVIDER_ERROR_PATTERNS` to decide whether to retry with a fallback model. `"PaymLow2/25/2026
v0.10.8# ClawRouter v0.10.8 โ€” Fix Partner Tool OpenClaw API Contract **Release Date:** 2026-02-24 --- ## ๐Ÿ› Bug Fix: Partner Tools Now Work Correctly in OpenClaw Three API contract mismatches between ClawRouter and OpenClaw's tool execution interface, discovered and reported by a user. ### Bug 1: `inputSchema` โ†’ `parameters` OpenClaw expects tool parameter schema under the key `parameters`, but ClawRouter was using `inputSchema`. The model had no way to know how to pass arguments. ### Bug 2: `exLow2/24/2026
v0.10.7# ClawRouter v0.10.7 โ€” Partner Tool Fixes & Wallet Safety **Release Date:** 2026-02-24 --- ## ๐ŸŽ‰ Highlights - โœ… **Partner tool now triggers reliably** โ€” AI will always call `blockrun_x_users_lookup` instead of answering from memory - โœ… **Baseline cost calculation fixed** โ€” savings % now computed correctly against `claude-opus-4.6` - โœ… **Wallet safety hardened** โ€” corrupted wallet file throws instead of silently overwriting --- ## ๐Ÿ”ง Fixes ### Fix: Partner tool description uses directive lLow2/24/2026
v0.10.6## Partner API Integration ClawRouter now supports partner APIs through the same wallet โ€” zero extra setup. First partner: **AttentionVC** (Twitter/X user intelligence). ### How it works ``` Agent โ†’ ClawRouter proxy โ†’ x402 payment โ†’ BlockRun API โ†’ AttentionVC โ†’ Twitter/X data ``` Your existing funded wallet handles payment automatically. Partner API calls route to `/v1/x/*` and `/v1/partner/*` through a new simplified proxy path (no smart routing, SSE, or compression โ€” just forward + pay). Low2/24/2026
v0.10.1## ๐Ÿฉบ New Feature: `blockrun doctor` AI-powered diagnostics when things go wrong. Collects system info and sends to Claude Opus 4.6 for analysis. ### Usage ```bash # Run automatic diagnostics npx @blockrun/clawrouter doctor # Ask a specific question npx @blockrun/clawrouter doctor "why is my request failing?" ``` ### What it checks - **System**: OS, Node version, memory - **Wallet**: Key exists, balance, low balance warning - **Network**: BlockRun API reachability, local proxy status - **LLow2/22/2026
v0.10.0# ClawRouter v0.10.0 - Full OpenClaw 2026.2.21 Alignment **Release Date:** 2026-02-21 --- ## ๐ŸŽ‰ Highlights - โœ… **Claude 4.6** - Using newest Sonnet 4.6 and Opus 4.6 models - โœ… **Gemini 3.1 Pro Preview** - Newest Gemini model now available - โœ… **Gemini 2.5 Flash Lite** - #2 most popular model on OpenRouter (16.8% of traffic!) - โœ… **7 New Models** - Total now 41 models (was 34) - โœ… **67% Cheaper ECO Tier** - Flash Lite dramatically reduces costs - โœ… **Fixed 5 Pricing Errors** - 15-30% better rLow2/21/2026
v0.9.39## Features - **Context Usage Headers**: Added `x-context-used-kb` and `x-context-limit-kb` response headers to help track token/context usage per request ## Fixes - **Model Selection**: Fixed issue where ClawRouter was hijacking user model selection, forcing `blockrun/auto` even when users explicitly selected other providers (#14) ## Improvements - **Auto Routing**: Removed Minimax models from auto/eco/agentic fallback chains as they don't support tool calling. Users can still explicitly sLow2/21/2026

Dependencies & License Audit

Loading dependencies...

Similar Packages

@robota-sdk/agent-coreComplete AI agent implementation with unified core and tools functionality - conversation management, plugin system, and advanced agent featuresmain@2026-06-05
tweetsave-mcp๐Ÿ“ Fetch Twitter/X content and convert it into blog posts using the MCP server for seamless integration and easy content management.main@2026-06-01
claude-memA Claude Code plugin that automatically captures everything Claude does during your coding sessions, compresses it with AI (using Claude's agent-sdk), and injects relevant context back into future sesv13.4.0
gatewayThe only fully local production-grade Super SDK that provides a simple, unified, and powerful interface for calling more than 200+ LLMs.v1.11.23
magi-markdownMAGI: Markdown for Agent Guidance & Instruction - A next-generation markdown extension designed specifically for AI systems. MAGI enhances standard markdown with structured metadata, embedded AI instrv1.0.0-rc.4

More in AI Agents

@blockrun/franklinFranklin โ€” The AI agent with a wallet. Spends USDC autonomously to get real work done. Pay per action, no subscriptions.
hermes-agentThe agent that grows with you
awesome-copilotCommunity-contributed instructions, agents, skills, and configurations to help you make the most of GitHub Copilot.
e2bE2B SDK that give agents cloud environments