AI Polymarket Agent

v1.0.0Finance & Fintechstable

Enable Claude, ChatGPT, and other AI agents to analyze markets, fetch real-time odds, and execute trades on Polymarket using the Model Context Protocol (MCP).

ai-polymarket-agentmcpai-integration
Share:
610
Stars
0
Downloads
0
Weekly
0/5

What is AI Polymarket Agent?

AI Polymarket Agent is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to enable claude, chatgpt, and other ai agents to analyze markets, fetch real-time odds, and execute trades on polymarket using the model context protocol (mcp).

Enable Claude, ChatGPT, and other AI agents to analyze markets, fetch real-time odds, and execute trades on Polymarket using the Model Context Protocol (MCP).

This server falls under the Finance & Fintech category on MCPgee, the world's largest MCP server directory with 33,000+ servers.

Features

  • Enable Claude, ChatGPT, and other AI agents to analyze marke

Use Cases

Enable Claude and ChatGPT to analyze prediction markets on Polymarket. Fetch real-time odds and market data for decision making. Execute trades on Polymarket through AI agents.
LicenseMIT
Languagetypescript
Versionv1.0.0
UpdatedMay 21, 2026
Statushealthy
Maintenanceactive

Works with

ClaudeOpenAIwindowsmacoslinux

Installation

Manual Installation

npx ai-polymarket-agent

Configuration

Configuration Details

Config File

claude_desktop_config.json

Performance

Response Metrics

Response Time< 200ms
ThroughputMedium

Resource Usage

Memory UsageLow
CPU UsageLow

How to Set Up and Use AI Polymarket Agent

The AI Polymarket Agent MCP server connects AI assistants like Claude and ChatGPT to Polymarket, the leading decentralized prediction market platform, enabling them to search active markets by keyword, retrieve real-time odds and order book data for any market, and optionally execute trades. By exposing Polymarket's API as MCP tools, the server lets you ask an AI to research prediction markets and report probabilities as a natural part of a conversation, without manually visiting the site or writing any API code. It is especially useful for researchers, traders, and decision-makers who want to incorporate crowd-sourced probability estimates into their AI workflows.

Prerequisites

  • Node.js 18 or later installed
  • An MCP-compatible client such as Claude Desktop or Cursor
  • A Polymarket account if you intend to execute trades (optional for read-only market research)
  • Basic familiarity with prediction markets and condition IDs
1

Clone or install the server

The server is available via npx for a zero-install run, or you can clone the repository and install dependencies manually.

npx ai-polymarket-agent
2

Install dependencies (if running from source)

If you cloned the repository, install the required Node.js packages including the MCP SDK and axios.

npm install @modelcontextprotocol/sdk axios
3

Configure environment variables

Copy the example environment file and set the Polymarket API base URL. For trading, you will also need to add wallet credentials.

cp .env.example .env
# Edit .env and set:
# POLYMARKET_API_BASE=https://clob.polymarket.com
4

Add the server to your MCP client config

Register the server in your MCP client configuration so your AI assistant can discover and call its tools.

5

Test a market search

Ask your AI assistant to search for a topic on Polymarket to verify the search_markets tool is working.

AI Polymarket Agent Examples

Client configuration

Add this block to your claude_desktop_config.json to run the AI Polymarket Agent MCP server via npx.

{
  "mcpServers": {
    "ai-polymarket-agent": {
      "command": "npx",
      "args": ["ai-polymarket-agent"],
      "env": {
        "POLYMARKET_API_BASE": "https://clob.polymarket.com"
      }
    }
  }
}

Prompts to try

These prompts use the search_markets and get_market_odds tools to research prediction markets.

- "Search Polymarket for active markets about the 2026 US midterm elections and show me the current odds."
- "What is the probability that Bitcoin reaches $150,000 according to Polymarket?"
- "Find the top 5 most traded Polymarket markets right now and summarize their topics."
- "Get the order book data for Polymarket market ID 0x1234... and tell me the bid/ask spread."
- "Are there any Polymarket markets about AI regulation? Show me the current probabilities."

Troubleshooting AI Polymarket Agent

search_markets returns no results

Polymarket only returns active, open markets. Try broader search terms (e.g., 'election' instead of a specific candidate name). The API may also have rate limits; wait a moment and retry.

get_market_odds fails with an invalid conditionId error

The conditionId must be the exact hexadecimal identifier for a Polymarket market, not the market title. Use search_markets first to find the correct conditionId, then pass it to get_market_odds.

Server starts but AI client shows no tools

Ensure the npx command resolves correctly by running 'npx ai-polymarket-agent' in a terminal and checking for startup errors. Confirm your MCP client config uses the exact command shown above and restart the client.

Frequently Asked Questions about AI Polymarket Agent

What is AI Polymarket Agent?

AI Polymarket Agent is a Model Context Protocol (MCP) server that enable claude, chatgpt, and other ai agents to analyze markets, fetch real-time odds, and execute trades on polymarket using the model context protocol (mcp). It connects AI assistants to external tools and data sources through a standardized interface.

How do I install AI Polymarket Agent?

Follow the installation instructions on the AI Polymarket Agent GitHub repository. Clone the repo, install dependencies, and add the server config to your AI client.

Which AI clients work with AI Polymarket Agent?

AI Polymarket Agent works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.

Is AI Polymarket Agent free to use?

Yes, AI Polymarket Agent is open source and available under the MIT license. You can use it freely in both personal and commercial projects.

Browse More Finance & Fintech MCP Servers

Explore all finance & fintech servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.

Quick Config Preview

{ "mcpServers": { "ai-polymarket-agent": { "command": "npx", "args": ["-y", "ai-polymarket-agent"] } } }

Add this to your claude_desktop_config.json or .cursor/mcp.json

Read the full setup guide →

Ready to use AI Polymarket Agent?

Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.

33,000+ ServersFree & Open SourceStep-by-Step Guides