tool-polymarket-book

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

polymarket_book (Polymarket CLOB book)

polymarket_book(Polymarket CLOB订单簿)

When to use

适用场景

  • Liquidity check before sizing into a market.
  • Spread + depth + mid estimation.
  • 进场交易前的流动性检查。
  • 点差、深度及中间价估算。

Parameters

参数

  • marketId
    (string, required): Gamma numeric id (e.g.
    "516710"
    ) or conditionId hex (
    "0x..."
    ).
  • outcome
    (
    "YES" | "NO"
    , optional): Defaults to
    "YES"
    .
  • depth
    (int, optional, 1–200): Levels per side; default 20.
  • marketId
    (字符串,必填):Gamma数字ID(例如
    "516710"
    )或conditionId十六进制值(
    "0x..."
    )。
  • outcome
    "YES" | "NO"
    ,可选):默认值为
    "YES"
  • depth
    (整数,可选,范围1–200):每一侧的订单层级;默认值为20。

Examples

示例

json
{ "name": "polymarket_book", "params": { "marketId": "0xabc...def", "outcome": "YES", "depth": 50 } }
json
{ "name": "polymarket_book", "params": { "marketId": "0xabc...def", "outcome": "YES", "depth": 50 } }

Output

输出

  • Returns:
    { marketId, conditionId, question, slug, endDate, outcome, tokenId, bookAvailable, bestBid, bestAsk, mid, bids[], asks[], ts }
  • Rendered:
    • Emits a JSON output with title
      orderbook
      (used by the UI to open/focus a book window when available).
    • Market
      (text with mid/bid/ask and “no CLOB orderbook” when missing)
    • Asks
      +
      Bids
      (tables)
  • 返回值:
    { marketId, conditionId, question, slug, endDate, outcome, tokenId, bookAvailable, bestBid, bestAsk, mid, bids[], asks[], ts }
  • 渲染效果:
    • 输出标题为
      orderbook
      的JSON结果(UI会在可用时打开/聚焦订单簿窗口)。
    • Market
      (文本,显示中间价/买价/卖价;若无CLOB订单簿则显示“无CLOB订单簿”)
    • Asks
      +
      Bids
      (表格形式)

Notes

注意事项

  • Some markets have no CLOB orderbook; the tool returns
    bookAvailable=false
    and empty bids/asks.
  • targetWindow
    :
    book
  • 部分市场无CLOB订单簿;此时工具会返回
    bookAvailable=false
    ,且bids/asks为空数组。
  • targetWindow
    :
    book