@newyorkcompute/kalshi-tui
v0.8.1
Published
Beautiful terminal UI for Kalshi prediction markets — real-time data, trading, and portfolio management
Maintainers
Readme
@newyorkcompute/kalshi-tui
Free. Open source. Beautiful.
A terminal so polished that the screenshot alone is the pitch. Real-time market data, orderbook visualization, portfolio management, and trading — all without leaving your terminal.
No AI. No gimmicks. Pure craft.
Installation
npx @newyorkcompute/kalshi-tuiOr install globally:
npm install -g @newyorkcompute/kalshi-tuiScreenshot
┌──────────────────────────────────────────────────────────────────────────────┐
│ ▓ KALSHI Balance: $1,234.56 ◉ │
│ NEW YORK COMPUTE │
├────────────────────────────────────┬─────────────────────────────────────────┤
│ MARKETS [F1] │ ORDERBOOK: KXBTC-25JAN-B100 │
│ ──────────────────────────────────│ ───────────────────────────────────── │
│ KXBTC-25JAN-B100 45¢ ▲ +2 │ ASK ████████████████ 52¢ (120) │
│ KXBTC-25JAN-B105 32¢ ▼ -1 │ ASK ████████████ 50¢ (85) │
│ KXETH-25JAN-B4000 67¢ ━ 0 │ BID ██████████ 46¢ (60) │
│ TRUMP-WIN-2024 52¢ ▲ +5 │ BID ████████████████ 42¢ (150) │
├───────────────────────────────────┼─────────────────────────────────────────┤
│ POSITIONS [F2] │ QUICK TRADE [F4] │
│ ──────────────────────────────────│ ───────────────────────────────────── │
│ KXBTC-25JAN-B100 +10 YES $45 │ Ticker: KXBTC-25JAN-B100 │
│ TRUMP-WIN-2024 -5 NO $26 │ Side: [YES] NO │
│ ──────────────────────────────────│ Qty: 10 Price: 45¢ │
│ Total Exposure: $71 │ Cost: $4.50 [BUY] │
├───────────────────────────────────┴─────────────────────────────────────────┤
│ Built by New York Compute • newyorkcompute.xyz [?] Help [q] Quit │
└──────────────────────────────────────────────────────────────────────────────┘Features
- Market Watch - Real-time prices with keyboard navigation
- Orderbook - Visual depth chart for selected market
- Portfolio - Live balance and position tracking
- Quick Trade - Place orders without leaving the terminal
- Keyboard-first - Full navigation without a mouse
Keybindings
| Key | Action |
|-----|--------|
| ↑ / ↓ | Navigate markets |
| Enter | Select market |
| Tab | Toggle YES/NO side |
| [ / ] | Adjust quantity |
| - / + | Adjust price |
| ? | Show help |
| q | Quit |
Environment Variables
| Variable | Required | Description |
|----------|----------|-------------|
| KALSHI_API_KEY | Yes | Your Kalshi API key ID |
| KALSHI_PRIVATE_KEY | Yes | RSA private key (PEM format) |
| KALSHI_BASE_PATH | No | API base URL (default: production) |
Usage
# With environment variables
export KALSHI_API_KEY="your-api-key"
export KALSHI_PRIVATE_KEY="-----BEGIN RSA PRIVATE KEY-----
...
-----END RSA PRIVATE KEY-----"
kalshi-tuiGetting API Keys
- Log into your Kalshi account
- Go to Account Settings → API
- Generate a new API key (you'll create an RSA key pair)
- Save your API Key ID and private key securely
Development
# Install dependencies
npm install
# Build the TUI
npx nx run @newyorkcompute/kalshi-tui:build
# Run the TUI (loads .env.local)
npx dotenv -e .env.local -- node packages/tui/dist/cli.jsWatch Mode
For active development, run the build in watch mode in one terminal:
# Terminal 1: Watch for changes
npx nx run @newyorkcompute/kalshi-tui:devThen run the TUI in another terminal:
# Terminal 2: Run the app (re-run after changes compile)
npx dotenv -e .env.local -- node packages/tui/dist/cli.jsTech Stack
Built By
New York Compute — Command-native tools for quantitative research, execution, and market intelligence.
Want this for equities? Request early access →
License
MIT © NewYorkCompute
