
Kalshi
io.github.yakub268由 GitHub 帳號 yakub268 發布v0.1.1更新於 Oct 24, 2026
Search, analyze, and trade Kalshi prediction markets through Claude Desktop
概覽
一個本機 MCP 伺服器,讓助理搜尋、分析並交易 Kalshi 預測市場,包括在 Claude Desktop 中下限價單。
- 可以做什麼
- 依關鍵字搜尋市場,查看熱門市場或某個系列下的所有市場,並取得價格與成交量。查看指定市場的完整資訊與訂單簿深度。讀取帳戶餘額與持倉,並以餘額和持倉資源形式提供。在 Kalshi 市場下限價單。
- 適用情境
- 適合想在對話中研究 Kalshi 預測市場、查看自身持倉,或直接下限價單的使用者。已擁有 Kalshi 帳戶與 API 憑證的人最適用。
- 執行需求
- 以 Python 套件形式在本機執行(需 Python 3.10+),並在 Claude Desktop 中設定。需要 Kalshi API key ID(KALSHI_API_KEY)與 RSA 私鑰 .pem 檔案路徑(KALSHI_PRIVATE_KEY_PATH)。需要連線至 Kalshi 的網路存取。
安裝
在 SourceWeft 中
- 開啟 儀表板中的 Kalshi,將其新增到工作區。
- 為需要使用其工具的對話啟用該服務。
Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。
其他 MCP 客戶端
參照 儲存庫 中的啟動說明。
README
Kalshi MCP Server
mcp-name: io.github.yakub268/kalshi
Model Context Protocol server for Kalshi prediction markets. Search, analyze, and trade prediction markets directly through Claude Desktop.
Built with production-grade authentication and rate limiting from a live trading system with 4+ months of uptime.
Features
Tools (6)
search_markets- Search by keyword, get prices/volumeget_market_details- Full market info + orderbook depthget_portfolio- Account balance + open positionsget_trending_markets- Top markets by 24h volumeplace_order- Execute limit ordersget_series_markets- All markets in a series (e.g., Fed events)
Resources (2)
kalshi://balance- Current account balancekalshi://positions- Open positions list
Installation
Prerequisites
-
Kalshi API credentials: Get from kalshi.com/profile/api-keys
- Download your API key ID
- Download the RSA private key (.pem file)
-
Python 3.10+
Quick Install (PyPI)
From Source
Claude Desktop Configuration
Add to your Claude Desktop config file:
macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
Windows: %APPDATA%\Claude\claude_desktop_config.json
Note:
- Replace
your-api-key-herewith your actual Kalshi API key - Update the private key path to where you saved your
.pemfile - On Windows, use double backslashes (
\\) in paths
Test the Connection
Restart Claude Desktop, then try:
or
Usage Examples
Search for Markets
Get Market Analysis
Check Portfolio
Place an Order
Authentication
This server uses RSA-PSS signature authentication:
- Each request is signed with your private key
- Kalshi verifies the signature with your public key
- Thread-safe rate limiting (150ms between requests)
- Automatic retry on 429 rate limit errors
Security: Your private key never leaves your machine. The server only signs requests locally.
Rate Limiting
- Built-in 150ms spacing between requests (~6.6 req/s)
- Automatic exponential backoff on 429 errors (0.5s → 1s → 2s)
- Safe for concurrent use across multiple Claude conversations
Architecture
Built on production code from a live Kalshi trading bot:
- Authentication: Reused from
kalshi_client.py(4+ months uptime) - Rate limiting: Shared across all client instances
- Error handling: Battle-tested retry logic
- Market discovery: Liquidity scoring from
scanner.py
Contributing
Issues and PRs welcome! This is an open-source project built to fill a gap in the MCP ecosystem.
License
MIT License - see LICENSE file
Acknowledgments
- Built with FastMCP
- Kalshi API documentation: docs.kalshi.com
- Production code from my trading bot arsenal
Questions? Open an issue or reach out on GitHub.
來源:README.md,提交 70fe3a7
工具
0版本歷史
1- v0.1.1最新Sep 16, 2026
評分
已滿足適用檢查項的 50%
該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。
- 近 30 天內可連通25 分
請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。
- 已宣告認證方式10 分
請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。
- 已列出工具15 分
請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。
- 描述必需15 分
- 圖示10 分
- 文件15 分
- 授權條款10 分