# Options Analytics API > Price European and American options, solve implied volatility, compute Greeks and strategy payoffs, fit SVI surfaces, and measure realised volatility, skew, parity, expected move and open-interest max pain from caller-supplied quotes. Each paid operation uses a fixed USDC price on Base with the x402 exact scheme. Unpaid GET, HEAD, and POST return 402 payment terms (POST validates the body only after payment terms are satisfied). A request that carries payment-signature is not yet charged: settlement happens only after a successful (2xx) result. HTTP 4xx/5xx are not charged. Coverage bodies with status complete, partial, or failed all return HTTP 200 and are charged at the full listed price. Settled 2xx responses include a payment-response header; 4xx/5xx do not. Follow https://www.brainiac.software/agent-instructions.txt for install, payment pins, idempotency, and billing rules. - Product: https://www.brainiac.software/api/options-analytics - Docs: https://www.brainiac.software/api/options-analytics/docs - OpenAPI: https://www.brainiac.software/api/options-analytics/openapi.json - Contact: support@brainiac.software (https://www.brainiac.software/contact) ## Operations ### POST /api/v1/options-analytics/black-scholes-greeks $0.02 USDC. Price a European option with Black-Scholes-Merton and return delta, gamma, vega, theta, rho, vanna and charm from caller-supplied spot, strike, time, rate, dividend yield and volatility. Pure computation with a high-accuracy normal CDF. Inputs: type, spot, strike, timeYears, rate?, dividendYield?, sigma, greeks?, dayCount? Docs: https://www.brainiac.software/api/options-analytics/docs#options-analytics-black-scholes-greeks Example request: ```json { "type": "call", "spot": 49, "strike": 50, "timeYears": 0.384615, "rate": 0.05, "dividendYield": 0, "sigma": 0.2, "greeks": [ "delta", "gamma", "vega", "theta", "rho", "vanna", "charm" ] } ``` Example response: ```json { "price": 2.400526, "d1": 0.054181, "d2": -0.069854, "delta": 0.521605, "gamma": 0.065544, "vega": 12.105474, "vegaPer1Pct": 0.121055, "theta": -4.305331, "thetaPerDay": -0.011795, "rho": 8.906952, "vanna": 0.139133, "charm": -0.196758, "model": "BSM", "inputsUsed": { "type": "call", "spot": 49, "strike": 50, "timeYears": 0.384615, "rate": 0.05, "dividendYield": 0, "sigma": 0.2, "dayCount": "ACT/365" }, "sources": [ { "source": "Black-Scholes-Merton model (Black and Scholes 1973, Merton 1973); formulas as in Hull, Options, Futures and Other Deriv…", "url": "https://en.wikipedia.org/wiki/Black%E2%80%93Scholes_model", "retrievedAt": "2026-11-14", "status": "ok" } ], "limitations": [ "European exercise, constant volatility, rate and continuous dividend or borrow yield. Discrete dividends are not modell…", "Vega and rho are per 1.00 change in volatility and rate; vegaPer1Pct is per 0.01. Theta is per year and thetaPerDay div…", "…" ] } ``` ### POST /api/v1/options-analytics/implied-volatility-solve $0.04 USDC. Solve implied volatility for 1 to 500 option prices with Newton and Brent root-finding on Black-Scholes-Merton, or on a Cox-Ross-Rubinstein tree for American options. Prices outside the no-arbitrage bounds return a status instead of a number. Inputs: style?, spot, rate?, dividendYield?, options, treeSteps? Docs: https://www.brainiac.software/api/options-analytics/docs#options-analytics-implied-volatility-solve Example request: ```json { "style": "european", "spot": 42, "rate": 0.1, "dividendYield": 0, "options": [ { "id": "c40", "type": "call", "strike": 40, "timeYears": 0.5, "price": 4.76 } ], "treeSteps": 200 } ``` Example response: ```json { "results": [ { "id": "c40", "index": 0, "iv": 0.200066, "iterations": 4, "method": "newton", "status": "ok" } ], "model": "BSM", "inputsUsed": { "style": "european", "spot": 42, "rate": 0.1, "dividendYield": 0, "optionCount": 1 }, "sources": [ { "source": "Black-Scholes-Merton model (Black and Scholes 1973, Merton 1973); formulas as in Hull, Options, Futures and Other Deriv…", "url": "https://en.wikipedia.org/wiki/Black%E2%80%93Scholes_model", "retrievedAt": "2026-11-14", "status": "ok" } ], "limitations": [ "status is ok, below_intrinsic (price at or under the no-arbitrage lower bound), above_upper_bound (price at or over the…", "European implied volatility uses Newton steps from a Brenner-Subrahmanyam start with a Brent fallback on [1e-4, 5] when…", "…" ] } ``` ### POST /api/v1/options-analytics/american-binomial-price $0.04 USDC. Price an American or European option on a Cox-Ross-Rubinstein tree with optional discrete cash dividends (escrowed method), and return tree delta, gamma, theta, the early-exercise boundary and the Black-Scholes-Merton European value for comparison. Inputs: type, style?, spot, strike, timeYears, rate?, dividendYield?, sigma, steps?, dividends? Docs: https://www.brainiac.software/api/options-analytics/docs#options-analytics-american-binomial-price Example request: ```json { "type": "put", "style": "american", "spot": 50, "strike": 50, "timeYears": 0.416667, "rate": 0.1, "dividendYield": 0, "sigma": 0.4, "steps": 5, "dividends": [] } ``` Example response: ```json { "price": 4.48846, "europeanPrice": 4.075982, "delta": -0.41453, "gamma": 0.034146, "theta": -4.3039, "earlyExerciseBoundary": [ { "timeYears": 0.25, "criticalSpot": 35.361113 }, { "timeYears": 0.333334, "criticalSpot": 39.689347 } ], "steps": 5, "convergence": { "priceAtHalfSteps": null }, "model": "CRR", "inputsUsed": { "type": "put", "style": "american", "spot": 50, "strike": 50, "timeYears": 0.416667, "rate": 0.1, "dividendYield": 0, "sigma": 0.4, "steps": 5, "dividends": [] }, "sources": [ { "source": "Cox-Ross-Rubinstein binomial options pricing model (1979)", "url": "https://en.wikipedia.org/wiki/Binomial_options_pricing_model", "retrievedAt": "2026-11-14", "status": "ok" } ], "limitations": [ "Cox-Ross-Rubinstein tree: u = e^(σ√Δt), d = 1/u. Delta and gamma come from tree nodes at steps 1 and 2, theta is (V₂,₁ …", "Discrete cash dividends use the escrowed-dividend method: the tree is built on spot minus the present value of dividend…", "…" ] } ``` ### POST /api/v1/options-analytics/strategy-payoff $0.03 USDC. Compute payoff and profit or loss of a multi-leg option and stock position at expiry and at a valuation date, with exact breakevens, maximum profit and loss, and unlimited-risk flags. Inputs: spot, rate?, dividendYield?, multiplier?, valuationTimeYears?, legs, grid? Docs: https://www.brainiac.software/api/options-analytics/docs#options-analytics-strategy-payoff Example request: ```json { "spot": 100, "rate": 0.04, "dividendYield": 0, "multiplier": 100, "valuationTimeYears": 0, "legs": [ { "kind": "option", "type": "call", "strike": 100, "timeYears": 0.25, "qty": 1, "premium": 5.47, "sigma": 0.25 }, { "kind": "option", "type": "call", "strike": 110, "timeYears": 0.25, "qty": -1, "premium": 1.92, "sigma": 0.25 } ], "grid": { "from": 80, "to": 120, "step": 1 } } ``` Example response: ```json { "netPremium": -355, "breakevens": [ 103.55 ], "maxProfit": 645, "maxLoss": -355, "unlimitedProfit": false, "unlimitedLoss": false, "grid": [ { "spot": 80, "pnlAtExpiry": -355, "pnlAtValuation": -337.518626 }, { "spot": 81, "pnlAtExpiry": -355, "pnlAtValuation": -332.879352 }, "…" ], "model": "intrinsic at expiry", "inputsUsed": { "spot": 100, "rate": 0.04, "dividendYield": 0, "multiplier": 100, "valuationTimeYears": 0, "legCount": 2, "frontExpiryYears": 0.25 }, "sources": [ { "source": "Black-Scholes-Merton model (Black and Scholes 1973, Merton 1973); formulas as in Hull, Options, Futures and Other Deriv…", "url": "https://en.wikipedia.org/wiki/Black%E2%80%93Scholes_model", "retrievedAt": "2026-11-14", "status": "ok" } ], "limitations": [ "Expiry P/L = Σ (leg value − premium) × qty × multiplier. Option legs use the multiplier (default 100); stock legs are p…", "Breakevens and max profit/loss are exact on the piecewise-linear expiry payoff, evaluated at spot 0, each strike and th…", "…" ] } ``` ### POST /api/v1/options-analytics/probability-of-profit $0.02 USDC. Compute lognormal probabilities of finishing above or below levels, touching a level before expiry, and finishing in profit for a strategy given its breakevens, under risk-neutral or real-world drift. Inputs: spot, sigma, timeYears, rate?, dividendYield?, measure?, drift?, levels?, breakevens?, profitAbove?, profitBetween? Docs: https://www.brainiac.software/api/options-analytics/docs#options-analytics-probability-of-profit Example request: ```json { "spot": 100, "sigma": 0.25, "timeYears": 0.25, "rate": 0.04, "dividendYield": 0, "measure": "risk_neutral", "levels": [ 110 ], "breakevens": [ 103.55 ], "profitAbove": true } ``` Example response: ```json { "levels": [ { "level": 110, "pAbove": 0.228141, "pBelow": 0.771859, "pTouch": 0.45173 } ], "probabilityOfProfit": 0.396824, "model": "lognormal", "inputsUsed": { "spot": 100, "sigma": 0.25, "timeYears": 0.25, "measure": "risk_neutral", "driftUsed": 0.04, "rate": 0.04, "dividendYield": 0 }, "sources": [ { "source": "Lognormal (geometric Brownian motion) terminal and first-passage probabilities", "url": "https://en.wikipedia.org/wiki/Geometric_Brownian_motion", "retrievedAt": "2026-11-14", "status": "ok" } ], "limitations": [ "ln S_T ~ N(ln S + (m − σ²/2)T, σ²T) with m = rate − dividendYield (risk_neutral) or the supplied drift (real_world). Ri…", "pTouch is the exact first-passage probability of a Brownian motion with drift ν = m − σ²/2 and continuous monitoring; i…", "…" ] } ``` ### POST /api/v1/options-analytics/iv-rank-percentile $0.02 USDC. Compute IV rank and IV percentile of the current implied volatility against caller-supplied history over a trailing window of observations. Inputs: current, history, windowDays? Docs: https://www.brainiac.software/api/options-analytics/docs#options-analytics-iv-rank-percentile Example request: ```json { "current": 0.3, "history": [ { "date": "2026-05-01", "iv": 0.2 }, { "date": "2026-05-02", "iv": 0.25 }, { "date": "2026-05-03", "iv": 0.3 }, { "date": "2026-05-04", "iv": 0.35 }, { "date": "2026-05-05", "iv": 0.4 }, { "date": "2026-05-06", "iv": 0.22 }, { "date": "2026-05-07", "iv": 0.28 } ], "windowDays": 252 } ``` Example response: ```json { "ivRank": 0.5, "rankNote": null, "ivPercentile": 0.571429, "min": 0.2, "max": 0.4, "current": 0.3, "observations": 7, "window": { "from": "2026-05-01", "to": "2026-05-07" }, "model": "rank and percentile", "inputsUsed": { "windowDays": 252, "historyPoints": 7 }, "sources": [ { "source": "Caller-supplied option quotes, positions and history processed locally", "url": "https://www.brainiac.software/api/v1/options-analytics", "retrievedAt": "2026-11-14", "status": "ok" } ], "limitations": [ "IV rank = (current − min)/(max − min) over the window, clipped to [0, 1]; IV percentile = share of window observations …", "Outputs are standard-model calculations on caller-supplied inputs for human review. No market data is fetched, and this…", "…" ] } ``` ### POST /api/v1/options-analytics/historical-volatility $0.04 USDC. Compute close-to-close, Parkinson, Garman-Klass, Rogers-Satchell and Yang-Zhang realised volatility from OHLC bars, optionally excluding flagged days and returning a rolling series. Inputs: bars, estimators?, annualization?, window? Docs: https://www.brainiac.software/api/options-analytics/docs#options-analytics-historical-volatility Example request: ```json { "bars": [ { "date": "2026-10-01", "open": 100, "high": 101.2, "low": 99.4, "close": 100.9 }, { "date": "2026-10-02", "open": 100.8, "high": 101.5, "low": 99.9, "close": 100.3 }, { "date": "2026-10-03", "open": 100.2, "high": 100.9, "low": 99.1, "close": 99.7 }, { "date": "2026-10-04", "open": 99.6, "high": 102.6, "low": 99.2, "close": 102.3 }, { "date": "2026-10-05", "open": 102.4, "high": 103.8, "low": 101.7, "close": 103.2 } ], "estimators": [ "close_to_close", "parkinson", "garman_klass", "rogers_satchell", "yang_zhang" ], "annualization": 252 } ``` Example response: ```json { "close_to_close": 0.239708, "parkinson": 0.211121, "garman_klass": 0.21012, "rogers_satchell": 0.198717, "yang_zhang": 0.208377, "observations": 5, "excluded": 0, "rolling": null, "model": "realised volatility", "inputsUsed": { "barCount": 5, "estimators": [ "close_to_close", "parkinson", "…" ], "annualization": 252, "window": null }, "sources": [ { "source": "Realised volatility estimators: Parkinson (1980), Garman-Klass (1980), Rogers-Satchell (1991), Yang-Zhang (2000)", "url": "https://en.wikipedia.org/wiki/Volatility_(finance)", "retrievedAt": "2026-11-14", "status": "ok" } ], "limitations": [ "Close-to-close uses the sample standard deviation (n−1) of log returns. Parkinson, Garman-Klass and Rogers-Satchell ave…", "Bars flagged exclude are dropped together with the returns that touch them; an estimator is null when too few bars rema…", "…" ] } ``` ### POST /api/v1/options-analytics/volatility-surface-fit $0.05 USDC. Fit a raw-SVI slice per expiry to strike implied volatilities with the Zeliade quasi-explicit method, interpolate the surface in total variance, and report butterfly and calendar static-arbitrage violations. Inputs: forwardByExpiry, points, query? Docs: https://www.brainiac.software/api/options-analytics/docs#options-analytics-volatility-surface-fit Example request: ```json { "forwardByExpiry": { "0.5": 100 }, "points": [ { "timeYears": 0.5, "strike": 74.08, "iv": 0.654967 }, { "timeYears": 0.5, "strike": 81.87, "iv": 0.56823 }, { "timeYears": 0.5, "strike": 90.48, "iv": 0.474486 }, { "timeYears": 0.5, "strike": 100, "iv": 0.4 }, { "timeYears": 0.5, "strike": 110.52, "iv": 0.401419 }, { "timeYears": 0.5, "strike": 122.14, "iv": 0.441458 }, { "timeYears": 0.5, "strike": 134.99, "iv": 0.486808 } ], "query": [ { "timeYears": 0.5, "strike": 100 } ] } ``` Example response: ```json { "slices": [ { "timeYears": 0.5, "forward": 100, "params": { "a": 0.039964, "b": 0.400074, "rho": -0.400043, "m": -0.000048, "sigma": 0.100087 }, "rmseIv": 0.000005, "status": "ok", "butterflyArbitrage": [], "rawPoints": [ { "strike": 74.08, "iv": 0.654967 }, { "strike": 81.87, "iv": 0.56823 }, "…" ] } ], "calendarArbitrage": [], "query": [ { "timeYears": 0.5, "strike": 100, "iv": 0.399996 } ], "model": "raw SVI", "inputsUsed": { "pointCount": 7, "expiries": [ 0.5 ], "queryCount": 1 }, "sources": [ { "source": "Raw SVI (Gatheral 2004) with Zeliade quasi-explicit calibration (2009) and Gatheral-Jacquier static-arbitrage conditions", "url": "https://www.zeliade.com/whitepapers/zwp-0005.pdf", "retrievedAt": "2026-11-14", "status": "ok" } ], "limitations": [ "Raw SVI w(k) = a + b[ρ(k − m) + √((k − m)² + σ²)] on total variance, fitted per expiry by the Zeliade quasi-explicit me…", "Expiries with fewer than 5 distinct strikes return status insufficient_points and the raw points. A failed fit returns …", "…" ] } ``` ### POST /api/v1/options-analytics/put-call-parity-check $0.03 USDC. Infer the implied forward and carry from call and put quote pairs, solve the rate by least squares when omitted, and flag pairs whose bid and ask break the European or American parity band. Inputs: style?, spot, rate?, timeYears, pairs, toleranceAbs? Docs: https://www.brainiac.software/api/options-analytics/docs#options-analytics-put-call-parity-check Example request: ```json { "spot": 100, "rate": 0.05, "timeYears": 0.5, "pairs": [ { "strike": 100, "callBid": 5.9, "callAsk": 6.1, "putBid": 3.9, "putAsk": 4.1 } ], "toleranceAbs": 0.05 } ``` Example response: ```json { "impliedForward": 102.05063, "impliedCarry": 0.040598, "impliedRate": null, "pairs": [ { "strike": 100, "mid": { "call": 6, "put": 4 }, "forward": 102.05063, "residual": 0, "violation": false } ], "model": "european parity", "inputsUsed": { "style": "european", "spot": 100, "rate": 0.05, "timeYears": 0.5, "toleranceAbs": 0.05 }, "sources": [ { "source": "Black-Scholes-Merton model (Black and Scholes 1973, Merton 1973); formulas as in Hull, Options, Futures and Other Deriv…", "url": "https://en.wikipedia.org/wiki/Black%E2%80%93Scholes_model", "retrievedAt": "2026-11-14", "status": "ok" } ], "limitations": [ "Outputs are standard-model calculations on caller-supplied inputs for human review. No market data is fetched, and this…", "European parity C − P = e^(−rT)(F − K). Forward is the median of per-pair forwards from mid quotes; carry is ln(F/S)/T …" ] } ``` ### POST /api/v1/options-analytics/expected-move $0.02 USDC. Compute the one and two standard deviation expected move and price ranges from implied volatility or from the at-the-money straddle price. Inputs: spot, daysToExpiry, iv?, straddlePrice?, dayBasis? Docs: https://www.brainiac.software/api/options-analytics/docs#options-analytics-expected-move Example request: ```json { "spot": 100, "daysToExpiry": 30, "iv": 0.3, "dayBasis": 365 } ``` Example response: ```json { "oneSigma": 8.600733, "twoSigma": 17.201465, "range1": [ 91.399267, 108.600733 ], "range2": [ 82.798535, 117.201465 ], "method": "iv", "ivFromStraddle": null, "model": "normal approximation", "inputsUsed": { "spot": 100, "daysToExpiry": 30, "dayBasis": 365, "timeYears": 0.082192 }, "sources": [ { "source": "Black-Scholes-Merton model (Black and Scholes 1973, Merton 1973); formulas as in Hull, Options, Futures and Other Deriv…", "url": "https://en.wikipedia.org/wiki/Black%E2%80%93Scholes_model", "retrievedAt": "2026-11-14", "status": "ok" } ], "limitations": [ "From IV: move = S·σ·√(days/dayBasis). From a straddle: move ≈ straddle price (an at-the-money straddle ≈ 0.7979·S·σ√T, …", "Ranges are S ± move and S ± 2·move under a normal approximation; they are not probability-calibrated lognormal bounds a…", "…" ] } ``` ### POST /api/v1/options-analytics/skew-metrics $0.03 USDC. Compute 25-delta risk reversal, butterfly, skew slope and term-structure slope from strike and implied volatility quotes by expiry, with linear interpolation in log-moneyness and no extrapolation. Inputs: spot, rate?, dividendYield?, deltaConvention?, expiries Docs: https://www.brainiac.software/api/options-analytics/docs#options-analytics-skew-metrics Example request: ```json { "spot": 100, "rate": 0, "dividendYield": 0, "deltaConvention": "spot", "expiries": [ { "timeYears": 0.25, "points": [ { "strike": 90, "iv": 0.26 }, { "strike": 100, "iv": 0.24 }, { "strike": 110, "iv": 0.22 } ] } ] } ``` Example response: ```json { "expiries": [ { "timeYears": 0.25, "atmIv": 0.24, "call25dStrike": 108.479458, "call25dIv": 0.222921, "put25dStrike": 92.514363, "put25dIv": 0.25477, "riskReversal25": -0.031849, "butterfly25": -0.001155, "skewSlopePerLogMoneyness": -0.199165, "notes": [] } ], "termSlope": null, "model": "linear log-moneyness smile", "inputsUsed": { "spot": 100, "rate": 0, "dividendYield": 0, "deltaConvention": "spot", "expiryCount": 1 }, "sources": [ { "source": "Black-Scholes-Merton model (Black and Scholes 1973, Merton 1973); formulas as in Hull, Options, Futures and Other Deriv…", "url": "https://en.wikipedia.org/wiki/Black%E2%80%93Scholes_model", "retrievedAt": "2026-11-14", "status": "ok" } ], "limitations": [ "IV is interpolated linearly in log-moneyness ln(K/F) with F = S·e^((r−q)T); no extrapolation, so a 25-delta strike outs…", "The 25-delta strike solves BSM call delta = 0.25 and put delta = −0.25 by fixed-point iteration with the smile IV at th…", "…" ] } ``` ### POST /api/v1/options-analytics/position-greeks-aggregate $0.03 USDC. Aggregate share delta, dollar delta, gamma, vega, theta per day and beta-weighted delta across option and stock positions, computing Black-Scholes-Merton Greeks unless the caller supplies them. Inputs: benchmarkSpot, positions Docs: https://www.brainiac.software/api/options-analytics/docs#options-analytics-position-greeks-aggregate Example request: ```json { "benchmarkSpot": 500, "positions": [ { "underlying": "AAA", "spot": 49, "beta": 1.2, "kind": "option", "type": "call", "strike": 50, "timeYears": 0.384615, "rate": 0.05, "sigma": 0.2, "qty": 10, "multiplier": 100 }, { "underlying": "AAA", "spot": 49, "beta": 1.2, "kind": "stock", "qty": -300 } ] } ``` Example response: ```json { "byUnderlying": [ { "underlying": "AAA", "shareDelta": 221.604585, "dollarDelta": 10858.624684, "gamma": 65.544073, "vega": 12105.473954, "thetaPerDay": -11.795428 } ], "total": { "shareDelta": 221.604585, "dollarDelta": 10858.624684, "gamma": 65.544073, "vega": 12105.473954, "thetaPerDay": -11.795428, "betaWeightedDelta": 26.060699 }, "model": "BSM", "inputsUsed": { "benchmarkSpot": 500, "positionCount": 2 }, "sources": [ { "source": "Black-Scholes-Merton model (Black and Scholes 1973, Merton 1973); formulas as in Hull, Options, Futures and Other Deriv…", "url": "https://en.wikipedia.org/wiki/Black%E2%80%93Scholes_model", "retrievedAt": "2026-11-14", "status": "ok" } ], "limitations": [ "Share delta = Σ delta × qty × multiplier (stock delta 1, multiplier default 100 for options and 1 for stock). Dollar de…", "Gamma, vega and theta are summed × qty × multiplier. Option Greeks come from Black-Scholes-Merton unless the position s…", "…" ] } ``` ### POST /api/v1/options-analytics/covered-call-yield $0.02 USDC. Compute static and if-called returns, annualised returns, downside protection and breakeven for a covered call, or the return on collateral for a cash-secured put. Inputs: strategy, stockPrice?, strike, premium, daysToExpiry, dividendsBeforeExpiry?, commission? Docs: https://www.brainiac.software/api/options-analytics/docs#options-analytics-covered-call-yield Example request: ```json { "strategy": "covered_call", "stockPrice": 50, "strike": 55, "premium": 1.2, "daysToExpiry": 45, "dividendsBeforeExpiry": 0, "commission": 0 } ``` Example response: ```json { "strategy": "covered_call", "staticReturn": 0.02459, "ifCalledReturn": 0.127049, "staticAnnualized": 0.199454, "ifCalledAnnualized": 1.03051, "compoundAnnualized": 0.217794, "ifCalledCompoundAnnualized": 1.63824, "downsideProtection": 0.024, "breakeven": 48.8, "netDebit": 48.8, "collateral": null, "model": "static and if-called return", "inputsUsed": { "stockPrice": 50, "strike": 55, "premium": 1.2, "daysToExpiry": 45, "dividendsBeforeExpiry": 0, "commission": 0 }, "sources": [ { "source": "Caller-supplied option quotes, positions and history processed locally", "url": "https://www.brainiac.software/api/v1/options-analytics", "retrievedAt": "2026-11-14", "status": "ok" } ], "limitations": [ "Covered call: static = (premium + dividends − commission)/net debit; if called = (premium + dividends + strike − stock …", "Returns are per share before taxes, margin interest and assignment timing. Annualised figures are simple ×365/days; com…", "…" ] } ``` ### POST /api/v1/options-analytics/occ-symbol-parse $0.02 USDC. Parse or build OCC Options Symbology Initiative 21-character option symbols, validating the calendar date and flagging roots that look adjusted. Inputs: parse?, build? Docs: https://www.brainiac.software/api/options-analytics/docs#options-analytics-occ-symbol-parse Example request: ```json { "parse": [ "SPX 141122P01950000", "LAMR150117C00052500" ], "build": [ { "root": "AAPL", "expiry": "2027-01-15", "type": "call", "strike": 150 } ] } ``` Example response: ```json { "parsed": [ { "input": "SPX 141122P01950000", "root": "SPX", "expiry": "2014-11-22", "type": "put", "strike": 1950, "valid": true, "possiblyAdjusted": false }, { "input": "LAMR150117C00052500", "root": "LAMR", "expiry": "2015-01-17", "type": "call", "strike": 52.5, "valid": true, "possiblyAdjusted": false } ], "built": [ { "symbol": "AAPL 270115C00150000", "compact": "AAPL270115C00150000" } ], "model": "OCC OSI", "inputsUsed": { "parseCount": 2, "buildCount": 1 }, "sources": [ { "source": "OCC Options Symbology Initiative (OSI) 21-character option symbol, in force since 12 Feb 2010", "url": "https://www.theocc.com/", "retrievedAt": "2026-11-14", "status": "ok" } ], "limitations": [ "Format: root right-padded to 6 characters, expiry YYMMDD (20YY), C or P, strike × 1000 zero-padded to 8 digits. The sym…", "Roots ending in a digit (for example AAPL1) are parsed but flagged possiblyAdjusted: the deliverable of an adjusted con…", "…" ] } ``` ### POST /api/v1/options-analytics/max-pain-oi $0.02 USDC. Compute the max-pain strike, per-strike payout, put/call open-interest ratio and the highest open-interest call and put walls for one expiry from a supplied option chain. Inputs: multiplier?, chain, topWalls? Docs: https://www.brainiac.software/api/options-analytics/docs#options-analytics-max-pain-oi Example request: ```json { "multiplier": 100, "chain": [ { "strike": 90, "callOi": 100, "putOi": 500 }, { "strike": 95, "callOi": 300, "putOi": 400 }, { "strike": 100, "callOi": 800, "putOi": 700 }, { "strike": 105, "callOi": 600, "putOi": 200 }, { "strike": 110, "callOi": 900, "putOi": 50 } ], "topWalls": 3 } ``` Example response: ```json { "maxPain": 100, "painByStrike": [ { "strike": 90, "totalPayout": 1300000 }, { "strike": 95, "totalPayout": 675000 }, "…" ], "putCallOiRatio": 0.685185, "callWalls": [ 110, 100, "…" ], "putWalls": [ 100, 90, "…" ], "model": "max pain", "inputsUsed": { "multiplier": 100, "strikeCount": 5, "totalCallOi": 2700, "totalPutOi": 1850, "topWalls": 3 }, "sources": [ { "source": "Caller-supplied option quotes, positions and history processed locally", "url": "https://www.brainiac.software/api/v1/options-analytics", "retrievedAt": "2026-11-14", "status": "ok" } ], "limitations": [ "Payout at settlement X sums callOi × max(X − K, 0) + putOi × max(K − X, 0) over the chain times the multiplier; max pai…", "One expiry per call. Open interest is as supplied (usually previous-day), and max pain is a descriptive statistic, not …", "…" ] } ```