Tutorials Get the App

Home · Learn · Kalshi trading bot

Kalshi trading bot: how the API works

A Kalshi trading bot places orders through Kalshi's documented APIs for event-contract markets, using REST, WebSocket or FIX. Kalshi offers a demo environment with mock funds, API keys and token-based rate limits that depend on your tier. You agree to Kalshi's Developer Agreement by using the API.

Updated November 23, 2026 · By Moby

Sources checked November 23, 2026

Moby doesn't offer prediction markets today. This page is general education, not advice.

What the Kalshi API covers

Kalshi's welcome page describes Predictions APIs for event-contract markets: REST, WebSocket and FIX. The same page says that continuing to use the API means you agree to the Developer Agreement. It also lists API keys, a demo environment, and an MCP connector for an AI assistant.

API at a glance

PieceWhat the docs saySource
Event contractsREST, WebSocket and FIX.Welcome
Demodemo.kalshi.co, mock funds, credentials not shared with production. Recommended REST root: external-api.demo.kalshi.co/trade-api/v2.Demo environment
KeysYou sign each request with a private key. Kalshi stores the public key. The private key is shown once.API keys
LimitsToken budgets by tier. Basic Read is 200 tokens per second and Basic Write is 100. Most requests cost 10 tokens. A batch does not get a discount.Rate limits
AI assistantAn MCP connector is listed for exploring markets, reading a portfolio and managing price alerts.MCP connector

Start in the demo environment

Kalshi's demo page says the demo environment uses mock funds and that credentials are not shared with production. The price and behavior of demo markets may not match real markets. The recommended demo REST root on that page is https://external-api.demo.kalshi.co/trade-api/v2. Build there before you point a bot at production.

API keys and authentication

The API keys page says you create a key pair from account settings, or register a public key you generated. Requests carry the key id, a timestamp and a signature over the timestamp, the method and the path. The private key is not stored for you to download again. Follow Kalshi's page if you create a key.

Rate limits and tiers

Limits are token budgets. At the Basic tier the Read budget is 200 tokens per second and the Write budget is 100. The default cost is 10 tokens. Kalshi's page says Basic Write buckets hold one second of budget. Advanced access is requested through an upgrade endpoint, and Kalshi says at least one of your latest 100 orders must have been placed through the API or that call is refused. Higher tiers raise the budgets. Kalshi says some of those tiers come from trading activity, or are assigned by Kalshi. A request over the limit returns 429 without a Retry-After header, and the page says to apply exponential backoff.

Arithmetic on the documented numbers. At Basic, Write is 100 tokens per second and an order costs 10 tokens by default, so 10 order writes per second can be sustained. A batch of 25 orders costs 250 tokens, because each order is billed. 250 is greater than 100, so that batch cannot fit in a Basic Write bucket in one go.

Building responsibly

Where Moby fits

Moby doesn't offer prediction markets today. Moby's agents trade Solana tokens from a side wallet you fund. That is a different product from a Kalshi event-contract bot. See agentic trading for the Solana agent.

Sources

Frequently asked questions

Does Kalshi have an API for trading bots?

Yes. Kalshi's docs describe REST, WebSocket and FIX APIs for event-contract markets, plus API keys and a demo environment with mock funds. Using the API means agreeing to Kalshi's Developer Agreement. Moby doesn't offer prediction markets today.

Can I test a Kalshi bot without real money?

Kalshi offers a demo environment with mock funds, separate credentials from production, and its own API endpoints. Kalshi warns that demo prices and behavior may not match real markets. Moby doesn't offer prediction markets today.

What are Kalshi's API rate limits?

At Kalshi's Basic tier, Read is 200 tokens per second and Write is 100. Most requests cost 10 tokens. A limited request returns 429, and Kalshi says to back off. Moby doesn't offer prediction markets today.

Can an AI assistant connect to Kalshi?

Kalshi's welcome page lists an MCP connector so an AI assistant can explore markets, read a portfolio and manage price alerts. That connector is Kalshi's. Moby doesn't offer prediction markets today.

What you can do on Moby today

Moby is the side wallet your AI agent trades from. You fund it with what you choose, and the agent trades Solana tokens from that wallet. You set your agent's per-trade and daily spending limits and market-cap range; Moby blocks red-rated tokens. The agent cannot withdraw, transfer or send funds. No subscription. Pay only a 0.75% swap fee ($0.90 minimum). AI Trading needs an access pass on Moby today. Download Moby to get started.

AI trading bot · Agentic trading · Is AI trading legit · Agentic trading glossary · Polymarket trading bot · MCP for trading · Build a trading bot in Python · AI agent security