kalshi
89
总安装量
88
周安装量
#4728
全站排名
安装命令
npx skills add https://github.com/machina-sports/sports-skills --skill kalshi
Agent 安装分布
codex
74
gemini-cli
73
opencode
72
cursor
66
github-copilot
64
claude-code
63
Skill 文档
Kalshi â Prediction Markets
CRITICAL: Always use the sport parameter
For single-game markets, ALWAYS pass sport='<code>' to search_markets and get_todays_events.
Without it, search returns only high-volume futures and misses individual game markets.
WRONG: search_markets(query="Leeds") â 0 results
WRONG: search_markets(query="Manchester City") â 0 results
RIGHT: search_markets(sport='epl', query='Leeds') â returns all Leeds markets
RIGHT: search_markets(sport='nba', query='Lakers') â returns all Lakers markets
Quick Start
Prefer the CLI â it avoids Python import path issues:
# Search NBA markets
sports-skills kalshi search_markets --sport=nba
# Get today's NBA events with nested markets
sports-skills kalshi get_todays_events --sport=nba
# List available sport codes
sports-skills kalshi get_sports_config
# Raw markets by series ticker
sports-skills kalshi get_markets --series_ticker=KXNBA --status=open
Python SDK (alternative):
from sports_skills import kalshi
# Sport-based search (same interface as polymarket)
kalshi.search_markets(sport='nba')
kalshi.search_markets(sport='nba', query='Lakers')
kalshi.get_todays_events(sport='nba')
kalshi.get_sports_config()
# Raw queries
kalshi.get_markets(series_ticker="KXNBA", status="open")
kalshi.get_event(event_ticker="KXNBA-26FEB14")
Important Notes
- On Kalshi, “Football” = NFL. For football (EPL, La Liga, etc.), use sport codes:
epl,ucl,laliga,bundesliga,seriea,ligue1,mls. - Prices are probabilities. A
last_priceof 20 means 20% implied probability. Scale is 0-100 (not 0-1 like Polymarket). - Always use
status="open"when querying markets, otherwise results include settled/closed markets. - Shared interface with Polymarket:
search_markets(sport=...),get_todays_events(sport=...), andget_sports_config()work the same way on both platforms. - Football has multiple series per league. EPL maps to 5 series (KXEPLGAME, KXEPLTOTAL, KXEPLBTTS, KXEPLSPREAD, KXEPLGOAL). The
sportparameter queries all of them automatically.
For detailed reference data, see the files in the references/ directory.
Workflows
Workflow: Sport Market Search (Recommended)
search_markets --sport=nbaâ finds all open NBA markets.- Optionally add
--query="Lakers"to filter by keyword. - Results include yes_bid, no_bid, volume for each market.
Workflow: Today’s Events
get_todays_events --sport=nbaâ open events with nested markets.- Present events with prices (price = implied probability, 0-100 scale).
Workflow: Discover Available Sports
get_sports_configâ lists sport codes and series tickers.- Use any code with
search_markets(sport=...)orget_todays_events(sport=...).
Workflow: Futures Market Check
get_markets --series_ticker=<ticker> --status=open- Sort by
last_pricedescending. - Present top contenders with probability and volume.
Workflow: Market Price History
- Get market ticker from
search_markets --sport=nba. get_market_candlesticks --series_ticker=<s> --ticker=<t> --start_ts=<start> --end_ts=<end> --period_interval=60- Present OHLC with volume.
Commands Reference
Sport-Aware Commands (same interface as Polymarket)
| Command | Required | Optional | Description |
|---|---|---|---|
get_sports_config |
Available sport codes and series tickers | ||
get_todays_events |
sport | limit | Today’s events for a sport with nested markets |
search_markets |
sport, query, status, limit | Find markets by sport and/or keyword |
Raw API Commands
| Command | Required | Optional | Description |
|---|---|---|---|
get_exchange_status |
Exchange trading status | ||
get_exchange_schedule |
Operating hours | ||
get_series_list |
category, tags | All series (leagues) | |
get_series |
series_ticker | Series details | |
get_events |
limit, cursor, status, series_ticker, with_nested_markets | Event listing | |
get_event |
event_ticker | with_nested_markets | Event details |
get_markets |
limit, cursor, event_ticker, series_ticker, status, tickers | Market listing | |
get_market |
ticker | Market details | |
get_trades |
limit, cursor, ticker, min_ts, max_ts | Recent trades | |
get_market_candlesticks |
series_ticker, ticker, start_ts, end_ts, period_interval | OHLC data | |
get_sports_filters |
Filter categories |
Sport Codes
US Sports
| Sport | Code | Series Ticker |
|---|---|---|
| NBA | nba |
KXNBA |
| NFL | nfl |
KXNFL |
| MLB | mlb |
KXMLB |
| NHL | nhl |
KXNHL |
| WNBA | wnba |
KXWNBA |
| College Football | cfb |
KXCFB |
| College Basketball | cbb |
KXCBB |
Football
| League | Code | Series Tickers |
|---|---|---|
| English Premier League | epl |
KXEPLGAME, KXEPLTOTAL, KXEPLBTTS, KXEPLSPREAD, KXEPLGOAL |
| Champions League | ucl |
KXUCL, KXUEFAGAME |
| La Liga | laliga |
KXLALIGA |
| Bundesliga | bundesliga |
KXBUNDESLIGA |
| Serie A | seriea |
KXSERIEA |
| Ligue 1 | ligue1 |
KXLIGUE1 |
| MLS | mls |
KXMLSGAME |
Examples
User: “What NBA markets are on Kalshi?”
- Call
search_markets(sport='nba')â same interface as polymarket - Present markets with yes/no prices and volume
User: “Show me Leeds vs Man City odds on Kalshi”
- Call
search_markets(sport='epl', query='Leeds')â searches all EPL series - Present markets with yes/no prices and volume
User: “What EPL games are available on Kalshi?”
- Call
get_todays_events(sport='epl')â returns events across all EPL series - Present events with nested markets
User: “Who will win the Champions League?”
- Call
search_markets(sport='ucl')orget_markets(series_ticker="KXUCL", status="open") - Sort by
last_pricedescending â price = implied probability (e.g., 20 = 20%) - Present top teams with
yes_sub_title,last_price, andvolume
User: “Show me the price history for this NBA game”
- Get the market ticker from
search_markets(sport='nba') - Call
get_market_candlesticks(series_ticker="KXNBA", ticker="...", start_ts=..., end_ts=..., period_interval=60) - Present OHLC data with volume
Common Mistakes
- Not using the
sportparameter âsearch_markets(query="Leeds")returns 0 results. Usesearch_markets(sport='epl', query='Leeds')instead. - Confusing NFL with football â on Kalshi, their “Football” category = NFL. For football (EPL, UCL, etc.), use sport codes
epl,ucl,laliga, etc. - Not knowing football is supported â Kalshi has deep EPL, UCL, and other football markets. Use
get_sports_config()to see all available sport codes.
Commands that DO NOT exist â never call these
â does not exist. Useget_oddssearch_marketsorget_marketsto find market prices.â does not exist. Kalshi has markets, not schedules. Use the sport-specific skill (nba-data, nfl-data, etc.) for schedules.get_team_schedule/get_scoresâ does not exist. Kalshi is a prediction market, not a scores provider. Use the sport-specific skill.get_results
If a command is not listed in the Commands Reference section above, it does not exist.
Error Handling & Fallbacks
- If search returns 0 results, make sure you’re using the
sportparameter. Without it, search misses single-game markets. - If series ticker returns no results, call
get_series_list()to discover available tickers. Seereferences/series-tickers.md. - If markets are empty, use
status="open"to filter. Default includes settled/closed markets. - Never fabricate market prices or probabilities. If no market exists, state so.