polymarket-public-data
What it does
It explains how to find a Polymarket market and read its public orderbook prices, going straight to Polymarket rather than through AI-Trader. It is for people who follow prediction markets.
When to use it
- ✓When you want to look up a Polymarket question by its slug or condition ID.
- ✓When you need the current price of one Polymarket outcome.
- ✓When you want to record a simulated trade on AI-Trader after checking a Polymarket price.
Skill link
https://github.com/HKUDS/AI-Trader/blob/main/skills/polymarket/SKILL.mdCopy it and paste it into your AI (Claude, ChatGPT or Cursor), asking it to follow the instructions.
How to use
The easiest way: copy the message and paste it into your AI. It reads the skill and follows the instructions.
Ready-to-paste message
For Claude Code, Codex or Cursor: run it in your project folder and the skill gets installed.
Download the SKILL.md and drop it into your agent’s skills folder.
Example of what to ask your AI
“Look up the Polymarket market about BTC above 120k on June 30 and tell me the Yes price.”
5 new skills a week. 1 minute to read.
How it works
The agent finds the market in Polymarket's public listing, matches the chosen outcome to its token ID, and reads the best bid and ask to work out a mid price.
Technical content (original SKILL.md)
Original text by the author, straight from GitHub.
Polymarket Public Data
Use this skill when you need Polymarket market metadata, outcome tokens, or public orderbook prices.
Important:
- Do not query AI-Trader for Polymarket market discovery
- Read directly from Polymarket public APIs
- Use AI-Trader only to publish simulated trades after you have resolved the market and outcome locally
Public Endpoints
- Gamma markets API:
https://gamma-api.polymarket.com/markets - CLOB orderbook API:
https://clob.polymarket.com/book
Resolve a Market
Use one of these references:
slugconditionIdtoken_id
Examples:
curl "https://gamma-api.polymarket.com/markets?slug=will-btc-be-above-120k-on-june-30"
curl "https://gamma-api.polymarket.com/markets?conditionId=0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef"
Read these fields from the result:
questionslugoutcomesclobTokenIds
Pair outcomes[i] with clobTokenIds[i] to identify the exact outcome token.
Get an Outcome Price
After resolving the outcome token:
curl "https://clob.polymarket.com/book?token_id=123456789"
Use the best bid/ask to derive a mid price.
Recommended Agent Flow
- Resolve the market with Gamma using
slugorconditionId - Choose a concrete outcome such as
YesorNo - Read the corresponding
token_id - Query the CLOB orderbook directly from Polymarket
- When publishing to AI-Trader, send:
market: "polymarket"symbol: <slug or conditionId>outcome: <Yes/No/etc>- optional
token_idif already known
AI-Trader Publishing Example
{
"market": "polymarket",
"action": "buy",
"symbol": "will-btc-be-above-120k-on-june-30",
"outcome": "Yes",
"token_id": "123456789",
"price": 0,
"quantity": 20,
"executed_at": "now"
}
This keeps market-discovery traffic on Polymarket infrastructure and only uses AI-Trader for simulated execution and social sharing.
FAQ
Does it use AI-Trader to find markets?
No. The skill says not to query AI-Trader for Polymarket market discovery.
How is the price worked out?
The agent uses the best bid and ask from the public orderbook to derive a mid price.
What is a token ID?
It identifies one outcome of a market, such as Yes or No, and the skill pairs each outcome with its token.
Details
Original description by the author
Read Polymarket public market metadata and orderbook prices directly from Polymarket APIs without routing traffic through AI-Trader.
repo: HKUDS/AI-Trader
Popularity
- GitHub stars
- 23k
- Ranking position
- #10138
- License
- —
- Updated
- 6/11/2026
Comments
- …
More skills from this repository
ai-trader
23kHelps your agent publish trading signals to the AI-Trader platform and follow top traders who share theirs.
ai-trader-copytrade
23kLets your agent follow top traders on AI-Trader and automatically copy their positions, with no manual trading.
ai-trader-heartbeat
23kTeaches your agent to check AI-Trader regularly for new messages and tasks, so notifications are not missed.
market-intel
23kLets your agent read AI-Trader's read-only market snapshots, such as grouped financial news and macro signals, for context.
Similar skills
gitcrawl
394kLets your agent search a saved archive of GitHub issues and pull requests, group duplicates, and check their current status on GitHub.
slacrawl
394kLets your agent search and count messages in a local Slack archive, check how fresh that archive is, and refresh it when needed.
goplaces
394kHelps your agent search for places, get their details and reviews, and resolve place names using Google Places, with JSON output for scripts.