Skip to main content
Glama
polymarket-mcp

polymarket-mcp

by simonlokc

polymarket_resolve_token_onchain

Resolve an outcome token ID to its conditionId and outcome index using Polygon on-chain registry data, with block provenance and verification level.

Instructions

Resolve a token id to conditionId + outcomeIndex from Polygon ground truth (reads the CTF Exchange registry and derives ConditionalTokens position ids), not the Gamma API. Returns block provenance and verification level (fully_verified / pair_only for NegRisk). Requires env POLYGON_RPC_URL (a free public/free-tier Polygon RPC works).

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "token_id": "<token_id>"
    },
    "name": "polymarket_resolve_token_onchain"
  }
}

Input Schema

NameRequiredDescriptionDefault
blockNoOptional Polygon block number to read at (default latest).
token_idYesOutcome token id (decimal uint256 string).

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.3/5.0
Behavior4/5

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

With no annotations supplied, the description does the heavy lifting: it discloses the underlying read path (CTF Exchange registry, derived ConditionalTokens position ids), the return payload including block provenance and the fully_verified / pair_only distinction for NegRisk, and the POLYGON_RPC_URL environment prerequisite. It leaves out failure behavior when that env var is unset and any RPC rate or latency characteristics.

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

Conciseness5/5

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

Two sentences, front-loaded with the action and resource, then the provenance and prerequisite details. Parenthetical asides are short and carry real information rather than filler.

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?

No output schema exists, yet the description explains the return shape (conditionId, outcomeIndex, block provenance, verification level) and the environment requirement. For a two-parameter read tool this is sufficient for an agent to call it and interpret the result correctly.

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

Parameters3/5

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

Schema description coverage is 100%, so both parameters are already documented, and the description adds no format or usage detail beyond what the schema states — notably it never mentions the optional block parameter. Baseline 3 applies when the schema carries parameter semantics.

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?

States a specific verb and resource — resolving an outcome token id to a conditionId plus outcomeIndex — and pins the source of truth to the on-chain CTF Exchange registry rather than the Gamma API, which cleanly separates it from polymarket_resolve_token. The two output fields and the verification level are named outright, so an agent knows exactly what it gets back.

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

Usage Guidelines4/5

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

The contrast with the Gamma API gives clear context for when this tool is the right pick: cases needing Polygon ground truth and provenance. It stops short of an explicit either/or rule naming the sibling tool and the condition that selects it, and gives no when-not-to-use guidance such as cost or latency of an RPC read.

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