Context MCP Server
OfficialClick on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Context MCP Serverlist active prediction markets"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Quick Start
Claude Code
claude mcp add context-markets -- npx context-markets-mcpClaude Desktop
Add to your claude_desktop_config.json:
{
"mcpServers": {
"context-markets": {
"command": "npx",
"args": ["context-markets-mcp"]
}
}
}No environment variables needed — the server walks you through setup on first use.
Related MCP server: polymarket-mcp
Getting Started
The first time you (or your agent) use a trading tool, the server will guide you through onboarding:
Wallet —
context_generate_walletcreates a new wallet or imports an existing private keySave credentials — persists to
~/.config/context/config.env(chmod 600, shared with the CLI)API key — pass your Context API key (get one at context.markets) via the
apiKeyparamApprove contracts —
context_account_setupapproves on-chain (requires ETH on Base for gas)Deposit USDC —
context_depositdeposits USDC into the exchange
If anything fails (no ETH, rate limit, etc.), you can re-run the same tool — it detects your existing config and picks up where you left off.
Manual setup
If you prefer to configure manually:
# Option 1: Environment variables
export CONTEXT_API_KEY="your-api-key"
export CONTEXT_PRIVATE_KEY="0x..."
# Option 2: Config file (created by context_generate_wallet or `context setup` in the CLI)
# ~/.config/context/config.envCredentials are loaded in order: env vars > config file.
Need an API key? Visit context.markets.
Available Tools
Read-only (no wallet needed)
Tool | Description | Key Params |
| List and search prediction markets on Context Markets |
|
| Get detailed information about a specific prediction market |
|
| Get current bid/ask/last prices for a market's YES and NO outcomes |
|
| Get the orderbook (bid/ask ladder) for a market |
|
| Simulate a trade to estimate fill price, cost, and slippage |
|
| Get historical price data for a market over a specified timeframe |
|
| Get the AI oracle's resolution analysis for a market |
|
| Get recent trading activity across all markets | -- |
Account setup and funding
Tool | Description | Key Params |
| Generate a new wallet or import an existing key |
|
| Get address, balances, and approval status | -- |
| Approve USDC spending and operator permissions | -- |
| Deposit USDC into the exchange |
|
| Withdraw USDC from the exchange back to your wallet |
|
| Mint test USDC on Base Sepolia |
|
Trading and orders
Tool | Description | Key Params |
| Place a buy or sell order on a prediction market |
|
| Cancel an open order |
|
| Atomically cancel an existing order and place a new one |
|
| List your open orders |
|
| Create multiple orders in a single atomic batch |
|
| Cancel multiple open orders in a single batch |
|
| Atomically create and cancel orders in a single batch |
|
Portfolio
Tool | Description | Key Params |
| Get positions with P&L |
|
| Get USDC balance and token holdings | -- |
Market creation
Tool | Description | Key Params |
| Create a market from a question |
|
| Submit a fully formed market draft, wait for oracle approval, and create it on-chain |
|
Key Concepts
Prices are in cents (1–99). A price of 65 means $0.65 per share.
Outcomes are yes or no. Each market is a binary question.
Read-only tools work with zero config. Trading tools need a wallet — run
context_generate_walletfirst.Shared config. The MCP server and CLI share
~/.config/context/config.env, so you only set up once.
Documentation
Tool Catalog — full list of tools with parameters and examples
MCP Guide — setup, configuration, and usage patterns
Ecosystem
Package | Description |
TypeScript SDK for trading | |
React hooks for market data and trading | |
MCP server for AI agents | |
CLI for trading from the terminal | |
AI agent skill files | |
Claude Code plugin |
License
MIT — see LICENSE for details.
This server cannot be deployed
Maintenance
Related MCP Connectors
Calibrated world model for AI agents. 40 tools: world state, markets, trading. Kalshi + Polymarket.
Pay-per-use tool marketplace for AI agents. Search, price-check, and call APIs via MCP.
OpenFinance gives any AI agent easy trading across every major market through one hosted MCP server. Trade crypto spot and perpetuals on Hyperliquid with market, limit and TWAP orders, leverage and margin control. Trade stocks, indices, commodities, forex and pre-IPO names as Hyperliquid HIP-3 perps. Trade Polymarket prediction markets with odds, order books, positions, PnL and trader leaderboards. Swap and bridge across 40+ EVM chains and Solana with Relay and Jupiter, find memecoins across 200+ chains, launch tokens on Robinhood Chain and Solana, and buy crypto with card, bank or UPI. Write actions are designed to ask for your confirmation first. Connect with OAuth (sign in to OpenFinance and approve) or an API key. Works with Claude, ChatGPT, Cursor, VS Code, Codex and any MCP client. No install. Home: https://openfinance.tech/agents · Docs: https://docs.openfinance.tech · GitHub: https://github.com/openfinance-tech/mcp
Agent MCP: 65 tools — 5-chain verification, risk, prediction & crypto trends, 17 web tools.
Related MCP Servers
- AlicenseBqualityNot gradedmaintenanceEnables AI agents to interact with the Polymarket prediction market platform to discover markets, analyze real-time pricing, and monitor public portfolio data. It provides comprehensive access to market analytics, implied probabilities, and order books through the Model Context Protocol.5926 npm-
- AlicenseAqualityCmaintenanceEnables AI agents to discover and analyze prediction markets, execute trades, and manage positions on Polymarket via the Model Context Protocol.718 npm20MIT
- AlicenseAqualityDmaintenanceProvides search, trending, odds, arbitrage, and category browsing for prediction markets (Polymarket & Kalshi) via the Model Context Protocol, enabling AI agents to access live market data without API keys.51MIT
- AlicenseNot gradedqualityDmaintenanceEnables AI agents to trade on Limitless prediction markets on Base via MCP, with tools for wallet management, market discovery, order placement, and portfolio tracking.PolyForm Noncommercial 1.0.0