{"openapi":"3.1.0","info":{"title":"Cabrini.ai — Market Data API for AI Agents","version":"3.0.0","description":"23 years of multi-timeframe OHLCV data for all US equities (2003–present), plus SEC EDGAR fundamentals, filings, and insider data. Pay per query via x402 micropayments (USDC on Base). No API keys, no subscriptions.\n\n## Payment Flow\n1. POST/GET any paid endpoint without payment → HTTP 402 + `payment-required` header\n2. Decode header (base64 JSON) → get amount, receiver address, network, asset\n3. Sign a USDC `transferWithAuthorization` (EIP-3009) on Base mainnet\n4. Retry the same request with `X-PAYMENT: <base64 signed payload>` header\n5. Receive HTTP 200 + data + `payment-response` settlement receipt\n\n## Libraries\n- **Python:** `pip install x402 httpx eth-account` — use `x402ClientSync().register()` with `EthAccountSigner`\n- **TypeScript:** `npm install x402-fetch viem` — use `wrapFetchWithPayment(fetch, account)`\n\n## Discovery\n- MCP server: `https://cabrini.ai/mcp` — paid tools are payable in-band via the\n  x402 MCP transport binding: terms arrive as an `isError` tool result, payment goes\n  back in `params._meta[\"x402/payment\"]`, settlement in `result._meta[\"x402/payment-response\"]`\n- x402 manifest: `https://cabrini.ai/.well-known/x402`\n- Agent card (A2A): `https://cabrini.ai/.well-known/agent-card.json`\n"},"servers":[{"url":"https://cabrini.ai","description":"Production"}],"components":{"securitySchemes":{"x402":{"type":"apiKey","in":"header","name":"X-PAYMENT","description":"x402 v2 payment. Base64-encoded signed payment payload (EIP-3009 transferWithAuthorization for USDC on Base)."}},"schemas":{"BarData":{"type":"object","description":"Intraday bar. Carries both absolute OHLC price levels and each one's fractional change from that day's open: pct_x = (bar_x - day_open) / day_open, so day_open * (1 + pct_x) = bar_x. Both are in this response — no second call.","properties":{"window_start":{"type":"string","example":"2024-01-02T14:30:00","description":"Bar start, ISO 8601 UTC"},"timestamp":{"type":"integer","description":"Bar start, nanoseconds since Unix epoch, UTC"},"open":{"type":"number","example":191.52,"description":"Absolute price at bar open"},"high":{"type":"number","example":191.76,"description":"Absolute high within the bar"},"low":{"type":"number","example":191.43,"description":"Absolute low within the bar"},"close":{"type":"number","example":191.68,"description":"Absolute price at bar close"},"pct_open":{"type":"number","example":0.0,"description":"Fractional change of the bar open from the daily open"},"pct_high":{"type":"number","example":0.001253,"description":"Fractional change of the bar high from the daily open"},"pct_low":{"type":"number","example":-0.00047,"description":"Fractional change of the bar low from the daily open"},"pct_close":{"type":"number","example":0.000835,"description":"Fractional change of the bar close from the daily open"},"volume":{"type":"integer","description":"Shares traded in the bar"},"transactions":{"type":"integer","description":"Trade count in the bar"},"_note":{"type":"string","description":"The enclosing response also carries a day-level range_pct = (high - low) / open"}}},"DailyBar":{"type":"object","description":"Daily aggregate: absolute price levels rolled up to the session, plus VWAP and volatility.","properties":{"date":{"type":"string","example":"2024-01-15"},"open":{"type":"number","example":182.16},"high":{"type":"number","example":185.34},"low":{"type":"number","example":181.92},"close":{"type":"number","example":184.78},"volume":{"type":"integer","example":67234521},"transactions":{"type":"integer","example":892341},"vwap":{"type":"number","example":183.94,"description":"sum((h+l+c)/3 * volume) / sum(volume) across the day's minute bars"},"range_pct":{"type":"number","example":0.01878,"description":"(high - low) / open — intraday swing as a fraction, ignores overnight gaps. Computed over the full session in our data, which includes pre- and post-market prints, so it runs wider than a regular-session-only range."},"true_range_pct":{"type":"number","nullable":true,"example":0.02143,"description":"(max(high, prev_close) - min(low, prev_close)) / prev_close — standard true range, includes the overnight gap. Null when no prior close is available."}}}}},"security":[{"x402":[]}],"paths":{"/v1/query":{"post":{"operationId":"query_minute_bars","summary":"Query intraday bars — one ticker, one day ($0.025)","description":"Returns a full trading day of intraday bars for one US stock. Every bar carries absolute open/high/low/close and the matching pct_open/pct_high/pct_low/pct_close (fractional change from that day's open), plus raw volume and transactions. Default 3-minute bars (~130 bars/day). Supports 3/6/9/12/15/30/60/240 minute intervals.","parameters":[{"name":"X-PAYMENT","in":"header","required":false,"description":"Base64-encoded x402 payment payload. On first request without this header, the server returns HTTP 402 with a `payment-required` header containing base64-encoded JSON payment terms (amount, receiver, network, asset). Sign the USDC transferWithAuthorization on Base and retry with this header.","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["ticker","date"],"properties":{"ticker":{"type":"string","example":"AAPL","description":"US stock ticker symbol"},"date":{"type":"string","example":"2024-01-15","description":"Trading date (YYYY-MM-DD, 2003-09 to present)"},"interval":{"type":"integer","enum":[3,6,9,12,15,30,60,240],"default":3,"description":"Bar interval in minutes"},"adjusted":{"type":"boolean","default":false,"description":"Split-adjusted prices"}}}}}},"responses":{"200":{"description":"Intraday bars — absolute OHLC plus fractional change from the daily open on every bar. A `payment-response` header contains the base64-encoded settlement receipt with transaction hash.","headers":{"payment-response":{"description":"Base64 JSON: {x402Version, success, settlement: {transaction, network, payer}}","schema":{"type":"string"}}}},"402":{"description":"Payment required. Decode the `payment-required` response header (base64 JSON) for x402 v2 terms: amount, receiver, network, asset.","headers":{"payment-required":{"description":"Base64-encoded JSON: {x402Version, accepts: [{scheme, network, amount, payTo, asset, maxTimeoutSeconds, extra}]}","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string","example":"payment_required"},"message":{"type":"string"},"price":{"type":"string","example":"$0.025 USDC"},"payment_info":{"type":"object","properties":{"network":{"type":"string","example":"Base (eip155:8453)"},"asset":{"type":"string","example":"USDC"},"receiver":{"type":"string","example":"0xb40867B72334463eE9bF5D2bD933eab5FB4ab8e0"},"protocol":{"type":"string","example":"x402 v2"}}}}}}}}}}},"/v1/range":{"post":{"operationId":"query_range","summary":"Multi-day intraday bars — one ticker, date range ($0.01/trading day)","description":"Returns intraday bars across multiple trading days for one ticker. No day limit. Price scales with the number of trading days in the range.","parameters":[{"name":"X-PAYMENT","in":"header","required":false,"description":"Base64-encoded x402 payment payload. On first request without this header, the server returns HTTP 402 with a `payment-required` header containing base64-encoded JSON payment terms (amount, receiver, network, asset). Sign the USDC transferWithAuthorization on Base and retry with this header.","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["ticker","start","end"],"properties":{"ticker":{"type":"string","example":"AAPL"},"start":{"type":"string","example":"2024-01-02","description":"Start date (YYYY-MM-DD)"},"end":{"type":"string","example":"2024-01-16","description":"End date (YYYY-MM-DD)"},"interval":{"type":"integer","enum":[3,6,9,12,15,30,60,240],"default":3},"adjusted":{"type":"boolean","default":false}}}}}},"responses":{"200":{"description":"Intraday bars — absolute OHLC plus fractional change from the daily open on every bar. A `payment-response` header contains the base64-encoded settlement receipt with transaction hash.","headers":{"payment-response":{"description":"Base64 JSON: {x402Version, success, settlement: {transaction, network, payer}}","schema":{"type":"string"}}}},"402":{"description":"Payment required. Decode the `payment-required` response header (base64 JSON) for x402 v2 terms: amount, receiver, network, asset.","headers":{"payment-required":{"description":"Base64-encoded JSON: {x402Version, accepts: [{scheme, network, amount, payTo, asset, maxTimeoutSeconds, extra}]}","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string","example":"payment_required"},"message":{"type":"string"},"price":{"type":"string","example":"$0.025 USDC"},"payment_info":{"type":"object","properties":{"network":{"type":"string","example":"Base (eip155:8453)"},"asset":{"type":"string","example":"USDC"},"receiver":{"type":"string","example":"0xb40867B72334463eE9bF5D2bD933eab5FB4ab8e0"},"protocol":{"type":"string","example":"x402 v2"}}}}}}}}}}},"/v1/batch":{"post":{"operationId":"query_batch","summary":"Multi-ticker bars — multiple tickers, one day ($0.02/ticker)","description":"Returns intraday bars for multiple tickers on a single date. No ticker limit. Price scales with number of tickers.","parameters":[{"name":"X-PAYMENT","in":"header","required":false,"description":"Base64-encoded x402 payment payload. On first request without this header, the server returns HTTP 402 with a `payment-required` header containing base64-encoded JSON payment terms (amount, receiver, network, asset). Sign the USDC transferWithAuthorization on Base and retry with this header.","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["tickers","date"],"properties":{"tickers":{"type":"array","items":{"type":"string"},"example":["AAPL","NVDA","MSFT"]},"date":{"type":"string","example":"2024-01-15"},"interval":{"type":"integer","enum":[3,6,9,12,15,30,60,240],"default":3}}}}}},"responses":{"200":{"description":"Intraday bars — absolute OHLC plus fractional change from the daily open on every bar. A `payment-response` header contains the base64-encoded settlement receipt with transaction hash.","headers":{"payment-response":{"description":"Base64 JSON: {x402Version, success, settlement: {transaction, network, payer}}","schema":{"type":"string"}}}},"402":{"description":"Payment required. Decode the `payment-required` response header (base64 JSON) for x402 v2 terms: amount, receiver, network, asset.","headers":{"payment-required":{"description":"Base64-encoded JSON: {x402Version, accepts: [{scheme, network, amount, payTo, asset, maxTimeoutSeconds, extra}]}","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string","example":"payment_required"},"message":{"type":"string"},"price":{"type":"string","example":"$0.025 USDC"},"payment_info":{"type":"object","properties":{"network":{"type":"string","example":"Base (eip155:8453)"},"asset":{"type":"string","example":"USDC"},"receiver":{"type":"string","example":"0xb40867B72334463eE9bF5D2bD933eab5FB4ab8e0"},"protocol":{"type":"string","example":"x402 v2"}}}}}}}}}}},"/v1/daily":{"post":{"operationId":"query_daily","summary":"Daily OHLCV bars — one ticker, date range ($0.001/year)","description":"Returns daily bars (one bar per trading day) across a date range. Extremely cheap for long histories — 20 years costs $0.02.","parameters":[{"name":"X-PAYMENT","in":"header","required":false,"description":"Base64-encoded x402 payment payload. On first request without this header, the server returns HTTP 402 with a `payment-required` header containing base64-encoded JSON payment terms (amount, receiver, network, asset). Sign the USDC transferWithAuthorization on Base and retry with this header.","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["ticker","start","end"],"properties":{"ticker":{"type":"string","example":"AAPL"},"start":{"type":"string","example":"2020-01-01"},"end":{"type":"string","example":"2024-12-31"},"adjusted":{"type":"boolean","default":false}}}}}},"responses":{"200":{"description":"Intraday bars — absolute OHLC plus fractional change from the daily open on every bar. A `payment-response` header contains the base64-encoded settlement receipt with transaction hash.","headers":{"payment-response":{"description":"Base64 JSON: {x402Version, success, settlement: {transaction, network, payer}}","schema":{"type":"string"}}}},"402":{"description":"Payment required. Decode the `payment-required` response header (base64 JSON) for x402 v2 terms: amount, receiver, network, asset.","headers":{"payment-required":{"description":"Base64-encoded JSON: {x402Version, accepts: [{scheme, network, amount, payTo, asset, maxTimeoutSeconds, extra}]}","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string","example":"payment_required"},"message":{"type":"string"},"price":{"type":"string","example":"$0.025 USDC"},"payment_info":{"type":"object","properties":{"network":{"type":"string","example":"Base (eip155:8453)"},"asset":{"type":"string","example":"USDC"},"receiver":{"type":"string","example":"0xb40867B72334463eE9bF5D2bD933eab5FB4ab8e0"},"protocol":{"type":"string","example":"x402 v2"}}}}}}}}}}},"/v1/bars":{"post":{"operationId":"query_bars","summary":"Custom timeframe bars — resampled intervals ($0.015/day)","description":"Returns OHLCV bars resampled to custom intervals (3m to 4h). Supports single date or date range.","parameters":[{"name":"X-PAYMENT","in":"header","required":false,"description":"Base64-encoded x402 payment payload. On first request without this header, the server returns HTTP 402 with a `payment-required` header containing base64-encoded JSON payment terms (amount, receiver, network, asset). Sign the USDC transferWithAuthorization on Base and retry with this header.","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["ticker","interval"],"properties":{"ticker":{"type":"string","example":"AAPL"},"interval":{"type":"integer","enum":[3,6,9,12,15,30,60,240],"description":"Bar interval in minutes"},"date":{"type":"string","example":"2024-01-15","description":"Single date (or use start/end)"},"start":{"type":"string","description":"Start date for multi-day"},"end":{"type":"string","description":"End date for multi-day"},"adjusted":{"type":"boolean","default":false}}}}}},"responses":{"200":{"description":"Intraday bars — absolute OHLC plus fractional change from the daily open on every bar. A `payment-response` header contains the base64-encoded settlement receipt with transaction hash.","headers":{"payment-response":{"description":"Base64 JSON: {x402Version, success, settlement: {transaction, network, payer}}","schema":{"type":"string"}}}},"402":{"description":"Payment required. Decode the `payment-required` response header (base64 JSON) for x402 v2 terms: amount, receiver, network, asset.","headers":{"payment-required":{"description":"Base64-encoded JSON: {x402Version, accepts: [{scheme, network, amount, payTo, asset, maxTimeoutSeconds, extra}]}","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string","example":"payment_required"},"message":{"type":"string"},"price":{"type":"string","example":"$0.025 USDC"},"payment_info":{"type":"object","properties":{"network":{"type":"string","example":"Base (eip155:8453)"},"asset":{"type":"string","example":"USDC"},"receiver":{"type":"string","example":"0xb40867B72334463eE9bF5D2bD933eab5FB4ab8e0"},"protocol":{"type":"string","example":"x402 v2"}}}}}}}}}}},"/v1/scan":{"post":{"operationId":"scan_market","summary":"Market scanner — find stocks matching criteria ($0.10)","description":"Scans all US stocks on a given date for custom criteria (gap%, change%, volume minimums). Returns matching tickers with stats.","parameters":[{"name":"X-PAYMENT","in":"header","required":false,"description":"Base64-encoded x402 payment payload. On first request without this header, the server returns HTTP 402 with a `payment-required` header containing base64-encoded JSON payment terms (amount, receiver, network, asset). Sign the USDC transferWithAuthorization on Base and retry with this header.","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["date"],"properties":{"date":{"type":"string","example":"2024-01-15","description":"Trading date to scan (YYYY-MM-DD)"},"gap_up_pct":{"type":"number","description":"Minimum gap up from prior close, in percent (5 = 5%)"},"gap_down_pct":{"type":"number","description":"Minimum gap down from prior close, in percent"},"change_pct_min":{"type":"number","description":"Minimum open-to-close change, in percent"},"change_pct_max":{"type":"number","description":"Maximum open-to-close change, in percent"},"volume_min":{"type":"integer","description":"Minimum total volume for the day"},"volume_ratio_min":{"type":"number","description":"Minimum volume vs prior day, e.g. 2.0 for 2x"},"transactions_min":{"type":"integer","description":"Minimum trade count"},"range_pct_min":{"type":"number","description":"Minimum intraday range (high-low)/open, in percent (5 = swung 5%+)"},"limit":{"type":"integer","default":50,"description":"Maximum matches to return"}}}}}},"responses":{"200":{"description":"Matching tickers with pct_change, range_pct, volume, transactions — plus pct_gap and true_range_pct when a gap or volume-ratio criterion was supplied. Criteria are in percent; outputs are fractional (0.05 = 5%)."},"402":{"description":"Payment required. Decode the `payment-required` response header (base64 JSON) for x402 v2 terms: amount, receiver, network, asset.","headers":{"payment-required":{"description":"Base64-encoded JSON: {x402Version, accepts: [{scheme, network, amount, payTo, asset, maxTimeoutSeconds, extra}]}","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string","example":"payment_required"},"message":{"type":"string"},"price":{"type":"string","example":"$0.025 USDC"},"payment_info":{"type":"object","properties":{"network":{"type":"string","example":"Base (eip155:8453)"},"asset":{"type":"string","example":"USDC"},"receiver":{"type":"string","example":"0xb40867B72334463eE9bF5D2bD933eab5FB4ab8e0"},"protocol":{"type":"string","example":"x402 v2"}}}}}}}}}}},"/v1/tickers":{"get":{"operationId":"list_tickers","summary":"List all tickers for a date ($0.005)","description":"Returns every US stock ticker that traded on a given date (7,000–16,000+ symbols).","parameters":[{"name":"X-PAYMENT","in":"header","required":false,"description":"Base64-encoded x402 payment payload. On first request without this header, the server returns HTTP 402 with a `payment-required` header containing base64-encoded JSON payment terms (amount, receiver, network, asset). Sign the USDC transferWithAuthorization on Base and retry with this header.","schema":{"type":"string"}},{"name":"date","in":"query","required":true,"schema":{"type":"string","example":"2024-01-15"},"description":"Trading date (YYYY-MM-DD)"}],"responses":{"200":{"description":"Array of ticker symbols"},"402":{"description":"Payment required. Decode the `payment-required` response header (base64 JSON) for x402 v2 terms: amount, receiver, network, asset.","headers":{"payment-required":{"description":"Base64-encoded JSON: {x402Version, accepts: [{scheme, network, amount, payTo, asset, maxTimeoutSeconds, extra}]}","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string","example":"payment_required"},"message":{"type":"string"},"price":{"type":"string","example":"$0.025 USDC"},"payment_info":{"type":"object","properties":{"network":{"type":"string","example":"Base (eip155:8453)"},"asset":{"type":"string","example":"USDC"},"receiver":{"type":"string","example":"0xb40867B72334463eE9bF5D2bD933eab5FB4ab8e0"},"protocol":{"type":"string","example":"x402 v2"}}}}}}}}}}},"/v1/company":{"get":{"operationId":"get_company","summary":"Company profile from SEC EDGAR ($0.005)","description":"Returns company name, CIK, SIC industry code, exchange, and fiscal year end from SEC EDGAR.","parameters":[{"name":"X-PAYMENT","in":"header","required":false,"description":"Base64-encoded x402 payment payload. On first request without this header, the server returns HTTP 402 with a `payment-required` header containing base64-encoded JSON payment terms (amount, receiver, network, asset). Sign the USDC transferWithAuthorization on Base and retry with this header.","schema":{"type":"string"}},{"name":"ticker","in":"query","required":true,"schema":{"type":"string","example":"AAPL"}}],"responses":{"200":{"description":"Company profile object"},"402":{"description":"Payment required. Decode the `payment-required` response header (base64 JSON) for x402 v2 terms: amount, receiver, network, asset.","headers":{"payment-required":{"description":"Base64-encoded JSON: {x402Version, accepts: [{scheme, network, amount, payTo, asset, maxTimeoutSeconds, extra}]}","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string","example":"payment_required"},"message":{"type":"string"},"price":{"type":"string","example":"$0.025 USDC"},"payment_info":{"type":"object","properties":{"network":{"type":"string","example":"Base (eip155:8453)"},"asset":{"type":"string","example":"USDC"},"receiver":{"type":"string","example":"0xb40867B72334463eE9bF5D2bD933eab5FB4ab8e0"},"protocol":{"type":"string","example":"x402 v2"}}}}}}}}}}},"/v1/fundamentals":{"post":{"operationId":"get_fundamentals","summary":"Quarterly financials from SEC EDGAR ($0.02)","description":"Returns quarterly financial data (revenue, EPS, net income, margins, cash, debt) from SEC EDGAR XBRL filings.","parameters":[{"name":"X-PAYMENT","in":"header","required":false,"description":"Base64-encoded x402 payment payload. On first request without this header, the server returns HTTP 402 with a `payment-required` header containing base64-encoded JSON payment terms (amount, receiver, network, asset). Sign the USDC transferWithAuthorization on Base and retry with this header.","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["ticker"],"properties":{"ticker":{"type":"string","example":"AAPL"}}}}}},"responses":{"200":{"description":"Quarterly financial data array"},"402":{"description":"Payment required. Decode the `payment-required` response header (base64 JSON) for x402 v2 terms: amount, receiver, network, asset.","headers":{"payment-required":{"description":"Base64-encoded JSON: {x402Version, accepts: [{scheme, network, amount, payTo, asset, maxTimeoutSeconds, extra}]}","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string","example":"payment_required"},"message":{"type":"string"},"price":{"type":"string","example":"$0.025 USDC"},"payment_info":{"type":"object","properties":{"network":{"type":"string","example":"Base (eip155:8453)"},"asset":{"type":"string","example":"USDC"},"receiver":{"type":"string","example":"0xb40867B72334463eE9bF5D2bD933eab5FB4ab8e0"},"protocol":{"type":"string","example":"x402 v2"}}}}}}}}}}},"/v1/insiders":{"post":{"operationId":"get_insiders","summary":"Insider transactions — SEC Form 4 ($0.02)","description":"Returns insider buy/sell transactions from SEC Form 4 filings.","parameters":[{"name":"X-PAYMENT","in":"header","required":false,"description":"Base64-encoded x402 payment payload. On first request without this header, the server returns HTTP 402 with a `payment-required` header containing base64-encoded JSON payment terms (amount, receiver, network, asset). Sign the USDC transferWithAuthorization on Base and retry with this header.","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["ticker"],"properties":{"ticker":{"type":"string","example":"AAPL"}}}}}},"responses":{"200":{"description":"Insider transaction array"},"402":{"description":"Payment required. Decode the `payment-required` response header (base64 JSON) for x402 v2 terms: amount, receiver, network, asset.","headers":{"payment-required":{"description":"Base64-encoded JSON: {x402Version, accepts: [{scheme, network, amount, payTo, asset, maxTimeoutSeconds, extra}]}","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string","example":"payment_required"},"message":{"type":"string"},"price":{"type":"string","example":"$0.025 USDC"},"payment_info":{"type":"object","properties":{"network":{"type":"string","example":"Base (eip155:8453)"},"asset":{"type":"string","example":"USDC"},"receiver":{"type":"string","example":"0xb40867B72334463eE9bF5D2bD933eab5FB4ab8e0"},"protocol":{"type":"string","example":"x402 v2"}}}}}}}}}}},"/v1/filings":{"post":{"operationId":"get_filings","summary":"SEC filings index + text extraction ($0.01–$0.05)","description":"Returns SEC filing index (10-K, 10-Q, 8-K, proxies). Pass `sections` to extract full text of risk_factors or mdna ($0.05).","parameters":[{"name":"X-PAYMENT","in":"header","required":false,"description":"Base64-encoded x402 payment payload. On first request without this header, the server returns HTTP 402 with a `payment-required` header containing base64-encoded JSON payment terms (amount, receiver, network, asset). Sign the USDC transferWithAuthorization on Base and retry with this header.","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["ticker"],"properties":{"ticker":{"type":"string","example":"AAPL"},"types":{"type":"array","items":{"type":"string"},"example":["10-K","10-Q"],"description":"Filing types to filter"},"sections":{"type":"array","items":{"type":"string"},"example":["risk_factors","mdna"],"description":"Extract section text (increases price to $0.05)"}}}}}},"responses":{"200":{"description":"Filing index or extracted section text"},"402":{"description":"Payment required. Decode the `payment-required` response header (base64 JSON) for x402 v2 terms: amount, receiver, network, asset.","headers":{"payment-required":{"description":"Base64-encoded JSON: {x402Version, accepts: [{scheme, network, amount, payTo, asset, maxTimeoutSeconds, extra}]}","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string","example":"payment_required"},"message":{"type":"string"},"price":{"type":"string","example":"$0.025 USDC"},"payment_info":{"type":"object","properties":{"network":{"type":"string","example":"Base (eip155:8453)"},"asset":{"type":"string","example":"USDC"},"receiver":{"type":"string","example":"0xb40867B72334463eE9bF5D2bD933eab5FB4ab8e0"},"protocol":{"type":"string","example":"x402 v2"}}}}}}}}}}},"/v1/brief":{"post":{"operationId":"get_brief","summary":"Full research brief — price + fundamentals + insiders ($0.25)","description":"Joined research brief combining price action, fundamentals, insider activity, and splits for one ticker. Replaces ~20 individual queries.","parameters":[{"name":"X-PAYMENT","in":"header","required":false,"description":"Base64-encoded x402 payment payload. On first request without this header, the server returns HTTP 402 with a `payment-required` header containing base64-encoded JSON payment terms (amount, receiver, network, asset). Sign the USDC transferWithAuthorization on Base and retry with this header.","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["ticker"],"properties":{"ticker":{"type":"string","example":"NVDA"},"lookback_days":{"type":"integer","default":30,"minimum":1,"maximum":365,"description":"Days of price history to include"}}}}}},"responses":{"200":{"description":"Combined research brief object"},"402":{"description":"Payment required. Decode the `payment-required` response header (base64 JSON) for x402 v2 terms: amount, receiver, network, asset.","headers":{"payment-required":{"description":"Base64-encoded JSON: {x402Version, accepts: [{scheme, network, amount, payTo, asset, maxTimeoutSeconds, extra}]}","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string","example":"payment_required"},"message":{"type":"string"},"price":{"type":"string","example":"$0.025 USDC"},"payment_info":{"type":"object","properties":{"network":{"type":"string","example":"Base (eip155:8453)"},"asset":{"type":"string","example":"USDC"},"receiver":{"type":"string","example":"0xb40867B72334463eE9bF5D2bD933eab5FB4ab8e0"},"protocol":{"type":"string","example":"x402 v2"}}}}}}}}}}},"/v1/pricing":{"get":{"operationId":"get_pricing","summary":"Pricing and coverage info (free)","description":"Returns all endpoint prices, data coverage details, and usage examples. No payment required.","responses":{"200":{"description":"Pricing information object"}}}},"/v1/stats":{"get":{"operationId":"get_stats","summary":"Platform statistics (free)","description":"Returns platform stats: total data volume, coverage dates, ticker counts.","responses":{"200":{"description":"Statistics object"}}}},"/health":{"get":{"operationId":"health_check","summary":"Health check (free)","responses":{"200":{"description":"OK"}}}}}}