ClawRouter is a local service that chooses among language models for each request and handles payment for their use. Autonomous agents use it to access multiple LLM providers through one routing and billing system.
Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add BlockRunAI/ClawRouter --skill polymarket-tradinggit clone --depth 1 https://github.com/BlockRunAI/ClawRouterWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/blockrunai/clawrouter/polymarket-trading)<a href="https://agentmods.dev/skills/blockrunai/clawrouter/polymarket-trading"><img src="https://agentmods.dev/badge/skills/blockrunai/clawrouter/polymarket-trading.svg" alt="Measured on agentmods" height="20"></a>- NVIDIA SkillSpector pass
What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00076 | $0.01538 |
| Opus 5 | $0.00038 | $0.00769 |
| Sonnet 5 | $0.00015 | $0.00308 |
| Haiku 4.5 | $0.00008 | $0.00154 |
Grade A, and why
polymarket-trading scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 8d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 111 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Polymarket Trading (blockrun_polymarket)
Real-money trading on Polymarket's CLOB V2 (Polygon), signed locally by the
user's ClawRouter wallet key. Data discovery stays on the
blockrun_predexon_* tools — blockrun_polymarket only trades.
Mental model
- Signer = the ClawRouter wallet key (
~/.openclaw/blockrun/wallet.key, orBLOCKRUN_WALLET_KEY) — the SAME wallet that pays for LLM calls. Never leaves the machine. - Deposit wallet = a Polygon vault contract derived from that key (POLY_1271). It holds the betting funds in pUSD and only honors the signer's EIP-712 signatures. Deploy/approve/redeem are gasless (relayer).
- Money separation: bets spend pUSD on Polygon; x402 API fees spend USDC on
Base — but both come from the ONE ClawRouter wallet. The x402 budget ledger
does NOT cover bets —
confirm:true+ caps do. - Zero setup: no Polymarket account, no API keys, no gas token. On first
setupClawRouter bootstraps a builder key from the user's OWN wallet, then derives + deploys the vault (all gasless). Geoblock is handled by default — CLOB traffic routes through BlockRun's Tokyo egress out of the box.
Golden rules for agents
- Never pass
confirm:trueunless the user explicitly approved that exact trade. Call once WITHOUT confirm → show the dry-run preview → ask → re-call withconfirm:true. - Per-order cap
POLYMARKET_MAX_BET_USD(default $25) and optional session cap are enforced locally; don't try to split orders to sneak past them. - On ANY error, read the message — it says exactly what to do next (fund, approve, region, re-run setup). Don't retry blindly.
End-to-end flow
# 0. No Polymarket account or API keys needed — ClawRouter bootstraps everything
# from the user's own wallet on first setup. (Set POLYMARKET_CLOB_HOST to a
# permitted-region egress only if the user is in a geoblocked region.)
# 1. Provision + inspect (idempotent, safe to re-run any time)
blockrun_polymarket action:"setup"
# → deposit wallet address + funding instructions + region status
# 2. Fund the vault from the user's Base USDC — gasless x402, one call ($0.01 fee,
# non-custodial). pUSD credit is ASYNC (minutes) — re-run setup to watch it. Min $2.
blockrun_polymarket action:"fund" amount_usd:5 # dry-run preview
blockrun_polymarket action:"fund" amount_usd:5 confirm:true
# 3. Sign the one-time gasless approval batch (after user consent)
blockrun_polymarket action:"setup" confirm:true
# 4. Find a market + token (data tool, paid data)
blockrun_predexon_markets ... # → clobTokenIds, conditionId (Polymarket /v1/pm data)
# 5. Preview, then place
blockrun_polymarket action:"buy" token_id:"..." amount_usd:2 # dry-run
blockrun_polymarket action:"buy" token_id:"..." amount_usd:2 confirm:true # market FOK
# or limit: price:0.45 size:10 (GTC; order_type:"GTD" + expires_at for expiry)
# or via condition: condition_id:"0x..." outcome:"Yes"
# 6. Manage
blockrun_polymarket action:"orders" # open orders
blockrun_polymarket action:"cancel" order_id:"..." # or all:true
blockrun_polymarket action:"positions" # holdings + PnL + redeemable
# 7. Claim winnings after resolution (gasless)
blockrun_polymarket action:"redeem" condition_id:"0x..." # preview
blockrun_polymarket action:"redeem" condition_id:"0x..." confirm:true
# 8. Cash out — pUSD → native USDC on Base, back to the user's agent wallet
blockrun_polymarket action:"withdraw" # dry-run (full balance)
blockrun_polymarket action:"withdraw" confirm:true # (partial: amount_usd:5)
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 8d ago First seen · 111 lines · 76 tokens per session scan A 973fb1744ac5
polymarket-trading is a skill published in the GitHub repository BlockRunAI/ClawRouter (6,579 stars, last pushed today), licensed MIT. It adds 76 tokens to every session and 1,538 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other skills, from other repositories
finance-expert
Expert-level financial systems, FinTech, banking, payments, and financial technology. Use when the user mentions fintech, banking, payments, trading, or accounting, or when the task involves Financial Systems, FinTech Stack, Key Challenges, or Data Handling.
insurance-expert
Expert-level insurance systems, underwriting, claims processing, actuarial analysis, risk assessment, and insurtech solutions. Use when the user mentions underwriting, claims, actuarial, risk, or insurtech, or when the task involves Insurance Systems, Insurance Types, Standards and Regulations, or Claims Processing.
trading-expert
Expert-level algorithmic trading, market systems, quantitative analysis, and trading platforms. Use when the user mentions algorithmic trading, quant, markets, finance, or high-frequency trading, or when the task involves Trading Systems, Market Data, or Execution.
blockchain-expert
Expert-level blockchain, Web3, smart contracts, DeFi, and cryptocurrency development. Use when the user mentions Web3, smart contracts, DeFi, Ethereum, or Solidity, or when the task involves Blockchain Fundamentals, Web3 & DeFi, Smart Contract Security, or Gas Optimization.
accountant-expert
Expert-level accounting, tax, financial reporting, and accounting systems. Use when the user mentions accounting, tax, financial reporting, GAAP, or IFRS, or when the task involves Accounting Principles, Financial Statements, Tax & Compliance, or Accounting Systems.
finops-expert
Expert-level cloud financial operations, cost optimization, and cloud economics. Use when the user mentions cloud cost, optimization, cloud economics, or AWS cost, or when the task involves FinOps Fundamentals, Cost Management, FinOps Practices, or Cost Visibility.