Polymarket MCP Server
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| POLYMARKET_DRY_RUN | No | Enable dry-run mode for simulated orders (default: true) | true |
| POLYMARKET_PRIVATE_KEY | No | Private key for authenticated trading tools | |
| POLYMARKET_MAX_ORDER_SIZE | No | Maximum order size in USD (default: 100) | 100 |
| POLYMARKET_WALLET_ADDRESS | No | Wallet address for account tools |
Instructions
Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.
This server publishes no instructions, or was last inspected before Glama recorded them.
Capabilities
Features and capabilities supported by this server
Protocol revision2025-11-25
| Capability | Details |
|---|---|
| tools | {
"listChanged": false
} |
| prompts | {
"listChanged": false
} |
| resources | {
"subscribe": false,
"listChanged": false
} |
| experimental | {} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| clob_health_checkA | Check if the Polymarket Central Limit Order Book (CLOB) API server is reachable and operational. Returns 'OK' if the API is currently healthy. |
| clob_server_timeA | Get the current server time from the Polymarket CLOB API as a Unix timestamp. |
| get_clob_marketsB | Retrieve a paginated list of all prediction markets actively trading on the Polymarket CLOB API. Provides comprehensive details for each market, including the on-chain condition IDs, corresponding outcome token IDs, and trading configuration parameters. Args: next_cursor (Optional[str]): The pagination cursor string returned from a previous request. Omit this argument to fetch the first page of results. |
| get_clob_simplified_marketsA | Retrieve a paginated, simplified list of all prediction markets actively trading on the Polymarket CLOB API. This provides less detail than get_clob_markets but operates significantly faster, making it suitable for overview data. Args: next_cursor (Optional[str]): The pagination cursor string returned from a previous request. Omit this argument to fetch the first page of results. |
| get_clob_marketB | Retrieve detailed, comprehensive information regarding a single Polymarket prediction market. Args: condition_id (str): The unique on-chain identifier corresponding to the specific market's conditions. |
| get_market_trades_eventsB | Fetch the stream of live trade activity and lifecycle events occurring on a specific Polymarket prediction market. Args: condition_id (str): The unique on-chain identifier corresponding to the specific market's conditions. |
| get_order_bookB | Retrieve the current full depth of the order book (all pending bids and asks) for a specific outcome token. This provides a complete snapshot of all open buy and sell orders mapped to their respective price levels. Args: token_id (str): The fundamental token ID associated with a specific outcome (e.g., the YES or NO side of the bet) in a prediction market. |
| get_order_booksB | Retrieve the current order books for up to multiple discrete tokens concurrently. Args: token_ids (str): A comma-separated list of foundational token IDs to fetch mapping for. |
| get_priceB | Fetch the single best available price for a given outcome token on a specified directional side. Pricing maps intrinsically to outcome probabilities in the range Args: token_id (str): The fundamental token identifier indicating the outcome side. side (str): The designated trading side to check, either strictly 'BUY' or 'SELL'. |
| get_midpointB | Calculate and return the mid-market price for a specified outcome token. The midpoint serves as a fair-value indicator generated by averaging the current best bid and best ask prices. Args: token_id (str): The fundamental token identifier indicating the outcome side. |
| get_midpointsA | Calculate and return the mid-market prices concurrently for multiple outcome tokens. Args: token_ids (str): A comma-separated list of foundational token IDs to fetch fair value for. |
| get_spreadC | Calculate and return the current bid-ask spread for a specified outcome token. The spread serves as a key liquidity indicator; smaller spreads typically denote deeper, more efficient markets. Args: token_id (str): The fundamental token identifier indicating the outcome side. |
| get_spreadsB | Calculate and return the current bid-ask spreads for multiple specified tokens concurrently. Args: token_ids (str): A comma-separated list of foundational token IDs. |
| get_last_trade_priceC | Retrieve the exact transaction price of the most recently executed trade for an outcome token. Args: token_id (str): The fundamental token identifier indicating the outcome side. |
| get_last_trades_pricesB | Retrieve the transaction prices of the most recently executed trades for multiple outcome tokens concurrently. Args: token_ids (str): A comma-separated list of foundational token IDs. |
| get_tick_sizeB | Retrieve the minimum allowable price increment (tick size) for trading a specific token's market. Args: token_id (str): The fundamental token identifier indicating the outcome side. |
| get_neg_riskC | Verify whether a specified outcome token's market utilizes the negative risk mathematical framework. Args: token_id (str): The fundamental token identifier indicating the outcome side. |
| get_fee_rateC | Retrieve the baseline trading fee rate (measured in basis points) applicable to a specific token's market. Args: token_id (str): The fundamental token identifier indicating the outcome side. |
| get_price_historyA | Retrieve historical price time-series data for a specified token. Provides a chronologically ordered list of objects containing timestamp and price data, facilitating charting and trend analysis. Args: token_id (str): The fundamental token ID associated with a specific outcome. interval (Optional[str]): A predefined time window ending at the current moment. Valid options include: '1h', '6h', '1d', '1w', '1m', 'max'. This parameter is mutually exclusive with 'start_ts'/'end_ts'. fidelity (Optional[int]): The data resolution expressed in minutes (e.g., 60 for hourly data, 1440 for daily data). start_ts (Optional[int]): The starting Unix timestamp in UTC. Use in conjunction with 'end_ts' instead of 'interval'. end_ts (Optional[int]): The ending Unix timestamp in UTC. Use in conjunction with 'start_ts' instead of 'interval'. |
| get_open_interestA | Retrieve the current open interest (total outstanding shares) for a specific market or globally. Open interest serves as an indicator of market conviction and overall liquidity. Args: condition_id (Optional[str]): The unique on-chain identifier for a specific market's conditions. Omit to retrieve a global aggregate. |
| get_positionsA | Retrieve current portfolio positions and quantitative holdings for the authenticated user. Provides detailed position data including share size, average entry price, and calculated P&L for each held outcome token.
Automatically utilizes the wallet address defined in the Args: market (Optional[str]): Filter results by a specific market condition ID. event_id (Optional[str]): Filter results by a specific overarching event ID. size_threshold (Optional[float]): The minimum numerical position size required for inclusion in the results. limit (Optional[int]): The maximum number of paginated results to return. offset (Optional[int]): The pagination offset. |
| get_trade_historyB | Retrieve the historical log of executed trades associated with a specific user or market. Provides chronological records of executed trades, detailing transaction price, share size, designated side, and timestamp. Args: user (Optional[str]): The wallet address to query historical trades for. market (Optional[str]): Filter results by a specific market condition ID. limit (Optional[int]): The maximum number of paginated results to return. offset (Optional[int]): The pagination offset. |
| get_activityA | Retrieve a comprehensive activity log for the authenticated user, encompassing trades, splits, merges, and rewards. Provides a detailed audit trail of all supported account actions.
Automatically utilizes the wallet address defined in the Args: market (Optional[str]): Filter logs by a specific market condition ID. activity_type (Optional[str]): Filter logs by explicit activity type (e.g., 'TRADE', 'SPLIT', 'MERGE', 'REDEEM', 'REWARD', 'CONVERSION'). limit (Optional[int]): The maximum number of paginated results to return. offset (Optional[int]): The pagination offset. |
| search_eventsA | Search and discover Polymarket prediction events. Events function as high-level thematic containers grouping related markets (e.g., '2024 US Presidential Election' containing multiple candidate markets). This serves as the primary entry point for exploring the Polymarket ecosystem. Args: query (Optional[str]): A search term utilized to filter events by their title or descriptive slug. tag (Optional[str]): A thematic category tag for filtering (e.g., 'politics', 'crypto', 'sports'). active (Optional[bool]): Set to true to strictly return currently active and open events. closed (Optional[bool]): Set to true to strictly return resolved or closed events. order (Optional[str]): The chronological or statistical field to sort results by (e.g., 'volume', 'created_at', 'end_date_iso'). ascending (Optional[bool]): The sort direction. Defaults to false (descending order). limit (Optional[int]): The maximum number of paginated results to return. offset (Optional[int]): The pagination offset for results. |
| get_eventA | Retrieve detailed, comprehensive information regarding a specific Polymarket event. Provides complete event metadata alongside a listing of all associated constituent markets, including their real-time prices, trading volumes, and specific outcome token identifiers. Args: event_id (str): The unique Gamma identifier for the event (formatted as a numeric string). |
| search_marketsB | Search and discover specific, individual Polymarket prediction markets. Each individual market constitutes a singular yes/no predictive question utilizing tradeable outcome tokens. These markets provide the fundamental CLOB token IDs intrinsically required for pricing and order book evaluations. Args: query (Optional[str]): A search term utilized to filter markets by their title or descriptive slug. tag (Optional[str]): A thematic category tag for filtering. active (Optional[bool]): Set to true to strictly return currently active and successfully tradeable markets. closed (Optional[bool]): Set to true to strictly return definitively resolved or settled markets. condition_id (Optional[str]): Filter intrinsically by a unique on-chain condition ID. clob_token_ids (Optional[str]): Filter fundamentally by defined CLOB token IDs. order (Optional[str]): The specific field to sort the payload by. ascending (Optional[bool]): The structural sort direction. limit (Optional[int]): The maximum number of paginated results to return. offset (Optional[int]): The defined pagination offset limit. |
| get_gamma_marketB | Retrieve detailed, comprehensive information regarding a single, specific Polymarket market natively via the Gamma API. Provides complete structural market metadata including the core question, qualitative description, array of outcomes, respective CLOB token IDs, global condition ID, cumulative volume, and definitive resolution parameters. Args: market_id_or_slug (str): The unique Gamma market mapping ID (numeric string) or URL-friendly slug. |
| place_orderA | Place a limit order on a Polymarket prediction market. ⚠️ WARNING: This action actively spends real currency! The total order value (price × size) is validated against the Args: token_id (str): The fundamental CLOB token ID indicating the precise outcome side (e.g., YES or NO). price (float): The designated limit price, scaling strictly between 0.01 and 0.99 (representing outcome probability). size (float): The aggregate number of shares to purchase or sell. side (str): The functional trading direction, strictly either 'BUY' or 'SELL'. order_type (Optional[str]): The operational order type payload. Options: GTC (Good-Til-Cancelled), FOK (Fill-Or-Kill), GTD (Good-Til-Date), FAK (Fill-And-Kill). tick_size (Optional[str]): The calculated market tick size structure (e.g., '0.1', '0.01', '0.001', '0.0001'). neg_risk (Optional[bool]): Designates whether the overarching market utilizes a negative risk framework. |
| cancel_orderA | Cancel an individual specified open limit order directly via its unique ID. Args: order_id (str): The unique transaction order ID returned functionally during order placement. |
| cancel_all_ordersB | Cancel ALL currently active open orders sequentially. Functions as an emergency kill switch. Deploy this operation functionally to immediately liquidate all pending structural positions. |
| cancel_ordersB | Cancel multiple open limit orders concurrently via their unique IDs. Args: order_ids (str): A comma-separated sequential string of order IDs to be canceled. |
| get_open_ordersB | Retrieve a comprehensive list of all open/pending limit orders currently active for the authenticated account. Args: market (Optional[str]): Explicitly filter results chronologically by market condition ID. asset_id (Optional[str]): Explicitly filter results specifically by CLOB token ID. |
| get_orderB | Retrieve granular structural details and fundamental status of a specifically defined order. Args: order_id (str): The unique transaction order ID to dynamically query. |
| get_balance_allowanceC | Retrieve the functional token balance and structural approval threshold metrics on the Polymarket protocol. Args: asset_type (Optional[str]): 'COLLATERAL' to fetch the cumulative USDC balance or 'CONDITIONAL' to query conditional outcome token holdings. token_id (Optional[str]): Required intrinsically when the specified 'asset_type' functions as 'CONDITIONAL'. |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
No resources | |
TDQS
Scored across 34 tools
Many tools target distinct operations, but multiple market-retrieval endpoints overlap heavily: get_clob_markets, get_clob_simplified_markets, get_clob_market, get_gamma_market, and search_markets all fetch market information. Singular/plural order-book tools and price variants also require careful selection, though the descriptions help clarify differences.
Most tools use snake_case with predictable action prefixes such as get_, place_, cancel_, and search_, and batch variants are generally pluralized. Minor deviations include clob_health_check and clob_server_time, which lack the get_ action prefix, but the overall naming pattern is readable and consistent.
With 34 tools, the surface is above the 25-tool threshold for being heavy and includes several singular/plural duplicates and thin API wrappers. The domain is broad, but the set feels over-expanded rather than tightly scoped.
The server covers market discovery, pricing, order books, trading, order management, positions, and balance allowance, which is a strong lifecycle surface for Polymarket. Missing order modification and direct redeem/split/merge operations are minor gaps that agents can partly work around.