Skip to main content
Glama
Br0ski777

prediction-markets

by Br0ski777

Prediction Markets API

MCP Server x402 License: MIT

来自 Polymarket 和 Kalshi 的实时预测市场赔率。活跃市场、概率、成交量、分类。智能体进行事件预测所需的投注情报层。通过 x402 按次付费(Base L2 上的 USDC)——无需 API key,无需注册,没有速率限制。

作为 klymax402 市场的一部分 —— 面向 AI 智能体的 100 个 x402 微支付 API,一个钱包,USDC 在 Base 上。

快速入门 -- MCP

将以下内容添加到你的 MCP 客户端配置中(Claude Desktop、Cursor、ElizaOS 等):

{
  "mcpServers": {
    "prediction-markets": {
      "url": "https://prediction-markets.api.klymax402.com/mcp"
    }
  }
}

Related MCP server: Polymarket MCP Server

快速入门 -- HTTP(x402)

curl -X POST "https://prediction-markets.api.klymax402.com/api/markets" \
  -H "Content-Type: application/json" \
  -d '{}'
# -> 402 Payment Required, with an x402 payment challenge in the response body

任何支持 x402 的客户端(@x402/fetchx402-agent-tools、ATXP)都会自动处理 402 -> 签名 -> 重试这一完整流程。

工具

工具

方法

路径

价格

说明

prediction_list_markets

POST

/api/markets

$0.012

从 Polymarket 和 Kalshi 列出当前活跃的预测市场,包含最新赔率、成交量和分类。可按主题、平台筛选,并按成交量、最新或即将结束排序。

prediction_get_market_odds

POST

/api/odds

$0.012

通过 ID 或搜索词获取特定预测市场的详细赔率和交易数据。同时搜索 Polymarket 和 Kalshi。

prediction_trending_markets

POST

/api/trending

$0.008

来自 Polymarket 和 Kalshi 的顶级热门预测市场,按成交量和参与度排名。

prediction_list_markets

当你需要浏览当前活跃的预测市场,或查找真实世界事件的投注赔率时,请使用此工具。它返回来自 Polymarket 和 Kalshi 的活跃市场列表,包含当前概率、成交量以及元数据。

参数

名称

类型

必需

说明

category

string

按主题类别过滤市场。省略此参数则返回全部分类。

limit

number

返回市场的数量(1-50)。默认值:20。

sort

string

排序方式。'volume' = 成交量最高,'newest' = 最新创建,'closing_soon' = 结算最早。默认值:volume。

source

string

按平台过滤。省略此参数则同时获取 Polymarket 和 Kalshi 的市场。

返回

  • question —— 预测市场问题(例如:"比特币会在 2026 年 12 月前达到 10 万美元吗?")

  • outcomePrices —— 每个结果的概率,以小数表示(0.65 = 有 65% 的概率为 YES)

  • volume —— 总成交量(美元)

  • liquidity —— 当前可用流动性(美元)

  • endretentionDate —— 市场结算的时间

  • category —— 主题类别(政治、加密货币、体育、科学、文化)

  • active —— 市场当前是否处于交易状态

  • source —— 数据来源 -- "polymarket" 或 "kalshi"

示例响应:

{ markets: [{ question: "Will Trump win 2028?", outcomePrices: { "Yes": 0.42, "No": 0.58 }, volume: 15420000, liquidity: 890000, endDate: "2028-11-06", category: "politics", source: "polymarket" }] }

不适用场景:加密资产的价格数据(请使用 token_get_price)、加密货币新闻(请用 crypto_get_news)、股票价格(请用 stock_get_quote)、DeFi 收益率(请用 defi_find_best_yields)、Hyperliquid 永续合约数据(请用 hyperliquid_get_market_data)。

prediction_get_market_odds

当你需要特定预测市场的详细赔率、配对和交易数据时,请使用此工具。它会搜索 Polymarket 和 Kalshi,以市场 ID 或问题文本找到最佳匹配项。

参数

参数

类型

必需

说明

marketId

string

Polymarket 条件 ID 或 Kalshi ticker。如果你已知市场 ID,请使用此参数。

query

string

通过问题文本搜索市场的查询(例如 'bitcoin 100k'、'trump election')。当 marketId 未知时使用。

