Options Flow Data API
Access the same institutional-grade options flow data that powers the CapitalFlow exchange terminal. Query trades, top contracts, and order flow analytics programmatically — or connect your AI tools via MCP.
Authentication
Include your API key in the X-API-Key header with every request. Generate keys from the Developer Dashboard.
X-API-Key: cfsk-your-api-key-hereTrades
Query live and historical options trade data from the CapitalFlow exchange. Trades are sourced in real-time from OPRA and reflect institutional-level order flow including sweeps, blocks, and multi-leg spreads. Data is partitioned by trade date for efficient historical lookups. When no date range is specified, defaults to the last 7 days.
Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
| symbols | string[] | — | Filter by one or more ticker symbols (1–10 letters each, e.g. SPY). Pass multiple via ?symbols=SPY&symbols=AAPL |
| premiumMinimum | number | 25000 | Minimum total premium spent (price × size × 100). Must be non-negative |
| minCreated | ISO 8601 | 7 days ago | Start of time window, e.g. 2026-03-10T09:30:00Z. Must be before maxCreated when both are provided |
| maxCreated | ISO 8601 | now | End of time window. Must be after minCreated when both are provided |
| tradeDirectionType | string | — | C for calls, P for puts. Returns 400 for other values |
| unusual | boolean | false | When true, returns only trades flagged as unusual activity (volume > open interest) |
| limit | integer | 100 | Results per page (1–500). Returns 400 if outside range |
| offset | integer | 0 | Pagination offset for scrolling through large result sets (0–10,000) |
Example Request
Response Fields
| Field | Type | Description |
|---|---|---|
| id | string | Unique trade identifier (contract descriptor) |
| created | string | Trade timestamp in Eastern Time (ISO 8601) |
| symbol | string | Underlying ticker symbol (e.g. SPY, AAPL) |
| contract | string | Full contract identifier |
| strike | number | Option strike price |
| expiration | string | Contract expiration date (YYYY-MM-DD) |
| type | string | C (call) or P (put) |
| price | number | Fill price per contract |
| size | integer | Number of contracts traded |
| premium | number | Total premium spent (price × size × 100) |
| bid | number? | NBBO bid at time of execution |
| ask | number? | NBBO ask at time of execution |
| sentiment | string? | Inferred trade sentiment: BULLISH, BEARISH, or NEUTRAL. Only populated when unusual=true |
| additionalType | string? | Trade execution type: SWEEP, BLOCK, SPLIT, etc. Only populated when unusual=true |
| unusual | boolean | Flagged as unusual activity (volume exceeds open interest) |
| totalVolume | integer? | Total daily volume on this contract at time of trade |
| openInterest | integer? | Open interest on the contract |
Example Response
Orders
Aggregated order flow analytics computed from the raw trade stream. Top contracts ranks individual option contracts by total premium accumulated throughout the current trading session. This surfaces where the biggest institutional bets are concentrated — useful for identifying conviction trades and significant positioning.
Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
| symbol | string | — | Filter by a single ticker symbol (1–10 letters, e.g. AAPL). Omit for all symbols |
| limit | integer | 50 | Number of top contracts to return (1–500). Returns 400 if outside range |
Example Request
Response Fields
| Field | Type | Description |
|---|---|---|
| trade_date | string | Trading session date (YYYY-MM-DD) |
| symbol | string | Underlying ticker symbol |
| contract | string | Full option contract identifier |
| strike | number | Strike price |
| expiration | string | Contract expiration date (YYYY-MM-DD) |
| type | string | C (call) or P (put) |
| total_premium | number | Aggregate premium across all fills on this contract today |
| total_contracts | integer | Total number of contracts traded |
| fill_count | integer | Number of individual trade executions (fills) |
| first_seen | string? | Timestamp of the first trade on this contract today |
| last_seen | string? | Timestamp of the most recent trade |
Example Response
Reports
AI-generated market analysis reports produced by CapitalFlow throughout the trading day. Hourly movers highlight the most significant flow during each trading hour. Daily summaries provide an end-of-day recap of key options activity, sentiment shifts, and notable positioning across the market. Report listing endpoints support cursor-based pagination — use the created timestamp of the last result as the before parameter to fetch the next page.
Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
| limit | integer | 20 | Number of reports to return, most recent first (1–50) |
| before | ISO 8601 | — | Cursor for pagination. Only reports created before this timestamp are returned. Use the created field of the last result to page through older reports |
Example Request
Response Fields
| Field | Type | Description |
|---|---|---|
| id | string | Unique report identifier (UUID) |
| title | string | Report title |
| description | string | Brief summary of the report's key findings |
| slug | string | URL-friendly slug for linking to the full report |
| created | string | Report generation timestamp (ISO 8601) |
| type | string | Report type |
Example Response
Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
| limit | integer | 20 | Number of reports to return, most recent first (1–50) |
| before | ISO 8601 | — | Cursor for pagination. Only reports created before this timestamp are returned. Use the created field of the last result to page through older reports |
Example Request
Response Fields
| Field | Type | Description |
|---|---|---|
| id | string | Unique report identifier (UUID) |
| title | string | Report title |
| description | string | Brief summary of the report's key findings |
| slug | string | URL-friendly slug for linking to the full report |
| created | string | Report generation timestamp (ISO 8601) |
| type | string | Report type |
Example Response
Retrieves the full analysis content for a specific report. The listing endpoints (/hourly and /daily) return metadata only — use the slug from those responses to fetch the complete analysis here. Content is stored separately to keep list responses lightweight and token-efficient for AI integrations.
Path Parameters
| Parameter | Type | Description |
|---|---|---|
| slug | string | Report slug from the listing endpoint response. Must be alphanumeric and hyphens only (max 200 characters) |
Example Request
Response Fields
| Field | Type | Description |
|---|---|---|
| title | string | Report title |
| summary | string | High-level summary of the report (markdown) |
| overview | string | Detailed analysis body (markdown) |
| conclusion | string | Concluding remarks and key takeaways |
| insights | array | Individual contract-level insights, each with contract, heading, and detail |
Example Response
MCP Integration
Model Context Protocol
CapitalFlow exposes an MCP server so your AI coding tools and chat agents can query real-time options flow data. Two transports are available:
Streamable HTTP (recommended): https://developer.capitalflow.app/mcp
SSE (legacy): https://developer.capitalflow.app/mcp/sse
Authentication: Claude Desktop uses OAuth 2.1 (auto-discovered, no manual config needed). All other clients use an API key via the X-API-Key header.
Available Tools:
get_trades— Query options trades with symbol, premium, date, and direction filtersget_top_contracts— Retrieve the highest premium contracts for the current sessionget_hourly_reports— List recent hourly mover analysis reportsget_daily_reports— List recent daily market summary reportsget_report_content— Fetch the full analysis content for a report by slug
Setup Instructions
Click any client below to see step-by-step setup. Replace YOUR_API_KEY with your actual key.
- Open Claude Desktop → Settings → Developer → Add MCP Server
- Enter the server URL:
https://developer.capitalflow.app/mcp - Claude Desktop will automatically discover OAuth configuration and prompt you to sign in with your CapitalFlow account.
- Approve the authorization request, and you're connected — no API key needed.
How it works: Claude Desktop uses OAuth 2.1 with auto-discovery (RFC 9728). It reads the protected resource metadata, registers as an OAuth client with Supabase, and handles token exchange automatically.
- Run the following in your terminal:
- Verify with
claude mcp list— you should seecapitalflow. - Use in any conversation: "Use the capitalflow tools to get SPY trades"
- Open Cursor Settings → Features → MCP Servers → Add New
- Or add manually to
.cursor/mcp.jsonin your project root:
- Restart Cursor. The tools will appear in Composer (Agent mode).
- Create or edit
.vscode/mcp.jsonin your workspace:
- Open Copilot Chat (Agent mode) — tools will be listed in the tool picker.
- Open Windsurf Settings → Cascade → MCP → Add Server → Custom
- Add to
~/.codeium/windsurf/mcp_config.json:
- Restart Windsurf. Tools will appear in Cascade chat.
- Open Settings → Tools → MCP Servers → Add Server
- Configure the server with the following:
- The CapitalFlow tools will be available in your next conversation.
- Open Perplexity → Settings → MCP Servers → Add
- Enter the server details:
- Enable the server toggle, then try: "What are the top SPY options trades today?"
- Open ChatGPT → Settings → Connected Tools → Add MCP Server
- Enter the connection details:
- Save and test with: "Get the top contracts for NVDA"
Rate Limits
Default rate limit is 60 requests/minute per API key. Rate limit headers are included in every response:
When the limit is exceeded, the API returns HTTP 429 with a Retry-After header indicating how many seconds to wait. Sustained abuse (10+ violations in 5 minutes) results in a temporary block. Blocked keys receive HTTP 403 until the block expires.
Troubleshooting
X-API-Key header (not as a query parameter or Bearer token). Make sure the key has not been revoked in the Developer Dashboard.Retry-After header for when to retry. Default limit is 60 requests/minute. Wait and retry, or contact support for a higher limit./mcp for Streamable HTTP or /mcp/sse for SSE.2. Ensure your API key is set in the headers configuration, not as a URL parameter.
3. Restart your client after editing the config file.
4. Check the client's MCP server status indicator — it should show connected/green.
/mcp/sse), not Streamable HTTP. Try switching transports. If using a VPN or firewall, ensure HTTPS traffic to developer.capitalflow.app is allowed.premiumMinimum filter is $25,000 — trades below this threshold are excluded. Set premiumMinimum=0 to see all trades. Also verify that the market was open during the time range you're querying./health to verify service status, or contact support with the response timestamp.