Skip to main content
Glama
BlockRunAI

BlockRun MCP

Official
by BlockRunAI

blockrun_polymarket

Destructive

Trade on Polymarket prediction markets with real pUSD via gasless orders. Setup deposit wallet, place limit/market bets, manage orders, redeem winnings, and withdraw USDC.

Instructions

Trade on Polymarket prediction markets (CLOB V2, Polygon). REAL MONEY — orders spend pUSD held in your Polymarket deposit wallet, signed locally by your BlockRun key. Free tool (no BlockRun API charge); discover markets/prices/token IDs with blockrun_markets first.

Run action:"setup" FIRST (and again after funding). It creates a gasless deposit wallet owned by your key, checks pUSD balance + exchange approvals, and prints funding instructions. Zero config — no Polymarket account or API keys; setup bootstraps its credentials from your wallet key.

Actions:

  • setup — create/inspect deposit wallet, funding, approvals (confirm:true to sign the approval batch), region check. Idempotent.

  • fund — top up the deposit wallet from your OWN Base USDC, gasless (confirm:true). amount_usd required. BlockRun pays the gas + charges $0.01; you need no ETH. Non-custodial (USDC → Polymarket bridge → your vault).

  • buy / sell — token_id (or condition_id+outcome) + either price+size (limit) or amount_usd (market buy) / size (market sell). confirm:true REQUIRED to place; omitting it returns a dry-run preview. Per-order cap: POLYMARKET_MAX_BET_USD (default $25).

  • orders — list open orders (optional condition_id filter)

  • cancel — order_id:"…" or all:true

  • positions — holdings incl. redeemable winnings (free Data-API)

  • redeem — claim resolved winnings for condition_id (confirm:true; gasless)

  • withdraw — cash out pUSD → native USDC on Base to your agent wallet (confirm:true). amount_usd optional (default: full balance); to_address optional (default: your wallet).

Prices are probabilities 0–1 on the market's tick grid. token_id comes from blockrun_markets Polymarket data. Geoblock is handled by default (CLOB traffic routes through BlockRun's Finland egress) — setup reports your region status. Complying with Polymarket's terms for the user's jurisdiction is the user's responsibility.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
allNocancel: cancel ALL open orders
sizeNoShares — required for limit orders and market sells
priceNoLimit price as probability (0–1). Omit for a market order.
actionYesOperation to perform
confirmNoMust be true to place orders / sign approvals / redeem. Omit for a dry-run preview.
outcomeNoOutcome label (e.g. 'Yes') — used with condition_id when token_id is omitted
agent_idNoTag for the session betting ledger (bets do NOT draw from the x402 API budget)
order_idNoOrder ID to cancel
token_idNoOutcome token ID (decimal ERC-1155 id from blockrun_markets clobTokenIds)
post_onlyNoMaker-only limit order (rejected if it would cross the book)
amount_usdNopUSD dollars — to spend (market buy) or to cash out (withdraw; default full balance)
expires_atNoUnix seconds expiry (GTD only, ≥ ~3 min in the future)
order_typeNoDefault: GTC for limit orders, FOK for market orders
to_addressNowithdraw: destination address on Base (default: your agent wallet)
condition_idNoMarket condition ID (0x…). With `outcome` it resolves token_id; required for redeem.
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotated as destructive and open-world; description richly expands with details like real money, non-custodial, gasless, BlockRun pays gas for some actions, region check, dry-run mode, and compliance responsibility. No contradiction with annotations.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Description is long but well-structured with sections per action and critical notes front-loaded. Every sentence provides essential information; no wasted words. Could be slightly more concise, but comprehensiveness justifies length.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a complex 15-parameter tool with 9 actions, the description covers all actions, their parameters, important constraints (gas, limits, region), and return behavior (dry-run vs confirm). Even without output schema, it explains what to expect, making it complete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Input schema has 100% description coverage, so baseline is 3. Description adds value beyond schema by explaining price as probability 0-1 on tick grid, token_id source from blockrun_markets, and usage of amount_usd in different actions. Marginally improves understanding.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states it's for trading on Polymarket prediction markets, listing specific actions (setup, fund, buy, sell, etc.) and distinguishing from sibling tools like blockrun_markets (for discovery) and blockrun_polymarket_read (likely read-only). It uses specific verbs and resource references.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly instructs to run 'setup' first and again after funding, and to use blockrun_markets for market discovery. Provides clear guidance on when to use each action, when to set confirm:true vs omit for dry-run, and mentions per-order caps and region handling. No ambiguity.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/BlockRunAI/blockrun-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server