返回

  • question —— 完整的预测市场问题文本。

  • outcomes —— 所有可能结果及其当前概率的数组。

  • outcomePrices —— 每个结果的十进制概率(0.72 = 市场隐含 72% 的概率)。

  • volume —— 历史总成交量(美元)。

  • volume24h —— 过去 24 小时成交量(美元)。

  • liquidity —— 当前订单簿深度(美元)。

  • endDate —— 市场结算日期。

  • description —— 详细的市场描述和结算条件。

  • active —— 市场当前是否开放交易。

  • source —— 市场来自哪个平台 -- "polymarket" 或 "kalshi"。

示例响应:

{ question: "Will ETH flip BTC by 2027?", outcomes: ["Yes", "No"], outcomePrices: { "Yes": 0.08, "No": 0.92 }, volume: 2340000, volume24h: 45000, liquidity: 120000, endDate: "2027-12-31", active: true, source: "polymarket" }

不适用场景:加密资产价格数据(请使用 token_get_price)、加密货币数据(请用 crypto_get_news)、股票价格(请用 stock_get_quote)、DeFi 收益率(请用 defi_find_best_yields)、Hyperliquid 永续合约数据(请用 hyperliquid_get_market_data)。

当你需要了解当前哪些预测市场正在热门时,请使用此工具。它根据近期的交易量和活跃度,返回 Polymarket 和 Kalshi 中最热门的市场。

参数

参数

类型

必需

说明

limit

number

返回的热门市场数量(1-30)。默认值:10。

source

string

按平台过滤。缺少此参数则同时获取 Polymarket 和 Kalshi 的热门市场。

返回

  • question —— 市场问题

  • probability —— 当前领先结果概率(十进制)

  • volume24h —— 过去 24 小时的成交量(美元)

  • totalVolume —— 历史总成交量(美元)

  • priceChange24h —— 过去 24 小时概率的变化值(例如:+0.05 = 概率上升 5%)

  • category —— 主题类别

  • endDate —— 市场结算时间

  • source —— 数据来源 -- "polymarket" 或 "kalshi"

示例响应:

{ trending: [{ question: "Will Fed cut rates in July 2026?", probability: 0.73, volume24h: 890000, totalVolume: 12500000, priceChange24h: 0.08, category: "politics", endDate: "2026-07-31", source: "polymarket" }] }

不适用场景:加密资产价格数据(请使用 token_get_price)、加密货币数据(请用 crypto_get_news)、股票价格(请用 stock_get_quote)、DeFi 收益率(请用 defi_find_best_yields)、Hyperliquid 永续合约数据(请用 hyperliquid_get_market_data)。

示例智能体提示词

  • "浏览活跃的预测市场或查找真实事件的投注赔率"

  • "获取特定观察市场的详细赔率、概率和交易数据"

  • "看看当前有哪些预测市场正在热门"

付款方式

  • 协议: x402 —— 基于 HTTP 的原生按次付费,无需注册、无需 API 密钥

  • 网络: Base L2(eip155:8453

  • 资产:USDC

  • Facilitator:Coinbase CDP(主要)、PayAI(备用)

  • 也可通过 ATXP 访问(OAuth 包装的 x402,RFC 9728 受保护资源元数据)

属于 klymax402

面向 AI 智能体的 100 个 x402 微支付 API —— 一个钱包,Base 链,零注册。

许可证

MIT

A
license - permissive license
Not graded
quality - not tested
B
maintenance

Maintenance

Maintainers
Response time
Release cycle
Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Servers

  • A
    license
    Not graded
    quality
    D
    maintenance
    Enables AI assistants to query Polymarket prediction markets, accessing real-time odds, market data, price history, order books, and trending markets across categories like politics, crypto, and sports through natural language.
    15
    5
    MIT
  • A
    license
    B
    quality
    Not graded
    maintenance
    Enables AI agents to interact with the Polymarket prediction market platform to discover markets, analyze real-time pricing, and monitor public portfolio data. It provides comprehensive access to market analytics, implied probabilities, and order books through the Model Context Protocol.
    59
    15
  • A
    license
    A
    quality
    B
    maintenance
    Enables AI agents to discover and analyze prediction markets, execute trades, and manage positions on Polymarket via the Model Context Protocol.
    7
    76
    19
    MIT

View all related MCP servers

Related MCP Connectors

  • Calibrated world model for AI agents. 40 tools: world state, markets, trading. Kalshi + Polymarket.

  • Pay-per-use weather, environment, finance, and on-chain intelligence tools for AI agents via x402.

  • Machine-payable prediction-market briefs and probability-change monitoring for AI agents.

View all MCP Connectors

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/Br0ski777/prediction-markets-x402'

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