Skip to main content
Glama
PaulieB14

graph-polymarket-mcp

get_market_revisions

Retrieve moderator revisions for Polymarket markets to see when and how moderators intervened in market resolution.

Instructions

Get moderator revisions/updates for Polymarket markets. Shows when and how moderators intervened in market resolution.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
questionIdNoOptional: filter revisions for a specific market questionId
firstNoNumber of revisions to return

Implementation Reference

  • src/index.ts:805-837 (registration)
    Registration of the 'get_market_revisions' tool using server.registerTool. The tool queries the 'resolution' subgraph for Revision entities (moderator updates to market resolution). It accepts optional questionId filter and first parameter.
    // ---------------------------------------------------------------------------
    // Tool 18: get_market_revisions
    // ---------------------------------------------------------------------------
    server.registerTool(
      "get_market_revisions",
      {
        description:
          "Get moderator revisions/updates for Polymarket markets. Shows when and how moderators intervened in market resolution.",
        inputSchema: {
          questionId: z.string().optional().describe("Optional: filter revisions for a specific market questionId"),
          first: z.number().min(1).max(100).default(20).describe("Number of revisions to return"),
        },
      },
      async ({ questionId, first }) => {
        try {
          const where = questionId ? `, where: { questionId: "${questionId}" }` : "";
          const query = `{
            revisions(first: ${first}, orderBy: timestamp, orderDirection: desc${where}) {
              id
              moderator
              questionId
              timestamp
              update
              transactionHash
            }
          }`;
          const data = await querySubgraph(SUBGRAPHS.resolution.ipfsHash, query);
          return textResult(data);
        } catch (error) {
          return errorResult(error);
        }
      }
    );
  • Handler function that executes the tool logic. Builds a GraphQL query for 'revisions' from the resolution subgraph, optionally filtered by questionId, ordered by timestamp descending. Returns moderator, questionId, timestamp, update, and transactionHash fields.
      async ({ questionId, first }) => {
        try {
          const where = questionId ? `, where: { questionId: "${questionId}" }` : "";
          const query = `{
            revisions(first: ${first}, orderBy: timestamp, orderDirection: desc${where}) {
              id
              moderator
              questionId
              timestamp
              update
              transactionHash
            }
          }`;
          const data = await querySubgraph(SUBGRAPHS.resolution.ipfsHash, query);
          return textResult(data);
        } catch (error) {
          return errorResult(error);
        }
      }
    );
  • Input schema for get_market_revisions. Accepts optional questionId (string) and first (number, 1-100, default 20).
        "Get moderator revisions/updates for Polymarket markets. Shows when and how moderators intervened in market resolution.",
      inputSchema: {
        questionId: z.string().optional().describe("Optional: filter revisions for a specific market questionId"),
        first: z.number().min(1).max(100).default(20).describe("Number of revisions to return"),
      },
    },
Behavior3/5

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

No annotations are provided, so the description carries full burden. It implies a safe read operation but does not explicitly state if it requires authentication, rate limits, or any side effects. The transparency is adequate but could be improved by confirming read-only nature.

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?

Description is extremely concise with two sentences. The first sentence immediately states the purpose, and the second adds useful context. No wasted words or redundant information.

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

Completeness3/5

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

Without an output schema, the description could elaborate on what the response contains (e.g., fields like timestamp, moderator, action). It only says 'when and how' but is vague. For a tool with simple parameters, it is minimally adequate but not fully complete.

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?

Input schema coverage is 100% with both parameters having descriptions. The description adds no extra meaning beyond the schema; it does not explain parameter formats or provide examples. Baseline score of 3 is appropriate.

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 the tool's purpose: retrieving moderator revisions/updates for Polymarket markets. It specifies the action ('get') and the resource ('moderator revisions'), and adds context about showing when and how moderators intervened, differentiating it from siblings like get_market_resolution which likely returns current resolution.

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

Usage Guidelines2/5

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

The description does not provide any guidance on when to use this tool versus alternatives. It lacks explicit when-to-use, when-not-to-use, or references to sibling tools. Users are left to infer usage from the purpose alone.

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/PaulieB14/graph-polymarket-mcp'

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