# ChainHilt Polymarket Order Book

> ChainHilt Polymarket Order Book is a paid API for AI agents from chainhilt.ai, paid per call via x402, $0.001/call, status unknown (last checked 2026-12-01).

Returns the current order book (bids and asks) for every outcome of a specified Polymarket prediction market.

## Facts

- Endpoint: GET https://chainhilt.ai/api/v1/predict/polymarket/markets/:marketId/book?utm_source=zero.xyz
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-12-01
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/chainhilt-polymarket-order-book-6114f7df
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_Wf70oVS8QxLF9DbRrzF1c

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability chainhilt-polymarket-order-book-6114f7df
```

Example prompt: Pull the full order book for all outcomes of Polymarket market ID '0xabc123' so I can see the current bids and asks for each outcome.

## When to prefer this

Use this endpoint when you need real-time order book data (bids, asks, depth) for all outcomes of a specific Polymarket prediction market. Prefer this over general market search endpoints when you already have a marketId and need granular liquidity data for trading decisions, arbitrage analysis, or pre-trade evaluation.

## Known failure modes

- Invalid or malformed marketId returns a 400 or 404 error
- Market no longer active or resolved may return empty order book or error
- Payment failure (insufficient USDC balance) returns a 402 Payment Required
- Rate limiting or network issues may return 5xx errors
- MarketId that does not exist on Polymarket returns not found error

## How this service works

Live order book for each outcome of a prediction market: bids and asks (price, size) per outcome tokenId, read from the venue at `observedAt`. Check depth and spread here before quoting or constructing an order. A closed or untradable market returns 422, which is not charged.

## Output

Returns the order book for each outcome of the specified Polymarket market, including bid and ask levels with prices and quantities, enabling analysis of market depth, liquidity, and spread.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ],
     "type": "string"
    },
    "pathParams": {
     "type": "object",
     "$schema": "https://json-schema.org/draft/2020-12/schema",
     "required": [
      "marketId"
     ],
     "properties": {
      "marketId": {
       "type": "string",
       "pattern": "^[A-Za-z0-9_-]{1,128}$",
       "description": "Polymarket market id as returned by markets/search, e.g. \"512329\"."
      }
     }
    },
    "queryParams": {
     "type": "object",
     "properties": {}
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/chainhilt-polymarket-order-book-6114f7df/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from chainhilt.ai](https://www.zero.xyz/host/chainhilt.ai/llms.txt)
