# Context Docs ## Docs - [Command reference](https://docs.context.markets/agents/cli/commands.md): Complete reference for all Context CLI commands - [CLI](https://docs.context.markets/agents/cli/index.md): Command-line tool for trading on Context Markets with JSON output for agents and scripts - [Agent workflows](https://docs.context.markets/agents/cli/workflows.md): End-to-end scripting patterns for trading agents using the Context CLI - [For agents](https://docs.context.markets/agents/index.md): Everything AI agents need to trade prediction markets on Context - [MCP server](https://docs.context.markets/agents/mcp/index.md): Connect AI agents to Context Markets with 25 tools for browsing, trading, and creating prediction markets - [Tool catalog](https://docs.context.markets/agents/mcp/tools.md): All available MCP tools for Context Markets - [Claude Code plugin](https://docs.context.markets/agents/plugin.md): One install: MCP server, expert skills, and reference files for Context Markets - [Best practices](https://docs.context.markets/agents/react-sdk/best-practices.md): Recommended patterns for using the Context React SDK - [Hooks reference](https://docs.context.markets/agents/react-sdk/hooks-reference.md): Complete hook API reference for the Context React SDK - [React SDK](https://docs.context.markets/agents/react-sdk/index.md): React hooks for prediction market data, trading, and portfolio management on Context Markets - [Build skill](https://docs.context.markets/agents/skills/build.md): Skill for building prediction market frontends with the Context React SDK - [Create skill](https://docs.context.markets/agents/skills/create.md): Create prediction markets from natural language - [Skills](https://docs.context.markets/agents/skills/index.md): Model-agnostic instruction sets that teach AI agents how to trade prediction markets on Context - [Research skill](https://docs.context.markets/agents/skills/research.md): Skill for market discovery, price analysis, and portfolio monitoring on Context Markets - [Trade skill](https://docs.context.markets/agents/skills/trade.md): Skill for order management, market making, and orderbook trading on Context Markets - [API reference](https://docs.context.markets/agents/typescript-sdk/api-reference.md): Complete method signatures for the Context TypeScript SDK - [Best practices](https://docs.context.markets/agents/typescript-sdk/best-practices.md): Recommended patterns for agents using the Context TypeScript SDK - [TypeScript SDK](https://docs.context.markets/agents/typescript-sdk/index.md): Type-safe SDK for trading on Context Markets with automatic EIP-712 signing - [Dismiss pending migration restorations](https://docs.context.markets/api-reference/account/dismiss-pending-migration-restorations.md) - [Execute sponsored legacy funds migration](https://docs.context.markets/api-reference/account/execute-sponsored-legacy-funds-migration.md) - [Get migration status](https://docs.context.markets/api-reference/account/get-migration-status.md) - [Restore retired legacy orders as SettlementV2 orders](https://docs.context.markets/api-reference/account/restore-retired-legacy-orders-as-settlementv2-orders.md) - [Start migration by retiring legacy orders](https://docs.context.markets/api-reference/account/start-migration-by-retiring-legacy-orders.md) - [List global market activity](https://docs.context.markets/api-reference/activity/list-global-market-activity.md) - [Get balance summary for address](https://docs.context.markets/api-reference/balance/get-balance-summary-for-address.md) - [Get ERC-20 balance](https://docs.context.markets/api-reference/balance/get-erc-20-balance.md) - [Get settlement balance](https://docs.context.markets/api-reference/balance/get-settlement-balance.md) - [Mint test USDC](https://docs.context.markets/api-reference/balance/mint-test-usdc.md) - [Relay setOperatorBySig](https://docs.context.markets/api-reference/gasless/relay-setoperatorbysig.md) - [Create market from question submission](https://docs.context.markets/api-reference/markets/create-market-from-question-submission.md) - [Get market](https://docs.context.markets/api-reference/markets/get-market.md) - [Get market activity](https://docs.context.markets/api-reference/markets/get-market-activity.md) - [Get market orderbook](https://docs.context.markets/api-reference/markets/get-market-orderbook.md) - [Get market price history](https://docs.context.markets/api-reference/markets/get-market-price-history.md) - [Get oracle summary](https://docs.context.markets/api-reference/markets/get-oracle-summary.md) - [List markets](https://docs.context.markets/api-reference/markets/list-markets.md) - [Search markets](https://docs.context.markets/api-reference/markets/search-markets.md) - [Simulate market trade](https://docs.context.markets/api-reference/markets/simulate-market-trade.md) - [Bulk cancel orders](https://docs.context.markets/api-reference/orders/bulk-cancel-orders.md) - [Bulk create orders](https://docs.context.markets/api-reference/orders/bulk-create-orders.md) - [Bulk order operations](https://docs.context.markets/api-reference/orders/bulk-order-operations.md) - [Cancel and replace order](https://docs.context.markets/api-reference/orders/cancel-and-replace-order.md) - [Cancel order](https://docs.context.markets/api-reference/orders/cancel-order.md) - [Create order](https://docs.context.markets/api-reference/orders/create-order.md) - [Get order by id](https://docs.context.markets/api-reference/orders/get-order-by-id.md) - [List orders](https://docs.context.markets/api-reference/orders/list-orders.md) - [List recent orders](https://docs.context.markets/api-reference/orders/list-recent-orders.md) - [Simulate order execution](https://docs.context.markets/api-reference/orders/simulate-order-execution.md) - [Get claimable positions](https://docs.context.markets/api-reference/portfolio/get-claimable-positions.md) - [Get portfolio positions](https://docs.context.markets/api-reference/portfolio/get-portfolio-positions.md) - [Get portfolio stats](https://docs.context.markets/api-reference/portfolio/get-portfolio-stats.md) - [Get portfolio summary](https://docs.context.markets/api-reference/portfolio/get-portfolio-summary.md) - [Get submission status](https://docs.context.markets/api-reference/questions/get-submission-status.md) - [Submit market draft directly](https://docs.context.markets/api-reference/questions/submit-market-draft-directly.md) - [Submit question for generation](https://docs.context.markets/api-reference/questions/submit-question-for-generation.md) - [Changelog](https://docs.context.markets/changelog/index.md): What's new in Context - [Geoblocking](https://docs.context.markets/developers/api-reference/geoblocking.md): Geographic restrictions for the Context API - [API reference](https://docs.context.markets/developers/api-reference/index.md): Authentication, rate limits, and API conventions - [Rate limits](https://docs.context.markets/developers/api-reference/rate-limits.md): API rate limits for read and write requests - [Common flows](https://docs.context.markets/developers/contracts/common-flows.md): Step-by-step examples for funding, trading, minting, redeeming, and converting positions - [Holdings](https://docs.context.markets/developers/contracts/holdings.md): Internal token ledger — deposits, withdrawals, transfers, operator approvals, and signature-based flows - [MarketFactory](https://docs.context.markets/developers/contracts/market-factory.md): Core market lifecycle contract — creation, resolution, mint/burn/redeem, and negative-risk conversion - [Settlement](https://docs.context.markets/developers/contracts/settlement.md): Order settlement contract — signed order execution plus Holdings-native mint/burn/redeem/conversion flows - [API keys](https://docs.context.markets/developers/guides/api-keys.md): How to create and manage API keys for the Context API - [Before you trade](https://docs.context.markets/developers/guides/before-you-trade.md): Required wallet setup — approve contracts and deposit USDC before placing orders - [Contract migration guide](https://docs.context.markets/developers/guides/contract-migration.md): Upgrade to Holdings and Settlement V2 for improved market execution and quoting - [Fetching market data](https://docs.context.markets/developers/guides/fetching-market-data.md): How to query markets, prices, and orderbooks using the SDK - [Placing your first order](https://docs.context.markets/developers/guides/placing-first-order.md): Step-by-step guide to submitting orders on Context - [Protocol overview](https://docs.context.markets/developers/guides/protocol-overview.md): How the Context protocol works onchain — contracts, order signing, token mechanics, and negative risk - [Quickstart](https://docs.context.markets/developers/guides/quickstart.md): Fetch market data from Context in under 2 minutes - [Introduction](https://docs.context.markets/developers/index.md): Build on Context - the onchain prediction market with AI-native resolution - [Testnet addresses](https://docs.context.markets/developers/testnet/addresses.md): Contract addresses for Context Markets on Base Sepolia - [Testnet vs mainnet](https://docs.context.markets/developers/testnet/differences.md): Differences between the Context Markets testnet and mainnet environments - [Using the testnet](https://docs.context.markets/developers/testnet/index.md): How to connect to the Context Markets testnet for development and testing - [FAQs](https://docs.context.markets/learn/faqs.md): Frequently asked questions about Context - [Create an account](https://docs.context.markets/learn/getting-started/create-account.md): Set up your Context account and fund it with USDC - [Create your first market](https://docs.context.markets/learn/getting-started/create-market.md): Launch a prediction market on Context - [Make your first trade](https://docs.context.markets/learn/getting-started/first-trade.md): Buy and sell outcome tokens on Context - [What is Context?](https://docs.context.markets/learn/index.md): A prediction market where you trade on real-world outcomes - [How markets resolve](https://docs.context.markets/learn/markets/how-markets-resolve.md): What happens when a market ends and how you claim winnings - [How markets work](https://docs.context.markets/learn/markets/how-markets-work.md): Understanding prediction markets, prices, and the orderbook - [Get help](https://docs.context.markets/learn/support.md): Contact the Context Markets team for support ## OpenAPI Specs - [openapi](https://api.context.markets/v2/openapi.json)